-
Notifications
You must be signed in to change notification settings - Fork 2
/
azure-pipelines.yml
179 lines (136 loc) · 4.87 KB
/
azure-pipelines.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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
trigger:
batch: true
branches:
include:
- master
resources:
containers:
- container: ubuntu1404
image: mardy/qt:trusty-qt512
jobs:
- job: 'WindowsBuild'
displayName: "End-to-end Windows build & testing"
timeoutInMinutes: 0
cancelTimeoutInMinutes: 300
pool:
vmImage: 'vs2017-win2016'
steps:
- script: |
choco install doxygen.install cmake git
displayName: 'Install dependencies'
#- script: |
# python -m pip install sphinx breathe sphinx_rtd_theme
# displayName: 'Installing Sphinx and related stuff'
- script: |
mkdir bin
cd bin
call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x64
cmake -DBUILD_DOCUMENTATION=OFF -DCMAKE_GENERATOR_PLATFORM=x64 -DCMAKE_INSTALL_PREFIX="./install" ..
setx PATH "%PATH%;$(Build.SourcesDirectory)/bin/qt/5.12.1/bin"
cmake --build . --target ALL_BUILD --config Release
displayName: 'Configure and compile Superbuild'
- script: |
cd bin
call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x64
cmake -DBUILD_DOCUMENTATION=OFF -DBUILD_TESTING=ON -DCMAKE_GENERATOR_PLATFORM=x64 -DCMAKE_INSTALL_PREFIX="./install" -DCAPTK_DISABLE_CWL=ON ..
setx PATH "%PATH%;$(Build.SourcesDirectory)/bin/qt/5.12.1/bin"
cmake --build . --target ALL_BUILD --config Release
displayName: 'Configure and compile CBICA_Toolkit'
- script: |
cd bin
cmake --build . --target RUN_TESTS --config Release
displayName: 'Running Tests'
- job: 'XenialBuild'
displayName: "End-to-end Linux (Xenial) build"
timeoutInMinutes: 0
cancelTimeoutInMinutes: 300
pool:
vmImage: 'Ubuntu-16.04'
steps:
# Dependency manager
- bash: |
sudo apt-get update && sudo apt-get install -qq gcc g++ make libgl-dev cmake python3-pip python-numpy dos2unix libxkbcommon-x11-0 doxygen
displayName: 'Install dependencies from Aptitude'
#- script: |
# python -m pip install sphinx breathe sphinx_rtd_theme
# displayName: 'Installing Sphinx and related stuff'
# Create build dir
- bash: |
mkdir -p bin
displayName: 'Create build directory'
# Configure and build superbuild
- bash: |
cd bin
cmake -DBUILD_DOCUMENTATION=OFF ..
make -j2
displayName: 'Configure and compile Superbuild'
# Configure and build CaPTk
- bash: |
cd bin
cmake -DBUILD_DOCUMENTATION=OFF -DBUILD_TESTING=ON ..
make -j2
#make install/strip
displayName: 'Configure and compile CBICA_Toolkit'
# Check qt
- bash: |
cd bin
make test
displayName: 'Running Tests'
- job: 'MacOSBuild'
displayName: "End-to-end MacOS build & testing"
timeoutInMinutes: 0
cancelTimeoutInMinutes: 300
pool:
vmImage: 'MacOS-10.14'
steps:
- bash: |
brew install make doxygen llvm
displayName: 'Brew dependencies'
#- script: |
# python -m pip install sphinx breathe sphinx_rtd_theme
# displayName: 'Installing Sphinx and related stuff'
- bash: |
export CC=""
export CXX=""
export LDFLAGS=""
export CPPFLAGS=""
# git lfs install && git lfs fetch --all
export CMAKE_INSTALL_RPATH_USE_LINK_PATH=TRUE
export CMAKE_PREFIX_PATH="/Library/TeX/texbin"
displayName: 'Export variables'
- bash: |
mkdir bin
displayName: 'Create build directory'
- bash: |
cd bin
cmake -DBUILD_DOCUMENTATION=OFF ../ -DCMAKE_INSTALL_PREFIX="./install"
cmake -DBUILD_DOCUMENTATION=OFF ../ -DCMAKE_INSTALL_PREFIX="./install"
make -j2
displayName: 'Configure and compile Superbuild'
- bash: |
cd bin
rm CMakeCache.txt
export CC=/usr/local/opt/llvm/bin/clang
export CXX=/usr/local/opt/llvm/bin/clang++
export LDFLAGS="-L/usr/local/opt/llvm/lib"
export CPPFLAGS="-L/usr/local/opt/llvm/include"
cmake -DBUILD_DOCUMENTATION=OFF -DBUILD_TESTING=ON ../
cmake -DBUILD_DOCUMENTATION=OFF -DBUILD_TESTING=ON ../
make -j 2
displayName: 'Export variables for llvm then Configure and compile CBICA_Toolkit'
- bash: |
cd bin
rm CMakeCache.txt
export CC=/usr/local/opt/llvm/bin/clang
export CXX=/usr/local/opt/llvm/bin/clang++
export LDFLAGS="-L/usr/local/opt/llvm/lib"
export CPPFLAGS="-L/usr/local/opt/llvm/include"
cmake -DBUILD_DOCUMENTATION=OFF -DBUILD_TESTING=ON ../
cmake -DBUILD_DOCUMENTATION=OFF -DBUILD_TESTING=ON ../
make -j 2
make -j 2
displayName: 'Ensure documentations are picked up properly'
- bash: |
cd bin
make test
displayName: 'Running Tests'