diff --git a/scripts/dev_cli.sh b/scripts/dev_cli.sh index 0d25a0dc0..80bb58fff 100755 --- a/scripts/dev_cli.sh +++ b/scripts/dev_cli.sh @@ -310,9 +310,7 @@ cmd_tests() { --volume "$CLH_ROOT_DIR:$CTR_CLH_ROOT_DIR" \ --volume "$CLH_INTEGRATION_WORKLOADS:$CTR_CLH_INTEGRATION_WORKLOADS" \ --env USER="root" \ - --env BUILD_TARGET="$target" \ - --env CFLAGS="$cflags" \ - --env TARGET_CC="$target_cc" \ + --env CH_LIBC="${libc}" \ "$CTR_IMAGE" \ ./scripts/run_integration_tests.sh "$@" || fix_dir_perms $? || exit $? fi diff --git a/scripts/run_integration_tests.sh b/scripts/run_integration_tests.sh index e1bc35ff3..4b10ee78c 100755 --- a/scripts/run_integration_tests.sh +++ b/scripts/run_integration_tests.sh @@ -210,6 +210,13 @@ sudo ip tuntap add name vunet-tap0 mode tap # Create tap interface with multipe queues support for vhost_user_net test. sudo ip tuntap add name vunet-tap1 mode tap multi_queue +BUILD_TARGET="$(uname -m)-unknown-linux-${CH_LIBC}" +CFLAGS="" +TARGET_CC="" +if [[ "$target" == "x86_64-unknown-linux-musl" ]]; then +TARGET_CC="musl-gcc" +CFLAGS="-I /usr/include/x86_64-linux-musl/ -idirafter /usr/include/" +fi cargo build --release --target $BUILD_TARGET strip target/$BUILD_TARGET/release/cloud-hypervisor