summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorgy Yakovlev <gyakovlev@gentoo.org>2019-03-10 21:46:09 -0700
committerGeorgy Yakovlev <gyakovlev@gentoo.org>2019-03-10 21:51:16 -0700
commit6e428d13d6870832812748de67e48f170cbce6a5 (patch)
treed92c71b0a3edf89b6bdfb5483005b1d5dd9f26b5 /dev-lang
parentnet-libs/libtrace: use HTTPS (diff)
downloadgentoo-6e428d13d6870832812748de67e48f170cbce6a5.tar.gz
gentoo-6e428d13d6870832812748de67e48f170cbce6a5.tar.bz2
gentoo-6e428d13d6870832812748de67e48f170cbce6a5.zip
dev-lang/rust-bin: fix cargo on ppc64
Bug: https://bugs.gentoo.org/679806 Package-Manager: Portage-2.3.62, Repoman-2.3.12 Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org>
Diffstat (limited to 'dev-lang')
-rw-r--r--dev-lang/rust-bin/rust-bin-1.32.0.ebuild13
-rw-r--r--dev-lang/rust-bin/rust-bin-1.33.0.ebuild13
2 files changed, 24 insertions, 2 deletions
diff --git a/dev-lang/rust-bin/rust-bin-1.32.0.ebuild b/dev-lang/rust-bin/rust-bin-1.32.0.ebuild
index a2af32c2885b..170a05bf8146 100644
--- a/dev-lang/rust-bin/rust-bin-1.32.0.ebuild
+++ b/dev-lang/rust-bin/rust-bin-1.32.0.ebuild
@@ -76,7 +76,18 @@ src_install() {
dosym "../../opt/${P}/bin/${rustlldb}" "/usr/bin/${rustlldb}"
local cargo=cargo-bin-${PV}
- mv "${D}/opt/${P}/bin/cargo" "${D}/opt/${P}/bin/${cargo}" || die
+ # ugly hack for https://bugs.gentoo.org/679806
+ if use ppc64; then
+ mv "${D}/opt/${P}/bin/cargo" "${D}/opt/${P}/bin/${cargo}".bin || die
+ sed -i 's/getentropy/gEtEnTrOpY/g' "${D}/opt/${P}/bin/${cargo}".bin || die
+ cat <<- 'EOF' > "${D}/opt/${P}/bin/${cargo}"
+ #!/bin/sh
+ OPENSSL_ppccap=0 $(realpath $0).bin "${@}"
+ EOF
+ fperms +x "/opt/${P}/bin/${cargo}"
+ else
+ mv "${D}/opt/${P}/bin/cargo" "${D}/opt/${P}/bin/${cargo}" || die
+ fi
dosym "../../opt/${P}/bin/${cargo}" "/usr/bin/${cargo}"
if use clippy; then
local clippy_driver=clippy-driver-bin-${PV}
diff --git a/dev-lang/rust-bin/rust-bin-1.33.0.ebuild b/dev-lang/rust-bin/rust-bin-1.33.0.ebuild
index a2af32c2885b..170a05bf8146 100644
--- a/dev-lang/rust-bin/rust-bin-1.33.0.ebuild
+++ b/dev-lang/rust-bin/rust-bin-1.33.0.ebuild
@@ -76,7 +76,18 @@ src_install() {
dosym "../../opt/${P}/bin/${rustlldb}" "/usr/bin/${rustlldb}"
local cargo=cargo-bin-${PV}
- mv "${D}/opt/${P}/bin/cargo" "${D}/opt/${P}/bin/${cargo}" || die
+ # ugly hack for https://bugs.gentoo.org/679806
+ if use ppc64; then
+ mv "${D}/opt/${P}/bin/cargo" "${D}/opt/${P}/bin/${cargo}".bin || die
+ sed -i 's/getentropy/gEtEnTrOpY/g' "${D}/opt/${P}/bin/${cargo}".bin || die
+ cat <<- 'EOF' > "${D}/opt/${P}/bin/${cargo}"
+ #!/bin/sh
+ OPENSSL_ppccap=0 $(realpath $0).bin "${@}"
+ EOF
+ fperms +x "/opt/${P}/bin/${cargo}"
+ else
+ mv "${D}/opt/${P}/bin/cargo" "${D}/opt/${P}/bin/${cargo}" || die
+ fi
dosym "../../opt/${P}/bin/${cargo}" "/usr/bin/${cargo}"
if use clippy; then
local clippy_driver=clippy-driver-bin-${PV}