forked from borglab/gtsam
-
Notifications
You must be signed in to change notification settings - Fork 0
/
REBUILD_GTSAM.sh
executable file
·32 lines (22 loc) · 956 Bytes
/
REBUILD_GTSAM.sh
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
#!bin/bash
# Script to re-build gtsam with Python/MATLAB interface in GNU/Linux systems
# Note: this script assumes to be in the "gtsam" root folder and that GTSAM has been previously installed from source
buildpath="build"
if ! [ -d $buildpath ]; then
echo "ERROR: NO PREVIOUS BUILD FOUND! EXITING..." >&2
exit 1
else
cd build
# ADD check to see if in build else throw error
# Generate makefiles with verbose output log
cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo \
-DGTSAM_BUILD_UNSTABLE:OPTION=OFF -DGTSAM_BUILD_CONVENIENCE_LIBRARIES:OPTION=ON \
-DGTSAM_BUILD_PYTHON=OFF -DGTSAM_INSTALL_MATLAB_TOOLBOX=ON \
-DGTSAM_WITH_TBB=ON \
-DGTSAM_WITH_EIGEN_MKL=OFF \
-DCMAKE_VERBOSE_MAKEFILE=ON . |& tee CMAKE_OUTPUT_LOG.txt ..
# Build and install (system-wide)
sudo make check -j4 |& tee MAKE_CHECK_OUTPUT_LOG.txt
sudo make install -j4 |& tee MAKE_INSTALL_OUTPUT_LOG.txt
#make python-install -j4
fi