forked from rpng/open_vins
-
Notifications
You must be signed in to change notification settings - Fork 7
/
Makefile
42 lines (35 loc) · 1.2 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
nproc=$(shell python3 -c 'import multiprocessing; print( max(multiprocessing.cpu_count() - 1, 1))')
use_integ=$(ILLIXR_INTEGRATION)
CXX := clang++-10
CC := clang-10
.PHONY: dbg plugin.dbg.so
plugin.dbg.so: dbg
dbg: build/Debug/Makefile
make -C build/Debug "-j$(nproc)" && \
rm -f [email protected] && \
ln -s build/Debug/ov_msckf/libslam2.so [email protected] && \
true
.PHONY: opt plugin.opt.so
plugin.opt.so: opt
opt: build/RelWithDebInfo/Makefile
make -C build/RelWithDebInfo "-j$(nproc)" && \
rm -f [email protected] && \
ln -s build/RelWithDebInfo/ov_msckf/libslam2.so [email protected] && \
true
build/Debug/Makefile:
mkdir -p build/Debug && \
cd build/Debug && \
echo "Using ILLIXR_INTEGRATION: $(use_integ)" && \
cmake -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_COMPILER=$(CXX) -DCMAKE_C_COMPILER=$(CC) -DILLIXR_INTEGRATION=$(use_integ) ../.. && \
true
build/RelWithDebInfo/Makefile:
mkdir -p build/RelWithDebInfo && \
cd build/RelWithDebInfo && \
echo "Using ILLIXR_INTEGRATION: $(use_integ)" && \
cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_CXX_COMPILER=$(CXX) -DCMAKE_C_COMPILER=$(CC) -DILLIXR_INTEGRATION=$(use_integ) ../.. && \
true
tests/run:
tests/gdb:
.PHONY: clean
clean:
touch build && rm -rf build *.so