Skip to content

Commit a08283b

Browse files
committed
wip
1 parent ee4e499 commit a08283b

File tree

3 files changed

+183
-0
lines changed

3 files changed

+183
-0
lines changed
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
name: Build Mars Client C++
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
ref:
7+
description: 'Branch/tag/commit to build'
8+
required: false
9+
type: string
10+
default: 'develop'
11+
12+
jobs:
13+
build:
14+
runs-on: ubuntu-latest
15+
container:
16+
image: ghcr.io/ozaq/images:latest
17+
steps:
18+
- uses: actions/checkout@v5
19+
with:
20+
repository: ecmwf/mars-client-bundle
21+
ref: cpp
22+
path: bundle
23+
token: ${{ secrets.GH_REPO_READ_TOKEN }}
24+
25+
- uses: actions/checkout@v5
26+
with:
27+
repository: ecmwf/ecbuild
28+
ref: develop
29+
path: ecbuild
30+
token: ${{ secrets.GH_REPO_READ_TOKEN }}
31+
32+
- name: Configure
33+
run: |
34+
git config --global url."https://${{ secrets.GH_REPO_READ_TOKEN }}@github.com/".insteadOf "git@github.com:"
35+
git config --global url."https://${{ secrets.GH_REPO_READ_TOKEN }}@github.com/".insteadOf "ssh://git@github.com/"
36+
mkdir build
37+
cmake \
38+
-GNinja \
39+
-S bundle \
40+
-B build \
41+
-DENABLE_BUNDLED_DEPENDENCIES=ON
42+
43+
- name: Checkout ref in folders
44+
run: |
45+
cd bundle
46+
FOLDERS=(eckit eccodes odc metkit atlas atlas-orca mir fdb5 gribjump polytope-client mars-client-cpp)
47+
for dir in "${FOLDERS[@]}"; do
48+
[ -d "$dir" ] && (cd "$dir" && git checkout ${{ inputs.ref }} || true)
49+
done
50+
- name: Build
51+
run: |
52+
cmake --build build -j
53+
- name: Test
54+
run: |
55+
cd build
56+
ctest -j2
Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
name: Build and Test Z3FDB
2+
3+
on:
4+
pull_request:
5+
workflow_dispatch:
6+
push:
7+
branches:
8+
- "master"
9+
- "develop"
10+
tags-ignore:
11+
- "**"
12+
13+
jobs:
14+
build:
15+
strategy:
16+
matrix:
17+
runner:
18+
- [self-hosted, platform-builder-debian-11]
19+
- [self-hosted, platform-builder-ubuntu-22.04]
20+
- [self-hosted, platform-builder-rocky-8.6]
21+
- [self-hosted, platform-builder-fedora-37]
22+
runs-on: ${{ matrix.runner }}
23+
runs-on: ubuntu-latest
24+
steps:
25+
- name: Get ecbuild
26+
uses: actions/checkout@v5
27+
with:
28+
repository: ecmwf/ecbuild
29+
ref: develop
30+
path: ecbuild
31+
- name: Get cxx-dependencies
32+
uses: actions/checkout@v5
33+
with:
34+
repository: ecmwf/cxx-dependencies
35+
ref: master
36+
path: cxx-dependencies-src
37+
token: ${{ secrets.GH_REPO_READ_TOKEN }}
38+
submodules: recursive
39+
- name: Install dependencies
40+
run: |
41+
mkdir cxx-dependencies-build
42+
BUILD_PATH=cxx-dependencies-build INSTALL_PREFIX=dependencies cxx-dependencies-src/build.sh
43+
- name: Get eccodes
44+
uses: actions/checkout@v5
45+
with:
46+
repository: ecmwf/eccodes
47+
ref: develop
48+
path: eccodes-src
49+
- name: Install eccodes
50+
run: |
51+
mkdir eccodes-build
52+
cmake \
53+
-B eccodes-build \
54+
-S eccodes-src \
55+
-GNinja \
56+
-DCMAKE_INSTALL_PREFIX=dependencies \
57+
-DCMAKE_PREFIX_PATH=dependencies \
58+
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
59+
-DENABLE_MEMFS=ON \
60+
-DENABLE_AEC=ON
61+
cmake --build eccodes-build -j -t install
62+
- name: Get eckit
63+
uses: actions/checkout@v5
64+
with:
65+
repository: ecmwf/eckit
66+
ref: develop
67+
path: eckit-src
68+
- name: Install eckit
69+
run: |
70+
mkdir eckit-build
71+
cmake \
72+
-B eckit-build \
73+
-S eckit-src \
74+
-GNinja \
75+
-DCMAKE_INSTALL_PREFIX=dependencies \
76+
-DCMAKE_PREFIX_PATH=dependencies \
77+
-DCMAKE_BUILD_TYPE=RelWithDebInfo
78+
cmake --build eckit-build -j -t install
79+
- name: Get metkit
80+
uses: actions/checkout@v5
81+
with:
82+
repository: ecmwf/metkit
83+
ref: develop
84+
path: metkit-src
85+
- name: Install metkit
86+
run: |
87+
mkdir metkit-build
88+
cmake \
89+
-B metkit-build \
90+
-S metkit-src \
91+
-GNinja \
92+
-DCMAKE_INSTALL_PREFIX=dependencies \
93+
-DCMAKE_PREFIX_PATH=dependencies \
94+
-DCMAKE_BUILD_TYPE=RelWithDebInfo
95+
cmake --build metkit-build -j -t install
96+
- name: Build fdb
97+
run: |
98+
export PATH=$(pwd)/dependencies/bin:$PATH
99+
mkdir fdb-build
100+
cmake \
101+
-B fdb-build \
102+
-S fdb-src \
103+
-GNinja \
104+
-DCMAKE_INSTALL_PREFIX=dependencies \
105+
-DCMAKE_PREFIX_PATH=dependencies \
106+
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
107+
-DENABLE_TOOLS=ON \
108+
cmake --build fdb-build -j
109+
cd fdb-build
110+
ctest -j $(nproc) --output-on-failure
111+
build-mars-client-bundle:
112+
uses: ozaq/test-bundle/.github/workflows/build.yml@demo/ci
113+
secrets:
114+
GH_REPO_READ_TOKEN: ${{ secrets.GH_REPO_READ_TOKEN }}
115+
with:
116+
ref: ${{ github.ref }}

.github/workflows/z3fdb.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@ name: Build and Test z3fdb
33
on:
44
pull_request:
55
workflow_dispatch: # Allows manual trigger
6+
push:
7+
branches:
8+
- "master"
9+
- "develop"
10+
tags-ignore:
11+
- "**"
612

713
jobs:
814
prepare-deps:
@@ -138,3 +144,8 @@ jobs:
138144
path: "fdb-build/z3fdb-*.whl"
139145
retention-days: 10
140146
if-no-files-found: error # 'warn' or 'ignore' are also available, defaults to `warn`
147+
build-upstream:
148+
uses: ./.github/workflows/build-bundles.yml
149+
secrets: inherit
150+
with:
151+
ref: ${{ github.ref }}

0 commit comments

Comments
 (0)