Lines 12-17
Link Here
|
12 |
DESCRIPTION="Systems programming language from Mozilla" |
12 |
DESCRIPTION="Systems programming language from Mozilla" |
13 |
HOMEPAGE="https://www.rust-lang.org/" |
13 |
HOMEPAGE="https://www.rust-lang.org/" |
14 |
SRC_URI="$(rust_all_arch_uris ${MY_P}) |
14 |
SRC_URI="$(rust_all_arch_uris ${MY_P}) |
|
|
15 |
abi_x86_x32? ( "${RUST_TOOLCHAIN_BASEURL%/}/2022-04-07/rust-std-${PV}-x86_64-unknown-linux-gnux32.tar.xz" ) |
15 |
rust-src? ( ${MY_SRC_URI} ) |
16 |
rust-src? ( ${MY_SRC_URI} ) |
16 |
" |
17 |
" |
17 |
|
18 |
|
Lines 32-38
Link Here
|
32 |
verify-sig? ( sec-keys/openpgp-keys-rust ) |
33 |
verify-sig? ( sec-keys/openpgp-keys-rust ) |
33 |
" |
34 |
" |
34 |
|
35 |
|
35 |
REQUIRED_USE="x86? ( cpu_flags_x86_sse2 )" |
36 |
REQUIRED_USE=" |
|
|
37 |
x86? ( cpu_flags_x86_sse2 ) |
38 |
abi_x86_x32? ( abi_x86_64 ) |
39 |
" |
36 |
|
40 |
|
37 |
QA_PREBUILT=" |
41 |
QA_PREBUILT=" |
38 |
opt/${P}/bin/.* |
42 |
opt/${P}/bin/.* |
Lines 68-74
Link Here
|
68 |
|
72 |
|
69 |
default_src_unpack |
73 |
default_src_unpack |
70 |
|
74 |
|
71 |
mv "${WORKDIR}/${MY_P}-$(rust_abi)" "${S}" || die |
75 |
# x32 is provided as a target for the amd64 install |
|
|
76 |
if [[ "${ABI}" != x32 ]]; then |
77 |
mv "${WORKDIR}/${MY_P}-$(rust_abi)" "${S}" || die |
78 |
fi |
72 |
} |
79 |
} |
73 |
|
80 |
|
74 |
patchelf_for_bin() { |
81 |
patchelf_for_bin() { |
Lines 94-99
Link Here
|
94 |
use clippy && components="${components},clippy-preview" |
101 |
use clippy && components="${components},clippy-preview" |
95 |
use rls && components="${components},rls-preview,${analysis}" |
102 |
use rls && components="${components},rls-preview,${analysis}" |
96 |
use rustfmt && components="${components},rustfmt-preview" |
103 |
use rustfmt && components="${components},rustfmt-preview" |
|
|
104 |
if use abi_x86_x32; then |
105 |
einfo "Adding x32 target to x86-64 rust" |
106 |
mv -v "${WORKDIR}/rust-std-${PV}-x86_64-unknown-linux-gnux32/rust-std-x86_64-unknown-linux-gnux32" "${S}" || die |
107 |
echo rust-std-x86_64-unknown-linux-gnux32 >> ./components || die |
108 |
components="${components},rust-std-x86_64-unknown-linux-gnux32" |
109 |
fi |
97 |
# Rust component 'rust-src' is extracted from separate archive |
110 |
# Rust component 'rust-src' is extracted from separate archive |
98 |
if use rust-src; then |
111 |
if use rust-src; then |
99 |
einfo "Combining rust and rust-src installers" |
112 |
einfo "Combining rust and rust-src installers" |
Lines 188-198
Link Here
|
188 |
#end native abi install |
201 |
#end native abi install |
189 |
|
202 |
|
190 |
else |
203 |
else |
191 |
local rust_target |
204 |
if [[ "${ABI}" != x32 ]]; then |
192 |
rust_target="$(rust_abi $(get_abi_CHOST ${v##*.}))" |
205 |
local rust_target |
193 |
dodir "/opt/${P}/lib/rustlib" |
206 |
rust_target="$(rust_abi $(get_abi_CHOST ${v##*.}))" |
194 |
cp -vr "${WORKDIR}/rust-${PV}-${rust_target}/rust-std-${rust_target}/lib/rustlib/${rust_target}"\ |
207 |
dodir "/opt/${P}/lib/rustlib" |
195 |
"${ED}/opt/${P}/lib/rustlib" || die |
208 |
cp -vr "${WORKDIR}/rust-${PV}-${rust_target}/rust-std-${rust_target}/lib/rustlib/${rust_target}"\ |
|
|
209 |
"${ED}/opt/${P}/lib/rustlib" || die |
210 |
fi |
196 |
fi |
211 |
fi |
197 |
|
212 |
|
198 |
# BUG: installs x86_64 binary on other arches |
213 |
# BUG: installs x86_64 binary on other arches |