forked from shogun-toolbox/shogun
/
README.cmake
27 lines (19 loc) · 994 Bytes
/
README.cmake
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
# getting a list of possible interfaces to enable:
grep -E "OPTION.*(Modular|Static)" CMakeLists.txt
# setup cmake for developers (debugging symbols on, optimization off, etc.):
mkdir build-debug
cd build-debug
cmake -DCMAKE_BUILD_TYPE=Debug -DENABLE_TESTING=ON -DTRACE_MEMORY_ALLOCS=OFF -DPythonModular=ON -DCMAKE_INSTALL_PREFIX="$BUILDDIR/install" ..
# setup cmake for building the final binaries (debugging off, optimization on):
mkdir build-release
cd build-release
cmake -DCMAKE_BUILD_TYPE=Release -DENABLE_TESTING=ON -DCMAKE_INSTALL_PREFIX="$BUILDDIR/install" ..
# compile everything and install
make -j GoogleMock # only needed on first build: fetch and compile GoogleMock
make -j all # compiling everything
make -j install # install required for "make test"
make -j test # compile and run all tests and examples
# alternative build targets:
make -j shogun # only compiling libshogun
make -j shogun-unit-test # build unit test binary
make -j unit-tests # build and run unit tests