[gimp-help/gimp-help-2-10] build: bring back support for using GIMP's po files as Compendium



commit d4fc5d30319a94b1ddad0d6ec69b2b8e643322ed
Author: Jacob Boerema <jgboerema gmail com>
Date:   Wed Mar 2 17:49:57 2022 -0500

    build: bring back support for using GIMP's po files as Compendium
    
    We had support for using GIMP's po files as Compendium that can be used
    to add translations. This got removed in 2012 in commit 140bc842 when
    the Makefiles got revised.
    
    Since the help about GIMP_PO_ROOT never got removed nor the part that
    checks GIMP's folders for po files, I think this was done by mistake, so
    let's get support for this back.
    
    If you set GIMP_PO_ROOT to GIMP's folder and touch all xml files in the
    /src folder before make po, you will see that it improves the translation
    percentage for several languages, especially the ones that are not very
    complete. In some cases it increases the percentage by almost 10%.

 Makefile.GNU | 3 ++-
 Makefile.am  | 3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/Makefile.GNU b/Makefile.GNU
index aa7b67fe6..653401014 100644
--- a/Makefile.GNU
+++ b/Makefile.GNU
@@ -199,7 +199,8 @@ xml2pot = $(XML2PO) $(XML2POFLAGS) --output='-' $(filter %.xml,$(1)) \
 #     $3 - output PO file
 pot2po = test -e $(3) || \
              $(MSGINIT) $(MSGINITFLAGS) --input $(1) --locale=$(2) --output=$(3); \
-         with_compendium="$(shell $(call get_compendium,$3))"; \
+         with_compendium="$(shell $(call get_compendium,$3)) \
+                          $(shell $(call use_gimp_po_files,$2))"; \
          $(MSGMERGE) $(MSGMERGEFLAGS) $${with_compendium} --update $(3) $(1) \
          && $(MSGFMT) $(MSGFMTFLAGS) $(3) || exit 70; \
          rm -f $(3)~ messages.mo messages.gmo
diff --git a/Makefile.am b/Makefile.am
index 2bd2c178a..36bcd615a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -236,7 +236,8 @@ xml2pot = $(XML2PO) $(XML2POFLAGS) --output='-' $(filter %.xml,$(1)) \
 #     $3 - output PO file
 pot2po = test -e $(3) || \
              $(MSGINIT) $(MSGINITFLAGS) --input $(1) --locale=$(2) --output=$(3); \
-         with_compendium="$(shell $(call get_compendium,$3))"; \
+         with_compendium="$(shell $(call get_compendium,$3)) \
+                          $(shell $(call use_gimp_po_files,$2))"; \
          $(MSGMERGE) $(MSGMERGEFLAGS) $${with_compendium} --update $(3) $(1) \
          && $(MSGFMT) $(MSGFMTFLAGS) $(3) || exit 70; \
          rm -f $(3)~ messages.mo messages.gmo


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