forked from iitmcvg/eye-gaze
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
83 lines (60 loc) · 2.54 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
# Makefile for Project Timeline
#
# Your compiler
CXX = g++
# Compilation flags
# '-g' turns debugging flags on.
# Not Using O2 flag for optimisation.
CXXFLAGS = -g -I./include -I./src/dlib/all/source.cpp -ljpeg -mavx -lm -lGL -lglut -lGLU -lpthread -lX11 -DDLIB_HAVE_BLAS -DNDEBUG -DDLIB_JPEG_SUPPORT -DDLIB_HAVE_AVX -O3 `pkg-config --cflags opencv`
# Linker flags
# When you need to add a library
LDFLAGS = -ljpeg -mavx -lm -lGL -lglut -lGLU -lpthread -lX11 `pkg-config --libs opencv` -DDLIB_HAVE_BLAS -DNDEBUG -DDLIB_JPEG_SUPPORT -DDLIB_HAVE_AVX -O3
# all is a target
# $(VAR) gives value of the variable.
# $@ stores the target
# $^ stores the dependency
all: bin/oic bin/facegesmatch bin/facegescreate bin/facegeslisten
bin/oic: obj/dlib.o obj/faceDetection.o obj/pupilDetection.o obj/kalmanFilters.o obj/util.o obj/kmeansUtils.o obj/pupilCdf.o obj/gazeComputation.o obj/oic.o
$(CXX) -o $@ $^ $(LDFLAGS)
bin/facegescreate: obj/dlib.o obj/faceDetection.o obj/util.o obj/gestureDetection.o obj/facegescreate.o
$(CXX) -o $@ $^ $(LDFLAGS)
bin/facegesmatch: obj/dlib.o obj/faceDetection.o obj/util.o obj/gestureDetection.o obj/facegesmatch.o
$(CXX) -o $@ $^ $(LDFLAGS)
bin/facegeslisten: obj/dlib.o obj/faceDetection.o obj/gestureDetection.o obj/util.o obj/facegeslisten.o
$(CXX) -o $@ $^ $(LDFLAGS)
obj/dlib.o: src/dlib/all/source.cpp
mkdir -p obj bin
$(CXX) -c $(CXXFLAGS) -o $@ $<
obj/faceDetection.o: src/faceDetection.cpp
$(CXX) -c $(CXXFLAGS) -o $@ $<
obj/pupilDetection.o: src/pupilDetection.cpp
$(CXX) -c $(CXXFLAGS) -o $@ $<
obj/kalmanFilters.o: src/kalmanFilters.cpp
$(CXX) -c $(CXXFLAGS) -o $@ $<
obj/util.o: src/util.cpp
$(CXX) -c $(CXXFLAGS) -o $@ $<
obj/kmeansUtils.o: src/kmeansUtils.cpp
$(CXX) -c $(CXXFLAGS) -o $@ $<
#obj/viewUtils.o: src/viewUtils.cpp
# $(CXX) -c $(CXXFLAGS) -o $@ $<
obj/oic.o: src/oic.cpp
$(CXX) -c $(CXXFLAGS) -o $@ $<
obj/facegesmatch.o: src/facegesMatch.cpp
$(CXX) -c $(CXXFLAGS) -o $@ $<
obj/facegescreate.o: src/facegesCreate.cpp
$(CXX) -c $(CXXFLAGS) -o $@ $<
obj/facegeslisten.o: src/facegesListen.cpp
$(CXX) -c $(CXXFLAGS) -o $@ $<
obj/gestureDetection.o: src/gestureDetection.cpp
$(CXX) -c $(CXXFLAGS) -o $@ $<
obj/pupilCdf.o: src/pupilCdf.cpp
$(CXX) -c $(CXXFLAGS) -o $@ $<
obj/gazeComputation.o: src/gazeComputation.cpp
$(CXX) -c $(CXXFLAGS) -o $@ $<
# .PHONY tells make that 'all' or 'clean' aren't _actually_ files, and always
# execute the compilation action when 'make all' or 'make clean' are used
.PHONY: all oic
# Delete all the temporary files we've created so far
clean:
rm -rf obj/*.o
rm -rf bin/oic