Ouss4 commented on a change in pull request #594: Tools refine
URL: https://github.com/apache/incubator-nuttx/pull/594#discussion_r395968633
 
 

 ##########
 File path: tools/configure.sh
 ##########
 @@ -168,16 +164,25 @@ fi
 
 src_config=${configpath}/defconfig
 dest_config="${TOPDIR}/.config"
+backup_config="${TOPDIR}/defconfig"
 
 if [ ! -r ${src_config} ]; then
   echo "File ${src_config} does not exist"
   exit 5
 fi
 
-if [ ${skip} != 1 ] && [ -r ${dest_config} ]; then
-  echo "Already configured!"
-  echo "Do 'make distclean' and try again."
-  exit 6
+if [ -r ${dest_config} ]; then
+  if cmp -s ${src_config} ${backup_config}; then
+    exit 0 # No any config change
+  fi
+
+  if [ "X${enforce}" = "Xy" ]; then
+    make -C ${TOPDIR} $* distclean 1>/dev/null
 
 Review comment:
   @xiaoxiang781216 Do you prefer running distclean quietly? For a second I 
thought my system was hung.
   (Maybe it's just my slow laptop?)

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to