X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=cirros-testvm%2Fsrc-cirros%2Fbuildroot-2015.05%2Fpackage%2Fgutenprint%2F0001-use-pregen-xmli18n-header.patch;fp=cirros-testvm%2Fsrc-cirros%2Fbuildroot-2015.05%2Fpackage%2Fgutenprint%2F0001-use-pregen-xmli18n-header.patch;h=533fe33d8241406ef692cf59c903eab8a7e923a2;hb=b0a0f15dfaa205161a7fcb20cf1b8cd4948c2ef3;hp=0000000000000000000000000000000000000000;hpb=c6ac3cd55ee2da956195eee393b0882105dfad4e;p=packages%2Ftrusty%2Fcirros-testvm.git diff --git a/cirros-testvm/src-cirros/buildroot-2015.05/package/gutenprint/0001-use-pregen-xmli18n-header.patch b/cirros-testvm/src-cirros/buildroot-2015.05/package/gutenprint/0001-use-pregen-xmli18n-header.patch new file mode 100644 index 0000000..533fe33 --- /dev/null +++ b/cirros-testvm/src-cirros/buildroot-2015.05/package/gutenprint/0001-use-pregen-xmli18n-header.patch @@ -0,0 +1,48 @@ +src/xml: use preg-gen xmli18n_tmp.h if specified + +Ideally, the programs needed at build-time should be built with +CC_FOR_BUILD, and not with CC_FOR_HOST. + +Unfortunately, this program wants to link against the gutenprint libs, +so we would also need to build them with CC_FOR_HOST, that is build them +twice, once for build, once for host. + +Instead, in the Buildroot context, we first build gutenprint for the build +system, use that to generate the incriminated header, and then re-use that +header to build the gutenprint for the host. + +It is not possible to have such constructs in Makefile.am: + ifeq ($(FOO),) + bar: bla + cat $< >$@ + else + bar: + echo $(FOO) >$@ + endif + +as autoreconf will yell loudly that there is an 'endif' without an 'if'. +Sigh... :-( + +Signed-off-by: "Yann E. MORIN" + +diff -durN gutenprint-5.2.9.orig/src/xml/Makefile.am gutenprint-5.2.9/src/xml/Makefile.am +--- gutenprint-5.2.9.orig/src/xml/Makefile.am 2011-03-30 02:43:24.000000000 +0200 ++++ gutenprint-5.2.9/src/xml/Makefile.am 2013-03-24 17:08:08.435918773 +0100 +@@ -52,10 +52,13 @@ + + + xmli18n-tmp.h: xml-stamp extract-strings +- -rm -f $@ $@.tmp +- ./extract-strings `cat xml-stamp | sed -e 's;^;$(srcdir)/;'` > $@.tmp +- mv $@.tmp $@ +- ++ if [ -z "$(BR2_USE_PREGEN_XMLI18N_TMP_H)" ]; then \ ++ rm -f $@ $@.tmp; \ ++ ./extract-strings `cat xml-stamp | sed -e 's;^;$(srcdir)/;'` > $@.tmp; \ ++ mv $@.tmp $@; \ ++ else \ ++ cp $(BR2_USE_PREGEN_XMLI18N_TMP_H) $@; \ ++ fi + + dist-hook: xmli18n-tmp.h xml-stamp + # xmli18n-tmp.h is needed by po/POTFILES.in at dist time