-
Notifications
You must be signed in to change notification settings - Fork 1
/
makefile
41 lines (22 loc) · 890 Bytes
/
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
SRCS=$(wildcard *.cpp)
BINS=$(SRCS:.cpp=)
CXX = g++
CXXFLAGS = $(shell pkg-config --cflags ibex)
LIBS = $(shell pkg-config --libs ibex)
ifeq ($(DEBUG), yes)
CXXFLAGS := $(CXXFLAGS) -O0 -g -pg -Wall
else
CXXFLAGS := $(CXXFLAGS) -std=c++11
endif
collision-avoidance: collision-avoidance.o functions.o interval_tools.o vibes.o
$(CXX) $^ -o collision-avoidance $(CXXFLAGS) $(LIBS)
vibes.o: vibes.h vibes.cpp
$(CXX) vibes.cpp -c $(CXXFLAGS) $(LIBS)
interval_tools.o: interval_tools.h vibes.h interval_tools.cpp
$(CXX) interval_tools.cpp -c $(CXXFLAGS) $(LIBS)
functions.o: functions.h interval_tools.h vibes.h functions.cpp
$(CXX) functions.cpp -c $(CXXFLAGS) $(LIBS)
collision-avoidance.o: functions.h vibes.h interval_tools.h json.hpp collision-avoidance.cpp
$(CXX) collision-avoidance.cpp -c $(CXXFLAGS) $(LIBS)
clean:
rm -rf *.bak rm -rf *.o collision-avoidance