From 588bc1103ab7744ccab61f1d42e299718ba305a9 Mon Sep 17 00:00:00 2001 From: axel Date: Thu, 19 Jan 2006 02:59:17 +1000 Subject: [PATCH] Make it possible to manually rebuild an existing messages.pot using 'make messages'. Don't use the --no-wrap switch for xgettext, since it's not universally supported. Print an explanation if xgettext fails. darcs-hash:20060118165917-ac50b-2bea9293231907ea373216dbd6097a359886a062.gz --- Makefile.in | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/Makefile.in b/Makefile.in index 96560b953..2bdfc5eb6 100644 --- a/Makefile.in +++ b/Makefile.in @@ -223,20 +223,23 @@ doc.h:$(BUILTIN_DOC_SRC) $(CMD_DOC_SRC) doc_src/doc.hdr fi # Update existing po file or copy messages.pot -%.po: messages.pot +%.po:messages.pot if test $(HAVE_GETTEXT) = 1;then \ if test -f $*.po; then \ - msgmerge -U --backup=existing --no-wrap $*.po messages.pot;\ + msgmerge -U --backup=existing $*.po messages.pot;\ else \ cp messages.pot $*.po;\ fi; \ fi # Create a template translation object -messages.pot: +messages messages.pot: if test $(HAVE_GETTEXT) = 1;then \ - xgettext -k_ -kN_ -kcomplete_desc --no-wrap *.c *.h -o messages.pot; \ - xgettext -j -k_ -LShell --no-wrap init/*.in init/*.fish init/completions/*.fish -o messages.pot; \ + xgettext -k_ -kN_ -kcomplete_desc *.c *.h -o messages.pot; \ + if ! xgettext -j -k_ -LShell init/*.in init/*.fish init/completions/*.fish -o messages.pot; then \ + echo "Your xgettext version is too old to build the messages.pot file"\ + false;\ + fi; \ fi # Generate the internal help functions by making doxygen create