Materialize legacy libc paths in the x64 sysroot.
Some checks failed
Tagged release / prepare-release (push) Successful in 3m2s
Tagged release / build-linux-x64 (push) Failing after 28m40s
Tagged release / build-macos (push) Has been skipped
Tagged release / build-linux-arm64 (push) Has been skipped
Tagged release / build-windows (push) Has been skipped
Tagged release / publish-release (push) Has been skipped
Some checks failed
Tagged release / prepare-release (push) Successful in 3m2s
Tagged release / build-linux-x64 (push) Failing after 28m40s
Tagged release / build-macos (push) Has been skipped
Tagged release / build-linux-arm64 (push) Has been skipped
Tagged release / build-windows (push) Has been skipped
Tagged release / publish-release (push) Has been skipped
This commit is contained in:
@@ -80,11 +80,26 @@ case "$target" in
|
||||
sudo dpkg-deb --extract "$package" "$sysroot"
|
||||
done
|
||||
|
||||
# Recreate Ubuntu's merged-/usr root links. libc development linker
|
||||
# scripts refer to /lib paths, while libc6 stores the files in
|
||||
# /usr/lib; --sysroot expects the same links as a complete rootfs.
|
||||
sudo ln -s usr/lib "$sysroot/lib"
|
||||
sudo ln -s usr/lib64 "$sysroot/lib64"
|
||||
# libc's development linker scripts use legacy absolute paths even
|
||||
# though Noble stores their targets below /usr. Materialize those few
|
||||
# aliases so GNU ld can resolve them inside the extracted sysroot.
|
||||
legacy_lib="$sysroot/lib/x86_64-linux-gnu"
|
||||
sudo mkdir -p "$legacy_lib" "$sysroot/lib64"
|
||||
for library in libc.so.6 libm.so.6 libmvec.so.1; do
|
||||
source="$sysroot/usr/lib/x86_64-linux-gnu/$library"
|
||||
if [ ! -f "$source" ]; then
|
||||
echo "the downloaded amd64 libc is missing $library" >&2
|
||||
exit 1
|
||||
fi
|
||||
sudo cp -a "$sysroot/usr/lib/x86_64-linux-gnu/$library" "$legacy_lib/"
|
||||
done
|
||||
loader="$sysroot/usr/lib/x86_64-linux-gnu/ld-linux-x86-64.so.2"
|
||||
if [ ! -f "$loader" ]; then
|
||||
echo "the downloaded amd64 libc is missing its dynamic loader" >&2
|
||||
exit 1
|
||||
fi
|
||||
sudo cp -a "$sysroot/usr/lib/x86_64-linux-gnu/ld-linux-x86-64.so.2" \
|
||||
"$sysroot/lib64/"
|
||||
|
||||
# Architecture-independent development packages may already be
|
||||
# installed on the host, so apt does not download them again. Their
|
||||
|
||||
@@ -195,8 +195,9 @@ fn tagged_releases_are_built_and_packaged_with_rust_tools() {
|
||||
"Architectures: arm64",
|
||||
"--download-only",
|
||||
"dpkg-deb --extract",
|
||||
"ln -s usr/lib \"$sysroot/lib\"",
|
||||
"ln -s usr/lib64 \"$sysroot/lib64\"",
|
||||
"libc.so.6 libm.so.6 libmvec.so.1",
|
||||
"cp -a \"$sysroot/usr/lib/x86_64-linux-gnu/$library\"",
|
||||
"cp -a \"$sysroot/usr/lib/x86_64-linux-gnu/ld-linux-x86-64.so.2\"",
|
||||
"/usr/share/pkgconfig/.",
|
||||
"/opt/ruds-x64-sysroot",
|
||||
] {
|
||||
|
||||
Reference in New Issue
Block a user