Skip to content

Commit 4821803

Browse files
committed
Advanced Gitlab CI pipeline for test and packaging
* added several OS * added dowstream repo packaging (internally)
1 parent 5e5f639 commit 4821803

1 file changed

Lines changed: 70 additions & 12 deletions

File tree

.gitlab-ci.yml

Lines changed: 70 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,95 @@
11
stages:
22
- test
33
- package
4-
- container
4+
- downstream
55

66
test-of:
7-
stage: package #test
7+
stage: test
8+
image: "registry.forge.inrae.fr/openfluid/incubateur/openfluid/ofbuild/debian-12-qt6"
9+
script:
10+
- mkdir ./_build
11+
- cd ./_build && cmake .. -DOFBUILD_ENABLE_DOCS=OFF -DOFBUILD_ENABLE_GUI=OFF
12+
- make stylecheck
13+
- make -j `nproc`
14+
- ctest -j 4 --output-on-failure
15+
16+
test-of-full:
17+
stage: test
18+
when: manual
819
parallel:
920
matrix:
10-
- TAG: ["debian-12-qt6",
11-
"ubuntu-22.04-qt5", "ubuntu-24.04-qt6", "ubuntu-24.10-qt6", "ubuntu-25.04-qt6"]
21+
- TAG: ["debian-11-qt5", "debian-12-qt6", "debian-13-qt6",
22+
"ubuntu-22.04-qt5", "ubuntu-24.04-qt6", "ubuntu-24.10-qt6", "ubuntu-25.04-qt6",
23+
"fedora-41-qt5", "fedora-42-qt6"]
1224
image: "registry.forge.inrae.fr/openfluid/incubateur/openfluid/ofbuild/$TAG"
1325
script:
1426
- mkdir ./_build
1527
- cd ./_build && cmake .. -DOFBUILD_ENABLE_DOCS=OFF -DOFBUILD_ENABLE_GUI=OFF
16-
- make -j 3
17-
- make stylecheck
18-
- ctest -j 3 --output-on-failure
28+
- make -j `nproc`
29+
- ctest -j 4 --output-on-failure
1930

31+
pkg-of-no-ui:
32+
stage: package
33+
image: "registry.forge.inrae.fr/openfluid/incubateur/openfluid/ofbuild/debian-12-qt6"
34+
script:
35+
- mkdir ./_build_noui
36+
- cd ./_build_noui && cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr -DOFBUILD_ENABLE_GUI=OFF
37+
- make -j `nproc`
38+
- cpack -j `nproc`
39+
artifacts:
40+
paths:
41+
- /builds/openfluid/incubateur/openfluid/_build_noui/*.deb
2042

21-
pkg-of:
43+
pkg-of-full:
2244
stage: package
45+
when: manual
2346
parallel:
2447
matrix:
25-
- TAG: ["ubuntu-22.04-qt5"]
48+
- TAG: ["debian-11-qt5", "debian-12-qt6", "debian-13-qt6",
49+
"ubuntu-22.04-qt5", "ubuntu-24.04-qt6", "ubuntu-24.10-qt6", "ubuntu-25.04-qt6",
50+
"fedora-41-qt5", "fedora-42-qt6"]
2651
image: "registry.forge.inrae.fr/openfluid/incubateur/openfluid/ofbuild/$TAG"
2752
script:
28-
- mkdir ./_build
29-
- cd ./_build && cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr -DOFBUILD_ENABLE_GUI=OFF
53+
- mkdir ./_build_release
54+
- cd ./_build_release && cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
3055
- make -j `nproc`
3156
- cpack -j `nproc`
3257
artifacts:
3358
paths:
34-
- /builds/openfluid/incubateur/openfluid/_build/*.deb
59+
- /builds/openfluid/incubateur/openfluid/_build_release/*.deb
60+
61+
pkg-bindings-r:
62+
stage: downstream
63+
image: "registry.forge.inrae.fr/openfluid/incubateur/openfluid/ofbuild/debian-12-qt6"
64+
before_script:
65+
- sudo apt-get update && sudo apt-get install -y /builds/openfluid/incubateur/openfluid/_build_noui/*.deb
66+
script:
67+
- mkdir downstream && cd downstream
68+
- git clone https://forge.inrae.fr/openfluid/incubateur/ropenfluid.git
69+
- cd ropenfluid
70+
- cmake -P check.cmake
71+
- cmake -P build.cmake
72+
artifacts:
73+
paths:
74+
- /builds/openfluid/incubateur/openfluid/downstream/ropenfluid/_build/*.tar.gz
75+
76+
77+
pkg-bindings-py:
78+
stage: downstream
79+
image: "registry.forge.inrae.fr/openfluid/incubateur/openfluid/ofbuild/debian-12-qt6"
80+
before_script:
81+
- sudo apt-get update && sudo apt-get install -y /builds/openfluid/incubateur/openfluid/_build_noui/*.deb
82+
script:
83+
- mkdir downstream && cd downstream
84+
- git clone https://github.com/OpenFLUID/pyopenfluid
85+
- cd pyopenfluid
86+
- python3 setup.py check
87+
- python3 setup.py build
88+
- python3 setup.py test
89+
- python3 setup.py sdist bdist
90+
artifacts:
91+
paths:
92+
- /builds/openfluid/incubateur/openfluid/downstream/pyopenfluid/dist/*.tar.gz
3593

3694

3795
# build-of-container-ubuntu-22-04:

0 commit comments

Comments
 (0)