]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
Rules-quot: Use built-in quot filter if possible
authorDaiki Ueno <ueno@gnu.org>
Mon, 21 Apr 2014 08:58:41 +0000 (17:58 +0900)
committerDaiki Ueno <ueno@gnu.org>
Mon, 21 Apr 2014 08:58:41 +0000 (17:58 +0900)
gettext-runtime/po/ChangeLog
gettext-runtime/po/Rules-quot
gettext-tools/po/ChangeLog
gettext-tools/po/Rules-quot

index 5011350a4b52b8d478a3c2b67a765da8e9369aa0..d3f2cdc3579c9d89881f45d47e01c29f4af5c689 100644 (file)
@@ -1,3 +1,7 @@
+2014-04-21  Daiki Ueno  <ueno@gnu.org>
+
+       * Rules-quot: Use built-in filter if possible.
+
 2014-04-02  Daiki Ueno  <ueno@gnu.org>
 
        * Rules-quot: Add a license notice.
index 63ab418ce9715712b371ad2734813c7ec965dfb6..7b92c7e45665c3343672097191946a503b894191 100644 (file)
@@ -21,7 +21,17 @@ en@boldquot.po-update: en@boldquot.po-update-en
        ll=`echo $$lang | sed -e 's/@.*//'`; \
        LC_ALL=C; export LC_ALL; \
        cd $(srcdir); \
-       if $(MSGINIT) -i $(DOMAIN).pot --no-translator -l $$lang -o - 2>/dev/null | sed -f $$tmpdir/$$lang.insert-header | $(MSGCONV) -t UTF-8 | $(MSGFILTER) $(SED) -f `echo $$lang | sed -e 's/.*@//'`.sed 2>/dev/null > $$tmpdir/$$lang.new.po; then \
+       if $(MSGINIT) -i $(DOMAIN).pot --no-translator -l $$lang -o - 2>/dev/null \
+          | $(SED) -f $$tmpdir/$$lang.insert-header | $(MSGCONV) -t UTF-8 | \
+          { case `$(MSGFILTER) --version | sed 1q | sed -e 's,^[^0-9]*,,'` in \
+            '' | 0.[0-9] | 0.[0-9].* | 0.1[0-8] | 0.1[0-8].*) \
+              $(MSGFILTER) $(SED) -f `echo $$lang | sed -e 's/.*@//'`.sed \
+              ;; \
+            *) \
+              $(MSGFILTER) `echo $$lang | sed -e 's/.*@//'` \
+              ;; \
+            esac } 2>/dev/null > $$tmpdir/$$lang.new.po \
+            ; then \
          if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \
            rm -f $$tmpdir/$$lang.new.po; \
          else \
index 2868c1953fb5a1150260ad91e484fcf0aca903f7..98ed78106e3e3f22a4fe36de845c5a2046f14cbd 100644 (file)
@@ -1,3 +1,11 @@
+2014-04-21  Daiki Ueno  <ueno@gnu.org>
+
+       * Rules-quot: Use built-in filter if possible.
+
+2014-04-02  Daiki Ueno  <ueno@gnu.org>
+
+       * Rules-quot: Add a license notice.
+
 2013-07-04  Daiki Ueno  <ueno@gnu.org>
 
        * bg.po: Update from Roumen Petrov <transl@roumenpetrov.info>.
index 5931e539232121cc8a1ee61cf101399e33d51edf..7b92c7e45665c3343672097191946a503b894191 100644 (file)
@@ -1,3 +1,4 @@
+# This file, Rules-quot, can be copied and used freely without restrictions.
 # Special Makefile rules for English message catalogs with quotation marks.
 
 DISTFILES.common.extra1 = quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot
@@ -20,7 +21,17 @@ en@boldquot.po-update: en@boldquot.po-update-en
        ll=`echo $$lang | sed -e 's/@.*//'`; \
        LC_ALL=C; export LC_ALL; \
        cd $(srcdir); \
-       if $(MSGINIT) -i $(DOMAIN).pot --no-translator -l $$lang -o - 2>/dev/null | sed -f $$tmpdir/$$lang.insert-header | $(MSGCONV) -t UTF-8 | $(MSGFILTER) $(SED) -f `echo $$lang | sed -e 's/.*@//'`.sed 2>/dev/null > $$tmpdir/$$lang.new.po; then \
+       if $(MSGINIT) -i $(DOMAIN).pot --no-translator -l $$lang -o - 2>/dev/null \
+          | $(SED) -f $$tmpdir/$$lang.insert-header | $(MSGCONV) -t UTF-8 | \
+          { case `$(MSGFILTER) --version | sed 1q | sed -e 's,^[^0-9]*,,'` in \
+            '' | 0.[0-9] | 0.[0-9].* | 0.1[0-8] | 0.1[0-8].*) \
+              $(MSGFILTER) $(SED) -f `echo $$lang | sed -e 's/.*@//'`.sed \
+              ;; \
+            *) \
+              $(MSGFILTER) `echo $$lang | sed -e 's/.*@//'` \
+              ;; \
+            esac } 2>/dev/null > $$tmpdir/$$lang.new.po \
+            ; then \
          if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \
            rm -f $$tmpdir/$$lang.new.po; \
          else \