-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathJenkinsfile
118 lines (118 loc) · 5.32 KB
/
Jenkinsfile
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
pipeline {
agent none
stages {
stage('Parallel Stages') {
parallel {
stage('linux') {
agent {
docker {
label 'docker'
image 'aimagelab/ecvl:latest'
}
}
stages {
stage('Build') {
steps {
timeout(60) {
echo 'Building..'
cmakeBuild buildDir: 'build', buildType: 'Release', cmakeArgs: '-DECVL_TESTS=ON -DECVL_BUILD_EDDL=ON -DECVL_DATASET=ON -DECVL_WITH_DICOM=ON -DECVL_WITH_OPENSLIDE=ON -DECVL_GPU=OFF', installation: 'InSearchPath', sourceDir: '.', cleanBuild: true, steps: [
[args: '--parallel 4', withCmake: true]
]
}
}
}
stage('Test') {
steps {
timeout(15) {
echo 'Testing..'
ctest arguments: '-C Release -VV', installation: 'InSearchPath', workingDir: 'build'
}
}
}
stage('linux_end') {
steps {
echo 'Success!'
}
}
}
}
stage('windows') {
agent {
label 'windows && opencv'
}
stages {
stage('Build') {
steps {
timeout(60) {
echo 'Building..'
bat 'powershell ../../ecvl_dependencies/ecvl_dependencies.ps1'
cmakeBuild buildDir: 'build', buildType: 'Release', cmakeArgs: '-DECVL_TESTS=ON -DECVL_BUILD_EDDL=ON -DECVL_DATASET=ON -DECVL_WITH_DICOM=ON -DECVL_WITH_OPENSLIDE=ON -DOPENSLIDE_LIBRARIES=C:/Library/openslide-win32-20171122/lib/libopenslide.lib', installation: 'InSearchPath', sourceDir: '.', cleanBuild: true, steps: [
[args: '--config Release --parallel 4', withCmake: true]
]
}
}
}
stage('Test') {
steps {
timeout(15) {
echo 'Testing..'
bat 'cd build && ctest -C Release -VV'
}
}
}
stage('Coverage') {
steps {
timeout(15) {
echo 'Calculating coverage..'
bat '"C:/Program Files/OpenCppCoverage/OpenCppCoverage.exe" --source %cd% --export_type=cobertura --excluded_sources=3rdparty -- "build/bin/Release/ECVL_TESTS.exe"'
cobertura coberturaReportFile: 'ECVL_TESTSCoverage.xml'
bat 'codecov -f ECVL_TESTSCoverage.xml -t 7635bd2e-51cf-461e-bb1b-fc7ba9fb26d1'
}
}
}
stage('windows_end') {
steps {
echo 'Success!'
}
}
}
}
stage('documentation') {
when {
branch 'master'
beforeAgent true
}
agent {
label 'windows && ecvl_doxygen'
}
stages {
stage('Update documentation') {
steps {
timeout(15) {
bat 'cd doc\\doxygen && doxygen'
bat '"../../doxygen_git/update_doc_script.bat"'
}
}
}
}
}
stage('release-doc') {
when { tag "v*" }
agent {
label 'windows && ecvl_doxygen'
}
stages {
stage('Set Release Documentation') {
steps {
timeout(15) {
bat 'cd doc\\doxygen && doxygen'
bat '"../../doxygen_git/update_doc_script.bat" y'
}
}
}
}
}
}
}
}
}