-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmake.sh
executable file
·58 lines (50 loc) · 1.31 KB
/
make.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
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
#!/bin/bash
while [[ $# > 0 ]]; do
key="$1"
case $key in
debug|Debug)
BUILD_TYPE=Debug
shift
;;
lcov|coverage)
BUILD_TYPE=Debug
USE_TEST_COVERAGE=ON
shift
;;
models|test-models)
ADD_MODELS_TESTS=TRUE
shift
;;
compatibility|test-compatibility)
ADD_COMPATIBILITY_TESTS=TRUE
shift
;;
hdf|test-hdf-models)
ADD_HDF_TESTS=TRUE
shift
;;
*)
shift
;;
esac
done
## Preserve PTHONPATH in order to avoid problems with Sphinx on Fedora26 because of Pigments in ParaView
export PYTHONPATH_OLD=$PYTHONPATH
source env.sh
if [[ ${OS_NAME} = Fedora26-64 ]]
then
export PYTHONPATH=$PYTHONPATH_OLD
fi
CMAKE_ARGS=""
CMAKE_ARGS="${CMAKE_ARGS} -DCMAKE_BUILD_TYPE=${BUILD_TYPE:-Release}"
CMAKE_ARGS="${CMAKE_ARGS} -DUSE_TEST_COVERAGE=${USE_TEST_COVERAGE:-OFF}"
CMAKE_ARGS="${CMAKE_ARGS} -DADD_MODELS_TESTS=${ADD_MODELS_TESTS:-FALSE}"
CMAKE_ARGS="${CMAKE_ARGS} -DADD_COMPATIBILITY_TESTS=${ADD_COMPATIBILITY_TESTS:-FALSE}"
CMAKE_ARGS="${CMAKE_ARGS} -DADD_HDF_TESTS=${ADD_HDF_TESTS:-FALSE}"
CMAKE_ARGS="${CMAKE_ARGS} -DCMAKE_INSTALL_PREFIX:PATH=${SHAPER_ROOT_DIR}"
CMAKE_ARGS="${CMAKE_ARGS} ${SOURCES_DIR}"
mkdir -p ${BUILD_DIR}
cd ${BUILD_DIR}
set -e
cmake -G "Unix Makefiles" ${CMAKE_ARGS}
make -j$(nproc) install