mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2024-08-22 07:51:16 +00:00
scripts: Remove obsoleted env variable "cflags" and "target_cc"
To run unit tests correctly on musl target, We don't need to provide specific "CFLAGS" or "TARGET_CC", as long as we use the correct build target `*-linux-musl` with the "cargo test" command. Signed-off-by: Bo Chen <chen.bo@intel.com>
This commit is contained in:
parent
411b8b3a96
commit
1025783973
@ -354,12 +354,6 @@ cmd_tests() {
|
|||||||
|
|
||||||
process_volumes_args
|
process_volumes_args
|
||||||
target="$(uname -m)-unknown-linux-${libc}"
|
target="$(uname -m)-unknown-linux-${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
|
|
||||||
|
|
||||||
if [[ "$unit" = true ]] ; then
|
if [[ "$unit" = true ]] ; then
|
||||||
say "Running unit tests for $target..."
|
say "Running unit tests for $target..."
|
||||||
@ -371,8 +365,6 @@ cmd_tests() {
|
|||||||
--cap-add net_admin \
|
--cap-add net_admin \
|
||||||
--volume "$CLH_ROOT_DIR:$CTR_CLH_ROOT_DIR" $exported_volumes \
|
--volume "$CLH_ROOT_DIR:$CTR_CLH_ROOT_DIR" $exported_volumes \
|
||||||
--env BUILD_TARGET="$target" \
|
--env BUILD_TARGET="$target" \
|
||||||
--env CFLAGS="$cflags" \
|
|
||||||
--env TARGET_CC="$target_cc" \
|
|
||||||
"$CTR_IMAGE" \
|
"$CTR_IMAGE" \
|
||||||
./scripts/run_unit_tests.sh "$@" || fix_dir_perms $? || exit $?
|
./scripts/run_unit_tests.sh "$@" || fix_dir_perms $? || exit $?
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user