scripts: add verbose test build option

The option -v enables the verbose mode when testing a build.

Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
This commit is contained in:
Thomas Monjalon 2016-03-21 20:48:22 +01:00
parent c7e8b41ad4
commit 6e38dfe213

View File

@ -74,11 +74,13 @@ print_help () {
J=$DPDK_MAKE_JOBS J=$DPDK_MAKE_JOBS
short=false short=false
unset verbose
maxerr=-Wfatal-errors maxerr=-Wfatal-errors
while getopts hj:s ARG ; do while getopts hj:sv ARG ; do
case $ARG in case $ARG in
j ) J=$OPTARG ;; j ) J=$OPTARG ;;
s ) short=true ;; s ) short=true ;;
v ) verbose='V=1' ;;
h ) print_help ; exit 0 ;; h ) print_help ; exit 0 ;;
? ) print_usage ; exit 1 ;; ? ) print_usage ; exit 1 ;;
esac esac
@ -193,17 +195,17 @@ for conf in $configs ; do
echo "================== Build $dir" echo "================== Build $dir"
make -j$J EXTRA_CFLAGS="$maxerr $DPDK_DEP_CFLAGS" \ make -j$J EXTRA_CFLAGS="$maxerr $DPDK_DEP_CFLAGS" \
EXTRA_LDFLAGS="$DPDK_DEP_LDFLAGS" O=$dir EXTRA_LDFLAGS="$DPDK_DEP_LDFLAGS" $verbose O=$dir
! $short || break ! $short || break
echo "================== Build examples for $dir" echo "================== Build examples for $dir"
export RTE_SDK=$(pwd) export RTE_SDK=$(pwd)
export RTE_TARGET=$dir export RTE_TARGET=$dir
make -j$J -sC examples \ make -j$J -sC examples \
EXTRA_LDFLAGS="$DPDK_DEP_LDFLAGS" \ EXTRA_LDFLAGS="$DPDK_DEP_LDFLAGS" $verbose \
O=$(readlink -m $dir/examples) O=$(readlink -m $dir/examples)
! echo $target | grep -q '^x86_64' || \ ! echo $target | grep -q '^x86_64' || \
make -j$J -sC examples/performance-thread \ make -j$J -sC examples/performance-thread \
EXTRA_LDFLAGS="$DPDK_DEP_LDFLAGS" \ EXTRA_LDFLAGS="$DPDK_DEP_LDFLAGS" $verbose \
O=$(readlink -m $dir/examples/performance-thread) O=$(readlink -m $dir/examples/performance-thread)
unset RTE_TARGET unset RTE_TARGET
echo "################## $dir done." echo "################## $dir done."