commit: 8f3f98df255b0d5bc9b2ffa8bce8e3cbacd48e8a Author: Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org> AuthorDate: Mon Nov 23 22:21:04 2020 +0000 Commit: Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org> CommitDate: Tue Nov 24 00:37:41 2020 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8f3f98df
dev-lang/rust-bin: bump to 1.48.0 Package-Manager: Portage-3.0.10, Repoman-3.0.2 Signed-off-by: Georgy Yakovlev <gyakovlev <AT> gentoo.org> dev-lang/rust-bin/Manifest | 14 +++ dev-lang/rust-bin/rust-bin-1.48.0.ebuild | 155 +++++++++++++++++++++++++++++++ 2 files changed, 169 insertions(+) diff --git a/dev-lang/rust-bin/Manifest b/dev-lang/rust-bin/Manifest index 793f47cabc4..410ab8875a1 100644 --- a/dev-lang/rust-bin/Manifest +++ b/dev-lang/rust-bin/Manifest @@ -40,3 +40,17 @@ DIST rust-1.47.0-powerpc64le-unknown-linux-gnu.tar.xz 141965604 BLAKE2B b4b7ce86 DIST rust-1.47.0-s390x-unknown-linux-gnu.tar.xz 146987276 BLAKE2B 1810e7bfbd235613563677449376167700c33960eb57b100e65058f6a00692316db518f2f4b79b39e414f3892c62bb1ec09b0866ff2221641c4a3056659a1668 SHA512 dd5877b6ff5c310ca6aa23c1cc621e6b0675d4c46f5a06b2a0b107641b604a1a2101109ba8e286267bab1158768c601d5d9a922a8da72486c91755ef465720c0 DIST rust-1.47.0-x86_64-unknown-linux-gnu.tar.xz 150891572 BLAKE2B 45ff02465ba82ae96de25dd616fa08abb2396be21236d2f66f831effb349f39b047a380b38cb83254f27e56cecdbea8478f4de8ccc0aa23b11de2f11a28f501b SHA512 f695986ab8e67636b0e92ca7ea223984121e3c22788434a6f1062690e7932f6b30c0c302160fef96831f821acedaf8a909bd3d00a9aa873c7200d2b8fa39013f DIST rust-1.47.0-x86_64-unknown-linux-musl.tar.xz 166456672 BLAKE2B d6ccfc574a81ae3e9e6a96805e6863009970b5c480f35ee0d582a204b782fe513b9c6c7094d1adea509de1a3097a8a0524ac00c2186b968f70f390615904eb5a SHA512 f71b162635955ecd8a6ec322818be69c788c18d4e923d84d901916648f2eb58573b1f97b460209294ee64198e76566b78e472f9cbca8665c59444adfc5ae603c +DIST rust-1.48.0-aarch64-unknown-linux-gnu.tar.xz 133782948 BLAKE2B 95e80db4734a91a1aed6433cb6dcc65358ef713f365216f6c344c4940c2b5e43b7dc5805f53635c4e7585e70c9d5773b6c93034fa2ffd0a28efb2f20a18f1be8 SHA512 6ebbd936b1bc2ccf30b62dbbbc6f3986fb57738d89e33a23d58bab09be57a445c17df7912866add91cc108ef7547d229a08c6206db2d2fb00d72887ff6a0894d +DIST rust-1.48.0-arm-unknown-linux-gnueabi.tar.xz 133293068 BLAKE2B f98129d16e0de958a164233a1cc6317dc64eeeee76aa88b6982af2cb0a4b9f798a989b6bc153dcd55a7a6dfd3a8a6b36330faae82fedc133ae927b75638629aa SHA512 8958b8548711bb393e188d7516a842dcde5e7f9751804a90621d28a787a28b330057f343f14f930bafdcbdd8fa2cf391d6a4c1953f6d33a34bcbc65fd0e24e9b +DIST rust-1.48.0-arm-unknown-linux-gnueabihf.tar.xz 132424008 BLAKE2B ed0aad5dba3eff6ca18eac5e7fc1864d2b72e262b5c8d6b510196653edc505bcb2327d529b326b10279ad19d6e2258e40103ed39067094f6ac2bd9dfed170b35 SHA512 d932676a579eed1849e58c133aa3759750b01436aa6f837098953cc558b9025427bdd54f1f2688aa0022934c48177da34874e27cc319c7bf1c96e219615d2bb2 +DIST rust-1.48.0-armv7-unknown-linux-gnueabihf.tar.xz 134716224 BLAKE2B 1918eadca80dbaacb4700dc5af8c791cc0966a29b4d01bba10e8ec31d5506a2748f4a0c9ed6695e9aa9cd88511e0dc347354a1410b419013757d9ae443e9e9af SHA512 9763b0c5bc5dc7b265b86636ed32947aab98bd9b5732c4b298ade93e9a09bab82ad37fc7ca2d7c97dfd87634756b3c55015d47696c0a6ed2cb44be03659bcf55 +DIST rust-1.48.0-i686-unknown-linux-gnu.tar.xz 161602224 BLAKE2B e4f1d1b51d520f85f7af8ddd12ad716d8c501a25d1bcdf40efd23902da9c35168108ba705c08a7aa3617ac1afb41584180d1d2399732918900f9126158111c25 SHA512 b8b3c5407304a333fc6c10ad70363589a88673640dda7b5fde8971097e679f56a8c733da31b2183044ae2ce30700db923cc3c3cb8c590d785df680b60b199451 +DIST rust-1.48.0-mips-unknown-linux-gnu.tar.xz 96393696 BLAKE2B 6cd06b3b1b8aeb4b251bc14e47dd8b8cd099f9292705402d718657de4efd480f8999bf23694d9be455236e3ebd4d330b2645a0333eeab7f9a189239df5e02698 SHA512 973130e8c0924e4a22e3b803102b96e80d6247328879a92c3bf0d9e80ec185264b980bd481ee79b6f8afe8e47f7fd61b9657a85adb7ae99008357d39e2428a39 +DIST rust-1.48.0-mips64-unknown-linux-gnuabi64.tar.xz 107548156 BLAKE2B 98b481032689f094490689b3af5a0a9162c8bf0ac8a60203b0be2de0f0ac555296e0401d1d534934d2faee852c61b20324aadf0a1696dd57607b71389f03071a SHA512 b3adf893d3e1a36da859bbd3cb39acebb2358522591694e636574ac5a1f81484a60ee53a9de7f348717fbfdaac9f2dd6ec27ea78959cdf94346d251d4a6be877 +DIST rust-1.48.0-mipsel-unknown-linux-gnu.tar.xz 97538116 BLAKE2B c4777428637bf2a08964b0abf048c2ea3b895901130f6b2c4307bfd448c7e09e2d8e862d0a10bab23c73a580aa2e9d868c7716d6a7fd103fa40f0d4207090c71 SHA512 09529c30c2b31317a495b058ee48d8ad7b0c89a59a70e62c9085d59bbd2f22a37223956a13959175cd05b195b7541feac9b8acc49438f575fce3fad26d2bd927 +DIST rust-1.48.0-powerpc-unknown-linux-gnu.tar.xz 106401772 BLAKE2B 2b10bb21198b9104dee49038ca4a7bee9dc93331465166ce9ca451d84c7e759e7bd5635c017223f6a1b96f71430a8240bd65022e9067fb20e5be85d06e79baba SHA512 b77afbca6fe9f1122c863bee14a764adb1dc5f233058292c5aaa72e50f473c1f9cccd1fc08c427485a7edab460fcea595544fd902d5f96d290e208aa03d910a3 +DIST rust-1.48.0-powerpc64-unknown-linux-gnu.tar.xz 120497676 BLAKE2B 6aa1dedcf5953f1292997fa7aac19067a6daa5e676a7e5fb7b7a29707831328b5514a88904edcc00dcf76d32e911646c8a349e40431a531585c373ce755bfb3c SHA512 f79e1f984cc3c4dce08599418be2885666e0b6f73e639b10e97ffff4b900606d880c0596b6c2ab7c5f999cfc364d22b2ca6ab88db6ba38b8b227670b222fe23b +DIST rust-1.48.0-powerpc64le-unknown-linux-gnu.tar.xz 124335896 BLAKE2B fe95cb27e69258d4b0fe471e856bc98d4ddae3d90c7d5bbd723575cb86da28061c8b0ca8f5fd945f0ce4789997f5e7658edf5f40b57aa215d76ffeb3c3207602 SHA512 7ddd2b0599872012f8613ccab456622cb05a0a43587b7d389e8b7fdf9381f0387763726d892da931233c89e8e3ce45c2b303ed00b1cce1f91c88d8f88d6b148d +DIST rust-1.48.0-s390x-unknown-linux-gnu.tar.xz 127221600 BLAKE2B 08511be6aadc0feb36caa19df5914a207565eed3b4b3914cad7fc8f7170011a7431c14d50b1334f5d5e00b4c94e7e84ee59afad179286e889480cc9b21e1f402 SHA512 b2b1565f3b1cc0c3bf4aa06aba1da7df775c6e29c892ca7727d0e549f175b632080433be2586e799c5636231de6c678f0228dedee8358fbf167016a1f7d25389 +DIST rust-1.48.0-x86_64-unknown-linux-gnu.tar.xz 155254844 BLAKE2B 37bce978eb297bb1732f9d513bb6fdcee4aefc42a578496a84b5f8abbb9f90f1c524c73f28c85f33c25a365bf5ba566253b1739009bb112c2e1d46a2ed978e10 SHA512 0784e156e70c47386abfa88ecfeb62b1109364459b1fee225de0749c30379c4eb443ff3ff7faa7dc1a6ff373bc6eb43997007f937889cb35daf940a74641753b +DIST rust-1.48.0-x86_64-unknown-linux-musl.tar.xz 168361012 BLAKE2B efeb9a9812f2fa2cbf1cfd963b5b714cf18d73ca9b7a3de4efa701acf7e2e8fc3b610cd90f7391b10bddd1c9d44b8b0aa910f58ce739750d4e910b063825dc28 SHA512 7188fb0b1bf6fd6ab320089cd17f334867baefec1a9c57a81e6cb729276456e56850938dbd0eafbc52375266a87392ad3045a4dbd2c41689bba6b0da152e4034 diff --git a/dev-lang/rust-bin/rust-bin-1.48.0.ebuild b/dev-lang/rust-bin/rust-bin-1.48.0.ebuild new file mode 100644 index 00000000000..35f73db67e3 --- /dev/null +++ b/dev-lang/rust-bin/rust-bin-1.48.0.ebuild @@ -0,0 +1,155 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit bash-completion-r1 rust-toolchain toolchain-funcs multilib-minimal + +MY_P="rust-${PV}" + +DESCRIPTION="Systems programming language from Mozilla" +HOMEPAGE="https://www.rust-lang.org/" +SRC_URI="$(rust_all_arch_uris ${MY_P})" + +LICENSE="|| ( MIT Apache-2.0 ) BSD-1 BSD-2 BSD-4 UoI-NCSA" +SLOT="stable" +KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86" +IUSE="clippy cpu_flags_x86_sse2 doc rls rustfmt" + +DEPEND="" +RDEPEND=">=app-eselect/eselect-rust-20190311" + +REQUIRED_USE="x86? ( cpu_flags_x86_sse2 )" + +QA_PREBUILT=" + opt/${P}/bin/.* + opt/${P}/lib/.*.so + opt/${P}/lib/rustlib/.*/bin/.* + opt/${P}/lib/rustlib/.*/lib/.* +" + +pkg_pretend() { + if [[ "$(tc-is-softfloat)" != "no" ]] && [[ ${CHOST} == armv7* ]]; then + die "${CHOST} is not supported by upstream Rust. You must use a hard float version." + fi +} + +src_unpack() { + default + mv "${WORKDIR}/${MY_P}-$(rust_abi)" "${S}" || die +} + +multilib_src_install() { + if multilib_is_native_abi; then + + # start native abi install + pushd "${S}" >/dev/null || die + local analysis std + analysis="$(grep 'analysis' ./components)" + std="$(grep 'std' ./components)" + local components="rustc,cargo,${std}" + use doc && components="${components},rust-docs" + use clippy && components="${components},clippy-preview" + use rls && components="${components},rls-preview,${analysis}" + use rustfmt && components="${components},rustfmt-preview" + ./install.sh \ + --components="${components}" \ + --disable-verify \ + --prefix="${ED}/opt/${P}" \ + --mandir="${ED}/opt/${P}/man" \ + --disable-ldconfig \ + || die + + local symlinks=( + cargo + rustc + rustdoc + rust-gdb + rust-gdbgui + rust-lldb + ) + + use clippy && symlinks+=( clippy-driver cargo-clippy ) + use rls && symlinks+=( rls ) + use rustfmt && symlinks+=( rustfmt cargo-fmt ) + + einfo "installing eselect-rust symlinks and paths" + local i + for i in "${symlinks[@]}"; do + # we need realpath on /usr/bin/* symlink return version-appended binary path. + # so /usr/bin/rustc should point to /opt/rust-bin-<ver>/bin/rustc-<ver> + local ver_i="${i}-bin-${PV}" + ln -v "${ED}/opt/${P}/bin/${i}" "${ED}/opt/${P}/bin/${ver_i}" + dosym "../../opt/${P}/bin/${ver_i}" "/usr/bin/${ver_i}" + done + + # symlinks to switch components to active rust in eselect + dosym "../../../opt/${P}/lib" "/usr/lib/rust/lib-bin-${PV}" + dosym "../../../opt/${P}/man" "/usr/lib/rust/man-bin-${PV}" + dosym "../../opt/${P}/lib/rustlib" "/usr/lib/rustlib-bin-${PV}" + dosym "../../../opt/${P}/share/doc/rust" "/usr/share/doc/${P}" + + cat <<-_EOF_ > "${T}/50${P}" + LDPATH="${EPREFIX}/usr/lib/rust/lib" + MANPATH="${EPREFIX}/usr/lib/rust/man" + $(usex elibc_musl 'CARGO_TARGET_X86_64_UNKNOWN_LINUX_MUSL_RUSTFLAGS="-C target-feature=-crt-static"' '') + _EOF_ + doenvd "${T}/50${P}" + + # note: eselect-rust adds EROOT to all paths below + cat <<-_EOF_ > "${T}/provider-${P}" + /usr/bin/cargo + /usr/bin/rustdoc + /usr/bin/rust-gdb + /usr/bin/rust-gdbgui + /usr/bin/rust-lldb + /usr/lib/rustlib + /usr/lib/rust/lib + /usr/lib/rust/man + /usr/share/doc/rust + _EOF_ + + if use clippy; then + echo /usr/bin/clippy-driver >> "${T}/provider-${P}" + echo /usr/bin/cargo-clippy >> "${T}/provider-${P}" + fi + if use rls; then + echo /usr/bin/rls >> "${T}/provider-${P}" + fi + if use rustfmt; then + echo /usr/bin/rustfmt >> "${T}/provider-${P}" + echo /usr/bin/cargo-fmt >> "${T}/provider-${P}" + fi + + insinto /etc/env.d/rust + doins "${T}/provider-${P}" + popd >/dev/null || die + #end native abi install + + else + local rust_target + rust_target="$(rust_abi $(get_abi_CHOST ${v##*.}))" + dodir "/opt/${P}/lib/rustlib" + cp -vr "${WORKDIR}/rust-${PV}-${rust_target}/rust-std-${rust_target}/lib/rustlib/${rust_target}"\ + "${ED}/opt/${P}/lib/rustlib" || die + fi +} + +pkg_postinst() { + eselect rust update --if-unset + + elog "Rust installs a helper script for calling GDB now," + elog "for your convenience it is installed under /usr/bin/rust-gdb-bin-${PV}," + + if has_version app-editors/emacs; then + elog "install app-emacs/rust-mode to get emacs support for rust." + fi + + if has_version app-editors/gvim || has_version app-editors/vim; then + elog "install app-vim/rust-vim to get vim support for rust." + fi +} + +pkg_postrm() { + eselect rust cleanup +}