Skip to contentSkip to conversation

gettext: make host gettextize non-interactive

PATCH New Gustavo Zacarias 3 participants 4 messages Apr 3, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 gettext: make host gettextize non-interactive

Make the host gettextize tool non-interactive to avoid stalling for user confirmation when using it to fix up a package.

---
 package/gettext/gettext.mk | 6 ++++++
 1 file changed, 6 insertions(+)
package/gettext/gettext.mk +6 -0
index 748c2a5..b5efa76 100644
@@ -57,5 +57,11 @@ endef
 endif
 endif # GETTEXT_TOOLS = n
 
+# Disable interactive confirmation in host gettextize for package fixups
+define HOST_GETTEXT_GETTEXTIZE_CONFIRMATION
+	$(SED) '/read dummy/d' $(HOST_DIR)/usr/bin/gettextize
+endef
+HOST_GETTEXT_POST_INSTALL_HOOKS += HOST_GETTEXT_GETTEXTIZE_CONFIRMATION
+
 $(eval $(autotools-package))
 $(eval $(host-autotools-package))
Signature · 1 line
1.8.3.2
#1 lore raw

PATCH 2/2 wget: fix autoreconf brokeness

Fix failed AUTORECONF under certain circumstances where gettext infra is much newer (>= 0.18) than what wget source expects (~ 0.17). Do this by gettextizing the source before AUTORECONFing.
If this becomes common we may need a FOO_GETTEXTIZE generic option, but for now this seems to be the only package that needs so. Fixes:
http://autobuild.buildroot.net/results/c0f/c0f7c801f61fdc310cde64342060b00a70155431/

---
 package/wget/wget.mk | 8 ++++++++
 1 file changed, 8 insertions(+)
package/wget/wget.mk +8 -0
index 80f8314..f3a5274 100644
@@ -13,6 +13,14 @@ WGET_LICENSE_FILES = COPYING
 # patching gnulib .m4 file
 WGET_AUTORECONF = YES
 
+# Ugly kludge to fix autoreconf with old gettext infra
+# We need to gettextize before autoreconf to upgrade
+WGET_DEPENDENCIES += host-gettext
+define WGET_GETTEXTIZE
+	cd $(@D) ; $(HOST_DIR)/usr/bin/gettextize -f
+endef
+WGET_POST_PATCH_HOOKS += WGET_GETTEXTIZE
+
 # Prefer full-blown wget over busybox
 ifeq ($(BR2_PACKAGE_BUSYBOX),y)
 	WGET_DEPENDENCIES += busybox
Signature · 1 line
1.8.3.2
#2 lore raw

PATCH 2/2 wget: fix autoreconf brokeness

Hi Gustavo,

Quoted 8 lines · Gustavo Zacarias

Fix failed AUTORECONF under certain circumstances where gettext infra is much newer (>= 0.18) than what wget source expects (~ 0.17). Do this by gettextizing the source before AUTORECONFing.
If this becomes common we may need a FOO_GETTEXTIZE generic option, but for now this seems to be the only package that needs so. Fixes:
http://autobuild.buildroot.net/results/c0f/c0f7c801f61fdc310cde64342060b00a70155431/

Thanks,
baruch

Quoted 23 lines
---
 package/wget/wget.mk | 8 ++++++++
 1 file changed, 8 insertions(+)
package/wget/wget.mk +8 -0
index 80f8314..f3a5274 100644
@@ -13,6 +13,14 @@ WGET_LICENSE_FILES = COPYING
 # patching gnulib .m4 file
 WGET_AUTORECONF = YES
 
+# Ugly kludge to fix autoreconf with old gettext infra
+# We need to gettextize before autoreconf to upgrade
+WGET_DEPENDENCIES += host-gettext
+define WGET_GETTEXTIZE
+	cd $(@D) ; $(HOST_DIR)/usr/bin/gettextize -f
+endef
+WGET_POST_PATCH_HOOKS += WGET_GETTEXTIZE
+
 # Prefer full-blown wget over busybox
 ifeq ($(BR2_PACKAGE_BUSYBOX),y)
 	WGET_DEPENDENCIES += busybox
Signature · 3 lines
     http://baruch.siach.name/blog/                  ~. .~   Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
   - baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -
#3 lore raw

PATCH 1/2 gettext: make host gettextize non-interactive

In reply to Gustavo Zacarias

Dear Gustavo Zacarias,

Quoted 7 lines · Gustavo Zacarias

Make the host gettextize tool non-interactive to avoid stalling for user confirmation when using it to fix up a package.

---
 package/gettext/gettext.mk | 6 ++++++
 1 file changed, 6 insertions(+)

Both applied, thanks.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com