From: Daiki Ueno Date: Mon, 21 Apr 2014 08:58:41 +0000 (+0900) Subject: Rules-quot: Use built-in quot filter if possible X-Git-Tag: v0.19~95 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1431ba78ad26de5e9826e14586c6be0fde314ca9;p=thirdparty%2Fgettext.git Rules-quot: Use built-in quot filter if possible --- diff --git a/gettext-runtime/po/ChangeLog b/gettext-runtime/po/ChangeLog index 5011350a4..d3f2cdc35 100644 --- a/gettext-runtime/po/ChangeLog +++ b/gettext-runtime/po/ChangeLog @@ -1,3 +1,7 @@ +2014-04-21 Daiki Ueno + + * Rules-quot: Use built-in filter if possible. + 2014-04-02 Daiki Ueno * Rules-quot: Add a license notice. diff --git a/gettext-runtime/po/Rules-quot b/gettext-runtime/po/Rules-quot index 63ab418ce..7b92c7e45 100644 --- a/gettext-runtime/po/Rules-quot +++ b/gettext-runtime/po/Rules-quot @@ -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 \ diff --git a/gettext-tools/po/ChangeLog b/gettext-tools/po/ChangeLog index 2868c1953..98ed78106 100644 --- a/gettext-tools/po/ChangeLog +++ b/gettext-tools/po/ChangeLog @@ -1,3 +1,11 @@ +2014-04-21 Daiki Ueno + + * Rules-quot: Use built-in filter if possible. + +2014-04-02 Daiki Ueno + + * Rules-quot: Add a license notice. + 2013-07-04 Daiki Ueno * bg.po: Update from Roumen Petrov . diff --git a/gettext-tools/po/Rules-quot b/gettext-tools/po/Rules-quot index 5931e5392..7b92c7e45 100644 --- a/gettext-tools/po/Rules-quot +++ b/gettext-tools/po/Rules-quot @@ -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 \