Skip to content

finufft: Add version 2.5.1 - #3331

Draft
luhenry wants to merge 4 commits into
mainfrom
finufft
Draft

luhenry wants to merge 4 commits into
mainfrom
finufft

Conversation

@luhenry

@luhenry luhenry commented Oct 15, 2026 •

Copy link
Copy Markdown
Member

Compiles libfinufft.so (non-uniform FFT library), loaded via ctypes rather than the CPython C-API, hence the py3-none ABI tag despite being a genuine per-platform compiled build - confirmed from the published x86_64 wheel's contents (finufft/libfinufft.so + statically-built FFTW libs). Upstream publishes no riscv64 wheel.

Mirrors the Linux leg of upstream's build_finufft_wheels.yml (package-dir: python/finufft).

Differs from upstream

  • Overrides FINUFFT_ARCH_FLAGS to empty - upstream's pyproject.toml hardcodes -march=x86-64 for every platform via its own config-settings
  • FFTW is fetched and built from source by CMake, same as upstream; no external dependency
  • Installs openssl-devel in before-all - upstream pins cmake<4, which has no riscv64 wheel, so pip compiles CMake 3.x from source and its bootstrap needs OpenSSL headers

Matrix: single py3-none build (wheel.py-api = "py3" collapses the matrix)

Testing

  • same as upstream (pytest {project}/python/finufft/test, inherited from upstream's own [tool.cibuildwheel])

License: Wheel bundles FFTW (GPL-2.0-or-later), statically linked and built from source; upstream ships no licence text for it or for its own LICENSE, so the build adds both.

Patches

  • 0001-license-files.patch - Inappropriate (licensing gap, not riscv64-specific). Declares license = "Apache-2.0" + license-files so the wheel ships LICENSE + FFTW's LICENSE.fftw, and drops the License :: classifier that pyproject-metadata rejects alongside an SPDX licence.

Built on cp312; CI pending.

scikit-build-core/CMake build of libfinufft.so, loaded via ctypes (hence the
py3-none ABI tag despite being a genuine per-platform compiled artifact,
confirmed from the published x86_64 wheel's contents). FFTW is fetched and
built from source by CMake, no external riscv64-missing dependency. Overrides
FINUFFT_ARCH_FLAGS to empty on riscv64 (upstream hardcodes -march=x86-64 in
pyproject.toml for all platforms otherwise). Adds a licence patch: upstream
declares no license-files, so the wheel ships neither its own LICENSE nor
FFTW's (GPL-2.0-or-later, statically linked).
Upstream's pyproject.toml pins tool.cibuildwheel.linux.musllinux-x86_64-image
to the "musllinux_1_1" alias, which cibuildwheel 4.x no longer resolves.
cibuildwheel validates that value at config-load time regardless of the
selected CIBW_ARCHS/CIBW_BUILD, so the riscv64-only, manylinux-only build
failed before even starting. Override it to a supported alias.
…clash

{project} is the finufft checkout root and {package} is python/finufft, so
before-build copied LICENSE from a path above the container root and
staged both licence files next to the wrong pyproject.toml. Stage them in
{package}, where the patched license-files glob looks.

Drop the CIBW_TEST_COMMAND/CIBW_TEST_REQUIRES overrides: upstream's own
[tool.cibuildwheel] already runs pytest {project}/python/finufft/test,
while the override pointed at the C++ test/ directory.

pyproject-metadata rejects an SPDX project.license combined with a
"License ::" classifier, so the patch now drops that classifier too.
…ndency

Upstream's build-system.requires pins cmake (>= 3.19, < 4), and no
riscv64 cmake wheel exists below 4.x, so pip compiles CMake 3.31 from its
sdist. That bootstrap's cmcurl needs OpenSSL's development headers, which
the manylinux_riscv64 image does not ship (gotcha 608).

This branch has not been deployed

No deployments
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