Skip to content

Commit bcbab64

Browse files
committed
ci: add iOS
Signed-off-by: Henry Schreiner <[email protected]>
1 parent 1d33428 commit bcbab64

File tree

2 files changed

+34
-5
lines changed

2 files changed

+34
-5
lines changed

.github/workflows/emscripten.yaml

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: WASM
1+
name: CIBW
22

33
on:
44
workflow_dispatch:
@@ -15,16 +15,33 @@ concurrency:
1515
jobs:
1616
build-wasm-emscripten:
1717
name: Pyodide wheel
18-
runs-on: ubuntu-22.04
18+
runs-on: ubuntu-latest
1919
steps:
2020
- uses: actions/checkout@v4
2121
with:
2222
submodules: true
2323
fetch-depth: 0
2424

25-
- uses: pypa/cibuildwheel@v2.23
25+
- uses: pypa/cibuildwheel@v3.0.0b4
2626
env:
2727
PYODIDE_BUILD_EXPORTS: whole_archive
2828
with:
2929
package-dir: tests
3030
only: cp312-pyodide_wasm32
31+
32+
build-ios:
33+
name: iOS wheel
34+
runs-on: macos-latest
35+
steps:
36+
- uses: actions/checkout@v4
37+
with:
38+
submodules: true
39+
fetch-depth: 0
40+
41+
- run: brew upgrade cmake
42+
43+
- uses: pypa/[email protected]
44+
env:
45+
CIBW_PLATFORM: ios
46+
with:
47+
package-dir: tests

tests/pyproject.toml

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,22 @@ build-backend = "scikit_build_core.build"
88
[project]
99
name = "pybind11_tests"
1010
version = "0.0.1"
11-
dependencies = ["pytest", "pytest-timeout", "numpy", "scipy"]
11+
dependencies = ["pytest", "pytest-timeout", "numpy"]
12+
13+
[tool.scikit-build]
14+
build.verbose = true
1215

1316
[tool.scikit-build.cmake.define]
1417
PYBIND11_FINDPYTHON = true
1518

1619
[tool.cibuildwheel]
17-
test-command = "pytest -o timeout=0 -p no:cacheprovider {project}/tests/test_*.py"
20+
test-sources = ["tests", "pyproject.toml"]
21+
test-command = "python -m pytest -o timeout=0 -p no:cacheprovider tests/test_*.py"
22+
environment.PIP_ONLY_BINARY = "numpy"
23+
environment.PIP_PREFER_BINARY = "1"
24+
# BROKEN: ios.environment.IPHONEOS_DEPLOYMENT_TARGET = "17.0"
25+
ios.xbuild-tools = ["cmake", "ninja"]
26+
ios.environment.PIP_EXTRA_INDEX_URL = "https://pypi.anaconda.org/beeware/simple"
27+
28+
[tool.cibuildwheel.ios.config-settings]
29+
"cmake.define.CMAKE_CXX_FLAGS" = "-mios-min-version=17.0"

0 commit comments

Comments
 (0)