Skip to content

Commit eec1d51

Browse files
committed
ci: add iOS
Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
1 parent ba78f4c commit eec1d51

File tree

2 files changed

+33
-5
lines changed

2 files changed

+33
-5
lines changed

.github/workflows/tests-cibw.yml

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: henryiii/cibuildwheel@72d263930ad04fb48fb9d660c1e38a79c9675bf7
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: henryiii/cibuildwheel@72d263930ad04fb48fb9d660c1e38a79c9675bf7
44+
env:
45+
CIBW_PLATFORM: ios
46+
with:
47+
package-dir: tests

tests/pyproject.toml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,21 @@ 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
15+
logging.level = "INFO"
1216

1317
[tool.scikit-build.cmake.define]
1418
PYBIND11_FINDPYTHON = true
1519

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

0 commit comments

Comments
 (0)