4242 arch : x86_64
4343 python : 312
4444 builder : manylinux
45+ - os : ubuntu-latest
46+ arch : x86_64
47+ python : 313
48+ builder : manylinux
4549
4650 # MacOS x86_64. The macos-13 runner is the last
4751 # Intel-based runner version. At some point we'll
@@ -50,45 +54,49 @@ jobs:
5054 arch : x86_64
5155 python : 310
5256 builder : macosx
53- deploy : 13.0
5457 - os : macos-13
5558 arch : x86_64
5659 python : 311
5760 builder : macosx
58- deploy : 13.0
5961 - os : macos-13
6062 arch : x86_64
6163 python : 312
6264 builder : macosx
63- deploy : 13.0
65+ - os : macos-13
66+ arch : x86_64
67+ python : 313
68+ builder : macosx
6469
6570 # MacOS arm64
6671 - os : macos-latest
6772 arch : arm64
6873 python : 310
6974 builder : macosx
70- deploy : 14.0
7175 - os : macos-latest
7276 arch : arm64
7377 python : 311
7478 builder : macosx
75- deploy : 14.0
7679 - os : macos-latest
7780 arch : arm64
7881 python : 312
7982 builder : macosx
80- deploy : 14.0
83+ - os : macos-latest
84+ arch : arm64
85+ python : 313
86+ builder : macosx
8187 env :
8288 CIBW_BUILD : cp${{ matrix.python }}-${{ matrix.builder }}_${{ matrix.arch }}
8389 CIBW_MANYLINUX_X86_64_IMAGE : ${{ matrix.builder }}2014
8490 CIBW_MANYLINUX_I686_IMAGE : ${{ matrix.builder }}2014
8591 CIBW_BUILD_VERBOSITY : 3
86- CIBW_ENVIRONMENT_LINUX :
92+ CIBW_ENVIRONMENT_LINUX : >
93+ CC=gcc
8794 CIBW_ENVIRONMENT_MACOS : >
88- MACOSX_DEPLOYMENT_TARGET=${{ matrix.deploy }}
95+ CC=clang
8996 CIBW_BEFORE_BUILD_LINUX : ./packaging/wheels/install_deps_linux.sh
9097 CIBW_BEFORE_BUILD_MACOS : ./packaging/wheels/install_deps_osx.sh
91- CIBW_BEFORE_TEST : export OMP_NUM_THREADS=1
98+ CIBW_BEFORE_TEST : export OMP_NUM_THREADS=2
99+ CIBW_TEST_REQUIRES : h5py zarr
92100 CIBW_TEST_COMMAND : python3 -c 'import flacarray.tests; flacarray.tests.run()'
93101 steps :
94102 - name : Checkout
@@ -97,16 +105,41 @@ jobs:
97105 - uses : actions/setup-python@v5
98106 name : Install Python
99107 with :
100- python-version : ' 3.10 '
108+ python-version : ' 3.11 '
101109
102110 - name : Install cibuildwheel
103111 run : |
104- python -m pip install twine cibuildwheel==2.20 .0
112+ python -m pip install twine cibuildwheel==2.22 .0
105113
106114 - name : Build wheel
107115 run : |
108116 python -m cibuildwheel --output-dir wheelhouse
109117
110- - name : Upload to PyPI
111- run : |
112- python -m twine upload wheelhouse/flacarray*cp${{ matrix.python }}-${{ matrix.builder }}*${{ matrix.arch }}*.whl
118+ build_sdist :
119+ name : Build source distribution
120+ runs-on : ubuntu-latest
121+ steps :
122+ - uses : actions/checkout@v4
123+
124+ - name : Build sdist
125+ run : pipx run build --sdist
126+
127+ - uses : actions/upload-artifact@v4
128+ with :
129+ name : flacarray-sdist
130+ path : dist/*.tar.gz
131+
132+ upload_pypi :
133+ needs : [build_wheels, build_sdist]
134+ runs-on : ubuntu-latest
135+ permissions :
136+ id-token : write
137+ steps :
138+ - uses : actions/download-artifact@v4
139+ with :
140+ # Unpacks all artifacts into dist/
141+ pattern : flacarray-*
142+ path : dist
143+ merge-multiple : true
144+
145+ - uses : pypa/gh-action-pypi-publish@release/v1
0 commit comments