forked from anish-palakurthi/cloudsim_eec
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
34 lines (26 loc) · 627 Bytes
/
Copy pathMakefile
File metadata and controls
34 lines (26 loc) · 627 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# Compiler
CXX = g++
# Compiler flags
CXXFLAGS = -Wall -std=c++17
# Include directories
INCLUDES = -I.
# Source files
SRC = Init.cpp Machine.cpp main.cpp Scheduler.cpp Simulator.cpp Task.cpp VM.cpp
# Object files
OBJ = $(SRC:.cpp=.o)
# Executable
TARGET = simulator
# Default target
all: $(TARGET)
# Default target
scheduler: $(OBJ)
$(CXX) $(CXXFLAGS) $(INCLUDES) -o scheduler $(OBJ)
# Build target
$(TARGET): $(OBJ)
$(CXX) $(CXXFLAGS) $(INCLUDES) -o $(TARGET) $(OBJ)
# Compile source files into object files
%.o: %.cpp
$(CXX) $(CXXFLAGS) $(INCLUDES) -c $< -o $@
# Clean up build files
clean:
rm -f $(OBJ) $(TARGET)