[gimp-help-2] Set pot file timestamps



commit 73cd6f20938a1192ec0ac91a01c21b04be4ea1ba
Author: Ulf-D. Ehlert <ulfehlert svn gnome org>
Date:   Tue Apr 21 13:23:20 2009 +0200

    Set pot file timestamps
    
    Touch pot files using the src files' timestamps
    to prevent "make" from producing trivial updates
    where just the POT-Creation-Date changed.
---
 ChangeLog    |    9 +++++++++
 Makefile.GNU |    3 +++
 Makefile.am  |    1 +
 3 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 1141d56..72e8105 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2009-04-21  Ulf-D. Ehlert  <ulfehlert svn gnome org>
+
+	Set pot file timestamps
+
+	* Makefile.am
+	* Makefile.GNU: Touch pot files using the src files'
+	timestamps to prevent "make" from producing trivial
+	updates where just the POT-Creation-Date changed.
+
 2009-04-20  Ulf-D. Ehlert  <ulfehlert svn gnome org>
 
 	Handle more auto-generated files
diff --git a/Makefile.GNU b/Makefile.GNU
index 6791033..d6122cc 100644
--- a/Makefile.GNU
+++ b/Makefile.GNU
@@ -169,6 +169,7 @@ xml2pot = ($(XML2PO) --output='-' $(1) \
           | $(MSGCAT) $(MSGCATFLAGS) - > "$(2)") 2>&1 \
           | $(SED) -e '/image file .* not found/d'; \
           test -s "$(2)" || rm -f "$(2)"; \
+          touch -c -r $(call get_recent_file,$(1)) "$(2)" || true; \
           test -s "$(2)"
 
 # Merge template (pot) and message catalog (po) or create a new catalog
@@ -228,6 +229,8 @@ endif
 
 make_target_dir = f=$(1); d=$${f%/*}; test -d $$d || $(mkdir_p) $$d
 
+get_recent_file = $(shell ls -t $(1) | head -n 1)
+
 copy = $(ln_s) $(abs_srcdir)/$(1) $(2)
 
 ifneq ($(COMPENDIUM),"")
diff --git a/Makefile.am b/Makefile.am
index 2d63fad..8c7625a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -243,6 +243,7 @@ xml2pot = ($(XML2PO) --output='-' $(1) \
           | $(MSGCAT) $(MSGCATFLAGS) - > "$(2)") 2>&1 \
           | $(SED) -e '/image file .* not found/d'; \
           test -s "$(2)" || rm -f "$(2)"; \
+          touch -c -r `ls -t $(1) | head -n 1` "$(2)" || true; \
           test -s "$(2)"
 
 # Merge template (pot) and message catalog (po) or create a new catalog



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