]> git.lyx.org Git - lyx.git/blobdiff - po/Makefile.in.in
revert
[lyx.git] / po / Makefile.in.in
index 825d5e52cdb9db59eb46a9e761a402d91d2c5416..5fee5f919e17450551c5128c6fe8b12934d3034e 100644 (file)
@@ -63,7 +63,7 @@ CATALOGS = @CATALOGS@
        $(COMPILE) $<
 
 .po.pox:
-       $(MAKE) $(PACKAGE).pot
+       $(MAKE) $(srcdir)/$(PACKAGE).pot
        $(MSGMERGE) $< $(srcdir)/$(PACKAGE).pot -o $*.pox
 
 .po.mo:
@@ -86,9 +86,9 @@ all-no:
 # otherwise packages like GCC can not be built if only parts of the source
 # have been downloaded.
 
-$(srcdir)/$(PACKAGE).pot: $(POTFILES) $(srcdir)/POTFILES.in
+$(srcdir)/$(PACKAGE).pot: $(POTFILES) $(srcdir)/POTFILES.in $(top_srcdir)/src/ext_l10n.h
        $(XGETTEXT) --default-domain=$(PACKAGE) --directory=$(top_srcdir) \
-         --add-comments --keyword=_ --keyword=N_ \
+         --escape --add-comments --keyword=_ --keyword=N_ \
          --files-from=$(srcdir)/POTFILES.in \
        && test ! -f $(PACKAGE).po \
           || ( rm -f $(srcdir)/$(PACKAGE).pot \
@@ -198,9 +198,9 @@ Makefile: Makefile.in.in $(top_builddir)/config.status POTFILES.in
 ${srcdir}/POTFILES.in: $(POTFILE_IN_DEPS)
        rm -f $@-t \
        && ( cd $(top_srcdir); \
-            grep -l "_(\".*\")" `find src -path src/frontends/kde  -prune -o -name \*.[hHC] -print `| \
+            grep -l "_(\".*\")" `find src -name \*.[hHC] -print` |\
             sed -e '/xforms.forms/d' | \
-            sort -f -d | uniq ) > $@-t \
+            sort -f -n | uniq ) > $@-t \
        && echo "src/ext_l10n.h" >> $@-t \
        && mv $@-t $@
 
@@ -213,6 +213,8 @@ $(top_srcdir)/src/ext_l10n.h: $(top_srcdir)/lib/layouts/*.layout $(top_srcdir)/l
                sed -n -e 's/^[sS]tyle[ ]*\([^ ]*\)$$/_("\1");/p' | \
                sort | uniq >> $@
        sed < $(top_srcdir)/lib/languages -e '/^#/d' -e 's/[^"]*\("[A-Za-z0-9][^"]*"\).*/_(\1);/' >> $@
+       cat $(top_srcdir)/src/frontends/qt2/ui/*.ui | grep '<string>..*</string>' | \
+               sed 's,&amp;,\&,;s,^.*<string>,_(",;s,</string>,"),;' | uniq >> $@
 
 # Tell versions [3.59,3.63) of GNU make not to export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.