@@ -165,9 +165,16 @@ jobs:
165165 name : cibw-wheels-${{ matrix.python }}-${{ matrix.manylinux }}
166166 path : |
167167 ./wheelhouse/*.whl
168+
169+ - uses : actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
170+ with :
171+ name : stubs-${{ matrix.python }}-${{ matrix.manylinux }}
172+ path : |
168173 ./wheelhouse/OpenImageIO/__init__.pyi
169- # if stub validation fails we want to upload the stubs for users to review
170- if : success() || failure()
174+ # if stub validation fails we want to upload the stubs for users to review.
175+ # keep the python build in sync with the version specified in tool.cibuildwheel.overrides
176+ # section of pyproject.toml
177+ if : always() && contains(matrix.python, 'cp311-manylinux')
171178
172179 # ---------------------------------------------------------------------------
173180 # Linux ARM Wheels
@@ -231,65 +238,78 @@ jobs:
231238 name : cibw-wheels-${{ matrix.python }}-${{ matrix.manylinux }}
232239 path : |
233240 ./wheelhouse/*.whl
241+
242+ - uses : actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
243+ with :
244+ name : stubs-${{ matrix.python }}-${{ matrix.manylinux }}
245+ path : |
234246 ./wheelhouse/OpenImageIO/__init__.pyi
235- # if stub validation fails we want to upload the stubs for users to review
236- if : success() || failure()
247+ # if stub validation fails we want to upload the stubs for users to review.
248+ # keep the python build in sync with the version specified in tool.cibuildwheel.overrides
249+ # section of pyproject.toml
250+ if : always() && contains(matrix.python, 'cp311-manylinux')
237251
238252 # ---------------------------------------------------------------------------
239253 # macOS Wheels
240254 # ---------------------------------------------------------------------------
241255
242- # macos:
243- # name: Build wheels on macOS
244- # runs-on: macos-13
245- # if: |
246- # github.event_name != 'schedule' ||
247- # github.repository == 'AcademySoftwareFoundation/OpenImageIO'
248- # strategy:
249- # matrix:
250- # include:
251- # # -------------------------------------------------------------------
252- # # CPython 64 bits
253- # # -------------------------------------------------------------------
254- # - build: CPython 3.9 64 bits
255- # python: cp39-macosx_x86_64
256- # arch: x86_64
257- # - build: CPython 3.10 64 bits
258- # python: cp310-macosx_x86_64
259- # arch: x86_64
260- # - build: CPython 3.11 64 bits
261- # python: cp311-macosx_x86_64
262- # arch: x86_64
263- # - build: CPython 3.12 64 bits
264- # python: cp312-macosx_x86_64
265- # arch: x86_64
266- # - build: CPython 3.13 64 bits
267- # python: cp313-macosx_x86_64
268- # arch: x86_64
269-
270- # steps:
271- # - name: Checkout repo
272- # uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
273-
274- # - name: Install Python
275- # uses: actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 # v5.2.0
276- # with:
277- # python-version: '3.9'
278-
279- # - name: Build wheels
280- # uses: pypa/cibuildwheel@d4a2945fcc8d13f20a1b99d461b8e844d5fc6e23 # v2.21.1
281- # env:
282- # CIBW_BUILD: ${{ matrix.python }}
283- # CIBW_ARCHS: ${{ matrix.arch }}
284- # CMAKE_GENERATOR: "Unix Makefiles"
285- # # TODO: Re-enable HEIF when we provide a build recipe that does
286- # # not include GPL-licensed dynamic libraries.
287- # USE_Libheif: 'OFF'
288-
289- # - uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
290- # with:
291- # name: cibw-wheels-${{ matrix.python }}
292- # path: ./wheelhouse/*.whl
256+ macos :
257+ name : Build wheels on macOS
258+ runs-on : macos-13
259+ if : |
260+ github.event_name != 'schedule' ||
261+ github.repository == 'AcademySoftwareFoundation/OpenImageIO'
262+ strategy :
263+ matrix :
264+ include :
265+ # -------------------------------------------------------------------
266+ # CPython 64 bits
267+ # -------------------------------------------------------------------
268+ - build : CPython 3.9 64 bits
269+ python : cp39-macosx_x86_64
270+ arch : x86_64
271+ - build : CPython 3.10 64 bits
272+ python : cp310-macosx_x86_64
273+ arch : x86_64
274+ - build : CPython 3.11 64 bits
275+ python : cp311-macosx_x86_64
276+ arch : x86_64
277+ - build : CPython 3.12 64 bits
278+ python : cp312-macosx_x86_64
279+ arch : x86_64
280+ - build : CPython 3.13 64 bits
281+ python : cp313-macosx_x86_64
282+ arch : x86_64
283+
284+ steps :
285+ - name : Checkout repo
286+ uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
287+
288+ - name : Install Python
289+ uses : actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 # v5.2.0
290+ with :
291+ python-version : ' 3.9'
292+
293+ - name : Remove brew OpenEXR/Imath
294+ run : |
295+ brew uninstall --ignore-dependencies openexr imath || true
296+
297+ - name : Build wheels
298+ uses : pypa/cibuildwheel@d4a2945fcc8d13f20a1b99d461b8e844d5fc6e23 # v2.21.1
299+ env :
300+ CIBW_BUILD : ${{ matrix.python }}
301+ CIBW_ARCHS : ${{ matrix.arch }}
302+ MACOSX_DEPLOYMENT_TARGET : 10.15
303+ CMAKE_GENERATOR : " Unix Makefiles"
304+ # TODO: Re-enable HEIF when we provide a build recipe that does
305+ # not include GPL-licensed dynamic libraries.
306+ USE_Libheif : ' OFF'
307+
308+ - uses : actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
309+ with :
310+ name : cibw-wheels-${{ matrix.python }}
311+ path : ./wheelhouse/*.whl
312+
293313
294314 # ---------------------------------------------------------------------------
295315 # macOS ARM Wheels
@@ -332,7 +352,6 @@ jobs:
332352
333353 - name : Install Python
334354 uses : actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 # v5.2.0
335- # https://cibuildwheel.pypa.io/en/stable/faq/#macos-building-cpython-38-wheels-on-arm64
336355 with :
337356 python-version : ' 3.8'
338357
@@ -407,7 +426,7 @@ jobs:
407426
408427
409428 upload_pypi :
410- needs : [sdist, linux, linux-arm, macos-arm, windows]
429+ needs : [sdist, linux, linux-arm, macos, macos -arm, windows]
411430 runs-on : ubuntu-latest
412431 permissions :
413432 id-token : write
0 commit comments