-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
124 lines (103 loc) · 4.67 KB
/
Makefile
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
CC = gcc
#CHANGEME: Wherever you installed Gaul, this should point to that location.
#Malleo's version:
#GAUL_BASE = /usr/local
#MMTrebuchet's version:
GAUL_BASE = /home/pi/gaul-install
GAUL_FLAGS = -L${GAUL_BASE}/lib -I${GAUL_BASE}/include
CFLAGS = -g -O3 -Wall -Wextra
CLIBS = -lm
GAUL_LIBS = -lgaul -lgaul_util
GAUL_THREADS = 4
OBJ_DIR = obj
SRC_DIR = src
test_simulation: ${OBJ_DIR}/run_simulation.o ${OBJ_DIR}/plane_physics.o ${SRC_DIR}/test_simulation.c
${CC} ${CFLAGS} -o$@ $^ ${CLIBS}
${OBJ_DIR}/run_simulation.o: ${SRC_DIR}/run_simulation.c ${SRC_DIR}/run_simulation.h ${SRC_DIR}/plane_physics.h ${OBJ_DIR}/plane_physics.o
${CC} ${CFLAGS} -c -o$@ ${SRC_DIR}/run_simulation.c ${CLIBS}
${OBJ_DIR}/plane_physics.o: ${SRC_DIR}/plane_physics.h ${SRC_DIR}/plane_physics.c
${CC} ${CFLAGS} -c -o$@ ${SRC_DIR}/plane_physics.c ${CLIBS}
${OBJ_DIR}/run_ga.o: ${SRC_DIR}/run_ga.c ${SRC_DIR}/run_ga.h ${OBJ_DIR}/run_simulation.o ${OBJ_DIR}/plane_physics.o ${SRC_DIR}/boring_callbacks.c ${SRC_DIR}/mixing_callbacks.c ${SRC_DIR}/mutate_callbacks.c ${SRC_DIR}/util_callbacks.c
${CC} ${CFLAGS} ${GAUL_FLAGS} -c -o$@ ${SRC_DIR}/run_ga.c ${CLIBS} ${GAUL_LIBS}
ga_main: ${SRC_DIR}/ga_main.c ${OBJ_DIR}/run_ga.o ${OBJ_DIR}/run_simulation.o ${OBJ_DIR}/plane_physics.o
${CC} ${CFLAGS} ${GAUL_FLAGS} -o$@ $^ ${CLIBS} ${GAUL_LIBS}
simulate_single: ${SRC_DIR}/simulate_single.c ${OBJ_DIR}/run_simulation.o ${OBJ_DIR}/plane_physics.o ${SRC_DIR}/run_simulation.h ${SRC_DIR}/plane_physics.h
${CC} ${CFLAGS} -o$@ ${SRC_DIR}/simulate_single.c ${OBJ_DIR}/run_simulation.o ${OBJ_DIR}/plane_physics.o ${CLIBS}
# Prologue
tyd_east_room: ga_main playerdats/tyd_east_room.dat
LD_LIBRARY_PATH=${GAUL_BASE}/lib GAUL_NUM_THREADS=${GAUL_THREADS} ./ga_main \
--player-dat=playerdats/tyd_east_room.dat \
--output-file=SimRes_tyd_east_room.txt \
--pop-size=3000 \
--max-frames=125 \
--num-generations=200000
tyd_east_room_no_yellow_block: ga_main playerdats/tyd_east_room_no_yellow_block.dat
LD_LIBRARY_PATH=${GAUL_BASE}/lib GAUL_NUM_THREADS=${GAUL_THREADS} ./ga_main \
--player-dat=playerdats/tyd_east_room_no_yellow_block.dat \
--output-file=SimRes_tyd_east_room_no_yellow_block.txt \
--pop-size=3000 \
--max-frames=125 \
--num-generations=200000
tyd_east_room_tas: ga_main playerdats/tyd_east_room_tas.dat
LD_LIBRARY_PATH=${GAUL_BASE}/lib GAUL_NUM_THREADS=${GAUL_THREADS} ./ga_main \
--player-dat=playerdats/tyd_east_room_tas.dat \
--output-file=SimRes_tyd_east_room_tas.txt \
--pop-size=3000 \
--max-frames=125 \
--num-generations=200000
blooper: ga_main playerdats/blooper.dat
LD_LIBRARY_PATH=${GAUL_BASE}/lib GAUL_NUM_THREADS=${GAUL_THREADS} ./ga_main \
--player-dat=playerdats/blooper.dat \
--output-file=simRes_blooper.txt \
--pop-size=3000 \
--max-frames=100 \
--num-generations=1000
flurrie_unraised: ga_main playerdats/flurrie_unraised.dat
LD_LIBRARY_PATH=${GAUL_BASE}/lib GAUL_NUM_THREADS=${GAUL_THREADS} ./ga_main \
--player-dat=playerdats/flurrie_unraised.dat \
--output-file=simRes_flurrie_unraised.txt \
--pop-size=1500 \
--max-frames=450 \
--num-generations=50000
flurrie_raised: ga_main playerdats/flurrie_raised.dat
LD_LIBRARY_PATH=${GAUL_BASE}/lib GAUL_NUM_THREADS=${GAUL_THREADS} ./ga_main \
--player-dat=playerdats/flurrie_raised.dat \
--output-file=simRes_flurrie_raised.txt \
--pop-size=3000 \
--max-frames=250 \
--num-generations=50000
glitzville: ga_main playerdats/glitzville.dat
LD_LIBRARY_PATH=${GAUL_BASE}/lib GAUL_NUM_THREADS=${GAUL_THREADS} ./ga_main \
--player-dat=playerdats/glitzville.dat \
--output-file=simRes_glitzville.txt \
--pop-size=2000 \
--max-frames=340 \
--num-generations=200000
gloomtail: ga_main playerdats/gloomtail.dat
LD_LIBRARY_PATH=${GAUL_BASE}/lib GAUL_NUM_THREADS=${GAUL_THREADS} ./ga_main \
--player-dat=playerdats/gloomtail.dat \
--output-file=simRes_gloomtail.txt \
--pop-size=3000 \
--max-frames=900 \
--num-generations=100000
grodus: ga_main playerdats/grodus.dat
LD_LIBRARY_PATH=${GAUL_BASE}/lib GAUL_NUM_THREADS=${GAUL_THREADS} ./ga_main \
--player-dat=playerdats/grodus.dat \
--output-file=simRes_grodus.txt \
--pop-size=2000 \
--max-frames=300 \
--num-generations=10000
plane_game: ga_main playerdats/plane_game.dat
LD_LIBRARY_PATH=${GAUL_BASE}/lib GAUL_NUM_THREADS=${GAUL_THREADS} ./ga_main \
--player-dat=playerdats/plane_game.dat \
--output-file=test_plane_game.txt \
--pop-size=1000 \
--max-frames=1500 \
--num-generations=2000
blooper_tall: ga_main playerdats/blooper_tall.dat
LD_LIBRARY_PATH=${GAUL_BASE}/lib GAUL_NUM_THREADS=${GAUL_THREADS} ./ga_main \
--player-dat=playerdats/blooper_tall.dat \
--output-file=simRes_blooper_tall.txt \
--pop-size=1000 \
--max-frames=200 \
--num-generations=1000