-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
33 lines (21 loc) · 728 Bytes
/
Makefile
File metadata and controls
33 lines (21 loc) · 728 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
# Makefile
# target: dependencies
# action
# -c code to object file (.o), Compile and assemble, but do not link.
# -o Place the output into <file>
GDB = -g
THREADING = -pthread
INCLUDES = -I ./include
OBJECTS = ./build/genetic.o ./build/dynamic.o
all: ${OBJECTS} ./src/main.cpp
g++ ${GDB} ${INCLUDES} ${THREADING} ./src/main.cpp ${OBJECTS} -o ./bin/main
./build/genetic.o: ./src/genetic.cpp ./include/genetic.h ./include/loot.h
g++ ${GDB} ${INCLUDES} ./src/genetic.cpp -c -o ./build/genetic.o
./build/dynamic.o: ./src/dynamic.cpp ./include/dynamic.h ./include/loot.h
g++ ${GDB} ${INCLUDES} ./src/dynamic.cpp -c -o ./build/dynamic.o
clean:
rm -f build/*.o bin/main
run:
bin/main
debug:
gdb -tui bin/main