-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathMakefile
More file actions
80 lines (63 loc) · 2.09 KB
/
Makefile
File metadata and controls
80 lines (63 loc) · 2.09 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
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
# Designed to work on Linux/MacOS.
# Thanks to David Bommes for suggestions about how to compile on MacOS.
# Operating system dependent variables.
ifeq ($(shell uname -s), Linux)
CXX = g++-5
LIB_BOOST_PO = -lboost_program_options
else # uname = "Darwin" (i.e. MacOS)
CXX = clang++
LIB_BOOST_PO = -lboost_program_options-mt
endif
CXXFLAGS = -std=c++11 -g
TARGET = subvor
SRCS = $(wildcard *.cpp)
OBJS = ${SRCS:.cpp=.o}
DEPS = $(SRCS:.cpp=.depends)
INCLUDE=-lpng $(LIB_BOOST_PO) -L/usr/lib -lglut -lglui -lGLU -lGL
# Build commands.
all: $(TARGET)
$(TARGET): $(OBJS)
$(CXX) $(CXXFLAGS) $(OBJS) $(LDFLAGS) $(INCLUDE) -o $(TARGET)
.cpp.o:
$(CXX) $(CXXFLAGS) $(INCLUDE) -c $< -o $@
%.depends: %.cpp
$(CXX) -M $(CXXFLAGS) $< > $@
clean:
rm -f *~ *.o test_* benchmarks/*.pyc benchmarks/test_* $(TARGET)
# Test commands.
paper_figures:
make shapes
make random_examples
shapes:
./subvor benchmarks/shapes-1-1-1 --aeps=0.001 &
./subvor benchmarks/shapes-2-1-1 --aeps=0.001 &
./subvor benchmarks/shapes-4-1-1 --aeps=0.001 &
./subvor benchmarks/shapes-4-1-1 --geps=0.001 &
random_examples:
python benchmarks/gen_segs.py 20 -d 300
./subvor test_segs_d_300_20 &
./subvor test_segs_d_300_20 --geps=0.001 --grid=false &
python benchmarks/gen_mixed.py 10 10
./subvor test_mixed_10_pts_10_sgs --geps=0.001 --grid=false &
python benchmarks/gen_points.py 20 -m -l 10
./subvor test_m_l_10_20 --geps=0.001 --grid=false &
conics:
./subvor benchmarks/conics/ellipse &
./subvor benchmarks/conics/parabola &
./subvor benchmarks/conics/hyperbola &
conics_highres:
./subvor benchmarks/conics/ellipse --geps=0.001 &
./subvor benchmarks/conics/parabola --geps=0.001 &
./subvor benchmarks/conics/hyperbola --geps=0.001 &
rand_w_points_10:
python benchmarks/gen_points.py 10 -w
./subvor test_w_l_6_10 --aeps=0.001 &
rand_w_points_10_highres:
python benchmarks/gen_points.py 10 -w
./subvor test_w_l_6_10 --geps=0.001 &
rand_w_segs_10:
python benchmarks/gen_segs.py 10 -w
./subvor test_segs_w_l_6_10 --aeps=0.001 &
rand_w_segs_10_highres:
python benchmarks/gen_segs.py 10 -w
./subvor test_segs_w_l_6_10 --geps=0.001 &