Fix PROGRAM_INVOCATION handling with external toolchains
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Fri, 31 Jul 2009 09:40:34 +0000 (11:40 +0200)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Fri, 31 Jul 2009 09:40:34 +0000 (11:40 +0200)
BR2_UCLIBC_PROGRAM_INVOCATION is a toolchain configuration option,
like BR2_INET_IPV6, BR2_INET_RPC, on which some packages
depend. Therefore, it should be handled like BR2_INET_IPV6 and
BR2_INET_RPC in order to work properly with external toolchains.

Since we move it out of toolchain/uClibc/Config.in into
toolchain/Config.in.2, we rename the option to BR2_PROGRAM_INVOCATION
(since BR2_INET_RPC and others don't have UCLIBC in their name).

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/coreutils/Config.in
package/tar/Config.in
target/generic/Config.in
toolchain/Config.in.2
toolchain/external-toolchain/ext-tool.mk
toolchain/uClibc/Config.in
toolchain/uClibc/uclibc.mk

index 5dfe43c9de82ee271a2356a5ce6f41d8300a6e3d..a7159cf9ea75cfdd9d33f65d0d6705dbf39031ed 100644 (file)
@@ -1,6 +1,6 @@
 config BR2_PACKAGE_COREUTILS
        bool "coreutils"
-       depends on BR2_USE_WCHAR && BR2_UCLIBC_PROGRAM_INVOCATION
+       depends on BR2_USE_WCHAR && BR2_PROGRAM_INVOCATION
        help
          All of the basic file/text/shell utilities.  These are the
          core utilities which are expected to exist on every system.
@@ -14,4 +14,4 @@ config BR2_PACKAGE_COREUTILS
          http://www.gnu.org/software/coreutils/
 
 comment "coreutils requires a toolchain with WCHAR and PROGRAM_INVOCATION support"
-       depends on !(BR2_USE_WCHAR && BR2_UCLIBC_PROGRAM_INVOCATION)
+       depends on !(BR2_USE_WCHAR && BR2_PROGRAM_INVOCATION)
index a257949398eb6c4ddb3b6baf3b7822791bcc4be1..20529e378318d423b7b3e4a9c897c9bbef4fd8b4 100644 (file)
@@ -1,6 +1,6 @@
 config BR2_PACKAGE_TAR
        bool "tar"
-       depends on BR2_USE_WCHAR && BR2_UCLIBC_PROGRAM_INVOCATION
+       depends on BR2_USE_WCHAR && BR2_PROGRAM_INVOCATION
        help
          A program that saves many files together into a single tape or disk
          archive, and can restore individual files from the archive.
@@ -8,4 +8,4 @@ config BR2_PACKAGE_TAR
          http://www.gnu.org/software/tar/
 
 comment "tar requires a toolchain with WCHAR and PROGRAM_INVOCATION support"
-       depends on !(BR2_USE_WCHAR && BR2_UCLIBC_PROGRAM_INVOCATION)
+       depends on !(BR2_USE_WCHAR && BR2_PROGRAM_INVOCATION)
index 5f5110ca51e24c194c2d3647a28af9e7bd760e74..5de581104c143eb7871d5d91fee40b3f7254c8ae 100644 (file)
@@ -18,7 +18,7 @@ config BR2_TARGET_GENERIC_FIREWALL
 
 config BR2_TARGET_GENERIC_DEV_SYSTEM
        bool "Generic development system"
-       depends on BR2_USE_WCHAR && BR2_UCLIBC_PROGRAM_INVOCATION
+       depends on BR2_USE_WCHAR && BR2_PROGRAM_INVOCATION
        select BR2_CCACHE
        select BR2_PACKAGE_GDB
        select BR2_PACKAGE_GDB_SERVER
@@ -59,7 +59,7 @@ config BR2_TARGET_GENERIC_DEV_SYSTEM
          Board support for a generic development system.
 
 comment "Generic development system requires a toolchain with WCHAR and PROGRAM_INVOCATION support"
-       depends on !(BR2_USE_WCHAR && BR2_UCLIBC_PROGRAM_INVOCATION)
+       depends on !(BR2_USE_WCHAR && BR2_PROGRAM_INVOCATION)
 
 menuconfig BR2_TARGET_GENERIC_GETTY
        bool "Generic serial port config"
index 5df04e01be33764a8e870e02146429a1c3a8a057..2a9ce24ef4c4287da0f70fe8b318296d33b1bd23 100644 (file)
@@ -119,6 +119,16 @@ choice
                bool "Native POSIX Threading (NPTL)"
 endchoice
 
+config BR2_PROGRAM_INVOCATION
+       bool "Enable 'program invocation name'"
+       help
+         Support for the GNU-specific program_invocation_name and
+         program_invocation_short_name strings.  Some GNU packages
+         (like tar and coreutils) utilize these for extra useful
+         output, but in general are not required.
+         If you have an external binary toolchain that has been built
+         with program invocation support then enable this option.
+
 config BR2_GCC_CROSS_CXX
        bool
        help
index d441a92524f96763d2707525749c9dda0e3a5def..568ac3a35bc9be16f9a72dbcd3fe2e0e0bc141d0 100644 (file)
@@ -115,7 +115,8 @@ check_glibc = \
        $(call check_glibc_feature,BR2_INET_IPV6,IPv6 support) ;\
        $(call check_glibc_feature,BR2_INET_RPC,RPC support) ;\
        $(call check_glibc_feature,BR2_ENABLE_LOCALE,Locale support) ;\
-       $(call check_glibc_feature,BR2_USE_WCHAR,Wide char support)
+       $(call check_glibc_feature,BR2_USE_WCHAR,Wide char support) ;\
+       $(call check_glibc_feature,BR2_PROGRAM_INVOCATION,Program invocation support)
 
 #
 # Check the conformity of Buildroot configuration with regard to the
@@ -160,6 +161,7 @@ check_uclibc = \
        $(call check_uclibc_feature,__UCLIBC_HAS_RPC__,BR2_INET_RPC,$${UCLIBC_CONFIG_FILE},RPC support) ;\
        $(call check_uclibc_feature,__UCLIBC_HAS_LOCALE__,BR2_ENABLE_LOCALE,$${UCLIBC_CONFIG_FILE},Locale support) ;\
        $(call check_uclibc_feature,__UCLIBC_HAS_WCHAR__,BR2_USE_WCHAR,$${UCLIBC_CONFIG_FILE},Wide char support) ;\
+       $(call check_uclibc_feature,__UCLIBC_HAS_PROGRAM_INVOCATION_NAME__,BR2_PROGRAM_INVOCATION,$${UCLIBC_CONFIG_FILE},Program invocation support) ;\
 
 #
 # Check that the Buildroot configuration of the ABI matches the
index b7678a356dd0ae80ed321441815e454ce6e9163f..d0486abd64a47c0b17b47801c2f48eddeaba8cdb 100644 (file)
@@ -68,14 +68,6 @@ config BR2_PTHREAD_DEBUG
        help
          Build the thread library with debugging enabled.
 
-config BR2_UCLIBC_PROGRAM_INVOCATION
-       bool "Enable 'program invocation name'"
-       help
-         Support for the GNU-specific program_invocation_name and
-         program_invocation_short_name strings.  Some GNU packages
-         (like tar and coreutils) utilize these for extra useful
-         output, but in general are not required.
-
 config BR2_UCLIBC_INSTALL_TEST_SUITE
        bool "Compile and install uClibc tests"
        select BR2_PACKAGE_MAKE
index 80d7d9861b1f34ee02e6e0b6b6ff949b68e2ba84..de8e1d56238d07d3a296914a5524ca7f560b3337 100644 (file)
@@ -353,7 +353,7 @@ ifeq ($(BR2_USE_WCHAR),y)
 else
        $(SED) 's,^.*UCLIBC_HAS_WCHAR.*,UCLIBC_HAS_WCHAR=n,g' $(UCLIBC_DIR)/.oldconfig
 endif
-ifeq ($(BR2_UCLIBC_PROGRAM_INVOCATION),y)
+ifeq ($(BR2_PROGRAM_INVOCATION),y)
        $(SED) 's,^.*UCLIBC_HAS_PROGRAM_INVOCATION_NAME.*,UCLIBC_HAS_PROGRAM_INVOCATION_NAME=y,g' $(UCLIBC_DIR)/.oldconfig
 else
        $(SED) 's,^.*UCLIBC_HAS_PROGRAM_INVOCATION_NAME.*,UCLIBC_HAS_PROGRAM_INVOCATION_NAME=n,g' $(UCLIBC_DIR)/.oldconfig