Skip to content

rasterio: add build-rasterio.yml for riscv64 wheels - #912

Open
luhenry wants to merge 2 commits into
mainfrom
rasterio
Open

rasterio: add build-rasterio.yml for riscv64 wheels#912
luhenry wants to merge 2 commits into
mainfrom
rasterio

Conversation

@luhenry

@luhenry luhenry commented Sep 4, 2026

Copy link
Copy Markdown
Member

Cython bindings over GDAL for raster I/O. Upstream publishes no riscv64 wheel.

Mirrors the build_wheels/test_wheels jobs of upstream's build-wheels.yaml.

Differs from upstream

  • GDAL/GEOS/PROJ/SpatiaLite built once into a shared image, not per-interpreter - too slow to repeat six times on riscv64.
  • Same image shape as build-pyogrio.yml, but with BUILD_APPS=ON - rasterio's setup.py needs gdal-config/gdalinfo to auto-detect the install.
  • Image adds codec -devel packages so GDAL's PNG/JPEG/GIF/WebP/JPEG2000 drivers are system-linked, not skipped.

Matrix: cp312/cp313/cp314/cp314t/cp315/cp315t - the six ABI tags upstream itself publishes for 1.5.1.

Testing

  • same as upstream

License: wheel bundles GDAL, GEOS, PROJ and SpatiaLite plus the rest of the image's shared-library closure, all permissively licensed; a patch widens the license-files glob to ship all of it.

Patches

  • 0001-pyproject-ship-licence-files-of-bundled-libraries.patch - Inappropriate, no other platform's wheel vendors this dependency closure.

Built on cp312; dependency resolution against our registry verified for cp312 and cp314t.

rasterio is a Cython wrapper around GDAL, which has no riscv64 build
another way; GEOS/PROJ/SpatiaLite/GDAL are compiled from source into a
dedicated manylinux_riscv64 image, the same shape build-pyogrio.yml
already uses for the identical problem.

Patch pyproject.toml's explicit license-files list to pick up the
licences of everything auditwheel vendors from that image.
…64 CI

All six matrix legs failed test_complex_nodata: affine 3.0.1 (published
after 1.5.1 shipped) turns on a PendingDeprecationWarning for the `*`
operator that rasterio's own merge.py still uses, and the test wraps its
call in warnings.simplefilter('error'). Pin affine<3.0.1 to match what
upstream's release actually tested against.

cp314t additionally failed installing hypothesis: it became a Rust
extension and PyPI publishes no cp314t riscv64 wheel for the current
release (only cp310-abi3, incompatible with free threading), so pip's
default resolver falls back to the sdist and rustup can't cross-build
for riscv64. pypi.riseproject.dev already hosts a matching cp314t
wheel at an older hypothesis release; PIP_ONLY_BINARY=hypothesis keeps
pip off the incompatible sdist so it resolves that one instead.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant