forked from AIDASoft/DD4hep
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
154 lines (143 loc) · 4.87 KB
/
.gitlab-ci.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
stages:
- build
- documentation
- deployment
mac11-clang12:
stage: build
tags:
- mac
script:
- source /cvmfs/sft.cern.ch/lcg/views/LCG_102/x86_64-mac11-clang120-opt/setup.sh
- export CXX=clang++
- export CC=clang
- export FC=""
- mkdir build
- cd build
- cmake -GNinja -DDD4HEP_USE_GEANT4=ON -DBoost_NO_BOOST_CMAKE=ON -DDD4HEP_USE_LCIO=ON -DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_STANDARD=17 ..
- ninja
- ninja install
- . ../bin/thisdd4hep.sh
- ctest --output-on-failure -j4 -T Test --no-compress-output --test-output-size-failed 1024000
- cd ../examples/
- mkdir build
- cd build
- cmake -GNinja -DBoost_NO_BOOST_CMAKE=ON -DCMAKE_CXX_STANDARD=17 ..
- ninja
- ninja install
- ctest --output-on-failure -E t_ClientTests_Check_Shape_Eightpoint_Reflect_DetElement -T Test --no-compress-output --test-output-size-failed 1024000
after_script:
- xsltproc .github/utils/ctest2junit.xsl build/Testing/*/Test.xml > junit.xml
- xsltproc .github/utils/ctest2junit.xsl examples/build/Testing/*/Test.xml > junit_examples.xml
artifacts:
reports:
junit: junit*.xml
mac11-clang12-XERCESC:
stage: build
tags:
- mac
script:
- source /cvmfs/sft.cern.ch/lcg/views/LCG_102/x86_64-mac11-clang120-opt/setup.sh
- export CXX=clang++
- export CC=clang
- export FC=""
- mkdir build
- cd build
- cmake -GNinja -DDD4HEP_USE_GEANT4=ON -DBoost_NO_BOOST_CMAKE=ON -DDD4HEP_USE_LCIO=ON -DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_STANDARD=17 -DDD4HEP_USE_XERCESC=ON ..
- ninja
- ninja install
- . ../bin/thisdd4hep.sh
- ctest --output-on-failure -j4 -T Test --no-compress-output --test-output-size-failed 1024000
- cd ../examples/
- mkdir build
- cd build
- cmake -GNinja -DBoost_NO_BOOST_CMAKE=ON -DDD4HEP_USE_XERCESC=ON -DCMAKE_CXX_STANDARD=17 ..
- ninja
- ninja install
- ctest --output-on-failure -E t_ClientTests_Check_Shape_Eightpoint_Reflect_DetElement -T Test --no-compress-output --test-output-size-failed 1024000
after_script:
- xsltproc .github/utils/ctest2junit.xsl build/Testing/*/Test.xml > junit_XERCES.xml
- xsltproc .github/utils/ctest2junit.xsl examples/build/Testing/*/Test.xml > junit_examples_XERCES.xml
artifacts:
reports:
junit: junit*.xml
Python:
stage: build
tags:
- docker
image: ghcr.io/aidasoft/centos7:latest
script:
- source /cvmfs/sft.cern.ch/lcg/views/LCG_102/x86_64-centos7-gcc11-opt/setup.sh
- echo "RUNNING FLAKE8 CHECK"
- find . -name "*.py" -and -not -name 'ddsix.py' -exec flake8 {} +
#############################
# Documentation Compilation #
#############################
# Compile Doxygen reference
doxygen:
stage: documentation
needs: []
tags:
- docker
image: ghcr.io/aidasoft/centos7:latest
script:
- source /cvmfs/sft.cern.ch/lcg/views/LCG_102/x86_64-centos7-gcc11-opt/setup.sh
- mkdir -p public
- mkdir build
- cd build
- cmake -DBUILD_DOCS_ONLY=ON ..
- make reference
- mv reference/html ../public/reference
artifacts:
paths:
- public
expire_in: 3 hour
# Compile LaTeX user manual:
usermanuals:
stage: documentation
needs: []
tags:
- docker
image: ghcr.io/aidasoft/centos7:latest
script:
- yum install -y ghostscript poppler-utils perl
- source /cvmfs/sft.cern.ch/lcg/views/LCG_102/x86_64-centos7-gcc11-opt/setup.sh
- export PATH=/cvmfs/sft.cern.ch/lcg/external/texlive/2017/bin/x86_64-linux:$PATH
- export max_print_line=200
- mkdir -p public/usermanuals
- mkdir build
- cd build
- cmake -DBUILD_DOCS_ONLY=ON ..
- make pdf
- make html
- mv DD4hepManual ../public/usermanuals/.
- mv DDAlignManual ../public/usermanuals/.
- mv DDCondManual ../public/usermanuals/.
- mv DDEveManual ../public/usermanuals/.
- mv DDG4Manual ../public/usermanuals/.
- mv DDRecManual ../public/usermanuals/.
artifacts:
paths:
- public
expire_in: 3 hour
############################
# Documentation Deployment #
############################
# Automatically deploy documentation to the website
# Deployment job only executed for new tag pushs, not for every commit.
deploy-documentation:
variables:
EOS_PATH: "/eos/project/d/dd4hep/www/"
only:
- tags@CLICdp/DetectorSoftware/DD4hep
- master@CLICdp/DetectorSoftware/DD4hep
stage: deployment
tags:
- docker
needs: ["usermanuals", "doxygen"]
# Docker image with tools to deploy to EOS
image: gitlab-registry.cern.ch/ci-tools/ci-web-deployer:latest
script:
- deploy-eos
# do not run any globally defined before_script or after_script for this step
before_script: []
after_script: []