From 7ee27456e2684ea8fc924497c44049dd1ad15925 Mon Sep 17 00:00:00 2001 From: Patrick J Volkerding Date: Tue, 19 Nov 2019 06:15:35 +0000 Subject: Tue Nov 19 06:15:35 UTC 2019 d/rust-1.39.0-x86_64-1.txz: Upgraded. --- source/d/rust/rust.SlackBuild | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) (limited to 'source/d/rust/rust.SlackBuild') diff --git a/source/d/rust/rust.SlackBuild b/source/d/rust/rust.SlackBuild index 7e6b3dbc2..2dee9b218 100755 --- a/source/d/rust/rust.SlackBuild +++ b/source/d/rust/rust.SlackBuild @@ -1,7 +1,7 @@ #!/bin/bash # Copyright 2017 Andrew Clemons, Wellington, New Zealand -# Copyright 2017, 2018 Patrick J. Volkerding, Sebeka, Minnesota, USA +# Copyright 2017, 2018, 2019 Patrick J. Volkerding, Sebeka, Minnesota, USA # Copyright 2017 Stuart Winter # All rights reserved. # @@ -26,7 +26,7 @@ cd $(dirname $0) ; CWD=$(pwd) PKGNAM=rust SRCNAM="${PKGNAM}c" -VERSION=${VERSION:-1.37.0} +VERSION=${VERSION:-1.39.0} BUILD=${BUILD:-1} # Set this to YES to build with the system LLVM, or NO to use the bundled LLVM. @@ -34,9 +34,9 @@ BUILD=${BUILD:-1} SYSTEM_LLVM=${SYSTEM_LLVM:-YES} # Bootstrap variables (might not be kept updated for latest Rust): -RSTAGE0_VERSION=${RSTAGE0_VERSION:-1.36.0} -RSTAGE0_DIR=${RSTAGE0_DIR:-2019-07-04} -CSTAGE0_VERSION=${CSTAGE0_VERSION:-0.37.0} +RSTAGE0_VERSION=${RSTAGE0_VERSION:-1.38.0} +RSTAGE0_DIR=${RSTAGE0_DIR:-2019-09-26} +CSTAGE0_VERSION=${CSTAGE0_VERSION:-0.39.0} CSTAGE0_DIR=${CSTAGE0_DIR:-$RSTAGE0_DIR} # Automatically determine the architecture we're building on: @@ -148,6 +148,10 @@ if [ "${SYSTEM_LLVM}" = "YES" ]; then zcat $CWD/link_libffi.diff.gz | patch -p1 --verbose || exit 1 fi +# Try to debloat the build: +zcat $CWD/0001-WIP-minimize-the-rust-std-component.patch.gz | patch -p1 --verbose || exit 1 +zcat $CWD/hack.diff.gz | patch -p1 --verbose || exit 1 + if [ "$LOCAL_BOOTSTRAP" != "yes" ] ; then # rust requires bootstrapping with the previous rust version. # versions are defined in src/stage0.txt. @@ -165,6 +169,7 @@ fi cat << EOF > config.toml [llvm] ccache = "/usr/bin/ccache" +link-shared = true [build] build = "$BARCH-unknown-linux-$BABI" @@ -213,9 +218,9 @@ fi chown -R root:root . find -L . \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ - -o -perm 511 \) -exec chmod 755 {} \; -o \ + -o -perm 511 \) -exec chmod 755 {} \+ -o \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ - -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; + -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \+ export PKG_CONFIG_ALLOW_CROSS=1 @@ -263,7 +268,7 @@ sed -i "s,/tmp/package-rust/,/,g" $PKG/usr/lib$LIBDIRSUFFIX/rustlib/install.log gzip -9 $PKG/usr/lib$LIBDIRSUFFIX/rustlib/manifest-* # Correct permissions on shared libraries: -find $PKG/usr/lib$LIBDIRSUFFIX -name "*.so" -exec chmod 755 "{}" \; +find $PKG/usr/lib$LIBDIRSUFFIX -name "*.so" -exec chmod 755 "{}" \+ # Evidently there are a lot of duplicated libraries in this tree, so let's # try to save some space: @@ -280,7 +285,7 @@ find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | gr done # Compress man pages: -find $PKG/usr/man -type f -exec gzip -9 {} \; +find $PKG/usr/man -type f -exec gzip -9 {} \+ for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done # Add some documentation: -- cgit v1.2.3