Install Cython .pxd files for third-party acb_t cimport - #428
Open
djoubertthot wants to merge 1 commit into
Open
Install Cython .pxd files for third-party acb_t cimport#428djoubertthot wants to merge 1 commit into
djoubertthot wants to merge 1 commit into
Conversation
The wheels currently ship only .py/.pyi/.pyd, so another Cython extension cannot cimport flint.types.acb and call libflint on acb.val. Install the declaration files next to the extensions, including flintlib. Compiling still needs the FLINT C headers; the Windows PyPI wheel ships libflint without them.
Collaborator
|
See prior discussion in gh-420 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
The published wheels ship
.py/.pyi/ extension modules but not the Cython.pxdfiles. A third-party Cython extension therefore cannotacb.valis the underlyingacb_t. That is the supported way to call libflint in a tight loop without going through Python method dispatch.This showed up when building a Booker
Lambda_thetatrapezoid against python-flint 0.9.0 on Windows: the wheel haslibflint, the site-package has noacb.pxd.What
pyflint.pxd,flint_base/*.pxd,types/*.pxd,utils/*.pxd.flintlib(hand-written types + generated function declarations) socimport flint.flintlib.functions.acbworks after pip install.flint.__file__.flint/acb.h).Compiling an extension that uses these pxd files still requires a FLINT development install (headers + import library), matching the python-flint FLINT version.