1 # Special Makefile rules for Pig Latin message catalogs with quotation marks.
3 DISTFILES.common.extra3 = piglatin.sed en@piglatin.header insert-header.sin Rules-piglatin
5 .SUFFIXES: .insert-header .po-update-en-piglatin
8 $(MAKE) en@piglatin.po-update
10 en@piglatin.po-update: en@piglatin.po-update-en
12 .insert-header.po-update-en-piglatin:
13 @lang=`echo $@ | sed -e 's/\.po-update-en-piglatin$$//'`; \
14 if test "$(PACKAGE)" = "gettext"; then PATH=`pwd`/../src:$$PATH; GETTEXTLIBDIR=`cd $(top_srcdir)/src && pwd`; export GETTEXTLIBDIR; fi; \
17 ll=`echo $$lang | sed -e 's/@.*//'`; \
18 LC_ALL=C; export LC_ALL; \
20 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 \
21 if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \
22 rm -f $$tmpdir/$$lang.new.po; \
24 if mv -f $$tmpdir/$$lang.new.po $$lang.po; then \
27 echo "creation of $$lang.po failed: cannot move $$tmpdir/$$lang.new.po to $$lang.po" 1>&2; \
32 echo "creation of $$lang.po failed!" 1>&2; \
33 rm -f $$tmpdir/$$lang.new.po; \
36 en@piglatin.insert-header: insert-header.sin
37 sed -e '/^#/d' -e 's/HEADER/en@piglatin.header/g' $(srcdir)/insert-header.sin > en@piglatin.insert-header
39 mostlyclean: mostlyclean-piglatin