Build system: Add 'make oldconfig' target. Use this option in tools/testbuild.sh. Add --silent option to tools/refresh.sh so that it can be run in batch without human interaction
This commit is contained in:
parent
1c31e10397
commit
fea11c002a
|
@ -486,6 +486,9 @@ config: apps_preconfig
|
|||
oldconfig: apps_preconfig
|
||||
$(Q) APPSDIR=${CONFIG_APPS_DIR} kconfig-conf --oldconfig Kconfig
|
||||
|
||||
olddefconfig: apps_preconfig
|
||||
$(Q) APPSDIR=${CONFIG_APPS_DIR} kconfig-conf --olddefconfig Kconfig
|
||||
|
||||
menuconfig: apps_preconfig
|
||||
$(Q) APPSDIR=${CONFIG_APPS_DIR} kconfig-mconf Kconfig
|
||||
|
||||
|
|
|
@ -486,6 +486,9 @@ config: apps_preconfig
|
|||
oldconfig: apps_preconfig
|
||||
$(Q) set APPSDIR=$(patsubst "%",%,${CONFIG_APPS_DIR})& kconfig-conf --oldconfig Kconfig
|
||||
|
||||
olddefconfig: apps_preconfig
|
||||
$(Q) set APPSDIR=$(patsubst "%",%,${CONFIG_APPS_DIR})& kconfig-conf --olddefconfig Kconfig
|
||||
|
||||
menuconfig: configenv apps_preconfig
|
||||
$(Q) set APPSDIR=$(patsubst "%",%,${CONFIG_APPS_DIR})& kconfig-mconf Kconfig
|
||||
|
||||
|
|
2
arch
2
arch
|
@ -1 +1 @@
|
|||
Subproject commit c84c4f2edc06fc9bc5e0b4325063feda89b3d2a5
|
||||
Subproject commit 84aade6ed5dcc6fe8df0afb7cb0fc157e128c6bc
|
2
configs
2
configs
|
@ -1 +1 @@
|
|||
Subproject commit 88faa8e05cc65a32d47e0b97c1954ef1e6e073df
|
||||
Subproject commit b2be018b284cdaaf192afd6b61dfcd4dce065b73
|
|
@ -36,12 +36,16 @@ USAGE="USAGE: $0 [--debug|--help] <board>/<config>"
|
|||
ADVICE="Try '$0 --help' for more information"
|
||||
|
||||
unset CONFIG
|
||||
silent=n
|
||||
|
||||
while [ ! -z "$1" ]; do
|
||||
case $1 in
|
||||
--debug )
|
||||
set -x
|
||||
;;
|
||||
--silent )
|
||||
silent=y
|
||||
;;
|
||||
--help )
|
||||
echo "$0 is a tool for refreshing board configurations"
|
||||
echo ""
|
||||
|
@ -50,6 +54,8 @@ while [ ! -z "$1" ]; do
|
|||
echo "Where:"
|
||||
echo " --debug"
|
||||
echo " Enable script debug"
|
||||
echo " --silent"
|
||||
echo " Update board configuration without interaction"
|
||||
echo " --help"
|
||||
echo " Show this help message and exit"
|
||||
echo " <board>"
|
||||
|
@ -157,9 +163,13 @@ fi
|
|||
cp -a $DEFCONFIG .config || \
|
||||
{ echo "ERROR: Failed to copy $DEFCONFIG to .config"; exit 1; }
|
||||
|
||||
# Then run oldconfig
|
||||
# Then run oldconfig or oldefconfig
|
||||
|
||||
make oldconfig
|
||||
if [ "X${silent}" == "Xy" ]; then
|
||||
make olddefconfig
|
||||
else
|
||||
make oldconfig
|
||||
fi
|
||||
|
||||
# Show differences
|
||||
|
||||
|
@ -168,14 +178,21 @@ $CMPCONFIG $DEFCONFIG .config
|
|||
|
||||
# Save the refreshed configuration
|
||||
|
||||
read -p "Save the new configuration (y/n)?" -n 1 -r
|
||||
echo
|
||||
if [[ $REPLY =~ ^[Yy]$ ]]
|
||||
then
|
||||
if [ "X${silent}" == "Xy" ]; then
|
||||
echo "Saving the new configuration file"
|
||||
mv .config $DEFCONFIG || \
|
||||
{ echo "ERROR: Failed to move .config to $DEFCONFIG"; exit 1; }
|
||||
chmod 644 $DEFCONFIG
|
||||
else
|
||||
read -p "Save the new configuration (y/n)?" -n 1 -r
|
||||
echo
|
||||
if [[ $REPLY =~ ^[Yy]$ ]]
|
||||
then
|
||||
echo "Saving the new configuration file"
|
||||
mv .config $DEFCONFIG || \
|
||||
{ echo "ERROR: Failed to move .config to $DEFCONFIG"; exit 1; }
|
||||
chmod 644 $DEFCONFIG
|
||||
fi
|
||||
fi
|
||||
|
||||
# Restore any previous .config file
|
||||
|
|
|
@ -193,8 +193,7 @@ function configure {
|
|||
|
||||
echo " Refreshing..."
|
||||
cd $nuttx || { echo "ERROR: failed to CD to $nuttx"; exit 1; }
|
||||
make context 1>/dev/null 2>&1
|
||||
kconfig-conf --olddefconfig Kconfig 1>/dev/null
|
||||
make olddefconfig 1>/dev/null 2>&1
|
||||
}
|
||||
|
||||
# Perform the next build
|
||||
|
|
Loading…
Reference in New Issue