about summary refs log tree commit diff
path: root/scripts/setup_rust_fork.sh
diff options
context:
space:
mode:
authorbjorn3 <17426603+bjorn3@users.noreply.github.com>2022-10-23 16:22:55 +0200
committerbjorn3 <17426603+bjorn3@users.noreply.github.com>2022-10-23 16:22:55 +0200
commit9950bd1dc5bd249af274a14c7da30a2992c33295 (patch)
tree5d0461ac726e5c836ea3be27912bb3a17597ba60 /scripts/setup_rust_fork.sh
parent54ee5ac0734a5c715558190fda9c61be2446d93a (diff)
downloadrust-9950bd1dc5bd249af274a14c7da30a2992c33295.tar.gz
rust-9950bd1dc5bd249af274a14c7da30a2992c33295.zip
Merge commit '266e96785ab71834b917bf474f130a6d8fdecd4b' into sync_cg_clif-2022-10-23
Diffstat (limited to 'scripts/setup_rust_fork.sh')
-rw-r--r--scripts/setup_rust_fork.sh6
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/setup_rust_fork.sh b/scripts/setup_rust_fork.sh
index 091bfa1e992..d6a37789599 100644
--- a/scripts/setup_rust_fork.sh
+++ b/scripts/setup_rust_fork.sh
@@ -10,6 +10,8 @@ git fetch
 git checkout -- .
 git checkout "$(rustc -V | cut -d' ' -f3 | tr -d '(')"
 
+git am ../patches/*-sysroot-*.patch
+
 git apply - <<EOF
 diff --git a/library/alloc/Cargo.toml b/library/alloc/Cargo.toml
 index d95b5b7f17f..00b6f0e3635 100644
@@ -66,3 +68,7 @@ popd
 
 # FIXME remove once inline asm is fully supported
 export RUSTFLAGS="$RUSTFLAGS --cfg=rustix_use_libc"
+
+# Allow the testsuite to use llvm tools
+host_triple=$(rustc -vV | grep host | cut -d: -f2 | tr -d " ")
+export LLVM_BIN_DIR="$(rustc --print sysroot)/lib/rustlib/$host_triple/bin"