diff --git a/.github/workflows/buildwheel.yml b/.github/workflows/buildwheel.yml index 0134b6ae..95513eb3 100644 --- a/.github/workflows/buildwheel.yml +++ b/.github/workflows/buildwheel.yml @@ -15,7 +15,6 @@ env: PYODIDE_VERSION: '314.0.0' PYODIDE_EMSCRIPTEN_VERSION: '5.0.3' PYODIDE_PYTHON_VERSION: '3.14' - PYODIDE_CIBW_BUILD: 'cp314-*' jobs: build_wheels: @@ -26,54 +25,117 @@ jobs: fail-fast: false matrix: include: + - name: Build manylinux x86-64 wheels os: ubuntu-22.04 kind: native artifact_name: wheels-ubuntu-22.04 cibw_platform: auto - cibw_build: "*" + cibw_build: "cp313-* cp314-* cp314t-* pp311-*" + cibw_config_settings: "" + + - name: Build manylinux x86-64 stable ABI wheels + os: ubuntu-22.04 + kind: stable-abi + artifact_name: wheels-ubuntu-22.04-abi3 + cibw_platform: auto + cibw_build: "cp310-*" + cibw_config_settings: "setup-args=-Dpython.allow_limited_api=true" + - name: Build manylinux arm64 wheels os: ubuntu-22.04-arm kind: native artifact_name: wheels-ubuntu-22.04-arm cibw_platform: auto - cibw_build: "*" + cibw_build: "cp313-* cp314-* cp314t-* pp311-*" + cibw_config_settings: "" + + - name: Build manylinux arm64 stable ABI wheels + os: ubuntu-22.04-arm + kind: stable-abi + artifact_name: wheels-ubuntu-22.04-arm-abi3 + cibw_platform: auto + cibw_build: "cp310-*" + cibw_config_settings: "setup-args=-Dpython.allow_limited_api=true" + - name: Build Windows x86-64 wheels os: windows-2022 kind: native artifact_name: wheels-windows-2022 cibw_platform: auto - cibw_build: "*" + cibw_build: "cp313-* cp314-* cp314t-* pp311-*" + cibw_config_settings: "setup-args=--vsenv build-dir=build" + + - name: Build Windows x86-64 stable ABI wheels + os: windows-2022 + kind: stable-abi + artifact_name: wheels-windows-2022-abi3 + cibw_platform: auto + cibw_build: "cp310-*" + cibw_config_settings: "setup-args=--vsenv setup-args=-Dpython.allow_limited_api=true build-dir=build" + - name: Build Windows arm64 wheels os: windows-11-arm kind: native artifact_name: wheels-windows-11-arm cibw_platform: auto - cibw_build: "*" + cibw_build: "cp313-* cp314-* cp314t-* pp311-*" + cibw_config_settings: "setup-args=--vsenv build-dir=build" + + - name: Build Windows arm64 stable ABI wheels + os: windows-11-arm + kind: stable-abi + artifact_name: wheels-windows-11-arm-abi3 + cibw_platform: auto + cibw_build: "cp310-*" + cibw_config_settings: "setup-args=--vsenv setup-args=-Dpython.allow_limited_api=true build-dir=build" + - name: Build macOS x86-64 wheels os: macos-15-intel kind: native artifact_name: wheels-macos-15-intel cibw_platform: auto - cibw_build: "*" + cibw_build: "cp313-* cp314-* cp314t-* pp311-*" + cibw_config_settings: "" + + - name: Build macOS x86-64 stable ABI wheels + os: macos-15-intel + kind: stable-abi + artifact_name: wheels-macos-15-intel-abi3 + cibw_platform: auto + cibw_build: "cp310-*" + cibw_config_settings: "setup-args=-Dpython.allow_limited_api=true" + - name: Build macOS arm64 wheels os: macos-14 kind: native artifact_name: wheels-macos-14 cibw_platform: auto - cibw_build: "*" + cibw_build: "cp313-* cp314-* cp314t-* pp311-*" + cibw_config_settings: "" + + - name: Build macOS arm64 stable ABI wheels + os: macos-14 + kind: stable-abi + artifact_name: wheels-macos-14-abi3 + cibw_platform: auto + cibw_build: "cp310-*" + cibw_config_settings: "setup-args=-Dpython.allow_limited_api=true" + - name: Build Pyodide wheels os: ubuntu-22.04 kind: pyodide artifact_name: wheels-pyodide cibw_platform: pyodide + cibw_build: "cp314-*" + cibw_config_settings: "build-dir=flint_wasm_build setup-args=-Dflint_version_check=false" steps: - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 with: persist-credentials: false - - if: ${{ matrix.kind == 'native' }} + - if: ${{ matrix.kind != 'pyodide' }} uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6.3.0 with: python-version: '3.13' @@ -120,7 +182,8 @@ jobs: uses: pypa/cibuildwheel@294735312765b09d24a2fbec22660ce817587d55 # v4.1.0 env: CIBW_PLATFORM: ${{ matrix.cibw_platform }} - CIBW_BUILD: ${{ matrix.kind == 'pyodide' && env.PYODIDE_CIBW_BUILD || matrix.cibw_build }} + CIBW_BUILD: ${{ matrix.cibw_build }} + CIBW_CONFIG_SETTINGS: ${{ matrix.cibw_config_settings }} CIBW_PYODIDE_VERSION: ${{ env.PYODIDE_VERSION }} # override setting in pyproject.toml to use msys2 instead of msys64 bash CIBW_BEFORE_ALL_WINDOWS: ${{ matrix.os == 'windows-11-arm' && 'msys2 -c bin/cibw_before_all_windows_arm64.sh' || 'msys2 -c bin/cibw_before_all_windows_amd64.sh' }} @@ -172,8 +235,10 @@ jobs: macos-15, ] # This list to be kept in sync with python-requires in pyproject.toml. - python-version: ['3.11', '3.12', '3.13', '3.14', '3.14t', 'pypy3.11'] + python-version: ['3.10', '3.11', '3.12', '3.13', '3.14', '3.14t', '3.15', 'pypy3.11'] exclude: + - os: windows-11-arm + python-version: '3.10' - os: windows-11-arm python-version: pypy3.11 diff --git a/README.md b/README.md index db71dfae..83e0d14c 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ Author: Fredrik Johansson Installation ------------ -Currently python-flint supports CPython versions 3.11-3.14 and 3.14t +Currently python-flint supports CPython versions 3.10-3.14 and 3.14t (free-threaded) and provides binaries on PyPI for the following platforms: - Windows (x86-64) @@ -144,7 +144,7 @@ Compatible versions: | python-flint | Release date | CPython | FLINT | Cython | |--------------|---------------|-------------|------------|------------------| -| `0.9.0` | ??? | `3.11-3.14` | `3.0-3.6` | `3.1-3.2?` | +| `0.9.0` | ??? | `3.10-3.14` | `3.0-3.6` | `3.1-3.2?` | | `0.8.0` | 29th Aug 2025 | `3.11-3.14` | `3.0-3.3` | `3.1` only | | `0.7.0` | 16th Mar 2025 | `3.11-3.13` | `3.0-3.2` | `3.0.11-3.1.0a1` | | `0.6.0` | 1st Feb 2024 | `3.9-3.12` | `3.0` only | `3.0` only | diff --git a/bin/cibw.bat b/bin/cibw.bat index 8f62e8e9..431a7ec2 100644 --- a/bin/cibw.bat +++ b/bin/cibw.bat @@ -22,6 +22,10 @@ rem del /q wheelhouse\* rem override setting in pyproject.toml -set CIBW_BUILD=cp39-* cp310-* cp311-* +set CIBW_BUILD=cp313-* cp314-* cp314t-* pp311-* + +cibuildwheel --platform windows + +set CIBW_BUILD=cp310-* cibuildwheel --platform windows diff --git a/doc/source/build.rst b/doc/source/build.rst index 356bb925..e944aaf7 100644 --- a/doc/source/build.rst +++ b/doc/source/build.rst @@ -86,7 +86,7 @@ Compatible versions: - Cython * - 0.9.0 - Not yet - - 3.11-3.14 + - 3.10-3.14 - 3.0-3.6 - 3.1-3.2? * - 0.8.0 diff --git a/doc/source/install.rst b/doc/source/install.rst index 6e4ccef8..210eda62 100644 --- a/doc/source/install.rst +++ b/doc/source/install.rst @@ -47,9 +47,9 @@ Fully supported platforms Generally each release of python-flint will be compatible with a range of Python versions as described in `SPEC 0 -`_. At the time of writing, the -current release of ``python-flint`` is ``0.6.0`` and binaries are provided for -Python 3.9, 3.10 3.11 and 3.12 for the following platforms: +`_. At the time of writing, +binaries are provided for CPython 3.10-3.14 and PyPy 3.11 for the following +platforms: - Windows 64-bit (``x86_64``) - MacOS 64-bit Intel and 64-bit ARM (i.e. Apple Silicon) diff --git a/meson.options b/meson.options index d1094d31..5a3d4781 100644 --- a/meson.options +++ b/meson.options @@ -1,4 +1,4 @@ option('coverage', type : 'boolean', value : false, description : 'enable coverage build') option('add_flint_rpath', type : 'boolean', value : false) option('flint_version_check', type: 'boolean', value : true) -option('limited_api_version', type: 'string', value : '3.12') +option('limited_api_version', type: 'string', value : '3.10') diff --git a/pyproject.toml b/pyproject.toml index 3056fdd0..9df22119 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ description = "Bindings for FLINT" version = "0.8.0" # This needs to be in sync with README, and CI config. -requires-python = ">= 3.11" +requires-python = ">= 3.10" authors = [ {name = "Fredrik Johansson", email = "fredrik.johansson@gmail.com"}, {name = "Oscar Benjamin", email = "oscar.j.benjamin@gmail.com"}, @@ -154,7 +154,6 @@ repair-wheel-command = [ [tool.cibuildwheel.windows] before-build = "pip install wheel delvewheel" -config-settings = {setup-args = ["--vsenv"], build-dir = "build"} repair-wheel-command = [ """python bin/cibw_repair_wheel_licenses.py {wheel} \ --license LGPL-3.0-or-later \ @@ -199,7 +198,3 @@ WASM_LIBRARY_DIR = "$(pwd)/wasm-library-dir" PKG_CONFIG_PATH = "$(pwd)/wasm-library-dir/lib/pkgconfig:$PKG_CONFIG_PATH" CFLAGS = "-I$(pwd)/wasm-library-dir/include $CFLAGS" LDFLAGS = "-L$(pwd)/wasm-library-dir/lib -lflint -lmpfr -lgmp $LDFLAGS" - -[tool.cibuildwheel.pyodide.config-settings] -build-dir = "flint_wasm_build" -setup-args = ["-Dflint_version_check=false"]