forked from SuperElastix/SimpleElastix
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.travis.yml
63 lines (58 loc) · 2.69 KB
/
.travis.yml
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
language: cpp
env:
global:
EXTERNAL_DATA_DIR=${HOME}/build/.ExternalData
ITK_URL=https://github.com/InsightSoftwareConsortium/ITK
ITK_SOURCE_DIR=${HOME}/build/ITK-source
ITK_BUILD_DIR=${HOME}/build/ITK-build
ELASTIX_URL=https://github.com/SuperElastix/elastix
ELASTIX_SOURCE_DIR=${HOME}/build/Elastix-source
ELASTIX_BUILD_DIR=${HOME}/build/Elastix-build
SIMPLEELASTIX_SOURCE_DIR=${HOME}/build/SuperElastix/SimpleElastix/SuperBuild
SIMPLEELASTIX_BUILD_DIR=${HOME}/build/SimpleElastix-build
OMP_NUM_THREADS=2
cache:
directories:
- ${EXTERNAL_DATA_DIR}
- ${ITK_SOURCE_DIR}
- ${ITK_BUILD_DIR}
- ${ELASTIX_SOURCE_DIR}
- ${ELASTIX_BUILD_DIR}
matrix:
include:
- os: linux
compiler: clang
- os: linux
compiler: gcc
- os: osx
compiler: clang
- os: osx
compiler: gcc
before_script:
- mkdir -p ${SIMPLEELASTIX_BUILD_DIR}
- pwd
- ls -lR
script:
- if [[ ! -e ${ITK_BUILD_DIR}/ITKConfig.cmake ]]; then
rm -rf ${ITK_SOURCE_DIR} {ITK_BUILD_DIR} &&
git clone ${ITK_URL} ${ITK_SOURCE_DIR} &&
cd ${ITK_SOURCE_DIR} &&
git checkout v4.11.1 &&
mkdir -p ${ITK_BUILD_DIR} &&
cd ${ITK_BUILD_DIR} &&
cmake -DBUILD_EXAMPLES=OFF -DBUILD_TESTING=OFF -DCMAKE_BUILD_TYPE=Release -DCMAKE_POSITION_INDEPENDENT_CODE:BOOL=ON -DCMAKE_VISIBILITY_INLINES_HIDDEN:BOOL=ON -DBUILD_SHARED_LIBS:BOOL=OFF -DCMAKE_SKIP_RPATH:BOOL=ON -DITK_LEGACY_REMOVE:BOOL=ON -DITK_USE_KWSTYLE:BOOL=OFF -DITK_BUILD_DEFAULT_MODULES:BOOL=ON -DModule_ITKReview:BOOL=ON ${ITK_SOURCE_DIR} &&
make --jobs=4; fi
- if [[ ! -e ${ELASTIX_BUILD_DIR}/src/UseElastix.cmake ]]; then
rm -rf ${ELASTIX_SOURCE_DIR} ${ELASTIX_BUILD_DIR} &&
git clone ${ELASTIX_URL} ${ELASTIX_SOURCE_DIR} &&
cd ${ELASTIX_SOURCE_DIR} &&
git checkout e8354222396c6bd78e9fe6d5a39e4ecac4bb0d52 &&
mkdir -p ${ELASTIX_BUILD_DIR} &&
cd ${ELASTIX_BUILD_DIR} &&
cmake -DBUILD_TESTING:BOOL=OFF -DELASTIX_BUILD_EXECUTABLE:BOOL=OFF -DITK_DIR=${ITK_BUILD_DIR} -DCMAKE_BUILD_TYPE=Release ${ELASTIX_SOURCE_DIR} &&
make --jobs=4 &&
touch ${HOME}/built_cache; fi
- cd ${SIMPLEELASTIX_BUILD_DIR}
- if [[ ! -e ${HOME}/built_cache ]]; then
cmake -DWRAP_LUA:BOOL=OFF -DWRAP_PYTHON:BOOL=OFF -DWRAP_JAVA:BOOL=OFF -DWRAP_CSHARP:BOOL=OFF -DWRAP_TCL:BOOL=OFF -DWRAP_R:BOOL=OFF -DWRAP_RUBY:BOOL=OFF -DBUILD_EXAMPLES:BOOL=ON -DBUILD_TESTING:BOOL=OFF -DCMAKE_CXX_FLAGS=-w -DCMAKE_C_FLAGS=-w -DCMAKE_BUILD_TYPE=Release -DSimpleITK_USE_SYSTEM_ITK:BOOL=ON -DITK_DIR=${ITK_BUILD_DIR} -DSimpleITK_USE_SYSTEM_ELASTIX:BOOL=ON -DELASTIX_DIR=${ELASTIX_BUILD_DIR} -DSimpleITK_4D_IMAGES:BOOL=OFF ${SIMPLEELASTIX_SOURCE_DIR} &&
make --jobs=4; fi