French translation was updated.
[geeqie.git] / po / Makefile.in.in.patch
1 --- Makefile.in.in      2009-04-28 23:27:08.000000000 +0200
2 +++ Makefile.in.in.new  2009-04-28 23:25:22.000000000 +0200
3 @@ -92,7 +92,7 @@
4  all-yes: $(CATALOGS)
5  all-no:
6  
7 -$(srcdir)/$(GETTEXT_PACKAGE).pot: $(POTFILES)
8 +$(srcdir)/$(GETTEXT_PACKAGE).pot: $(POTFILES) $(srcdir)/POTFILES.in
9         $(XGETTEXT) --default-domain=$(GETTEXT_PACKAGE) --directory=$(top_srcdir) \
10           --add-comments --keyword=_ --keyword=N_ \
11            --flag=g_strdup_printf:1:c-format \
12 @@ -216,8 +216,31 @@
13             || cp -p $(srcdir)/$$file $(distdir); \
14         done
15  
16 -update-po: Makefile
17 -       $(MAKE) $(GETTEXT_PACKAGE).pot
18 +### Updating po and gmo files
19 +#
20 +# Update by merging all .po files with the .po template master file.
21 +#
22 +# It is possible to update only a single .po file by setting the PO variable to
23 +# either <lang> or <lang>.po when calling make. Example: make update-po PO=is
24 +
25 +update-po: Makefile $(srcdir)/$(GETTEXT_PACKAGE).pot
26 +       @cd $(srcdir); \
27 +       $(foreach lang,$(basename $(if $(strip $(PO)),$(PO),$(CATALOGS))), \
28 +         echo -n "$(lang): "; \
29 +         if $(MSGMERGE) $(lang).po $(srcdir)/$(GETTEXT_PACKAGE).pot -o $(lang).new.po; then \
30 +           mv -f $(lang).new.po $(lang).po; \
31 +         else \
32 +           echo "msgmerge failed!"; \
33 +           rm -f $(lang).new.po; \
34 +         fi; \
35 +       )
36 +       $(MAKE) update-gmo
37 +
38 +update-gmo: Makefile $(CATALOGS)
39 +       @:
40 +
41 +update-po-orig: Makefile
42 +       $(MAKE) $(srcdir)/$(GETTEXT_PACKAGE).pot
43         tmpdir=`pwd`; \
44         cd $(srcdir); \
45         catalogs='$(CATALOGS)'; \
46 @@ -225,7 +248,7 @@
47           cat=`basename $$cat`; \
48           lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
49           echo "$$lang:"; \
50 -         if $(MSGMERGE) $$lang.po $(GETTEXT_PACKAGE).pot -o $$tmpdir/$$lang.new.po; then \
51 +         if $(MSGMERGE) $$lang.po $(srcdir)/$(GETTEXT_PACKAGE).pot -o $$tmpdir/$$lang.new.po; then \
52             if cmp $$lang.po $$tmpdir/$$lang.new.po >/dev/null 2>&1; then \
53               rm -f $$tmpdir/$$lang.new.po; \
54              else \