mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2024-12-22 13:45:20 +00:00
scripts: Fix musl build error in AArch64 unit test
Signed-off-by: Michael Zhao <michael.zhao@arm.com>
This commit is contained in:
parent
8d11ba4833
commit
8ba1bc7621
@ -12,5 +12,11 @@ if [[ $(uname -m) = "aarch64" || $hypervisor = "mshv" ]]; then
|
|||||||
cargo_args+=("--no-default-features")
|
cargo_args+=("--no-default-features")
|
||||||
cargo_args+=("--features $hypervisor")
|
cargo_args+=("--features $hypervisor")
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [[ "${BUILD_TARGET}" == "aarch64-unknown-linux-musl" ]]; then
|
||||||
|
export TARGET_CC="musl-gcc"
|
||||||
|
export RUSTFLAGS="-C link-arg=-lgcc -C link_arg=-specs -C link_arg=/usr/lib/aarch64-linux-musl/musl-gcc.specs"
|
||||||
|
fi
|
||||||
|
|
||||||
export RUST_BACKTRACE=1
|
export RUST_BACKTRACE=1
|
||||||
cargo test --lib --bins --target $BUILD_TARGET --workspace ${cargo_args[@]} || exit 1;
|
cargo test --lib --bins --target $BUILD_TARGET --workspace ${cargo_args[@]} || exit 1;
|
||||||
|
Loading…
Reference in New Issue
Block a user