gimp-help-2 r2676 - in trunk: . po/de/menus po/de/menus/colors



Author: ulfehlert
Date: Thu Jan  8 20:14:42 2009
New Revision: 2676
URL: http://svn.gnome.org/viewvc/gimp-help-2?rev=2676&view=rev

Log:
2009-01-08  Ulf-D. Ehlert  <ulfehlert svn gnome org>

	* Makefile.am: clean silently; do not  clean "po/"
	* Makefile.GNU: use msgmerge's "--compendium" feature
	* po/de/menus/Compendium.po
	* po/de/menus/colors/Compendium.po: sample compendium files


Added:
   trunk/po/de/menus/Compendium.po
   trunk/po/de/menus/colors/Compendium.po
Modified:
   trunk/ChangeLog
   trunk/Makefile.GNU
   trunk/Makefile.am

Modified: trunk/Makefile.GNU
==============================================================================
--- trunk/Makefile.GNU	(original)
+++ trunk/Makefile.GNU	Thu Jan  8 20:14:42 2009
@@ -91,6 +91,10 @@
 # XXX: requires that "plainhtml.xsl" has been renamed to "html.xsl"
 HTML_STYLESHEETS = stylesheets/html*.xsl
 
+# This variable is used by "msgmerge";
+# use empty variable to disable the compendium option
+COMPENDIUM = Compendium.po
+
 # To talk or not to talk, that is the question!
 VERBOSE ?= 1
 
@@ -146,12 +150,12 @@
 #     $1 - input POT file
 #     $2 - translation language
 #     $3 - output PO file
-# TODO: include compendium (cf. "info msgmerge")
 pot2po = if [ -f $(3) ]; then \
+             with_compendium=$(shell $(call get_compendium,$3)); \
              $(MSGFMT)   $(MSGFMTFLAGS)   $(3); \
-             $(MSGMERGE) $(MSGMERGEFLAGS) $(3) $(1) | \
+             $(MSGMERGE) $(MSGMERGEFLAGS) $${with_compendium} $(3) $(1) | \
              $(MSGCAT) $(MSGCATFLAGS) - > .tmp.po && \
-	     mv -f .tmp.po $(3) || rm -v .tmp.po; \
+             mv -f .tmp.po $(3) || rm -v .tmp.po; \
          else \
              $(MSGINIT)  $(MSGINITFLAGS) --input $(1) --locale=$(2) --output $(3); \
          fi
@@ -180,7 +184,21 @@
 #--------------------------------------------------------------#
 
 make_target_dir = \
-	f=$(1); d=$${f%/*}; test -d $$d || $(mkdir_p) $$d;
+	f=$(1); d=$${f%/*}; test -d $$d || $(mkdir_p) $$d
+
+ifneq ($(COMPENDIUM),"")
+get_compendium = \
+	dir="$(1)"; dir=$${dir%/*}; \
+	while test "$${dir}" != "po"; do \
+		if test -f $${dir}/$(COMPENDIUM); then \
+			opt="$${opt} --compendium=$${dir}/$(COMPENDIUM)"; \
+		fi; \
+		dir="$${dir%/*}"; \
+	done; \
+	if test -n "$${opt}"; then echo $${opt}; fi
+else
+get_compendium =
+endif
 
 
 ########################################################################

Modified: trunk/Makefile.am
==============================================================================
--- trunk/Makefile.am	(original)
+++ trunk/Makefile.am	Thu Jan  8 20:14:42 2009
@@ -237,8 +237,8 @@
 pot2po = if [ -f $(3) ]; then \
              $(MSGFMT)   $(MSGFMTFLAGS)   $(3); \
              $(MSGMERGE) $(MSGMERGEFLAGS) $(3) $(1) | \
-             $(MSGCAT) $(MSGCATFLAGS) - > $(potdir)/.tmp.po && \
-	     mv -f $(potdir)/.tmp.po $(3) || rm -v $(potdir)/.tmp.po; \
+             $(MSGCAT) $(MSGCATFLAGS) - > .tmp.po && \
+             mv -f .tmp.po $(3) || rm -v .tmp.po; \
           else \
               $(MSGINIT)  $(MSGINITFLAGS) --input $(1) --locale=$(2) --output $(3); \
           fi
@@ -670,19 +670,18 @@
 
 
 clean-local:
-	rm -rf html
-	rm -rf odf
-	rm -rf pdf
-	rm -rf preview
-	rm -rf preview-*
-	rm -rf xml
-	rm -rf $(tarball_prefix)-*
-	rm -rf po
-	rm -rf pot
+	$(cmd) rm -rf html
+	$(cmd) rm -rf odf
+	$(cmd) rm -rf pdf
+	$(cmd) rm -rf xml
+	$(cmd) rm -rf log
+	$(cmd) rm -rf pot
+	$(cmd) rm -f $(tarball_prefix)-*
+	$(cmd) rm -f .tmp.po AUTHORS $(AUTHORS_DOCBOOK_XML) build-system.png
 
 
 maintainer-clean-local:
-	rm -rf html
+	$(cmd) rm -rf html
 
 # GNU Make, please don't delete these targets when a target that depends
 # on them fails, 'kay?



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