configure.sh now will ignore appconfig files if CONFIG_NUTTX_NEWCONFIG is defined

git-svn-id: https://nuttx.svn.sourceforge.net/svnroot/nuttx/trunk@5080 7fd9a85b-ad96-42d3-883c-3090e2eb8679
This commit is contained in:
patacongo
2012-09-03 15:16:32 +00:00
parent 1349b00b41
commit 612735d392
2 changed files with 45 additions and 2 deletions
+16 -2
View File
@@ -115,6 +115,18 @@ if [ ! -r "${configpath}/defconfig" ]; then
exit 6
fi
# Extract values needed from the defconfig file. We need:
# (1) The CONFIG_NUTTX_NEWCONFIG setting to know if this is a "new" style
# configuration, and
# (2) The CONFIG_APPS_DIR to see if there is a configured location for the
# application directory.
newconfig=`grep CONFIG_NUTTX_NEWCONFIG= "${configpath}/defconfig" | cut -d'=' -f2`
if [ -z "${appdir}" ]; then
appdir=`grep CONFIG_APPS_DIR= "${configpath}/defconfig" | cut -d'=' -f2`
fi
# Check for the apps/ dir in the usual place if appdir was not provided
if [ -z "${appdir}" ]; then
@@ -150,9 +162,11 @@ chmod 755 "${TOPDIR}/setenv.sh"
install -C "${configpath}/defconfig" "${TOPDIR}/.configX" || \
{ echo "Failed to copy ${configpath}/defconfig" ; exit 9 ; }
# Copy option appconfig
# Copy appconfig file. The appconfig file will be copied to ${appdir}/.config
# if both (1) ${appdir} is defined and (2) we are not using the new configuration
# (which does not require a .config file in the appsdir.
if [ ! -z "${appdir}" ]; then
if [ ! -z "${appdir}" -a "X${newconfig}" != "Xy" ]; then
if [ ! -r "${configpath}/appconfig" ]; then
echo "NOTE: No readable appconfig file found in ${configpath}"
else