Browse Source

rust: rebuild package

emacs-27
Leonid Plyushch 5 years ago
parent
commit
ac6da29269
No known key found for this signature in database GPG Key ID: 45F2964132545795
  1. 7
      packages/rust/build.sh

7
packages/rust/build.sh

@ -3,10 +3,11 @@ TERMUX_PKG_DESCRIPTION="Systems programming language focused on safety, speed an
TERMUX_PKG_LICENSE="MIT"
TERMUX_PKG_MAINTAINER="Kevin Cotugno @kcotugno"
TERMUX_PKG_VERSION=1.38.0
TERMUX_PKG_REVISION=2
TERMUX_PKG_SRCURL=https://static.rust-lang.org/dist/rustc-$TERMUX_PKG_VERSION-src.tar.xz
TERMUX_PKG_SHA256=3a7991aa4cb44ef941d71636e45a95468b520dc6fc7cf725364925bd3e3d3a34
TERMUX_PKG_DEPENDS="libc++, clang, openssl, lld, zlib"
TERMUX_PKG_REVISION=1
termux_step_configure() {
termux_setup_cmake
termux_setup_rust
@ -17,7 +18,7 @@ termux_step_configure() {
# configuration is used otherwise it fails a long time into the build...
# like 30 to 40 + minutes ... so lets get it right
# upstream only tests build ver one version behind $TERMUX_PKG_VERSION
# upstream only tests build ver one version behind $TERMUX_PKG_VERSION
rustup install 1.37.0
export PATH=$HOME/.rustup/toolchains/1.37.0-x86_64-unknown-linux-gnu/bin:$PATH
local RUSTC=$(which rustc)
@ -54,7 +55,7 @@ termux_step_make() {
}
termux_step_make_install() {
# ugly fix to get extended tools working
$TERMUX_PKG_SRCDIR/x.py install --host $CARGO_TARGET_NAME --target $CARGO_TARGET_NAME --target wasm32-unknown-unknown || cp ./build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/lib/librustc_macros-*.so ./build/x86_64-unknown-linux-gnu/stage2-tools/release/deps/librustc_macros-*.so
$TERMUX_PKG_SRCDIR/x.py install --host $CARGO_TARGET_NAME --target $CARGO_TARGET_NAME --target wasm32-unknown-unknown || cp ./build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/lib/librustc_macros-*.so ./build/x86_64-unknown-linux-gnu/stage2-tools/release/deps/librustc_macros-*.so
$TERMUX_PKG_SRCDIR/x.py install --host $CARGO_TARGET_NAME --target $CARGO_TARGET_NAME --target wasm32-unknown-unknown || true
cd "$TERMUX_PREFIX/lib"
rm -f libc.so libdl.so

Loading…
Cancel
Save