coreutils: use the new gettext logic
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Tue, 4 Jul 2017 10:28:00 +0000 (12:28 +0200)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Tue, 4 Jul 2017 23:27:24 +0000 (01:27 +0200)
This commit uses TARGET_NLS_DEPENDENCIES instead of existing logic to
add the dependency on gettext. To keep the existing behavior, we keep
the --with-libintl-prefix option, but only when a libintl library is
effectively provided by gettext.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/coreutils/coreutils.mk

index 14b952f5a1e10cd194b8bd0264426a4dbe9991ab..6a8a31b06140b578d8ad2dd5f6a70e52460a7831 100644 (file)
@@ -77,10 +77,11 @@ else
 COREUTILS_CONF_OPTS += --disable-xattr
 endif
 
+COREUTILS_DEPENDENCIES += $(TARGET_NLS_DEPENDENCIES)
+
 # It otherwise fails to link properly, not mandatory though
-ifeq ($(BR2_PACKAGE_GETTEXT),y)
+ifeq ($(BR2_PACKAGE_GETTEXT_PROVIDES_LIBINTL),y)
 COREUTILS_CONF_OPTS += --with-libintl-prefix=$(STAGING_DIR)/usr
-COREUTILS_DEPENDENCIES += gettext
 endif
 
 ifeq ($(BR2_PACKAGE_GMP),y)