[EDT] [PATCH] tests: Validate .config file for wpa_supplicant build
Jouni Malinen
j
Wed Jun 10 14:49:30 PDT 2015
On Wed, Jun 03, 2015 at 11:28:40AM +0000, Amit Khatri wrote:
> Subject: [PATCH] tests: Validate .config file for wpa_supplicant build and
> print warning message for hwsim build.
> diff --git a/tests/hwsim/build.sh b/tests/hwsim/build.sh
> @@ -4,6 +4,24 @@ set -e
> +validate_config_file()
> +{
> + temp=`grep CONFIG_P2P .config`;
> + if [ `echo "${temp:0:1}"` == '#' ]; then
This won't work with some /bin/sh options, e.g., on Ubuntu 14.04:
./build.sh: 1: ./build.sh: Bad substitution
./build.sh: 10: [: ==: unexpected operator
./build.sh: 1: ./build.sh: Bad substitution
./build.sh: 14: [: ==: unexpected operator
./build.sh: 1: ./build.sh: Bad substitution
./build.sh: 18: [: ==: unexpected operator
> + temp=`grep CONFIG_DEBUG_LINUX_TRACING .config`;
> + if [ `echo "${temp:0:1}"` == '#' ]; then
> + echo "CONFIG_DEBUG_LINUX_TRACING is not enabled in .config file";
> + fi
> + echo "Please check the above config options it may cause not to start wpa_supplicant";
> + echo "Either use -f or --force-config option";
Wouldn't these lines be printed regardless of whether .config included
the needed parameters? If I replace /bin/sh with /bin/bash, I'll get
this output even with a successful build that includes all the needed
functionality:
tests/hwsim$ ./build.sh
Building TNC testing tools
Building wlantest
Building hostapd
hostapd config file exists
Building wpa_supplicant
wpa_supplicant config file exists
Please check the above config options it may cause not to start wpa_supplicant
Either use -f or --force-config option
--
Jouni Malinen PGP id EFC895FA
More information about the Hostap
mailing list