docs: Add crosscompiling example#5793
Merged
ruben-arts merged 6 commits intoprefix-dev:mainfrom Apr 17, 2026
Merged
Conversation
ruben-arts
reviewed
Mar 30, 2026
Contributor
ruben-arts
left a comment
There was a problem hiding this comment.
Thanks for the write up! I would like to ask @wolfv to review the content more.
Comment on lines
+295
to
+296
| unzip -q output/YOUR_PACKAGE.conda -d tmp && \ | ||
| tar --use-compress-program=unzstd -xf tmp/info-*.tar.zst -C tmp && \ |
Contributor
There was a problem hiding this comment.
Did you know you could do this part with rattler-build package extract?
Contributor
Author
There was a problem hiding this comment.
I did not know that this was possible ! I will give it a try and update the documentation
ruben-arts
approved these changes
Apr 17, 2026
Contributor
ruben-arts
left a comment
There was a problem hiding this comment.
Sorry for the review delay. Nice work, thanks!
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.
Description
Following a discussion on Discord about cross-compiling with nanobind, we identified a working solution based on the pixi-build-rattler-build backend. This issue proposes adding a dedicated example to the documentation to help others facing the same challenge.
Cross-compiling Python extensions with nanobind can be non-trivial, especially when targeting platforms different from the build environment. The approach we explored leverages the pixi-build-rattler-build backend to handle dependencies and build configuration in a reproducible way.
Including a minimal, well-documented example would:
You can find in this PR the example, that as been tested locally and fully woking.