You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by gn...@apache.org on 2020/05/11 18:25:08 UTC

[incubator-nuttx] 02/03: tools/refresh.sh: replace cmpconfig with diff

This is an automated email from the ASF dual-hosted git repository.

gnutt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git

commit 3f83d2da30d814165565787d9c4e9f924de1c4d9
Author: Xiang Xiao <xi...@xiaomi.com>
AuthorDate: Mon May 11 12:03:43 2020 +0800

    tools/refresh.sh: replace cmpconfig with diff
    
    since we want to catch the order difference too
    
    Signed-off-by: Xiang Xiao <xi...@xiaomi.com>
---
 tools/refresh.sh | 32 +-------------------------------
 1 file changed, 1 insertion(+), 31 deletions(-)

diff --git a/tools/refresh.sh b/tools/refresh.sh
index 0319236..ceff44c 100755
--- a/tools/refresh.sh
+++ b/tools/refresh.sh
@@ -111,36 +111,6 @@ if [ ! -x tools/${MYNAME} ] ; then
   exit 1
 fi
 
-# If the cmpconfig executable does not exist, then build it
-
-CMPCONFIG_TARGET=cmpconfig
-CMPCONFIG1=tools/cmpconfig
-CMPCONFIG2=tools/cmpconfig.exe
-CMPCONFIGMAKEFILE=Makefile.host
-CMPCONFIGMAKEDIR=tools
-
-if [ -x ${CMPCONFIG1} ]; then
-  CMPCONFIG=${CMPCONFIG1}
-else
-  if [ -x ${CMPCONFIG2} ]; then
-    CMPCONFIG=${CMPCONFIG2}
-  else
-    make -C ${CMPCONFIGMAKEDIR} -f ${CMPCONFIGMAKEFILE} ${CMPCONFIG_TARGET} 1>/dev/null || \
-      { echo "ERROR: make ${CMPCONFIG1} failed" ; exit 1 ; }
-  fi
-fi
-
-if [ -x ${CMPCONFIG1} ]; then
-  CMPCONFIG=${CMPCONFIG1}
-else
-  if [ -x ${CMPCONFIG2} ]; then
-    CMPCONFIG=${CMPCONFIG2}
-  else
-    echo "ERROR: Failed to create  ${CMPCONFIG1}"
-    exit 1
-  fi
-fi
-
 # Get the board configuration
 
 if [ -z "${CONFIGS}" ]; then
@@ -259,7 +229,7 @@ for CONFIG in ${CONFIGS}; do
 
   # Show differences
 
-  if ! $CMPCONFIG $DEFCONFIG defconfig; then
+  if ! diff $DEFCONFIG defconfig; then
 
     # Save the refreshed configuration