This repository has been archived by the owner on Jun 15, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 149
/
.travis.yml
65 lines (60 loc) · 3.05 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
64
65
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:
- sudo apt-get remove cmake && sudo apt-get install swig lua5.3 libinsighttoolkit4-dev doxygen graphviz
- cd ${ExternalData_OBJECT_STORES} && if [[ ! -e ${CMAKE_DOWNLOAD_FILE} ]]; then curl -sSO https://cmake.org/files/v3.6/${CMAKE_DOWNLOAD_FILE}; fi
- echo "y\n" | sudo bash "${ExternalData_OBJECT_STORES}/${CMAKE_DOWNLOAD_FILE}" --prefix=/usr/local --exclude-subdir
- cmake --version
- mkdir -p ${SIMPLEITK_BUILD_DIR}
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}/ElastixConfig.cmake ]]; then
rm -rf ${ELASTIX_SOURCE_DIR} ${ELASTIX_BUILD_DIR} &&
git clone ${ELASTIX_URL} ${ELASTIX_SOURCE_DIR} &&
cd ${ELASTIX_SOURCE_DIR} &&
git checkout 6472fc81721725d37eb0f147aeda635ce42a3bb4 &&
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