Add an "-l <num>" argument to abuild that sets the LOGLEVEL variables
to the specified value. Only change Config-abuild.lb, as the others are for manual buildtarget use - adding __LOGLEVEL__ there would kill the build as it isn't replaced by the actual content. Signed-off-by: Patrick Georgi <patrick.georgi@coresystems.de> Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> Acked-by: Stefan Reinauer <stepan@coresystems.de> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@4153 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
This commit is contained in:
parent
16cdbb244c
commit
2d3e712d56
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE=1024*1024
|
||||
romimage "normal"
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE=1024*1024
|
||||
romimage "normal"
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FAILOVER_IMAGE=0
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE=1024*1024
|
||||
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE=512*1024
|
||||
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FAILOVER_IMAGE=0
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE=512*1024
|
||||
|
||||
|
|
|
@ -6,6 +6,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "fallback"
|
||||
option FALLBACK_SIZE = 256 * 1024
|
||||
|
|
|
@ -6,6 +6,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE=256*1024
|
||||
|
||||
|
|
|
@ -27,6 +27,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE = 512*1024
|
||||
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FAILOVER_IMAGE=0
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE=512*1024
|
||||
|
||||
|
|
|
@ -6,6 +6,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE=256*1024
|
||||
###
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FAILOVER_IMAGE=0
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE=512*1024
|
||||
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE=1024*(1024-64)
|
||||
option FALLBACK_SIZE=1024*512
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FAILOVER_IMAGE=0
|
||||
|
|
|
@ -26,6 +26,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FAILOVER_IMAGE = 0
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FALLBACK_IMAGE=0
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FALLBACK_IMAGE=0
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FAILOVER_IMAGE=0
|
||||
|
|
|
@ -26,6 +26,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "fallback"
|
||||
option USE_FALLBACK_IMAGE = 1
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FAILOVER_IMAGE=0
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FAILOVER_IMAGE=0
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FALLBACK_IMAGE=0
|
||||
|
|
|
@ -6,6 +6,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "fallback"
|
||||
option FALLBACK_SIZE = 256 * 1024
|
||||
|
|
|
@ -26,6 +26,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "fallback"
|
||||
option USE_FALLBACK_IMAGE = 1
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FAILOVER_IMAGE=0
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FAILOVER_IMAGE=0
|
||||
|
|
|
@ -26,6 +26,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
romimage "normal"
|
||||
option USE_FAILOVER_IMAGE=0
|
||||
|
|
|
@ -8,6 +8,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE=512*1024
|
||||
|
||||
|
|
|
@ -6,6 +6,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE=256*1024
|
||||
|
||||
|
|
|
@ -26,6 +26,7 @@ option CROSS_COMPILE = "CROSS_PREFIX"
|
|||
option HOSTCC = "CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
option ROM_SIZE = 512 * 1024
|
||||
|
||||
|
|
|
@ -52,6 +52,9 @@ scanbuild=false
|
|||
# stackprotect mode enabled by -ns option.
|
||||
stackprotect=false
|
||||
|
||||
# loglevel changed with -l / --loglevel option
|
||||
loglevel=default
|
||||
|
||||
ARCH=`uname -m | sed -e s/i.86/i386/ -e s/sun4u/sparc64/ \
|
||||
-e s/i86pc/i386/ \
|
||||
-e s/arm.*/arm/ -e s/sa110/arm/ -e s/x86_64/amd64/ \
|
||||
|
@ -154,6 +157,7 @@ option CROSS_COMPILE="CROSS_PREFIX"
|
|||
option HOSTCC="CROSS_HOSTCC"
|
||||
|
||||
__COMPRESSION__
|
||||
__LOGLEVEL__
|
||||
|
||||
EOF
|
||||
if [ "$TARCH" == i386 ] ; then
|
||||
|
@ -185,6 +189,14 @@ EOF
|
|||
) > $TARGET/Config-${VENDOR}_${MAINBOARD}.lb
|
||||
fi
|
||||
|
||||
if [ "$loglevel" != "default" ]; then
|
||||
LOGLEVEL1="option MAXIMUM_CONSOLE_LOGLEVEL=$loglevel"
|
||||
LOGLEVEL2="option DEFAULT_CONSOLE_LOGLEVEL=$loglevel"
|
||||
else
|
||||
LOGLEVEL1="# no loglevel override"
|
||||
LOGLEVEL2=""
|
||||
fi
|
||||
|
||||
if [ "`which lzma`" != "" -a "$PAYLOAD" != /dev/null ]; then
|
||||
COMPRESSION="option CONFIG_COMPRESSED_PAYLOAD_LZMA=1"
|
||||
else
|
||||
|
@ -199,6 +211,8 @@ EOF
|
|||
-e s:CROSS_PREFIX:"$CROSS_COMPILE":g \
|
||||
-e s:CROSS_HOSTCC:"$HOSTCC":g \
|
||||
-e s:__COMPRESSION__:"$COMPRESSION":g \
|
||||
-e s:__LOGLEVEL__:"$LOGLEVEL1"\
|
||||
"$LOGLEVEL2":g \
|
||||
$TARGET/Config-${VENDOR}_${MAINBOARD}.lb.pre > $TARGET/Config-${VENDOR}_${MAINBOARD}.lb
|
||||
printf " ok\n"
|
||||
}
|
||||
|
@ -573,11 +587,11 @@ verbose=false
|
|||
getoptbrand="`getopt -V`"
|
||||
if [ "${getoptbrand:0:6}" == "getopt" ]; then
|
||||
# Detected GNU getopt that supports long options.
|
||||
args=`getopt -l version,verbose,help,all,target:,broken,payloads:,test,cpus:,silent,xml,config Vvhat:bp:Tc:sxC -- "$@"`
|
||||
args=`getopt -l version,verbose,help,all,target:,broken,payloads:,test,cpus:,silent,xml,config,loglevel Vvhat:bp:Tc:sxCl: -- "$@"`
|
||||
eval set "$args"
|
||||
else
|
||||
# Detected non-GNU getopt
|
||||
args=`getopt Vvhat:bp:Tc:sxC $*`
|
||||
args=`getopt Vvhat:bp:Tc:sxCl: $*`
|
||||
set -- $args
|
||||
fi
|
||||
|
||||
|
@ -603,6 +617,7 @@ while true ; do
|
|||
-ns|--nostackprotect) shift; stackprotect=true;;
|
||||
-sb|--scan-build) shift; scanbuild=true;;
|
||||
-C|--config) shift; configureonly=1;;
|
||||
-l|--loglevel) shift; loglevel="$1"; shift;;
|
||||
--) shift; break;;
|
||||
-*) printf "Invalid option\n\n"; myhelp; exit 1;;
|
||||
*) break;;
|
||||
|
|
Loading…
Reference in New Issue