diff options
author | Georgy Yakovlev <gyakovlev@gentoo.org> | 2022-09-22 21:43:12 -0700 |
---|---|---|
committer | Georgy Yakovlev <gyakovlev@gentoo.org> | 2022-09-22 21:49:45 -0700 |
commit | 0433bdce4b55fe0d3fb0071bcb826af0acef7d4d (patch) | |
tree | 9f9305b9b69c412f2b5324e4e12223f88956303f /dev-lang/rust-bin | |
parent | app-emulation/vkd3d: add 1.5 (diff) | |
download | gentoo-0433bdce4b55fe0d3fb0071bcb826af0acef7d4d.tar.gz gentoo-0433bdce4b55fe0d3fb0071bcb826af0acef7d4d.tar.bz2 gentoo-0433bdce4b55fe0d3fb0071bcb826af0acef7d4d.zip |
dev-lang/rust-bin: improve musl envd file in 1.64.0
Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org>
Diffstat (limited to 'dev-lang/rust-bin')
-rw-r--r-- | dev-lang/rust-bin/rust-bin-1.64.0.ebuild | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/dev-lang/rust-bin/rust-bin-1.64.0.ebuild b/dev-lang/rust-bin/rust-bin-1.64.0.ebuild index 9e2846e0a8ac..9e7e4048e675 100644 --- a/dev-lang/rust-bin/rust-bin-1.64.0.ebuild +++ b/dev-lang/rust-bin/rust-bin-1.64.0.ebuild @@ -152,12 +152,14 @@ multilib_src_install() { dosym "../../opt/${P}/lib/rustlib" "/usr/lib/rustlib-bin-${PV}" dosym "../../../opt/${P}/share/doc/rust" "/usr/share/doc/${P}" - # musl logic can be improved a bit, but fine as is for now + # make all capital underscored variable + local CARGO_TRIPLET="$(rust_abi)" + CARGO_TRIPLET="${CARGO_TRIPLET//-/_}" + CARGO_TRIPLET="${CARGO_TRIPLET^^}" cat <<-_EOF_ > "${T}/50${P}" LDPATH="${EPREFIX}/usr/lib/rust/lib" MANPATH="${EPREFIX}/usr/lib/rust/man" - $(use amd64 && usex elibc_musl 'CARGO_TARGET_X86_64_UNKNOWN_LINUX_MUSL_RUSTFLAGS="-C target-feature=-crt-static"' '') - $(use arm64 && usex elibc_musl 'CARGO_TARGET_AARCH64_UNKNOWN_LINUX_MUSL_RUSTFLAGS="-C target-feature=-crt-static"' '') + $(usev elibc_musl "CARGO_TARGET_${CARGO_TRIPLET}_RUSTFLAGS=\"-C target-feature=-crt-static\"") _EOF_ doenvd "${T}/50${P}" |