Skip to content

Commit 1578c03

Browse files
committed
support dependency generation
1 parent fed30f6 commit 1578c03

File tree

4 files changed

+23
-63
lines changed

4 files changed

+23
-63
lines changed

.github/workflows/build-wheel-linux.yml

+18-59
Original file line numberDiff line numberDiff line change
@@ -19,69 +19,28 @@ on:
1919
# TODO automation trigger
2020

2121
jobs:
22-
2322
build:
24-
25-
runs-on: [self-hosted, Linux, platform-builder-Rocky-8.6]
26-
# TODO which manylinux do we want to build for? 2014? 2_28? 2_34? Matrix?
27-
container: eccr.ecmwf.int/wheelmaker/2_28:latest
28-
2923
name: Build manylinux_2_28
30-
31-
steps:
32-
- uses: actions/checkout@v2
33-
- run: /buildscripts/compile.sh ./eckit/python_wrapper/buildconfig
34-
35-
################################################################
36-
- run: /buildscripts/wheel-linux.sh ./eckit/python_wrapper/buildconfig 3.11
37-
- uses: actions/upload-artifact@v4
38-
name: Upload wheel 3.11
39-
with:
40-
name: wheel-manylinux2_28-3.11
41-
path: /build/wheel/*.whl
42-
43-
# TODO other python versions, once the above is correct.
44-
# NOTE if Matrix, then break into (compile) && (wheel & upload)@[matix] steps
45-
46-
test:
47-
48-
needs: build
49-
strategy:
50-
fail-fast: false
51-
matrix:
52-
python-version: ["3.11"] # ["3.8", "3.9", "3.10", "3.11", "3.12"] # TODO enable
53-
54-
name: Test with ${{ matrix.python-version }}
5524
runs-on: [self-hosted, Linux, platform-builder-Rocky-8.6]
56-
container: eccr.ecmwf.int/wheelmaker/2_28:latest
57-
steps:
58-
- uses: actions/checkout@v2
59-
- uses: actions/download-artifact@v4
60-
with:
61-
name: wheel-manylinux2_28-${{ matrix.python-version }}
62-
- run: /buildscripts/test-wheel.sh ${{ matrix.python-version }}
63-
64-
deploy:
65-
66-
if: ${{ github.ref_type == 'tag' || github.event_name == 'release' }}
67-
needs: [test, build]
68-
strategy:
69-
fail-fast: false
70-
matrix:
71-
python-version: ["3.11"] # ["3.8", "3.9", "3.10", "3.11", "3.12"] # TODO enable
72-
73-
name: Deploy wheel ${{ matrix.python-version }}
74-
runs-on: [self-hosted, Linux, platform-builder-Rocky-8.6]
75-
container: eccr.ecmwf.int/wheelmaker/2_28:latest
25+
# TODO which manylinux do we want to build for? 2014? 2_28? 2_34? Matrix?
26+
container:
27+
image: eccr.ecmwf.int/wheelmaker/2_28:0.9
28+
credentials:
29+
username: ${{ secrets.ECMWF_DOCKER_REGISTRY_USERNAME }}
30+
password: ${{ secrets.ECMWF_DOCKER_REGISTRY_ACCESS_TOKEN }}
7631
steps:
77-
- run: mkdir artifact-${{ matrix.python-version }}
78-
- uses: actions/checkout@v2
79-
- uses: actions/download-artifact@v4
80-
with:
81-
name: wheel-manylinux2_28-${{ matrix.python-version }}
82-
path: artifact-${{ matrix.python-version }}
83-
- run: |
84-
/buildsripts/upload-twine.sh ${{ matrix.python-version }}
32+
# TODO convert this to be matrix-friendly. Note it's a bit tricky since
33+
# we'd ideally not reexecute the compile step multiple times, but it
34+
# (non-essentially) depends on a matrix-based step
35+
# NOTE we dont use action checkout because it doesnt cleanup after itself correctly
36+
- run: git clone --depth=1 --branch="${GITHUB_REF#refs/heads/}" https://github.com/$GITHUB_REPOSITORY /proj
37+
- run: cd /proj && /buildscripts/prepare_deps.sh ./python_wrapper/buildconfig 3.11
38+
- run: cd /proj && /buildscripts/compile.sh ./python_wrapper/buildconfig
39+
- run: cd /proj && /buildscripts/wheel-linux.sh ./python_wrapper/buildconfig 3.11
40+
- run: cd /proj && /buildscripts/test-wheel.sh ./python_wrapper/buildconfig 3.11 /build/wheel/*whl
41+
- run: cd /proj && /buildscripts/upload-pypi.sh /build/wheel/*whl
8542
env:
8643
TWINE_USERNAME: __token__
8744
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
45+
# NOTE temporary thing until all the mess gets cleared
46+
- run: rm -rf ./* ./.git ./.github

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ It features facilities to easily handle, in a cross-platform way:
3535
* MPI object-oriented wrapper
3636
* linear algebra abstraction with multiple backends (BLAS, MKL, Armadillo, Eigen3)
3737
* advanced container classes
38-
* space partition trees
39-
* file-mapped arrays
38+
* space partition trees
39+
* file-mapped arrays
4040

4141

4242
Requirements

python_wrapper/buildconfig

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,6 @@
1111
# TODO we duplicate information -- pyproject.toml's `name` and `packages` are derivable from $NAME and must stay consistent
1212

1313
NAME="eckit"
14-
CMAKE_PARAMS="-DENABLE_MPI=0 -DENABLE_ECKIT_GEO=1"
14+
CMAKE_PARAMS="-DENABLE_MPI=0 -DENABLE_ECKIT_GEO=1 -DENABLE_BUILD_TOOLS=OFF"
1515
PYPROJECT_DIR="python_wrapper"
16-
FINDLIBS_DEPENDENCIES='[]'
16+
DEPENDENCIES='[]'

python_wrapper/setup.cfg

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
[metadata]
22
description = "eckit"
33
long_description = file: README.md
4+
long_description_content_type = text/markdown
45
author = file: AUTHORS

0 commit comments

Comments
 (0)