1 |
commit: 437ffbb4cc5dd7be1dec97c2ecde56da0238fa84 |
2 |
Author: Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Aug 27 17:24:44 2020 +0000 |
4 |
Commit: Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Aug 27 18:28:10 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=437ffbb4 |
7 |
|
8 |
dev-lang/rust-bin: bump to 1.46.0 |
9 |
|
10 |
Package-Manager: Portage-3.0.4, Repoman-3.0.1 |
11 |
Signed-off-by: Georgy Yakovlev <gyakovlev <AT> gentoo.org> |
12 |
|
13 |
dev-lang/rust-bin/Manifest | 14 +++ |
14 |
dev-lang/rust-bin/rust-bin-1.46.0.ebuild | 187 +++++++++++++++++++++++++++++++ |
15 |
2 files changed, 201 insertions(+) |
16 |
|
17 |
diff --git a/dev-lang/rust-bin/Manifest b/dev-lang/rust-bin/Manifest |
18 |
index 9a1b72d84fd..df15c422bf0 100644 |
19 |
--- a/dev-lang/rust-bin/Manifest |
20 |
+++ b/dev-lang/rust-bin/Manifest |
21 |
@@ -26,3 +26,17 @@ DIST rust-1.45.2-powerpc64le-unknown-linux-gnu.tar.xz 118941136 BLAKE2B 96b297b0 |
22 |
DIST rust-1.45.2-s390x-unknown-linux-gnu.tar.xz 125144128 BLAKE2B 66d8ee3b94b427cd55f8b662cae9f3b86ea108706c51bedfbc6e68018b40a7d0ad1162eb649b4af3c60e425c46cbdb23ef966d670abd698df383eae834a3b854 SHA512 7727cfbeed29e8a1e79398392332b25b5498900f593f3d08414c70b44da0cd06dca0791a361956c47c3367e6572d59d885085d3cd99fd4a9c28c431a158ddbfd |
23 |
DIST rust-1.45.2-x86_64-unknown-linux-gnu.tar.xz 118135364 BLAKE2B 0ad1277674284d29c4e4bc1cdf0163794caf37e39d28381f4dac29303381690a0c125fb2a56437ca735746c2bd6de7961dbfd325808939758ee2d4a15d72aec2 SHA512 dfd3ce0cc42ae82a2d13866c5c94c304b031e253a1485ccc1d6ecd62cc05018b01ac7b2183297bc45ada286b5e91d1344aa3d8417694ab834f8265c7838b4fd2 |
24 |
DIST rust-1.45.2-x86_64-unknown-linux-musl.tar.xz 124782956 BLAKE2B dac6f48204aee39598a5c83c16b6b1bfbd239a8842bc681450645ef4b7f030666694e6f005473933a5613e5545fc80b9090c0aeb3b3db3a213d8899a7e90e5bf SHA512 14f556599b29f85c4bac39774142e580dbbe68268a16d32f539169defc73353a3c9fd44835358bc53262db43345bb139d14143dd5b6ae64823b9c98b25c4eb75 |
25 |
+DIST rust-1.46.0-aarch64-unknown-linux-gnu.tar.xz 127384736 BLAKE2B a1efd25cf429a309a454ef5db38c68d642920e859ef6effbe88ace7f3c4050ae7e9cf10d2f5b70405475ffcbbbc80338e3a5e4b3cb632c555e31a0ebc1b76cd4 SHA512 53e5d8afadaa9505286dce4acbb911126d17bc7bf45ea4685070ff07be7f6c7860e543a7686eeac695e7e3e127ca38ba2f09b73467fbf5f92d0b2195467c51f2 |
26 |
+DIST rust-1.46.0-arm-unknown-linux-gnueabi.tar.xz 121741008 BLAKE2B d277cb19c9f9641f216eba9ddb8bdb0a1bf70b7376e82798dad3116ff6d976c6ec8f6442831ae6a3c64cfdb46c59cf47b482df5200af49ba5eeccb663538084b SHA512 74cc1c8f56c88bdb669d52edca69c8aed7500e51498e8bf4099b2edbf85a2beab1e6d447029eb24e12fdfcbf2272f5d8b741eb4aa48fe83dac44759478429284 |
27 |
+DIST rust-1.46.0-arm-unknown-linux-gnueabihf.tar.xz 120726564 BLAKE2B 5ef9c319d4744016e336a8d8bde99b2b9183dd13fc6873d4f0e239a52a86e054d42ee48ca1a84ac42d140b1bbe234f4eeaf90717f14959ad6966681429eef233 SHA512 89972cc03c05dd5bc003f6cf16e062b935b3fda288ae0c3d32a3d08ccdcbf7699c306aa3c017a13e76f13f8dca7a951ec98f23507de978ae87cffb6d6907af5c |
28 |
+DIST rust-1.46.0-armv7-unknown-linux-gnueabihf.tar.xz 123912836 BLAKE2B 97cdb2e8d643826f7dd1554096e14c58c35b38cc2eebb49c478343bf8bc157995a9f1099c014800701d34edbf0f0798ac29babbd2a5bf261d1956bc731b0a99c SHA512 c7e320fd5169c99bf8a12fb5bf1c5fb19a05d14f75ce655e4b64cad3456594ef09be1da7ac34a09b5d84da0c857d1a6e5a0695b5ff04cda491ea92fea15d28dc |
29 |
+DIST rust-1.46.0-i686-unknown-linux-gnu.tar.xz 141319800 BLAKE2B 712227e42b8597ee1c645cb344042e79ca40aef0e22d783c4a0c042bd07f686aafd9b80bebe0dfe69b4b012056509bfe510fffa8ba5357656d459fe5885fe0fe SHA512 b01e9b06c9de50e43bc6b5e1a5e6cc49dab1cf28b9cf0a8b974d2630c7ed4c6a5df6f321c872e11eb622c42f1d8cfaec77c1b67254a84365464fe3415acfa07f |
30 |
+DIST rust-1.46.0-mips-unknown-linux-gnu.tar.xz 110175584 BLAKE2B 23e38e81d281d0df23795ff60e4a7503f63d443d966bc6d5068edc50fc0dd90e2fe45eb90b901a1fb3f8f813375533eaa142d625b661f5d76d2097b0cf572606 SHA512 0635060dd15f548834e5c946ec8deea10bf234f550f6a01d4d491f45e0d5f16e957f99caba14c91225d100e7c59e909869b816dfffe9f8681c09e9e5b6ca2bdd |
31 |
+DIST rust-1.46.0-mips64-unknown-linux-gnuabi64.tar.xz 117357812 BLAKE2B c3118a0b710ceaffda8523840551306d4bbc7c78fc26016fc1ac0037c2a7cd68f56c11999f7e3bc435f93e0dbebf348fdc52255cc5978bdffb2d55dc9d56e23e SHA512 5dc6de40429e72ecad9546390f1f5e626d388938c7bc50a56fb258787b45e8d7363170d8d1a2bff56fbd8bef22060b6cb0c50fb016ccc7d4fb767ba6b7e80c2d |
32 |
+DIST rust-1.46.0-mipsel-unknown-linux-gnu.tar.xz 111804692 BLAKE2B 4779d5602f2107321d5c6042dce1baaf6eec2f60cf2ba4330bf72fda0868d7e8294cf573b3ffab3654a0689d11599f2fc37430005686e91439abc7ae6fefb977 SHA512 3c9d17fa89636d37e125d7665883abc9912330d4a1f5291d44771fd1cbb17d604deccc07685cb567f1b141dde3668d5ef55f3661b04e4506d5337d69acc6738c |
33 |
+DIST rust-1.46.0-powerpc-unknown-linux-gnu.tar.xz 111495200 BLAKE2B d618c61a05507abe13d1294594187a4552896cb61396c2f8bd6e506a71ab4bb5cd26ae3b2b573d1d5a4ea79fb4dd2238a2ae34059357ef397264beb0b67cbc34 SHA512 38df2204bd4bfe7371365266651a84da218ba909c3ae107432f6fef892e71488d193b8f54fe6738edd91aa0ca029038d864806b25289254711bd10f736bcc2d7 |
34 |
+DIST rust-1.46.0-powerpc64-unknown-linux-gnu.tar.xz 124882812 BLAKE2B 2362e25d39cfd2039ce18db08f43bceaaccd208ec113c16f6718803eadda964bb254a6afc606765a00026adc93cf366495d3546d6aac8a7444088f519d421c9b SHA512 40f9423d838cab74b9920372e728c4ca7057005d83af587387dd2b164a0bf93de65cebc035320bce25f80914c63ce65b84218b9a776b0b905428e4cba0821b8b |
35 |
+DIST rust-1.46.0-powerpc64le-unknown-linux-gnu.tar.xz 130200900 BLAKE2B d38a7f131983aee27e6af59ab03999e7420745a0f9256b2623e71f36dd6f12605025dbdc510bd5ffb73e0d31a5c7e56a791bdf718b2eba629d08e2f75221b1c8 SHA512 986f0bf7995f35836b73fb7045cf43ae5efe0c2543c75c66cdcc0f8c1dd3513def3c291e021241e328142deaca690ce113526ffc870c4412a7841f244258a43e |
36 |
+DIST rust-1.46.0-s390x-unknown-linux-gnu.tar.xz 134521076 BLAKE2B d3efd71dd7db812736680929185ad5f58a2dbf7d1b8a6f851834dd7b41713fc171dbcdf2472bedc13751bfeed58070d919d2a1138765ab75c0f4bdf817cb6418 SHA512 b6146695225ff6d0516e7bb6bc4620599356bb89b14f429a09d9d7f8715a94e8e218402346d5c9a10eeb54c0bdc40fb179289216b0cb4edd5bdf886f6b69aab4 |
37 |
+DIST rust-1.46.0-x86_64-unknown-linux-gnu.tar.xz 127200200 BLAKE2B 7d755e0622cda99d111490197b21ff4aaeb7b13292804566bc677b7b1d833eaa644b7a801863a1a01e3aa34be28a80344cae69edc57f8c8788884c78e037b750 SHA512 95f5adc2d2137010c7e5ac8a0fc70485250b4f9a909cb8b164b35fffff76ab88e9b09d305bfac37324ed080c5fc7643001d2abec5454ca911dc3513f1af52c88 |
38 |
+DIST rust-1.46.0-x86_64-unknown-linux-musl.tar.xz 142372372 BLAKE2B 7d3672234b61b772e2311127db569b37296bf3a9bf86841fb78c6d20da6a6abfc6c866ba4aa7cc44c12eebb0744fbeb401b491314db9eb481b926792cadcca22 SHA512 e2599c4c10fe9725e63524d89c0be869d43347620b0f6ff1a93cee5e7219f5560c6171d8eda99e5624eba60b9d488bfe0942c23eacdbac2ba42e4cd63f14b7c9 |
39 |
|
40 |
diff --git a/dev-lang/rust-bin/rust-bin-1.46.0.ebuild b/dev-lang/rust-bin/rust-bin-1.46.0.ebuild |
41 |
new file mode 100644 |
42 |
index 00000000000..6e586df2fca |
43 |
--- /dev/null |
44 |
+++ b/dev-lang/rust-bin/rust-bin-1.46.0.ebuild |
45 |
@@ -0,0 +1,187 @@ |
46 |
+# Copyright 1999-2020 Gentoo Authors |
47 |
+# Distributed under the terms of the GNU General Public License v2 |
48 |
+ |
49 |
+EAPI=7 |
50 |
+ |
51 |
+inherit bash-completion-r1 rust-toolchain toolchain-funcs multilib-minimal |
52 |
+ |
53 |
+MY_P="rust-${PV}" |
54 |
+ |
55 |
+DESCRIPTION="Systems programming language from Mozilla" |
56 |
+HOMEPAGE="https://www.rust-lang.org/" |
57 |
+SRC_URI="$(rust_all_arch_uris ${MY_P})" |
58 |
+ |
59 |
+LICENSE="|| ( MIT Apache-2.0 ) BSD-1 BSD-2 BSD-4 UoI-NCSA" |
60 |
+SLOT="stable" |
61 |
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86" |
62 |
+IUSE="clippy cpu_flags_x86_sse2 doc rls rustfmt" |
63 |
+ |
64 |
+DEPEND="" |
65 |
+RDEPEND=">=app-eselect/eselect-rust-20190311" |
66 |
+ |
67 |
+REQUIRED_USE="x86? ( cpu_flags_x86_sse2 )" |
68 |
+ |
69 |
+QA_PREBUILT=" |
70 |
+ opt/${P}/bin/*-${PV} |
71 |
+ opt/${P}/lib/*.so |
72 |
+ opt/${P}/lib/rustlib/*/bin/* |
73 |
+ opt/${P}/lib/rustlib/*/lib/*.so |
74 |
+ opt/${P}/lib/rustlib/*/lib/*.rlib* |
75 |
+" |
76 |
+ |
77 |
+pkg_pretend() { |
78 |
+ if [[ "$(tc-is-softfloat)" != "no" ]] && [[ ${CHOST} == armv7* ]]; then |
79 |
+ die "${CHOST} is not supported by upstream Rust. You must use a hard float version." |
80 |
+ fi |
81 |
+} |
82 |
+ |
83 |
+src_unpack() { |
84 |
+ default |
85 |
+ mv "${WORKDIR}/${MY_P}-$(rust_abi)" "${S}" || die |
86 |
+} |
87 |
+ |
88 |
+multilib_src_install() { |
89 |
+ if multilib_is_native_abi; then |
90 |
+ |
91 |
+ # start native abi install |
92 |
+ pushd "${S}" >/dev/null || die |
93 |
+ local analysis std |
94 |
+ analysis="$(grep 'analysis' ./components)" |
95 |
+ std="$(grep 'std' ./components)" |
96 |
+ local components="rustc,cargo,${std}" |
97 |
+ use doc && components="${components},rust-docs" |
98 |
+ use clippy && components="${components},clippy-preview" |
99 |
+ use rls && components="${components},rls-preview,${analysis}" |
100 |
+ use rustfmt && components="${components},rustfmt-preview" |
101 |
+ ./install.sh \ |
102 |
+ --components="${components}" \ |
103 |
+ --disable-verify \ |
104 |
+ --prefix="${ED}/opt/${P}" \ |
105 |
+ --mandir="${ED}/opt/${P}/man" \ |
106 |
+ --disable-ldconfig \ |
107 |
+ || die |
108 |
+ |
109 |
+ local rustc=rustc-bin-${PV} |
110 |
+ local rustdoc=rustdoc-bin-${PV} |
111 |
+ local rustgdb=rust-gdb-bin-${PV} |
112 |
+ local rustgdbgui=rust-gdbgui-bin-${PV} |
113 |
+ local rustlldb=rust-lldb-bin-${PV} |
114 |
+ |
115 |
+ mv "${ED}/opt/${P}/bin/rustc" "${ED}/opt/${P}/bin/${rustc}" || die |
116 |
+ mv "${ED}/opt/${P}/bin/rustdoc" "${ED}/opt/${P}/bin/${rustdoc}" || die |
117 |
+ mv "${ED}/opt/${P}/bin/rust-gdb" "${ED}/opt/${P}/bin/${rustgdb}" || die |
118 |
+ mv "${ED}/opt/${P}/bin/rust-gdbgui" "${ED}/opt/${P}/bin/${rustgdbgui}" || die |
119 |
+ mv "${ED}/opt/${P}/bin/rust-lldb" "${ED}/opt/${P}/bin/${rustlldb}" || die |
120 |
+ |
121 |
+ dosym "${rustc}" "/opt/${P}/bin/rustc" |
122 |
+ dosym "${rustdoc}" "/opt/${P}/bin/rustdoc" |
123 |
+ dosym "${rustgdb}" "/opt/${P}/bin/rust-gdb" |
124 |
+ dosym "${rustgdbgui}" "/opt/${P}/bin/rust-gdbgui" |
125 |
+ dosym "${rustlldb}" "/opt/${P}/bin/rust-lldb" |
126 |
+ |
127 |
+ dosym "../../opt/${P}/bin/${rustc}" "/usr/bin/${rustc}" |
128 |
+ dosym "../../opt/${P}/bin/${rustdoc}" "/usr/bin/${rustdoc}" |
129 |
+ dosym "../../opt/${P}/bin/${rustgdb}" "/usr/bin/${rustgdb}" |
130 |
+ dosym "../../opt/${P}/bin/${rustgdbgui}" "/usr/bin/${rustgdbgui}" |
131 |
+ dosym "../../opt/${P}/bin/${rustlldb}" "/usr/bin/${rustlldb}" |
132 |
+ |
133 |
+ local cargo=cargo-bin-${PV} |
134 |
+ mv "${ED}/opt/${P}/bin/cargo" "${ED}/opt/${P}/bin/${cargo}" || die |
135 |
+ dosym "${cargo}" "/opt/${P}/bin/cargo" |
136 |
+ dosym "../../opt/${P}/bin/${cargo}" "/usr/bin/${cargo}" |
137 |
+ |
138 |
+ if use clippy; then |
139 |
+ local clippy_driver=clippy-driver-bin-${PV} |
140 |
+ local cargo_clippy=cargo-clippy-bin-${PV} |
141 |
+ mv "${ED}/opt/${P}/bin/clippy-driver" "${ED}/opt/${P}/bin/${clippy_driver}" || die |
142 |
+ mv "${ED}/opt/${P}/bin/cargo-clippy" "${ED}/opt/${P}/bin/${cargo_clippy}" || die |
143 |
+ dosym "${clippy_driver}" "/opt/${P}/bin/clippy-driver" |
144 |
+ dosym "${cargo_clippy}" "/opt/${P}/bin/cargo-clippy" |
145 |
+ dosym "../../opt/${P}/bin/${clippy_driver}" "/usr/bin/${clippy_driver}" |
146 |
+ dosym "../../opt/${P}/bin/${cargo_clippy}" "/usr/bin/${cargo_clippy}" |
147 |
+ fi |
148 |
+ if use rls; then |
149 |
+ local rls=rls-bin-${PV} |
150 |
+ mv "${ED}/opt/${P}/bin/rls" "${ED}/opt/${P}/bin/${rls}" || die |
151 |
+ |
152 |
+ dosym "${rls}" "/opt/${P}/bin/rls" |
153 |
+ dosym "../../opt/${P}/bin/${rls}" "/usr/bin/${rls}" |
154 |
+ fi |
155 |
+ if use rustfmt; then |
156 |
+ local rustfmt=rustfmt-bin-${PV} |
157 |
+ local cargo_fmt=cargo-fmt-bin-${PV} |
158 |
+ mv "${ED}/opt/${P}/bin/rustfmt" "${ED}/opt/${P}/bin/${rustfmt}" || die |
159 |
+ mv "${ED}/opt/${P}/bin/cargo-fmt" "${ED}/opt/${P}/bin/${cargo_fmt}" || die |
160 |
+ dosym "${rustfmt}" "/opt/${P}/bin/rustfmt" |
161 |
+ dosym "${cargo_fmt}" "/opt/${P}/bin/cargo-fmt" |
162 |
+ dosym "../../opt/${P}/bin/${rustfmt}" "/usr/bin/${rustfmt}" |
163 |
+ dosym "../../opt/${P}/bin/${cargo_fmt}" "/usr/bin/${cargo_fmt}" |
164 |
+ fi |
165 |
+ |
166 |
+ cat <<-EOF > "${T}"/50${P} |
167 |
+ LDPATH="/opt/${P}/lib" |
168 |
+ MANPATH="/opt/${P}/man" |
169 |
+ EOF |
170 |
+ doenvd "${T}"/50${P} |
171 |
+ |
172 |
+ # note: eselect-rust adds EROOT to all paths below |
173 |
+ cat <<-EOF > "${T}/provider-${P}" |
174 |
+ /usr/bin/rustdoc |
175 |
+ /usr/bin/rust-gdb |
176 |
+ /usr/bin/rust-gdbgui |
177 |
+ /usr/bin/rust-lldb |
178 |
+ EOF |
179 |
+ echo /usr/bin/cargo >> "${T}/provider-${P}" |
180 |
+ if use clippy; then |
181 |
+ echo /usr/bin/clippy-driver >> "${T}/provider-${P}" |
182 |
+ echo /usr/bin/cargo-clippy >> "${T}/provider-${P}" |
183 |
+ fi |
184 |
+ if use rls; then |
185 |
+ echo /usr/bin/rls >> "${T}/provider-${P}" |
186 |
+ fi |
187 |
+ if use rustfmt; then |
188 |
+ echo /usr/bin/rustfmt >> "${T}/provider-${P}" |
189 |
+ echo /usr/bin/cargo-fmt >> "${T}/provider-${P}" |
190 |
+ fi |
191 |
+ |
192 |
+ insinto /etc/env.d/rust |
193 |
+ doins "${T}/provider-${P}" |
194 |
+ popd >/dev/null || die |
195 |
+ #end native abi install |
196 |
+ |
197 |
+ else |
198 |
+ local rust_target |
199 |
+ rust_target="$(rust_abi $(get_abi_CHOST ${v##*.}))" |
200 |
+ dodir "/opt/${P}/lib/rustlib" |
201 |
+ cp -vr "${WORKDIR}/rust-${PV}-${rust_target}/rust-std-${rust_target}/lib/rustlib/${rust_target}"\ |
202 |
+ "${ED}/opt/${P}/lib/rustlib" || die |
203 |
+ fi |
204 |
+} |
205 |
+ |
206 |
+pkg_postinst() { |
207 |
+ eselect rust update --if-unset |
208 |
+ |
209 |
+ elog "Rust installs a helper script for calling GDB now," |
210 |
+ elog "for your convenience it is installed under /usr/bin/rust-gdb-bin-${PV}," |
211 |
+ |
212 |
+ if has_version app-editors/emacs; then |
213 |
+ elog "install app-emacs/rust-mode to get emacs support for rust." |
214 |
+ fi |
215 |
+ |
216 |
+ if has_version app-editors/gvim || has_version app-editors/vim; then |
217 |
+ elog "install app-vim/rust-vim to get vim support for rust." |
218 |
+ fi |
219 |
+ |
220 |
+ if use elibc_musl; then |
221 |
+ ewarn "${PN} on *-musl targets is configured with crt-static" |
222 |
+ ewarn "" |
223 |
+ ewarn "you will need to set RUSTFLAGS=\"-C target-feature=-crt-static\" in make.conf" |
224 |
+ ewarn "to use it with portage, otherwise you may see failures like" |
225 |
+ ewarn "error: cannot produce proc-macro for serde_derive as the target " |
226 |
+ ewarn "x86_64-unknown-linux-musl does not support these crate types" |
227 |
+ fi |
228 |
+} |
229 |
+ |
230 |
+pkg_postrm() { |
231 |
+ eselect rust cleanup |
232 |
+} |