-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmakefile
More file actions
41 lines (33 loc) · 1.22 KB
/
makefile
File metadata and controls
41 lines (33 loc) · 1.22 KB
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
35
36
37
38
39
40
41
# define some Makefile variables for the compiler and compiler flags
# to use Makefile variables later in the Makefile: $()
CC = g++
CFLAGS = -g -Wall -Weffc++ -std=c++11
LFLAGS = -L/usr/lib
# All Targets
all: cTrace
# Tool invocations
# Executable "cTrace" depends on files.
cTrace: bin/main.o bin/Agent.o bin/Graph.o bin/Session.o bin/Tree.o
@echo 'Building target: cTrace'
@echo 'Invoking: C++ Linker'
$(CC) -o bin/cTrace bin/main.o bin/Agent.o bin/Graph.o bin/Session.o bin/Tree.o $(LFLAGS)
@echo 'Finished building target: cTrace'
@echo ' '
# Depends on the source and header files
bin/main.o: src/main.cpp
$(CC) $(CFLAGS) -c -Iinclude -o bin/main.o src/main.cpp
# Depends on the source and header files
bin/Agent.o: src/Agent.cpp
$(CC) $(CFLAGS) -c -Iinclude -o bin/Agent.o src/Agent.cpp
# Depends on the source and header files
bin/Graph.o: src/Graph.cpp
$(CC) $(CFLAGS) -c -Iinclude -o bin/Graph.o src/Graph.cpp
# Depends on the source and header files
bin/Session.o: src/Session.cpp
$(CC) $(CFLAGS) -c -Iinclude -o bin/Session.o src/Session.cpp
# Depends on the source and header files
bin/Tree.o: src/Tree.cpp
$(CC) $(CFLAGS) -c -Iinclude -o bin/Tree.o src/Tree.cpp
#Clean the build directory
clean:
rm -f bin/*