You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2020/01/24 01:37:06 UTC

[GitHub] [incubator-nuttx] xiaoxiang781216 commented on a change in pull request #131: Improve config

xiaoxiang781216 commented on a change in pull request #131: Improve config
URL: https://github.com/apache/incubator-nuttx/pull/131#discussion_r370440719
 
 

 ##########
 File path: tools/testbuild.sh
 ##########
 @@ -163,83 +138,19 @@ function distclean {
 function configure {
   cd $nuttx/tools || { echo "ERROR: failed to CD to $nuttx/tools"; exit 1; }
   echo "  Configuring..."
-  ./configure.sh $config
-
-  cd $nuttx || { echo "ERROR: failed to CD to $nuttx"; exit 1; }
-
-  if [ "X$host" == "Xlinux" ]; then
-    echo "  Select CONFIG_HOST_LINUX=y"
-
-    kconfig-tweak --file $nuttx/.config --enable CONFIG_HOST_LINUX
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_HOST_WINDOWS
-
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_TOOLCHAIN_WINDOWS
-
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_WINDOWS_NATIVE
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_WINDOWS_CYGWIN
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_WINDOWS_MSYS
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_WINDOWS_OTHER
-
-    kconfig-tweak --file $nuttx/.config --enable CONFIG_SIM_X8664_SYSTEMV
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_SIM_X8664_MICROSOFT
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_SIM_M32
-  else
-    echo "  Select CONFIG_HOST_WINDOWS=y"
-    kconfig-tweak --file $nuttx/.config --enable CONFIG_HOST_WINDOWS
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_HOST_LINUX
-
-    if [ "X$wenv" == "Xcygwin" ]; then
-      echo "  Select CONFIG_WINDOWS_CYGWIN=y"
-      kconfig-tweak --file $nuttx/.config --enable CONFIG_WINDOWS_CYGWIN
-      kconfig-tweak --file $nuttx/.config --disable CONFIG_WINDOWS_UBUNTU
-      kconfig-tweak --file $nuttx/.config --disable CONFIG_WINDOWS_NATIVE
-    else
-      kconfig-tweak --file $nuttx/.config --disable CONFIG_WINDOWS_CYGWIN
-      if [ "X$wenv" == "Xubuntu" ]; then
-        echo "  Select CONFIG_WINDOWS_UBUNTU=y"
-        kconfig-tweak --file $nuttx/.config --enable CONFIG_WINDOWS_UBUNTU
-        kconfig-tweak --file $nuttx/.config --disable CONFIG_WINDOWS_NATIVE
-      else
-        echo "  Select CONFIG_WINDOWS_NATIVE=y"
-        kconfig-tweak --file $nuttx/.config --disable CONFIG_WINDOWS_UBUNTU
-        kconfig-tweak --file $nuttx/.config --enable CONFIG_WINDOWS_NATIVE
-      fi
-    fi
-
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_WINDOWS_MSYS
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_WINDOWS_OTHER
-
-    kconfig-tweak --file $nuttx/.config --enable CONFIG_SIM_X8664_MICROSOFT
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_SIM_X8664_SYSTEMV
-    kconfig-tweak --file $nuttx/.config --disable CONFIG_SIM_M32
-  fi
-
-  kconfig-tweak --file $nuttx/.config --disable CONFIG_HOST_MACOS
-  kconfig-tweak --file $nuttx/.config --disable CONFIG_HOST_OTHER
-
-  if [ "X$sizet" == "Xlong" ]; then
 
 Review comment:
   @gregory-nutt here its the code modify CONFIG_CXX_NEWLONG, I remove this option for several reasons:
   1.Only testbuild.sh support -s option, other tools(configure.sh/sethost.sh) doesn't. I think these tools should be  consistent with each other.
   2.Toolchain is specified in testlist-file, but CONFIG_CXX_NEWLONG must specify through command line, which make it's hard to set these two related options correctly.
   How about we change the default value of CXX_NEWLONG base on the compiler config(CONFIG_XXX_TOOLCHAIN_YYY)? so the default value work out of box.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services