diff --git a/autobuild.sh b/autobuild.sh index 8b975c02f..8fc7b9775 100755 --- a/autobuild.sh +++ b/autobuild.sh @@ -6,7 +6,6 @@ rootdir=$(readlink -f $(dirname $0)) -source "$1" source "$rootdir/test/common/autobuild_common.sh" SPDK_TEST_AUTOBUILD=${SPDK_TEST_AUTOBUILD:-} diff --git a/test/common/autobuild_common.sh b/test/common/autobuild_common.sh index 9733a5dc6..45f95d768 100755 --- a/test/common/autobuild_common.sh +++ b/test/common/autobuild_common.sh @@ -3,6 +3,14 @@ # Copyright (C) 2022 Intel Corporation. # All rights reserved. +spdk_conf=${spdk_conf:-"$1"} + +if [[ ! -f $spdk_conf ]]; then + echo "ERROR: SPDK test configuration not specified" + return 1 +fi + +source "$spdk_conf" source "$rootdir/test/common/autotest_common.sh" source "$rootdir/scripts/common.sh" @@ -446,10 +454,3 @@ scanbuild_exclude+=" --exclude $rootdir/xnvme --exclude /tmp" scanbuild="scan-build -o $output_dir/scan-build-tmp $scanbuild_exclude --status-bugs" config_params=$(get_config_params) - -spdk_conf=${spdk_conf:-"$1"} - -if [[ ! -f $spdk_conf ]]; then - echo "ERROR: SPDK test configuration not specified" - return 1 -fi