feat: support maturin alternate src layout#920
Merged
mergify[bot] merged 1 commit intopython-wheel-build:mainfrom Feb 25, 2026
Merged
feat: support maturin alternate src layout#920mergify[bot] merged 1 commit intopython-wheel-build:mainfrom
mergify[bot] merged 1 commit intopython-wheel-build:mainfrom
Conversation
Collaborator
Author
|
PR is blocked by #921 |
654f906 to
3b77a18
Compare
Implement support for maturin's alternate src layout for vendored Rust crates. The alt src layout has `Cargo.toml` and `.cargo` directory in a `rust` directory. The alt src layout is used by `pendulum` package. See: https://www.maturin.rs/project_layout.html#alternate-python-source-directory-src-layout Signed-off-by: Christian Heimes <cheimes@redhat.com>
3b77a18 to
0857420
Compare
Collaborator
Author
|
With the fix, I'm able to build pendulum: $ pip install git+https://github.com/tiran/fromager.git@maturin-alt-src
$ fromager bootstrap pendulum
...
13:42:44 INFO pendulum: downloading source for pendulum
13:42:44 INFO pendulum: saved /opt/app-root/src/sdists-repo/downloads/pendulum-3.2.0.tar.gz
13:42:44 INFO pendulum: preparing source for pendulum from /opt/app-root/src/sdists-repo/downloads/pendulum-3.2.0.tar.gz
13:42:44 INFO pendulum: Use maturin's alternative src layout and alt rust root dir /opt/app-root/src/work-dir/pendulum-3.2.0/pendulum-3.2.0/rust
13:42:44 INFO pendulum: updating vendored rust dependencies in /opt/app-root/src/work-dir/pendulum-3.2.0/pendulum-3.2.0/rust
13:42:46 INFO pendulum: prepared source for pendulum at /opt/app-root/src/work-dir/pendulum-3.2.0/pendulum-3.2.0
13:42:46 INFO pendulum: created build environment in /opt/app-root/src/work-dir/pendulum-3.2.0/build-3.12.9
...
13:44:06 INFO pendulum: getting build backend dependencies for pendulum in /opt/app-root/src/work-dir/pendulum-3.2.0/pendulum-3.2.0
13:44:06 INFO pendulum: getting build sdist dependencies for pendulum in /opt/app-root/src/work-dir/pendulum-3.2.0/pendulum-3.2.0
13:44:06 INFO pendulum: looking for build sdist dependencies in /opt/app-root/src/work-dir/pendulum-3.2.0/pendulum-3.2.0
13:44:06 INFO pendulum: building cpu-ubi9 source distribution for pendulum in /opt/app-root/src/work-dir/pendulum-3.2.0/pendulum-3.2.0
13:44:08 INFO pendulum: built source distribution /opt/app-root/src/sdists-repo/builds/pendulum-3.2.0.tar.gz
13:44:08 INFO pendulum: starting build of toplevel dependency pendulum (3.2.0) for cpu-ubi9
13:44:08 INFO pendulum: building cpu-ubi9 wheel for pendulum in /opt/app-root/src/work-dir/pendulum-3.2.0/pendulum-3.2.0 writing to /opt/app-root/src/wheels-repo/build
13:44:27 INFO pendulum: Requires libraries: libc.so.6, libgcc_s.so.1
13:44:27 INFO pendulum: added extra metadata and build tag (0, ''), wheel renamed from pendulum-3.2.0-cp312-cp312-linux_x86_64.whl to pendulum-3.2.0-0-cp312-cp312-linux_x86_64.whl
13:44:27 INFO pendulum: adding pendulum-3.2.0-0-cp312-cp312-linux_x86_64.whl to local wheel server
13:44:27 INFO pendulum: built wheel for version 3.2.0: /opt/app-root/src/wheels-repo/downloads/pendulum-3.2.0-0-cp312-cp312-linux_x86_64.whl
13:44:27 INFO pendulum: starting post_bootstrap hooks for pendulum==3.2.0, sdist: /opt/app-root/src/sdists-repo/builds/pendulum-3.2.0.tar.gz, wheel_filename: /opt/app-root/src/wheels-repo/downloa
ds/pendulum-3.2.0-0-cp312-cp312-linux_x86_64.whl
13:44:27 INFO pendulum: pendulum: sdist filename 'pendulum-3.2.0.tar.gz' has expected name 'pendulum' and version 3.2.0
13:44:27 INFO pendulum: pendulum: wheel filename 'pendulum-3.2.0-0-cp312-cp312-linux_x86_64.whl' has expected name 'pendulum' and version 3.2.0
13:44:27 INFO pendulum: getting installation dependencies from /opt/app-root/src/wheels-repo/downloads/pendulum-3.2.0-0-cp312-cp312-linux_x86_64.whl
13:44:27 INFO pendulum: adding ('pendulum', '3.2.0') to build order |
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.
Implement support for maturin's alternate src layout for vendored Rust crates. The alt src layout has
Cargo.tomland.cargodirectory in arustdirectory. The alt src layout is used bypendulumpackage.See: https://www.maturin.rs/project_layout.html#alternate-python-source-directory-src-layout