-
Couldn't load subscription status.
- Fork 517
Add support for self-contained object files (musl).
#829
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
self-contained files.self-contained object files.
|
I also wrote this script to find what artifacts contained the #!/bin/bash
set -euo pipefail
MUSL=(
rust-std-1.26.0-aarch64-unknown-linux-musl
rust-std-1.26.0-x86_64-unknown-linux-musl
rust-std-1.36.0-aarch64-unknown-linux-musl
rust-std-1.36.0-aarch64-unknown-linux-musl
rust-std-1.45.0-aarch64-unknown-linux-musl
rust-std-1.45.0-x86_64-unknown-linux-musl
rust-std-1.46.0-aarch64-unknown-linux-musl
rust-std-1.46.0-x86_64-unknown-linux-musl
rust-std-1.53.0-aarch64-unknown-linux-musl
)
OTHER=(
rust-std-1.45.0-x86_64-apple-darwin
rust-std-1.45.0-wasm32-unknown-unknown
rust-std-1.45.0-x86_64-pc-windows-msvc
rust-std-1.46.0-x86_64-apple-darwin
rust-std-1.46.0-wasm32-unknown-unknown
rust-std-1.46.0-x86_64-pc-windows-msvc
)
function find_self_contained() {
temp_dir="$(mktemp -d -t rust-self-contained)"
pushd "${temp_dir}"
for art in ${@}; do
echo "${art}"
wget --quiet https://static.rust-lang.org/dist/${art}.tar.gz
tar -xf "${art}.tar.gz"
find "${art}" -name "self-contained" -exec tree {} \;
done
popd && rm -rf "${temp_dir}"
}
echo "Test MUSL"
find_self_contained ${MUSL[@]}
echo "Test OTHER"
find_self_contained ${OTHER[@]} |
|
Also, I'm not sure how to add a test for |
db51b64 to
e3c8e49
Compare
self-contained object files.self-contained object files (musl).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't feel like I have enough context to really review this (or indeed to suggest how to test it on CI), but in general the change looks reasonable? If anyone has more context, it'd be great for them to review, otherwise I can somewhat unknowingly approve...
|
Is there a way we could have a test? |
I had the same question (#829 (comment)) and opened bazelbuild/continuous-integration#1190 to try and answer it. Any suggestions? |
In newer
rust-stdartifacts there is aself-containeddirectory which contains some.ofiles. These are currently ignored but without them the rules cannot targetmusland users will see a similar linker error:These files appear to have been introduced in Rust
1.46.0. They seem related to rust-lang/rust#70740 but I'm still not clear what mechanism actually generates and installs these directories in the artifacts.Regardless, this change addresses these linker issues without impacting other target triples as far as I can tell.