Skip to contentSkip to conversation

Pull request for branch gettext-rework

GIT PULL New Thomas Petazzoni 3 participants 11 messages Jul 19, 2012 – Sep 1, 2012

lore
Share & tools
lore
#0 lore raw

Hello,

Here is a set of patches that builds on top of the work from Maxime Ripard and Samuel Martin to clean up how gettext is handled, and in the end migrate the gettext package to the autotools-package infrastructure.

Compared to Samuel last posting, I've splitted the work into more patches to ease the review process:

* The first patch removes the possibility of building gettext statically.

* The second patch removes the gettext-target make target, which was never used anywhere.

* The third patch removes the separation between gettext and libintl targets. Now, there is only a 'gettext' target, which installs just the necessary libraries in the target (identical to what libintl was doing previously). This patch breaks the build for many packages, but was kept separate to make the review easier.

* The fourth patch adjusts all the packages that add a dependency on libintl, and use instead a dependency on gettext.

* The final fifth patch converts the gettext package to the autotools-package infrastructure.

I hope that this rework of Maxime's and Samuel's work will help in getting this nice cleanup merged.

Please review and, if possible, ack this patch series.

Thanks!

Thomas

The following changes since commit 498ea22be27863c8eff99033384f9d268167a2b3:

sam-ba: only propose it if the host is x86 or x86_64 (2012-07-18 19:33:46 +0200)

are available in the git repository at:

git://git.free-electrons.com/users/thomas-petazzoni/buildroot.git gettext-rework

for you to fetch changes up to 66a7689f733357af7bb277467bc2198817fc9b69:

gettext: convert to autotools-package (2012-07-19 23:18:03 +0200)

----------------------------------------------------------------
Maxime Ripard (1):
gettext: convert to autotools-package

Thomas Petazzoni (4):
gettext: remove option to build statically
gettext: remove the gettext-target make target, unused
gettext: remove libintl handling
Remove all references to libintl

 package/avahi/Config.in                     |    1 -
 package/avahi/avahi.mk                      |    6 +-
 package/axel/Config.in                      |    1 -
 package/axel/axel.mk                        |    2 +-
 package/binutils/Config.in                  |    1 -
 package/binutils/binutils.mk                |    2 +-
 package/diffutils/diffutils.mk              |    3 +-
 package/dnsmasq/Config.in                   |    1 -
 package/dnsmasq/dnsmasq.mk                  |    2 +-
 package/flex/flex.mk                        |    3 +-
 package/gdk-pixbuf/Config.in                |    1 -
 package/gdk-pixbuf/gdk-pixbuf.mk            |    2 +-
 package/gettext/Config.in                   |   32 ++---
 package/gettext/gettext.mk                  |  181 ++++-----------------------
 package/glib-networking/Config.in           |    1 -
 package/glib-networking/glib-networking.mk  |    2 +-
 package/gmpc/Config.in                      |    1 -
 package/gmpc/gmpc.mk                        |    2 +-
 package/grep/Config.in                      |    1 -
 package/grep/grep.mk                        |    2 +-
 package/kbd/Config.in                       |    1 -
 package/kbd/kbd.mk                          |    2 +-
 package/libglib2/Config.in                  |    1 -
 package/libglib2/libglib2.mk                |    2 +-
 package/libsoup/Config.in                   |    1 -
 package/libsoup/libsoup.mk                  |    2 +-
 package/lshw/lshw.mk                        |    2 +-
 package/make/Config.in                      |    1 -
 package/make/make.mk                        |    2 +-
 package/midori/Config.in                    |    1 -
 package/midori/midori.mk                    |    2 +-
 package/multimedia/pulseaudio/Config.in     |    2 +-
 package/multimedia/pulseaudio/pulseaudio.mk |    2 +-
 package/ndisc6/ndisc6.mk                    |    4 +-
 package/pango/Config.in                     |    1 -
 package/pango/pango.mk                      |    2 +-
 package/psmisc/Config.in                    |    1 -
 package/psmisc/psmisc.mk                    |    2 +-
 package/quota/Config.in                     |    1 -
 package/quota/quota.mk                      |    2 +-
 package/sshfs/Config.in                     |    1 -
 package/sshfs/sshfs.mk                      |    2 +-
 package/sysstat/Config.in                   |    1 -
 package/sysstat/sysstat.mk                  |    2 +-
 package/ushare/Config.in                    |    1 -
 package/ushare/ushare.mk                    |    2 +-
 package/util-linux/util-linux.mk            |    4 +-
 package/vala/Config.in                      |    1 -
 package/vala/vala.mk                        |    2 +-
 49 files changed, 63 insertions(+), 234 deletions(-)

Thanks,

Signature · 1 line
Thomas Petazzoni
#1 lore raw

PATCH 1/5 gettext: remove option to build statically

---
 package/gettext/Config.in  |   12 ------------
 package/gettext/gettext.mk |    9 ---------
 2 files changed, 21 deletions(-)
package/gettext/Config.in +0 -12
index fabfe1e..0ee4065 100644
@@ -12,18 +12,6 @@ config BR2_PACKAGE_GETTEXT
 comment "gettext requires a toolchain with WCHAR support"
 	depends on BR2_NEEDS_GETTEXT && !BR2_USE_WCHAR
 
-config BR2_PACKAGE_GETTEXT_STATIC
-	bool "Use libgettext.a instead of libgettext.so.*"
-	depends on BR2_PACKAGE_GETTEXT
-	depends on BR2_arm
-	help
-	  The GNU `gettext' utilities are a set of tools that provide a
-	  framework to help other GNU packages produce multi-lingual
-	  messages.
-
-	  http://www.gnu.org/software/gettext/
-
-
 config BR2_PACKAGE_LIBINTL
 	bool "libintl"
 	depends on BR2_NEEDS_GETTEXT
package/gettext/gettext.mk +0 -9
index 9778007..20bd672 100644
@@ -11,11 +11,7 @@ GETTEXT_CAT:=$(ZCAT)
 GETTEXT_BINARY:=gettext-runtime/src/gettext
 GETTEXT_TARGET_BINARY:=usr/bin/gettext
 
-ifeq ($(BR2_PACKAGE_GETTEXT_STATIC),y)
-LIBINTL_TARGET_BINARY:=usr/lib/libintl.a
-else
 LIBINTL_TARGET_BINARY:=usr/lib/libintl.so
-endif
 
 $(DL_DIR)/$(GETTEXT_SOURCE):
 	 $(call DOWNLOAD,$(GETTEXT_SITE)/$(GETTEXT_SOURCE))
@@ -147,11 +143,6 @@ $(TARGET_DIR)/usr/lib/libintl.so: $(STAGING_DIR)/$(GETTEXT_TARGET_BINARY)
 		libgettext*.so*.la libintl*.so*.la)
 	touch -c $@
 
-$(TARGET_DIR)/usr/lib/libintl.a: $(STAGING_DIR)/$(GETTEXT_TARGET_BINARY)
-	cp -dpf $(STAGING_DIR)/usr/lib/libgettext*.a $(TARGET_DIR)/usr/lib/
-	cp -dpf $(STAGING_DIR)/usr/lib/libintl*.a $(TARGET_DIR)/usr/lib/
-	touch -c $@
-
 libintl: $(TARGET_DIR)/$(LIBINTL_TARGET_BINARY)
 
 #############################################################
Signature · 1 line
1.7.9.5
#2 lore raw

PATCH 2/5 gettext: remove the gettext-target make target, unused

In reply to Thomas Petazzoni
---
 package/gettext/gettext.mk |    4 ----
 1 file changed, 4 deletions(-)
package/gettext/gettext.mk +0 -4
index 20bd672..6b2c336 100644
@@ -130,10 +130,6 @@ gettext-dirclean:
 #
 #############################################################
 
-gettext-target: $(GETTEXT_DIR)/$(GETTEXT_BINARY)
-	$(MAKE) DESTDIR=$(TARGET_DIR) -C $(GETTEXT_DIR) install
-	chmod +x $(TARGET_DIR)/usr/lib/libintl.so* # identify as needing to be stripped
-
 $(TARGET_DIR)/usr/lib/libintl.so: $(STAGING_DIR)/$(GETTEXT_TARGET_BINARY)
 	cp -dpf $(STAGING_DIR)/usr/lib/libgettext*.so* \
 		$(STAGING_DIR)/usr/lib/libintl*.so* $(TARGET_DIR)/usr/lib/
Signature · 1 line
1.7.9.5
#3 lore raw

PATCH 3/5 gettext: remove libintl handling

In reply to Thomas Petazzoni

Now, the gettext package always:

* install everything to the staging directory
* install the libraries to the target directory

Note that this commit removes BR2_PACKAGE_LIBINTL without updating the packages, it is done in a separate commit to ease the review process.

---
 package/gettext/Config.in  |   14 ++++----------
 package/gettext/gettext.mk |    7 +------
 2 files changed, 5 insertions(+), 16 deletions(-)
package/gettext/Config.in +4 -10
index 0ee4065..de19410 100644
@@ -7,17 +7,11 @@ config BR2_PACKAGE_GETTEXT
 	  framework to help other GNU packages produce multi-lingual
 	  messages.
 
+	  Only the gettext libraries will be installed in the
+	  target. The full gettext suite, including tools, will be
+	  installed in the staging directory.
+
 	  http://www.gnu.org/software/gettext/
 
 comment "gettext requires a toolchain with WCHAR support"
 	depends on BR2_NEEDS_GETTEXT && !BR2_USE_WCHAR
-
-config BR2_PACKAGE_LIBINTL
-	bool "libintl"
-	depends on BR2_NEEDS_GETTEXT
-	depends on BR2_USE_WCHAR
-	help
-	  Selecting this package installs all of gettext in the staging
-	  directory and the shared library for it's use in the target.
-
-	  http://www.gnu.org/software/gettext/
package/gettext/gettext.mk +1 -6
index 6b2c336..4dff941 100644
@@ -112,7 +112,7 @@ $(STAGING_DIR)/$(GETTEXT_TARGET_BINARY): $(GETTEXT_DIR)/$(GETTEXT_BINARY)
 gettext-legal-info:
 	@$(call legal-warning-pkg,gettext,legal-info not yet implemented)
 
-gettext: host-pkg-config $(if $(BR2_PACKAGE_LIBICONV),libiconv) $(STAGING_DIR)/$(GETTEXT_TARGET_BINARY)
+gettext: host-pkg-config $(if $(BR2_PACKAGE_LIBICONV),libiconv) $(STAGING_DIR)/$(GETTEXT_TARGET_BINARY) $(TARGET_DIR)/$(LIBINTL_TARGET_BINARY)
 
 gettext-unpacked: $(GETTEXT_DIR)/.unpacked
 
@@ -139,16 +139,11 @@ $(TARGET_DIR)/usr/lib/libintl.so: $(STAGING_DIR)/$(GETTEXT_TARGET_BINARY)
 		libgettext*.so*.la libintl*.so*.la)
 	touch -c $@
 
-libintl: $(TARGET_DIR)/$(LIBINTL_TARGET_BINARY)
-
 #############################################################
 #
 # Toplevel Makefile options
 #
 #############################################################
-ifeq ($(BR2_PACKAGE_LIBINTL),y)
-TARGETS+=libintl
-endif
 ifeq ($(BR2_PACKAGE_GETTEXT),y)
 TARGETS+=gettext
 endif
Signature · 1 line
1.7.9.5
#4 lore raw

PATCH 3/5 gettext: remove libintl handling

Thomas, All,

Quoted 7 lines · On Thursday 19 July 2012 23:21:02 Thomas Petazzoni wrote:

Now, the gettext package always:

* install everything to the staging directory
* install the libraries to the target directory

Note that this commit removes BR2_PACKAGE_LIBINTL without updating the packages, it is done in a separate commit to ease the review process.

[--SNIP--]

package/gettext/Config.in config BR2_PACKAGE_GETTEXT · line 23

Quoted 9 lines
package/gettext/Config.in +0 -9
-config BR2_PACKAGE_LIBINTL
-	bool "libintl"
-	depends on BR2_NEEDS_GETTEXT
-	depends on BR2_USE_WCHAR
-	help
-	  Selecting this package installs all of gettext in the staging
-	  directory and the shared library for it's use in the target.
-
-	  http://www.gnu.org/software/gettext/

To avoid breaking the menuconfig, what about:

config BR2_PACKAGE_LIBINTL
- bool "libintl"
- depends on BR2_NEEDS_GETTEXT
- depends on BR2_USE_WCHAR
- help
- Selecting this package installs all of gettext in the staging
- directory and the shared library for it's use in the target.
-
- http://www.gnu.org/software/gettext/
+ bool

Thus, we keep an blind config option that can still be selected, although there is nothing in gettext.mk that uses it, and we do not break the other packages.

Then, it can be removed entirely in the next patch.

Regards,
Yann E. MORIN.

Signature · 6 lines
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
#5 lore raw

PATCH 4/5 Remove all references to libintl

In reply to Thomas Petazzoni

From now on, packages only need to select the BR2_PACKAGE_GETTEXT option and depend on the 'gettext' package to get the necessary i18n libraries installed on the target.

---
 package/avahi/Config.in                     |    1 -
 package/avahi/avahi.mk                      |    6 +++---
 package/axel/Config.in                      |    1 -
 package/axel/axel.mk                        |    2 +-
 package/binutils/Config.in                  |    1 -
 package/binutils/binutils.mk                |    2 +-
 package/diffutils/diffutils.mk              |    3 +--
 package/dnsmasq/Config.in                   |    1 -
 package/dnsmasq/dnsmasq.mk                  |    2 +-
 package/flex/flex.mk                        |    3 +--
 package/gdk-pixbuf/Config.in                |    1 -
 package/gdk-pixbuf/gdk-pixbuf.mk            |    2 +-
 package/glib-networking/Config.in           |    1 -
 package/glib-networking/glib-networking.mk  |    2 +-
 package/gmpc/Config.in                      |    1 -
 package/gmpc/gmpc.mk                        |    2 +-
 package/grep/Config.in                      |    1 -
 package/grep/grep.mk                        |    2 +-
 package/kbd/Config.in                       |    1 -
 package/kbd/kbd.mk                          |    2 +-
 package/libglib2/Config.in                  |    1 -
 package/libglib2/libglib2.mk                |    2 +-
 package/libsoup/Config.in                   |    1 -
 package/libsoup/libsoup.mk                  |    2 +-
 package/lshw/lshw.mk                        |    2 +-
 package/make/Config.in                      |    1 -
 package/make/make.mk                        |    2 +-
 package/midori/Config.in                    |    1 -
 package/midori/midori.mk                    |    2 +-
 package/multimedia/pulseaudio/Config.in     |    2 +-
 package/multimedia/pulseaudio/pulseaudio.mk |    2 +-
 package/ndisc6/ndisc6.mk                    |    4 ++--
 package/pango/Config.in                     |    1 -
 package/pango/pango.mk                      |    2 +-
 package/psmisc/Config.in                    |    1 -
 package/psmisc/psmisc.mk                    |    2 +-
 package/quota/Config.in                     |    1 -
 package/quota/quota.mk                      |    2 +-
 package/sshfs/Config.in                     |    1 -
 package/sshfs/sshfs.mk                      |    2 +-
 package/sysstat/Config.in                   |    1 -
 package/sysstat/sysstat.mk                  |    2 +-
 package/ushare/Config.in                    |    1 -
 package/ushare/ushare.mk                    |    2 +-
 package/util-linux/util-linux.mk            |    4 ++--
 package/vala/Config.in                      |    1 -
 package/vala/vala.mk                        |    2 +-
 47 files changed, 31 insertions(+), 53 deletions(-)
package/avahi/Config.in +0 -1
index eb3ccb6..8ba33d5 100644
@@ -1,7 +1,6 @@
 config BR2_PACKAGE_AVAHI
 	bool "avahi"
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	help
 	  Avahi is a system which facilitates service
 	  discovery on a local network.
package/avahi/avahi.mk +3 -3
index d9c0d1d..d7caa57 100644
@@ -83,7 +83,7 @@ AVAHI_CONF_OPT = --localstatedir=/var \
 		--with-autoipd-user=default \
 		--with-autoipd-group=default
 
-AVAHI_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl) host-intltool host-pkg-config
+AVAHI_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext) host-intltool host-pkg-config
 
 ifneq ($(BR2_PACKAGE_AVAHI_DAEMON)$(BR2_PACKAGE_AVAHI_AUTOIPD),)
 AVAHI_DEPENDENCIES += libdaemon
@@ -131,8 +131,8 @@ else
 AVAHI_CONF_OPT += --disable-python
 endif
 
-ifeq ($(BR2_PACKAGE_LIBINTL),y)
-AVAHI_DEPENDENCIES += libintl
+ifeq ($(BR2_PACKAGE_GETTEXT),y)
+AVAHI_DEPENDENCIES += gettext
 AVAHI_MAKE_OPT = LIBS=-lintl
 endif
 
package/axel/Config.in +0 -1
index 98f4941..d823272 100644
@@ -1,7 +1,6 @@
 config BR2_PACKAGE_AXEL
 	bool "axel"
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	depends on BR2_TOOLCHAIN_HAS_THREADS
 	help
 	  HTTP/FTP download accelerator.
package/axel/axel.mk +1 -1
index 893caf1..0ed8ad2 100644
@@ -10,7 +10,7 @@ AXEL_SITE = https://alioth.debian.org/frs/download.php/3015
 AXEL_LDFLAGS = -lpthread
 
 ifeq ($(BR2_NEEDS_GETTEXT_IF_LOCALE),y)
-AXEL_DEPENDENCIES += gettext libintl
+AXEL_DEPENDENCIES += gettext
 AXEL_LDFLAGS += -lintl
 endif
 
package/binutils/Config.in +0 -1
index e068b20..6480370 100644
@@ -1,7 +1,6 @@
 config BR2_PACKAGE_BINUTILS
 	bool "binutils"
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	help
 	  Install binutils on the target
 
package/binutils/binutils.mk +1 -1
index a91879a..d41cac4 100644
@@ -23,7 +23,7 @@ BINUTILS_SITE = ftp://www.at91.com/pub/buildroot
 endif
 BINUTILS_EXTRA_CONFIG_OPTIONS = $(call qstrip,$(BR2_BINUTILS_EXTRA_CONFIG_OPTIONS))
 BINUTILS_INSTALL_STAGING = YES
-BINUTILS_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl)
+BINUTILS_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext)
 
 # We need to specify host & target to avoid breaking ARM EABI
 BINUTILS_CONF_OPT = --disable-multilib --disable-werror \
package/diffutils/diffutils.mk +1 -2
index d6029a4..168d040 100644
@@ -7,8 +7,7 @@
 DIFFUTILS_VERSION = 3.2
 DIFFUTILS_SITE = $(BR2_GNU_MIRROR)/diffutils
 DIFFUTILS_DEPENDENCIES = \
-	$(if $(BR2_PACKAGE_GETTEXT),gettext) \
-	$(if $(BR2_PACKAGE_LIBINTL),libintl)
+	$(if $(BR2_PACKAGE_GETTEXT),gettext)
 
 ifeq ($(BR2_PACKAGE_BUSYBOX),y)
 DIFFUTILS_DEPENDENCIES += busybox
package/dnsmasq/Config.in +0 -1
index e67aa46..b76ddb2 100644
@@ -25,7 +25,6 @@ config BR2_PACKAGE_DNSMASQ_IDN
 	depends on BR2_USE_WCHAR
 	select BR2_PACKAGE_LIBIDN
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	help
 	  Enable IDN support in dnsmasq.
 	  This option is a big space taker since it pulls in many libraries.
package/dnsmasq/dnsmasq.mk +1 -1
index 1f714bf..e92a554 100644
@@ -24,7 +24,7 @@ endif
 
 # NLS requires IDN so only enable it (i18n) when IDN is true
 ifeq ($(BR2_PACKAGE_DNSMASQ_IDN),y)
-	DNSMASQ_DEPENDENCIES += libidn $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl)
+	DNSMASQ_DEPENDENCIES += libidn $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext)
 	DNSMASQ_MAKE_OPT += LDFLAGS+="-lidn $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),-lintl)"
 	DNSMASQ_COPTS += -DHAVE_IDN
 	DNSMASQ_I18N = $(if $(BR2_ENABLE_LOCALE),-i18n)
package/flex/flex.mk +1 -2
index 16f6801..2599cdc 100644
@@ -12,8 +12,7 @@ FLEX_SITE = $(BR2_DEBIAN_MIRROR)/debian/pool/main/f/flex
 FLEX_DIR = $(BUILD_DIR)/flex-$(FLEX_VERSION)
 FLEX_INSTALL_STAGING = YES
 FLEX_DEPENDENCIES = \
-	$(if $(BR2_PACKAGE_GETTEXT),gettext) \
-	$(if $(BR2_PACKAGE_LIBINTL),libintl)
+	$(if $(BR2_PACKAGE_GETTEXT),gettext)
 # we don't have a host-gettext/libintl
 HOST_FLEX_DEPENDENCIES =
 
package/gdk-pixbuf/Config.in +0 -1
index 28a0f12..33b5f7c 100644
@@ -3,7 +3,6 @@ config BR2_PACKAGE_GDK_PIXBUF
 	depends on BR2_USE_WCHAR # glib2
 	select BR2_PACKAGE_LIBGLIB2
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT
 	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
 	help
 	  Gdk-Pixbuf is an image loader and scaler. It uses GObject
package/gdk-pixbuf/gdk-pixbuf.mk +1 -1
index 751f499..f92101f 100644
@@ -35,7 +35,7 @@ GDK_PIXBUF_DEPENDENCIES += tiff
 endif
 
 GDK_PIXBUF_DEPENDENCIES += \
-	$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl) \
+	$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext) \
 	$(if $(BR2_ENABLE_LOCALE),,libiconv) \
 	host-pkg-config libglib2
 
package/glib-networking/Config.in +0 -1
index 16f0d4a..dab35ea 100644
@@ -3,7 +3,6 @@ config BR2_PACKAGE_GLIB_NETWORKING
 	depends on BR2_USE_WCHAR # glib2
 	select BR2_PACKAGE_LIBGLIB2
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT
 	help
 	  Network-related GIO modules for glib.
 
package/glib-networking/glib-networking.mk +1 -1
index 385ad47..823ba39 100644
@@ -13,7 +13,7 @@ GLIB_NETWORKING_SOURCE = glib-networking-$(GLIB_NETWORKING_VERSION).tar.xz
 GLIB_NETWORKING_INSTALL_STAGING = YES
 
 GLIB_NETWORKING_DEPENDENCIES = \
-	$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl) \
+	$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext) \
 	host-pkg-config \
 	host-intltool \
 	libglib2
package/gmpc/Config.in +0 -1
index f86945c..9b38d1a 100644
@@ -5,7 +5,6 @@ config BR2_PACKAGE_GMPC
 	depends on BR2_PACKAGE_XORG7
 	select BR2_PACKAGE_LIBGLIB2
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
 	select BR2_PACKAGE_LIBMPD
 	select BR2_PACKAGE_LIBSOUP
package/gmpc/gmpc.mk +1 -1
index 51d0cd9..a136cf4 100644
@@ -11,6 +11,6 @@ GMPC_CONF_OPT = --disable-mmkeys --disable-unique
 GMPC_DEPENDENCIES = host-gob2 host-intltool host-pkg-config host-vala \
 	libglib2 libgtk2 libmpd libsoup sqlite \
 	xlib_libICE xlib_libSM xlib_libX11 \
-	$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl)
+	$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext)
 
 $(eval $(autotools-package))
package/grep/Config.in +0 -1
index 1b39922..5906e69 100644
@@ -2,7 +2,6 @@ config BR2_PACKAGE_GREP
 	bool "grep"
 	depends on BR2_USE_WCHAR
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	help
 	  The GNU regular expression matcher.
 
package/grep/grep.mk +1 -1
index 4ed5fea..0ce747b 100644
@@ -8,7 +8,7 @@ GREP_VERSION = 2.13
 GREP_SITE = $(BR2_GNU_MIRROR)/grep
 GREP_SOURCE = grep-$(GREP_VERSION).tar.xz
 GREP_CONF_OPT = --disable-perl-regexp --without-included-regex
-GREP_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl)
+GREP_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext)
 
 # link with iconv if enabled
 ifeq ($(BR2_PACKAGE_LIBICONV),y)
package/kbd/Config.in +0 -1
index a23b70a..44c3163 100644
@@ -1,7 +1,6 @@
 config BR2_PACKAGE_KBD
 	bool "kbd"
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	# Uses fork()
 	depends on BR2_USE_MMU
 	help
package/kbd/kbd.mk +1 -1
index a52ad5a..325978e 100644
@@ -2,6 +2,6 @@ KBD_VERSION = 1.15.2
 KBD_SOURCE = kbd-$(KBD_VERSION).tar.gz
 KBD_SITE = $(BR2_KERNEL_MIRROR)/linux/utils/kbd
 
-KBD_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl)
+KBD_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext)
 
 $(eval $(autotools-package))
package/libglib2/Config.in +0 -1
index d1d7231..5282885 100644
@@ -1,7 +1,6 @@
 config BR2_PACKAGE_LIBGLIB2
 	bool "libglib2"
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT
 	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
 	select BR2_PACKAGE_LIBFFI
 	select BR2_PACKAGE_ZLIB
package/libglib2/libglib2.mk +1 -1
index 2b2bd32..030cecb 100644
@@ -55,7 +55,7 @@ HOST_LIBGLIB2_CONF_OPT = \
 		--disable-gtk-doc \
 		--enable-debug=no \
 
-LIBGLIB2_DEPENDENCIES = host-pkg-config host-libglib2 libffi zlib $(if $(BR2_NEEDS_GETTEXT),gettext libintl)
+LIBGLIB2_DEPENDENCIES = host-pkg-config host-libglib2 libffi zlib $(if $(BR2_NEEDS_GETTEXT),gettext)
 
 HOST_LIBGLIB2_DEPENDENCIES = host-pkg-config host-libffi host-zlib
 
package/libsoup/Config.in +0 -1
index eee6ade..c3b4ceb 100644
@@ -4,7 +4,6 @@ config BR2_PACKAGE_LIBSOUP
 	select BR2_PACKAGE_LIBXML2
 	select BR2_PACKAGE_LIBGLIB2
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT
 	help
 	  libsoup is an HTTP client/server library. It uses GObject
 	  and the GLib main loop, to integrate well with GNOME
package/libsoup/libsoup.mk +1 -1
index fe1a41c..30655ba 100644
@@ -19,7 +19,7 @@ endif
 
 LIBSOUP_CONF_OPT = --disable-glibtest --without-gnome
 
-LIBSOUP_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl) host-pkg-config host-libglib2 libglib2 libxml2
+LIBSOUP_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext) host-pkg-config host-libglib2 libglib2 libxml2
 
 ifeq ($(BR2_PACKAGE_LIBSOUP_SSL),y)
 LIBSOUP_DEPENDENCIES += glib-networking
package/lshw/lshw.mk +1 -1
index a53c107..68daa0d 100644
@@ -9,7 +9,7 @@ LSHW_SITE = http://ezix.org/software/files
 LSHW_MAKE_OPT = CC="$(TARGET_CC)" CXX="$(TARGET_CXX)" AR="$(TARGET_AR)" \
 	RPM_OPT_FLAGS="$(TARGET_CFLAGS)" all
 LSHW_MAKE_ENV = LIBS="$(if $(BR2_NEEDS_GETTEXT),-lintl)"
-LSHW_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT),libintl)
+LSHW_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT),gettext)
 
 define LSHW_BUILD_CMDS
 	$(LSHW_MAKE_ENV) $(MAKE) -C $(@D)/src $(LSHW_MAKE_OPT)
package/make/Config.in +0 -1
index 364bb1e..ea2ae1b 100644
@@ -1,7 +1,6 @@
 config BR2_PACKAGE_MAKE
 	bool "make"
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	help
 	  A tool which controls the generation of executables and other
 	  non-source files of a program from the program's source files.
package/make/make.mk +1 -1
index a0981c7..02b2741 100644
@@ -7,7 +7,7 @@ MAKE_VERSION:=3.81
 MAKE_SOURCE:=make-$(MAKE_VERSION).tar.bz2
 MAKE_SITE:=$(BR2_GNU_MIRROR)/make
 
-MAKE_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl)
+MAKE_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext)
 
 MAKE_CONF_ENV = make_cv_sys_gnu_glob=no \
 		GLOBINC='-I$(@D)/glob' \
package/midori/Config.in +0 -1
index 49867e4..41f4515 100644
@@ -3,7 +3,6 @@ config BR2_PACKAGE_MIDORI
 	select BR2_PACKAGE_WEBKIT
 	select BR2_PACKAGE_LIBSEXY
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
 	depends on BR2_PACKAGE_LIBGTK2
 	depends on BR2_INSTALL_LIBSTDCPP # webkit
package/midori/midori.mk +1 -1
index 87559bb..33f94cf 100644
@@ -14,7 +14,7 @@ MIDORI_DEPENDENCIES = \
 	libgtk2 \
 	libsexy \
 	webkit \
-	$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl) \
+	$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext) \
 	$(if $(BR2_PACKAGE_LIBICONV),libiconv)
 
 ifneq ($(BR2_PACKAGE_XORG7),y)
package/multimedia/pulseaudio/Config.in +1 -1
index 6e6d64c..6c767bb 100644
@@ -5,7 +5,7 @@ config BR2_PACKAGE_PULSEAUDIO
 	select BR2_PACKAGE_JSON_C
 	select BR2_PACKAGE_LIBSNDFILE
 	select BR2_PACKAGE_SPEEX
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT
+	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT
 	help
 	  PulseAudio is a sound system for POSIX OSes, meaning that it
 	  is a proxy for your sound applications. It allows you to do
package/multimedia/pulseaudio/pulseaudio.mk +1 -1
index 13d8770..6f7d7d2 100644
@@ -16,7 +16,7 @@ PULSEAUDIO_CONF_OPT = \
 
 PULSEAUDIO_DEPENDENCIES = \
 	host-pkg-config libtool json-c libsndfile speex host-intltool \
-	$(if $(BR2_PACKAGE_LIBINTL),libintl) \
+	$(if $(BR2_PACKAGE_GETTEXT),gettext) \
 	$(if $(BR2_PACKAGE_LIBATOMIC_OPS),libatomic_ops) \
 	$(if $(BR2_PACKAGE_LIBSAMPLERATE),libsamplerate) \
 	$(if $(BR2_PACKAGE_ALSA_LIB),alsa-lib) \
package/ndisc6/ndisc6.mk +2 -2
index eb30e11..f58cc13 100644
@@ -10,8 +10,8 @@ NDISC6_SITE = http://www.remlab.net/files/ndisc6/
 NDISC6_CONF_ENV = CC="$(TARGET_CC) -std=gnu99"
 NDISC6_CONF_OPT = --localstatedir=/var --disable-rpath --disable-suid-install
 
-ifeq ($(BR2_PACKAGE_LIBINTL),y)
-NDISC6_DEPENDENCIES += libintl
+ifeq ($(BR2_PACKAGE_GETTEXT),y)
+NDISC6_DEPENDENCIES += gettext
 NDISC6_CONF_ENV += LDFLAGS="$(TARGET_LDFLAGS) -lintl"
 endif
 
package/pango/Config.in +0 -1
index 923c3d4..60e9931 100644
@@ -6,7 +6,6 @@ config BR2_PACKAGE_PANGO
 	select BR2_PACKAGE_EXPAT
 	select BR2_PACKAGE_CAIRO
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	help
 	  Pango is a library for laying out and rendering of text, with an
 	  emphasis on internationalization. Pango can be used anywhere that
package/pango/pango.mk +1 -1
index efb722d..86ab474 100644
@@ -41,7 +41,7 @@ PANGO_CONF_ENV = ac_cv_func_posix_getpwuid_r=yes glib_cv_stack_grows=no \
 
 PANGO_CONF_OPT = --enable-explicit-deps=no --disable-debug
 
-PANGO_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl) host-pkg-config libglib2 cairo
+PANGO_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext) host-pkg-config libglib2 cairo
 
 ifeq ($(BR2_PACKAGE_XORG7),y)
         PANGO_CONF_OPT += --with-x \
package/psmisc/Config.in +0 -1
index a138204..cc8420b 100644
@@ -2,7 +2,6 @@ config BR2_PACKAGE_PSMISC
 	bool "psmisc"
 	select BR2_PACKAGE_NCURSES
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	help
 	  Helpful /proc related utilities such as pstree, fuser, and killall
 
package/psmisc/psmisc.mk +1 -1
index a70f071..e162716 100644
@@ -6,7 +6,7 @@
 
 PSMISC_VERSION = 22.16
 PSMISC_SITE = http://$(BR2_SOURCEFORGE_MIRROR).dl.sourceforge.net/project/psmisc/psmisc
-PSMISC_DEPENDENCIES = ncurses $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl)
+PSMISC_DEPENDENCIES = ncurses $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext)
 
 ifneq ($(BR2_TOOLCHAIN_BUILDROOT_USE_SSP),y)
 # Don't force -fstack-protector
package/quota/Config.in +0 -1
index 6c2beff..3ad0b8c 100644
@@ -6,7 +6,6 @@ config BR2_PACKAGE_QUOTA
 	select BR2_PACKAGE_UTIL_LINUX
 	select BR2_PACKAGE_UTIL_LINUX_MOUNT
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	help
 	  Implementation of the disk quota system.
 
package/quota/quota.mk +1 -1
index 44a5073..bd7c6aa 100644
@@ -11,7 +11,7 @@ QUOTA_SITE = http://$(BR2_SOURCEFORGE_MIRROR).dl.sourceforge.net/project/linuxqu
 QUOTA_MAKE_OPT = $(TARGET_CONFIGURE_OPTS) CFLAGS="$(TARGET_CFLAGS) -D_GNU_SOURCE"
 
 ifeq ($(BR2_NEEDS_GETTEXT_IF_LOCALE),y)
-QUOTA_DEPENDENCIES = gettext libintl
+QUOTA_DEPENDENCIES = gettext
 QUOTA_MAKE_OPT += LDFLAGS="$(TARGET_LDFLAGS) -lintl"
 endif
 
package/sshfs/Config.in +0 -1
index 73d552f..37188ba 100644
@@ -3,7 +3,6 @@ config BR2_PACKAGE_SSHFS
 	select BR2_PACKAGE_LIBFUSE
 	select BR2_PACKAGE_LIBGLIB2
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
 	select BR2_PACKAGE_OPENSSH
 	depends on BR2_LARGEFILE
package/sshfs/sshfs.mk +1 -1
index 80d3a45..f04db8e 100644
@@ -9,7 +9,7 @@ SSHFS_SITE = http://$(BR2_SOURCEFORGE_MIRROR).dl.sourceforge.net/project/fuse/ss
 SSHFS_SOURCE = sshfs-fuse-$(SSHFS_VERSION).tar.gz
 SSHFS_DEPENDENCIES = \
 	libglib2 libfuse openssh \
-	$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl) \
+	$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext) \
 	$(if $(BR2_ENABLE_LOCALE),,libiconv)
 
 $(eval $(autotools-package))
package/sysstat/Config.in +0 -1
index 6e62ff1..ceba503 100644
@@ -1,7 +1,6 @@
 config BR2_PACKAGE_SYSSTAT
 	bool "sysstat"
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	# Uses fork()
 	depends on BR2_USE_MMU
 	help
package/sysstat/sysstat.mk +1 -1
index 9d91a42..83609a0 100644
@@ -14,7 +14,7 @@ SYSSTAT_CONF_OPT += --disable-documentation
 endif
 
 ifeq ($(BR2_NEEDS_GETTEXT_IF_LOCALE),y)
-SYSSTAT_DEPENDENCIES += gettext libintl
+SYSSTAT_DEPENDENCIES += gettext
 SYSSTAT_MAKE_OPT += CFLAGS+=-lintl
 endif
 
package/ushare/Config.in +0 -1
index acf025f..f7b2124 100644
@@ -3,7 +3,6 @@ config BR2_PACKAGE_USHARE
 	depends on BR2_LARGEFILE
 	select BR2_PACKAGE_LIBUPNP
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	help
 	  uShare is a UPnP (TM) A/V & DLNA Media Server.
 	  It implements the server component that provides UPnP media devices
package/ushare/ushare.mk +1 -1
index 2d8bca5..78cbcda 100644
@@ -10,7 +10,7 @@ USHARE_SITE = http://ushare.geexbox.org/releases
 USHARE_DEPENDENCIES = host-pkg-config libupnp
 
 ifeq ($(BR2_NEEDS_GETTEXT_IF_LOCALE),y)
-USHARE_DEPENDENCIES += gettext libintl
+USHARE_DEPENDENCIES += gettext
 USHARE_LDFLAGS += -lintl
 endif
 
package/util-linux/util-linux.mk +2 -2
index ddc9c12..71a6c53 100644
@@ -29,8 +29,8 @@ else
 UTIL_LINUX_CONF_OPT += --without-ncurses
 endif
 
-ifeq ($(BR2_PACKAGE_LIBINTL),y)
-UTIL_LINUX_DEPENDENCIES += libintl
+ifeq ($(BR2_PACKAGE_GETTEXT),y)
+UTIL_LINUX_DEPENDENCIES += gettext
 UTIL_LINUX_MAKE_OPT += LIBS=-lintl
 endif
 
package/vala/Config.in +0 -1
index 89b4459..e0d665c 100644
@@ -3,7 +3,6 @@ config BR2_PACKAGE_VALA
 	depends on BR2_USE_WCHAR # glib2
 	select BR2_PACKAGE_LIBGLIB2
 	select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
-	select BR2_PACKAGE_LIBINTL if BR2_NEEDS_GETTEXT_IF_LOCALE
 	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
 	help
 	  Compiler for the GObject type system.
package/vala/vala.mk +1 -1
index 7c0ea9f..4cb89dc 100644
@@ -10,7 +10,7 @@ VALA_VERSION = $(VALA_VERSION_MAJOR).$(VALA_VERSION_MINOR)
 VALA_SITE = http://download.gnome.org/sources/vala/$(VALA_VERSION_MAJOR)
 VALA_SOURCE = vala-$(VALA_VERSION).tar.xz
 VALA_DEPENDENCIES = host-flex libglib2 \
-		$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext libintl)
+		$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext)
 HOST_VALA_DEPENDENCIES = host-flex host-libglib2
 
 $(eval $(autotools-package))
Signature · 1 line
1.7.9.5
#6 lore raw

PATCH 5/5 gettext: convert to autotools-package

In reply to Thomas Petazzoni

From: Maxime Ripard <[email protected]>

---
 package/gettext/Config.in  |   10 ++-
 package/gettext/gettext.mk |  163 ++++++--------------------------------------
 2 files changed, 30 insertions(+), 143 deletions(-)
package/gettext/Config.in +9 -1
index de19410..ee7d8cb 100644
@@ -7,11 +7,19 @@ config BR2_PACKAGE_GETTEXT
 	  framework to help other GNU packages produce multi-lingual
 	  messages.
 
-	  Only the gettext libraries will be installed in the
+	  Only the libintl library will be installed in the
 	  target. The full gettext suite, including tools, will be
 	  installed in the staging directory.
 
 	  http://www.gnu.org/software/gettext/
 
+config BR2_PACKAGE_GETTEXT_TOOLS
+	bool "Install gettext tools"
+	depends on BR2_PACKAGE_GETTEXT
+	help
+	  This option allows to install the complete gettext suite in
+	  the target filesystem. This is typically not useful for
+	  correct operation of programs.
+
 comment "gettext requires a toolchain with WCHAR support"
 	depends on BR2_NEEDS_GETTEXT && !BR2_USE_WCHAR
package/gettext/gettext.mk +21 -142

168 lines not on this page · raw message

Signature · 1 line
1.7.9.5
#7 lore raw

PATCH 5/5 gettext: convert to autotools-package

Hi Thomas, Maxime,

2012/7/19 Thomas Petazzoni <[email protected]>:
[...]

Quoted 8 lines
package/gettext/gettext.mk +0 -0
index 4dff941..35c0bd2 100644
@@ -3,147 +3,26 @@
 # gettext
 #
 #############################################################

[...]

Quoted 12 lines
package/gettext/gettext.mk +11 -0
+GETTEXT_VERSION = 0.16.1
+GETTEXT_SITE = $(BR2_GNU_MIRROR)/gettext
+GETTEXT_INSTALL_STAGING = YES
+
+GETTEXT_CONF_OPT += \
+       --disable-libasprintf \
+       --disable-openmp \
+       --disable-rpath \
+       --disable-java \
+       --disable-native-java \
+       --disable-csharp \

package/gettext/gettext.mk line 26

Quoted 10 lines
package/gettext/gettext.mk +9 -0
+       --disable-relocatable \
+       --without-emacs
+
+# When the gettext tools are not enabled in the configuration, we only
+# install libintl to the target.
+ifeq ($(BR2_PACKAGE_GETTEXT_TOOLS),)
+define GETTEXT_INSTALL_TARGET_CMDS
+       cp -dpf $(STAGING_DIR)/usr/lib/libintl*.so* $(TARGET_DIR)/usr/lib/
+endef
 endif

I would do:

ifeq ($(BR2_PACKAGE_GETTEXT_TOOLS),)
ifeq ($(BR2_ENABLE_LOCALE)\
$(BR2_TOOLCHAIN_BUILDROOT)$(BR2_TOOLCHAIN_CTNG_uClibc)\
$(BR2_TOOLCHAIN_EXTERNAL_UCLIBC)$(BR2_TOOLCHAIN_EXTERNAL_CUSTOM_UCLIBC),yy) # When the gettext tools are not enabled in the configuration, we only

# install libintl to the target if nls support is enabled and the libc
# does not provide it.
define GETTEXT_INSTALL_TARGET_CMDS
	cp -dpf $(STAGING_DIR)/usr/lib/libintl*.so* $(TARGET_DIR)/usr/lib/
endef
else
# Otherwise, when nls support is disabled or the libc provide libintl,
# just do nothing.
define GETTEXT_INSTALL_TARGET_CMDS
	:
endef
endif
endif

This way, the install-target command won't fail trying to install libintl if nls is disabled (see log hereafter), and libintl won't be installed if the libc already provide
i18n/l10n support.

--- snip ---
cp -dpf /home/samuel/data/workspace/src/buildroot/gettext-without-nls/output/host/usr/arm-unknown-linux-uclibcgnueabi/sysroot/usr/lib/libintl*.so* /home/samuel/data/workspace/src/buildroot/gettext-without-nls/output/target/usr/lib/
cp: cannot stat ?/home/samuel/data/workspace/src/buildroot/gettext-without-nls/output/host/usr/arm-unknown-linux-uclibcgnueabi/sysroot/usr/lib/libintl*.so*?:
No such file or directory
make: *** [/home/samuel/data/workspace/src/buildroot/gettext-without-nls/output/build/gettext-0.16.1/.stamp_target_installed] Error 1

Quoted 3 lines

+$(eval $(autotools-package))
--
1.7.9.5

Otherwise, the whole serie looks good to me!
So, for the whole serie + this change:

Signature · 1 line
Sam
#8 lore raw

PATCH 5/5 gettext: convert to autotools-package

Hi,

2012/7/22 Samuel Martin <[email protected]>:
[...]

Quoted 5 lines

ifeq ($(BR2_PACKAGE_GETTEXT_TOOLS),)

ifeq ($(BR2_ENABLE_LOCALE)\
$(BR2_TOOLCHAIN_BUILDROOT)$(BR2_TOOLCHAIN_CTNG_uClibc)\
$(BR2_TOOLCHAIN_EXTERNAL_UCLIBC)$(BR2_TOOLCHAIN_EXTERNAL_CUSTOM_UCLIBC),yy)

Just realize that this statement can be simplify like that:
ifeq ($(BR2_ENABLE_LOCALE)$(BR2_NEEDS_GETTEXT),yy)

In this case, maybe BR2_TOOLCHAIN_EXTERNAL_CUSTOM_UCLIBC should trigger BR2_NEEDS_GETTEXT too?

toolchain/toolchain-common.in +1 -0
index cc7b4de..4f1c8fb 100644
@@ -86,6 +86,7 @@ config BR2_NEEDS_GETTEXT
 	bool
 	default y if BR2_TOOLCHAIN_BUILDROOT
 	default y if BR2_TOOLCHAIN_EXTERNAL_UCLIBC
+	default y if BR2_TOOLCHAIN_EXTERNAL_CUSTOM_UCLIBC
 	default y if BR2_TOOLCHAIN_CTNG_uClibc
 
 config BR2_NEEDS_GETTEXT_IF_LOCALE

Tell me if you need I post a proper patch.

Cheers,

Signature · 1 line
Sam
#9 lore raw

PATCH 5/5 gettext: convert to autotools-package

Le Mon, 23 Jul 2012 05:44:28 +0200,
Samuel Martin <[email protected]> a ?crit :

Quoted 5 lines
Quoted 3 lines

ifeq ($(BR2_ENABLE_LOCALE)\
$(BR2_TOOLCHAIN_BUILDROOT)$(BR2_TOOLCHAIN_CTNG_uClibc)\
$(BR2_TOOLCHAIN_EXTERNAL_UCLIBC)$(BR2_TOOLCHAIN_EXTERNAL_CUSTOM_UCLIBC),yy)

Just realize that this statement can be simplify like that:
ifeq ($(BR2_ENABLE_LOCALE)$(BR2_NEEDS_GETTEXT),yy)

Yes, I will think about this in more details.

Quoted 2 lines

In this case, maybe BR2_TOOLCHAIN_EXTERNAL_CUSTOM_UCLIBC should trigger BR2_NEEDS_GETTEXT too?

No, because BR2_TOOLCHAIN_EXTERNAL_CUSTOM_UCLIBC already selects BR2_TOOLCHAIN_EXTERNAL_UCLIBC. Basically BR2_TOOLCHAIN_EXTERNAL_UCLIBC is an hidden bool which is selected either by the external toolchain profiles (when they are uClibc based) and by the BR2_TOOLCHAIN_EXTERNAL_CUSTOM_UCLIBC choice.

Best regards,

Thomas

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
#10 lore raw
In reply to Thomas Petazzoni

Thomas, All,

Quoted 4 lines · On Thursday 19 July 2012 23:20:59 Thomas Petazzoni wrote:

Here is a set of patches that builds on top of the work from Maxime Ripard and Samuel Martin to clean up how gettext is handled, and in the end migrate the gettext package to the autotools-package infrastructure.

I am currently looking at this patchset. Globally, I'm OK with most of it, except for some minor picks.

I am also almost finished doing the GETTEXT select rework I wrote about yesterday, and will push an updated patchset with your patches, and mine on-top of them.

Regards,
Yann E. MORIN.

Signature · 6 lines
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'