php: use the new gettext logic
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Mon, 3 Jul 2017 21:13:28 +0000 (23:13 +0200)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Tue, 4 Jul 2017 23:34:03 +0000 (01:34 +0200)
This commit switches to use the new gettext logic, which involves:

 - using TARGET_NLS_DEPENDENCIES instead of hand-encoded dependencies
   on gettext/host-gettext

 - dropping BR2_PACKAGE_GETTEXT selection. Thanks to this, we can drop
   the BR2_USE_WCHAR dependency

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

index bb6ada6a91226923b445e1c33a138b142567a1c6..6b3d86925d848c5032859b8da1146098e5d66b7a 100644 (file)
@@ -164,13 +164,12 @@ comment "Human language and character encoding support"
 
 config BR2_PACKAGE_PHP_EXT_GETTEXT
        bool "Gettext"
-       depends on BR2_USE_WCHAR
-       select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT
+       depends on BR2_SYSTEM_ENABLE_NLS
        help
          Gettext support
 
-comment "Gettext support needs a toolchain w/ wchar"
-       depends on !BR2_USE_WCHAR
+comment "Gettext support needs NLS enabled"
+       depends on !BR2_SYSTEM_ENABLE_NLS
 
 config BR2_PACKAGE_PHP_EXT_ICONV
        bool "iconv"
index fe531a4ae96ba4dbcb0916820a70d8c0e30de0c7..1a1ed21718b39f124399da8d2ffa374e9d23c033 100644 (file)
@@ -160,7 +160,7 @@ endif
 
 ifeq ($(BR2_PACKAGE_PHP_EXT_GETTEXT),y)
 PHP_CONF_OPTS += --with-gettext=$(STAGING_DIR)/usr
-PHP_DEPENDENCIES += $(if $(BR2_NEEDS_GETTEXT),gettext)
+PHP_DEPENDENCIES += $(TARGET_NLS_DEPENDENCIES)
 endif
 
 ifeq ($(BR2_PACKAGE_PHP_EXT_ICONV),y)