feat: add INCLUDE_DIRECTORIES keyword to cython_transpile#91
Merged
Conversation
Adds an INCLUDE_DIRECTORIES multi-value keyword that maps each entry to `-I <dir>` on the cython CLI, resolving relative paths against the current source dir. This gives a dedicated way to consume cimport-able .pxd files installed by another package instead of overloading CYTHON_ARGS. Also documents the inter-package .pxd install/consume pattern in the README. Assisted-by: ClaudeCode:claude-opus-4-8
henryiii
marked this pull request as ready for review
July 9, 2026 21:43
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.
🤖 AI text below 🤖
Adds an
INCLUDE_DIRECTORIESmulti-value keyword tocython_transpilethat maps each entry to-I <dir>on the cython CLI, resolving relative paths againstCMAKE_CURRENT_SOURCE_DIR. This is a dedicated place to point Cython atcimport-able.pxdfiles installed by another package, rather than overloading the singleCYTHON_ARGSescape hatch.cimported.pxdfiles reached this way are still tracked in the depfile, so incremental rebuilds work.The README gains a "Sharing
.pxdfiles between packages" section covering the provider (install(FILES foo.pxd ...)) and consumer (INCLUDE_DIRECTORIESpointed at the installed package located viaPython_EXECUTABLE) sides.A new
include_directoriesfixture and test exercise acimportthat only resolves via the new keyword.Addresses item 4 of the first comment on #84.