diff options
author | Georgy Yakovlev <gyakovlev@gentoo.org> | 2021-06-01 15:19:16 -0700 |
---|---|---|
committer | Georgy Yakovlev <gyakovlev@gentoo.org> | 2021-06-01 15:19:49 -0700 |
commit | 3927c242bb4a54dba21c689dc15657c5c13490ae (patch) | |
tree | a88918211220221c32892015aa9f401bc8960bec /dev-lang | |
parent | app-emulation/fs-uae: Fix building with GCC 11 / C++-17 (diff) | |
download | gentoo-3927c242bb4a54dba21c689dc15657c5c13490ae.tar.gz gentoo-3927c242bb4a54dba21c689dc15657c5c13490ae.tar.bz2 gentoo-3927c242bb4a54dba21c689dc15657c5c13490ae.zip |
dev-lang/rust: make sysroot detection more robust
Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org>
Diffstat (limited to 'dev-lang')
-rw-r--r-- | dev-lang/rust/rust-1.52.1.ebuild | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/dev-lang/rust/rust-1.52.1.ebuild b/dev-lang/rust/rust-1.52.1.ebuild index 42d6f2b17da0..efa716a08b92 100644 --- a/dev-lang/rust/rust-1.52.1.ebuild +++ b/dev-lang/rust/rust-1.52.1.ebuild @@ -279,10 +279,14 @@ src_configure() { local rust_stage0_root if use system-bootstrap; then - rust_stage0_root="$(rustc --print sysroot)" + local printsysroot + printsysroot="$(rustc --print sysroot || die "Can't determine rust's sysroot")" + rust_stage0_root="${printsysroot}" else rust_stage0_root="${WORKDIR}"/rust-stage0 fi + # in case of prefix it will be already prefixed, as --print sysroot returns full path + [[ -d ${rust_stage0_root} ]] || die "${rust_stage0_root} is not a directory" rust_target="$(rust_abi)" |