Skip to content

Commit e594054

Browse files
Merge #881
881: Update CI tests to use local cross build. r=Emilgardis a=Alexhuszagh Simplifies testing CI locally, without modifying the system installation. Co-authored-by: Alex Huszagh <[email protected]>
2 parents 6c2226d + 60326c9 commit e594054

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

ci/test.sh

+6-2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ set -euo pipefail
88
# installed version on macOS. likewise, "${var[@]}" is an unbound
99
# error if var is an empty array.
1010

11+
ci_dir=$(dirname "${BASH_SOURCE[0]}")
12+
ci_dir=$(realpath "${ci_dir}")
13+
project_home=$(dirname "${ci_dir}")
14+
1115
function retry {
1216
local tries="${TRIES-5}"
1317
local timeout="${TIMEOUT-1}"
@@ -41,15 +45,15 @@ main() {
4145
local td=
4246

4347
retry cargo fetch
44-
cargo install --force --path . --debug
48+
cargo build
4549

4650
# Unset RUSTFLAGS
4751
export RUSTFLAGS=""
4852

4953
export QEMU_STRACE=1
5054

5155
# ensure we have the proper toolchain and optional rust flags
52-
export CROSS=(cross)
56+
export CROSS=("${project_home}/target/debug/cross")
5357
export CROSS_FLAGS=""
5458
if (( ${BUILD_STD:-0} )); then
5559
# use build-std instead of xargo, due to xargo being

0 commit comments

Comments
 (0)