diff --git a/Makefile.am b/Makefile.am index 883bafc684..2030ba1ead 100644 --- a/Makefile.am +++ b/Makefile.am @@ -5170,6 +5170,20 @@ include Makefile.examples ############################################################################### +check-po-msgfmt: + @echo "check-po-msgfmt: check $(top_srcdir)/po/*.po files with msgfmt -vc" + @for f in "$(top_srcdir)/po"/*.po ; do \ + if ! msgfmt -vc "$$f" &>/dev/null ; then \ + echo "invalid po file: msgfmt -vc $$f" ; \ + msgfmt -vc "$$f" ; \ + exit 1 ; \ + fi ; \ + done + +check_local += check-po-msgfmt + +############################################################################### + check-local: $(check_local) dist-hook: $(dist_hook)