package/cups-filters: fix build without NLS
PATCH 1/1 package/cups-filters: fix build without NLS
From: Carlos Santos <[email protected]>
texttotext must be linked to libiconv if !BR2_ENABLE_LOCALE so patch Makefile.am to add the required -liconv argument.
We could patch configure.ac to use AM_ICONV but it would require more change adding AM_GNU_GETTEXT_VERSION([x.y.z]) to bring iconv.m4.
--- package/cups-filters/cups-filters.mk | 11 +++++++++++ 1 file changed, 11 insertions(+)
package/cups-filters/cups-filters.mk +11 -0
@@ -13,6 +13,17 @@ CUPS_FILTERS_AUTORECONF = YES CUPS_FILTERS_DEPENDENCIES = cups libglib2 lcms2 qpdf fontconfig freetype jpeg +# texttotext must be linked to libiconv if !BR2_ENABLE_LOCALE. We could patch +# configure.ac to use AM_ICONV but it would require iconv.m4, increasing the +# patch size by at least 130 lines. Let's keep it simple and just patch +# Makefile.am to append -liconv to the link command line. +ifeq ($(BR2_PACKAGE_LIBICONV),y) +define CUPS_FILTERS_LINK_LIBICONV + $(SED) '/texttotext_LDADD =/s/(CUPS_LIBS)$$/(CUPS_LIBS) -liconv/' $(@D)/Makefile.am +endef +CUPS_FILTERS_PRE_CONFIGURE_HOOKS += CUPS_FILTERS_LINK_LIBICONV +endif + CUPS_FILTERS_CONF_OPTS = --disable-imagefilters \ --disable-mutool \ --disable-foomatic \
Signature · 1 line
2.18.1
PATCH 1/1 package/cups-filters: fix build without NLS
Hi Carlos,
Quoted 41 lines · On Mon, Jul 22, 2019 at 10:12 AM <[email protected]> wrote:
From: Carlos Santos <[email protected]>
texttotext must be linked to libiconv if !BR2_ENABLE_LOCALE so patch Makefile.am to add the required -liconv argument.
We could patch configure.ac to use
AM_ICONVbut it would require more change addingAM_GNU_GETTEXT_VERSION([x.y.z])to bring iconv.m4.Signed-off-by Carlos Santos <[email protected]>--- package/cups-filters/cups-filters.mk | 11 +++++++++++ 1 file changed, 11 insertions(+)package/cups-filters/cups-filters.mk +11
-1@@ -13,6 +13,17 @@ CUPS_FILTERS_AUTORECONF = YES CUPS_FILTERS_DEPENDENCIES = cups libglib2 lcms2 qpdf fontconfig freetype jpeg +# texttotext must be linked to libiconv if !BR2_ENABLE_LOCALE. We could patch +# configure.ac to use AM_ICONV but it would require iconv.m4, increasing the +# patch size by at least 130 lines. Let's keep it simple and just patch +# Makefile.am to append -liconv to the link command line. +ifeq ($(BR2_PACKAGE_LIBICONV),y) +define CUPS_FILTERS_LINK_LIBICONV + $(SED) '/texttotext_LDADD =/s/(CUPS_LIBS)$$/(CUPS_LIBS) -liconv/' $(@D)/Makefile.am +endef +CUPS_FILTERS_PRE_CONFIGURE_HOOKS += CUPS_FILTERS_LINK_LIBICONV +endif + CUPS_FILTERS_CONF_OPTS = --disable-imagefilters \ --disable-mutool \ --disable-foomatic \ --2.18.1
Quoted 4 lines
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
I already sent patch to fix this problem (but I did not check the LOCALE config so looks like your version is better):
https://patchwork.ozlabs.org/patch/1134318
but in case of your version is it not enough to just add:
CUPS_FILTERS_CONF_ENV += LIBS=-liconv
?
Regards,
Vadim Kochan
PATCH 1/1 package/cups-filters: fix build without NLS
Quoted 53 lines · Vadim Kochan
Hi Carlos,
Quoted 41 lines · On Mon, Jul 22, 2019 at 10:12 AM <[email protected]> wrote:
From: Carlos Santos <[email protected]>
texttotext must be linked to libiconv if !BR2_ENABLE_LOCALE so patch Makefile.am to add the required -liconv argument.
We could patch configure.ac to use
AM_ICONVbut it would require more change addingAM_GNU_GETTEXT_VERSION([x.y.z])to bring iconv.m4.Signed-off-by Carlos Santos <[email protected]>--- package/cups-filters/cups-filters.mk | 11 +++++++++++ 1 file changed, 11 insertions(+)package/cups-filters/cups-filters.mk +11
-1@@ -13,6 +13,17 @@ CUPS_FILTERS_AUTORECONF = YES CUPS_FILTERS_DEPENDENCIES = cups libglib2 lcms2 qpdf fontconfig freetype jpeg +# texttotext must be linked to libiconv if !BR2_ENABLE_LOCALE. We could patch +# configure.ac to use AM_ICONV but it would require iconv.m4, increasing the +# patch size by at least 130 lines. Let's keep it simple and just patch +# Makefile.am to append -liconv to the link command line. +ifeq ($(BR2_PACKAGE_LIBICONV),y) +define CUPS_FILTERS_LINK_LIBICONV + $(SED) '/texttotext_LDADD =/s/(CUPS_LIBS)$$/(CUPS_LIBS) -liconv/' $(@D)/Makefile.am +endef +CUPS_FILTERS_PRE_CONFIGURE_HOOKS += CUPS_FILTERS_LINK_LIBICONV +endif + CUPS_FILTERS_CONF_OPTS = --disable-imagefilters \ --disable-mutool \ --disable-foomatic \ --2.18.1
Quoted 4 lines
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildrootI already sent patch to fix this problem (but I did not check the LOCALE config so looks like your version is better):
Quoted 7 lines
https://patchwork.ozlabs.org/patch/1134318but in case of your version is it not enough to just add:
CUPS_FILTERS_CONF_ENV += LIBS=-liconv?
This would link all programs to libiconv, not just texttotext.
Signature · 1 line
Carlos Santos <[email protected]>
PATCH 1/1 package/cups-filters: fix build without NLS
In reply to unixmania at gmail.compackage/cups-filters/cups-filters.mk CUPS_FILTERS_AUTORECONF = YES · line 19
Quoted 4 lines · On Mon, 22 Jul 2019 04:11:46 -0300 unixmania at gmail.com wrote:
package/cups-filters/cups-filters.mk +4
-0+# texttotext must be linked to libiconv if !BR2_ENABLE_LOCALE. We could patch +# configure.ac to use AM_ICONV but it would require iconv.m4, increasing the +# patch size by at least 130 lines. Let's keep it simple and just patch +# Makefile.am to append -liconv to the link command line.
Why is this AM_ICONV solution taking at least 130 lines ? This would be upstreamable, and looks a lot nicer. Could you propose a patch with an AM_ICONV base solution instead ?
Thanks!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com
PATCH 1/1 package/cups-filters: fix build without NLS
Quoted 13 lines · Thomas Petazzoni
package/cups-filters/cups-filters.mk CUPS_FILTERS_AUTORECONF = YES · line 19
Quoted 4 lines · On Mon, 22 Jul 2019 04:11:46 -0300 unixmania at gmail.com wrote:
package/cups-filters/cups-filters.mk +4
-0+# texttotext must be linked to libiconv if !BR2_ENABLE_LOCALE. We could patch +# configure.ac to use AM_ICONV but it would require iconv.m4, increasing the +# patch size by at least 130 lines. Let's keep it simple and just patch +# Makefile.am to append -liconv to the link command line.Why is this
AM_ICONVsolution taking at least 130 lines ? This would be upstreamable, and looks a lot nicer. Could you propose a patch with anAM_ICONVbase solution instead ?
Quoted 1 line
Thanks!
A change solving this was accepted upstream so I will submit a follow-up with that fix:
https://github.com/OpenPrinting/cups-filters/pull/155
Signature · 1 line
Carlos Santos <[email protected]>
PATCH 1/1 package/cups-filters: fix build without NLS
Quoted 18 lines · Carlos Santos
Quoted 13 lines · Thomas Petazzoni
package/cups-filters/cups-filters.mk CUPS_FILTERS_AUTORECONF = YES · line 19
Quoted 4 lines · On Mon, 22 Jul 2019 04:11:46 -0300 unixmania at gmail.com wrote:
package/cups-filters/cups-filters.mk +4
-0+# texttotext must be linked to libiconv if !BR2_ENABLE_LOCALE. We could patch +# configure.ac to use AM_ICONV but it would require iconv.m4, increasing the +# patch size by at least 130 lines. Let's keep it simple and just patch +# Makefile.am to append -liconv to the link command line.Why is this
AM_ICONVsolution taking at least 130 lines ? This would be upstreamable, and looks a lot nicer. Could you propose a patch with anAM_ICONVbase solution instead ?Quoted 1 line
Thanks!
Quoted 7 lines
A change solving this was accepted upstream so I will submit a follow-up with that fix:
https://github.com/OpenPrinting/cups-filters/pull/155
--
Carlos Santos <[email protected]>
Patch updated:
https://patchwork.ozlabs.org/patch/1164349/
I also sent a second patch, fixing a broken symlink:
https://patchwork.ozlabs.org/patch/1164350/
Signature · 1 line
Carlos Santos <[email protected]>