[gegl] Restore the versioning of the installed *.mo files



commit dc19cf4fd198eae137ce06ca08f6c1e847dc1678
Author: Debarshi Ray <debarshir gnome org>
Date:   Mon Nov 13 15:07:18 2017 +0100

    Restore the versioning of the installed *.mo files
    
    It seems slightly more elegant to use the GETTEXT_PACKAGE output
    variable instead of hard coding the version suffix in po/Makevars.
    
    Unfortunately, I couldn't find a way to not distribute the generated
    po/Makevars, or a way to insert custom variables in Gettext's
    Makevars. Failing that, since the value of GETTEXT_PACKAGE isn't going
    to change as a result of configuring the build, we stop distcheck from
    complaining about po/Makevars not getting removed after distclean by
    using distcleancheck_listfiles.
    
    Fallout from 37262520be05d3903d142c6cfe655bc727596ded
    
    https://bugzilla.gnome.org/show_bug.cgi?id=789010

 Makefile.am                  |    9 +++++++++
 configure.ac                 |    1 +
 po/.gitignore                |    1 +
 po/{Makevars => Makevars.in} |    2 +-
 4 files changed, 12 insertions(+), 1 deletions(-)
---
diff --git a/Makefile.am b/Makefile.am
index 2b6ff96..a73a50b 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -32,6 +32,7 @@ EXTRA_DIST =                  \
        autogen.sh              \
        gegl-uninstalled.pc.in  \
        m4/introspection.m4     \
+       po/Makevars.in          \
        gegl.pc.in
 
 # DISTCHECK_CONFIGURE_FLAGS = --enable-introspection
@@ -39,6 +40,14 @@ EXTRA_DIST =                         \
 DISTCLEANFILES = \
        $(built_dist_files)
 
+# The generated po/Makevars shouldn't be distributed, or we need a way
+# to insert custom variables in Gettext's Makevars. Failing that, this
+# stops distcheck from complaining about po/Makevars not getting removed
+# after a distclean.
+distcleancheck_listfiles = \
+       find . -type f -exec sh -c 'test -f $(srcdir)/$$1 || echo $$1' \
+               sh '{}' ';'
+
 if HAVE_W3M
 dist-check-w3m:
 NEWS: docs/NEWS.html
diff --git a/configure.ac b/configure.ac
index e5af760..a297c13 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1317,6 +1317,7 @@ operations/transform/Makefile
 operations/workshop/Makefile
 operations/workshop/external/Makefile
 operations/workshop/generated/Makefile
+po/Makevars
 tools/Makefile
 docs/Makefile
 docs/index.txt
diff --git a/po/.gitignore b/po/.gitignore
index f851f28..9f34df9 100644
--- a/po/.gitignore
+++ b/po/.gitignore
@@ -4,6 +4,7 @@
 /Makefile
 /Makefile.in
 /Makefile.in.in
+/Makevars
 /Makevars.template
 /POTFILES
 /Rules-quot
diff --git a/po/Makevars b/po/Makevars.in
similarity index 99%
rename from po/Makevars
rename to po/Makevars.in
index 5d3a61e..a80410e 100644
--- a/po/Makevars
+++ b/po/Makevars.in
@@ -1,7 +1,7 @@
 # Makefile variables for PO directory in any package using GNU gettext.
 
 # Usually the message domain is the same as the package name.
-DOMAIN = $(PACKAGE)
+DOMAIN = @GETTEXT_PACKAGE@
 
 # These two variables depend on the location of this directory.
 subdir = po


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]