From: Stefano Lattarini Date: Mon, 6 Sep 2010 12:32:30 +0000 (+0200) Subject: Fixlets for internationalization tests. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3e1c807be8de4b70fc41e1b10b2df35479c59777;p=thirdparty%2Fautomake.git Fixlets for internationalization tests. * tests/pot-copyright.test: Add trailing `:' command. * tests/pot-empty.test: Likewise. * tests/pot-download1.test: Likewise. Use `Exit', not `exit'. ($required): Remove gzip, as we must take it for granted anyway. * tests/pot-format-qt1.test: Use `Exit', not `exit'. Use `$MAKE', not bare `make'. Add trailing `:' command. Avoid useless use of cat. Do not redirect output of grep, cmp, etc. to /dev/null. Other minor cosmetic changes. * tests/pot-format-java1.test: Likewise, and ... ($required): Remove gzip, as we must take it for granted anyway. * tests/pot-format-java2.test: Likewise. * tests/pot-format-tcl1.test: Likewise. * tests/pot-linguas.test: Likewise. * tests/pot-noinst.test: Likewise. * tests/pot-samedir.test: Likewise. * tests/pot-topsrcdir.test: Likewise. * tests/pot-format-csharp1.test: Likewise, and quote all literal dots in grep regexps. * tests/pot-enable1.test: Use `$MAKE', not bare `make'. Do not redirect grep output to /dev/null. Add trailing `:' command. (Makefile.am): Explicitly declare phony target as such. * tests/pot-enable2.test: Likewise. * tests/pot-msgidbugs.test: Use `$MAKE', not bare `make'. Avoid useless use of cat. Add trailing `:' command. * tests/pot-xgettext1.test: Likewise. * tests/pot-xgettext2.test: Likewise. * tests/pot-xgettext3.test: Likewise. * tests/pot-xgettext4.test: Likewise. * tests/pot-no-linguas.test: Likewise, and do not redirect grep output to /dev/null. * tests/pot-override1.test: Likewise. * tests/pot-macro-warn.test: Avoid useless use of `AUTOMAKE_run'. Add trailing `:' command. * tests/pot-warn1.test: Likewise. * tests/pot-warn2.test: Likewise. --- diff --git a/ChangeLog b/ChangeLog index ef24a5d1e..0246cbf6b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,43 @@ 2010-09-06 Stefano Lattarini + Fixlets for internationalization tests. + * tests/pot-copyright.test: Add trailing `:' command. Use + `$MAKE', not bare `make'. + * tests/pot-empty.test: Likewise. + * tests/pot-download1.test: Likewise. Use `Exit', not `exit'. + ($required): Remove gzip, as we must take it for granted anyway. + * tests/pot-format-qt1.test: Use `Exit', not `exit'. Use `$MAKE', + not bare `make'. Add trailing `:' command. Avoid useless use of + cat. Do not redirect output of grep, cmp, etc. to /dev/null. + Other minor cosmetic changes. + * tests/pot-format-java1.test: Likewise, and ... + ($required): Remove gzip, as we must take it for granted anyway. + * tests/pot-format-java2.test: Likewise. + * tests/pot-format-tcl1.test: Likewise. + * tests/pot-linguas.test: Likewise. + * tests/pot-noinst.test: Likewise. + * tests/pot-samedir.test: Likewise. + * tests/pot-topsrcdir.test: Likewise. + * tests/pot-format-csharp1.test: Likewise, and quote all literal + dots in grep regexps. + * tests/pot-enable1.test: Use `$MAKE', not bare `make'. Do not + redirect grep output to /dev/null. Add trailing `:' command. + (Makefile.am): Explicitly declare phony target as such. + * tests/pot-enable2.test: Likewise. + * tests/pot-msgidbugs.test: Use `$MAKE', not bare `make'. Avoid + useless use of cat. Add trailing `:' command. + * tests/pot-xgettext1.test: Likewise. + * tests/pot-xgettext2.test: Likewise. + * tests/pot-xgettext3.test: Likewise. + * tests/pot-xgettext4.test: Likewise. + * tests/pot-no-linguas.test: Likewise, and do not redirect grep + output to /dev/null. + * tests/pot-override1.test: Likewise. + * tests/pot-macro-warn.test: Avoid useless use of `AUTOMAKE_run'. + Add trailing `:' command. + * tests/pot-warn1.test: Likewise. + * tests/pot-warn2.test: Likewise. + List internationalization tests in tests/Makefile.am. * tests/Makefile.am (TESTS, XFAIL_TESTS): Add internationalization tests `pot-*.test' introduced in previous commits. diff --git a/tests/pot-copyright.test b/tests/pot-copyright.test index e4f9ff2e5..fb11367d6 100755 --- a/tests/pot-copyright.test +++ b/tests/pot-copyright.test @@ -82,13 +82,13 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make dist" creates the expected .pot file. # (It is created under $sourcedir, because the .pot file is distributed. # Cf. the GNU standards, node "Makefile Basics".) - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot @@ -97,10 +97,12 @@ for builddir in . sub; do rm -f actual # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done + +: diff --git a/tests/pot-download1.test b/tests/pot-download1.test index a70845ba8..01aead170 100755 --- a/tests/pot-download1.test +++ b/tests/pot-download1.test @@ -16,7 +16,6 @@ # Check the download of translations from the Translation Project. -required='gzip' . ./defs || Exit 1 set -e @@ -57,26 +56,26 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir LINGUAS="de" $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that after "make install", a German translation has been installed. - make install + $MAKE install test -f "$instdir"/share/locale/de/LC_MESSAGES/clisp.mo # Check that after "make dist", the tarball does not include the German # translation. - make dist + $MAKE dist gzip -d -c < pot-download1-1.0.tar.gz | tar tf - > filelist - if grep '^pot-download1-1\.0/clisp-de\.po$' filelist >/dev/null; then - exit 1 - fi + grep '^pot-download1-1\.0/clisp-de\.po$' filelist && Exit 1 rm -f filelist # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done + +: diff --git a/tests/pot-empty.test b/tests/pot-empty.test index 09bca2bc1..46611aa20 100755 --- a/tests/pot-empty.test +++ b/tests/pot-empty.test @@ -57,13 +57,13 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir $sourcedir/configure --prefix="$instdir" - make - make dist + $MAKE + $MAKE dist # Check that no .pot file was created. test ! -f posub/foo-bar.pot - make install + $MAKE install # Check that still, no .pot file was created. test ! -f posub/foo-bar.pot @@ -72,10 +72,12 @@ for builddir in . sub; do test ! -d "$instdir"/share/locale/de/LC_MESSAGES # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done + +: diff --git a/tests/pot-enable1.test b/tests/pot-enable1.test index 77b154da3..ff98d8326 100755 --- a/tests/pot-enable1.test +++ b/tests/pot-enable1.test @@ -23,6 +23,7 @@ set -e cat > Makefile.am << 'END' +.PHONY: check-USE_NLS-yes check-USE_NLS-no check-USE_NLS-yes: test "@USE_NLS@" = yes check-USE_NLS-no: @@ -39,14 +40,16 @@ $AUTOMAKE -a $AUTOCONF # Check that the --help output advertises --disable-nls. -./configure --help | grep ' --disable-nls ' >/dev/null +./configure --help | grep ' --disable-nls ' # Check that --enable-nls causes USE_NLS to be yes. ./configure --enable-nls -make check-USE_NLS-yes +$MAKE check-USE_NLS-yes -make distclean +$MAKE distclean # Check that --disable-nls causes USE_NLS to be no. ./configure --disable-nls -make check-USE_NLS-no +$MAKE check-USE_NLS-no + +: diff --git a/tests/pot-enable2.test b/tests/pot-enable2.test index 02bde5be4..31ab56b1c 100755 --- a/tests/pot-enable2.test +++ b/tests/pot-enable2.test @@ -23,6 +23,7 @@ set -e cat > Makefile.am << 'END' +.PHONY: check-USE_NLS-yes check-USE_NLS-no check-USE_NLS-yes: test "@USE_NLS@" = yes check-USE_NLS-no: @@ -39,14 +40,16 @@ $AUTOMAKE -a $AUTOCONF # Check that the --help output advertises --disable-nls. -./configure --help | grep ' --disable-nls ' >/dev/null +./configure --help | grep ' --disable-nls ' # Check that --enable-nls causes USE_NLS to be yes. ./configure --enable-nls -make check-USE_NLS-yes +$MAKE check-USE_NLS-yes -make distclean +$MAKE distclean # Check that --disable-nls causes USE_NLS to be no. ./configure --disable-nls -make check-USE_NLS-no +$MAKE check-USE_NLS-no + +: diff --git a/tests/pot-format-csharp1.test b/tests/pot-format-csharp1.test index 8c7f6c7d9..1daf13f68 100755 --- a/tests/pot-format-csharp1.test +++ b/tests/pot-format-csharp1.test @@ -16,7 +16,6 @@ # Check the creation of compiled message catalogs in C# format. -required='gzip' . ./defs || Exit 1 set -e @@ -125,18 +124,18 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir env $config_options $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make install" creates the expected .pot file, .po files # and .resources.dll files. # (They are created under $sourcedir, because the files are distributed. # Cf. the GNU standards, node "Makefile Basics".) - make install + $MAKE install test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -171,11 +170,11 @@ for builddir in . sub; do rm -f $sourcedir/posub/foo-bar.pot - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -191,33 +190,25 @@ for builddir in . sub; do # Check that the tarball contains posub/foo-bar-{de,fr}.{po,resources.dll} # but not the others, regardless whether LINGUAS was specified or not. gzip -d -c < pot-format-csharp1-1.0.tar.gz | tar tf - > filelist - grep '^pot-format-csharp1-1\.0/posub/foo-bar-de\.po$' filelist >/dev/null - grep '^pot-format-csharp1-1\.0/posub/de/foo-bar\.resources.dll$' filelist >/dev/null - grep '^pot-format-csharp1-1\.0/posub/foo-bar-fr_CA@latin\.po$' filelist >/dev/null - grep '^pot-format-csharp1-1\.0/posub/fr-CA-Latn/foo-bar\.resources.dll$' filelist >/dev/null - if grep '^pot-format-csharp1-1\.0/posub/foo-bar-es\.po$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-csharp1-1\.0/posub/es/foo-bar\.resources.dll$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-csharp1-1\.0/posub/foo-bar-de\.mo$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-csharp1-1\.0/posub/foo-bar-fr_CA@latin\.mo$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-csharp1-1\.0/posub/foo-bar-es\.mo$' filelist >/dev/null; then - exit 1 - fi + grep '^pot-format-csharp1-1\.0/posub/foo-bar-de\.po$' filelist + grep '^pot-format-csharp1-1\.0/posub/de/foo-bar\.resources\.dll$' filelist + grep '^pot-format-csharp1-1\.0/posub/foo-bar-fr_CA@latin\.po$' filelist + grep '^pot-format-csharp1-1\.0/posub/fr-CA-Latn/foo-bar\.resources\.dll$' filelist + grep '^pot-format-csharp1-1\.0/posub/foo-bar-es\.po$' filelist && Exit 1 + grep '^pot-format-csharp1-1\.0/posub/es/foo-bar\.resources\.dll$' filelist && Exit 1 + grep '^pot-format-csharp1-1\.0/posub/foo-bar-de\.mo$' filelist && Exit 1 + grep '^pot-format-csharp1-1\.0/posub/foo-bar-fr_CA@latin\.mo$' filelist && Exit 1 + grep '^pot-format-csharp1-1\.0/posub/foo-bar-es\.mo$' filelist && Exit 1 rm -f filelist # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done done + +: diff --git a/tests/pot-format-java1.test b/tests/pot-format-java1.test index 6a9259b43..e148d43b7 100755 --- a/tests/pot-format-java1.test +++ b/tests/pot-format-java1.test @@ -18,7 +18,6 @@ # FIXME: Resource names with a dash maybe don't work. If so, it should be # mentioned in the documentation. -required='gzip' . ./defs || Exit 1 set -e @@ -126,18 +125,18 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir env $config_options $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make install" creates the expected .pot file, .po files # and .properties files. # (They are created under $sourcedir, because the files are distributed. # Cf. the GNU standards, node "Makefile Basics".) - make install + $MAKE install test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -172,11 +171,11 @@ for builddir in . sub; do rm -f $sourcedir/posub/foo-bar.pot - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -192,33 +191,25 @@ for builddir in . sub; do # Check that the tarball contains posub/foo-bar-{de,fr}.{po,properties} # but not the others, regardless whether LINGUAS was specified or not. gzip -d -c < pot-format-java1-1.0.tar.gz | tar tf - > filelist - grep '^pot-format-java1-1\.0/posub/foo-bar-de\.po$' filelist >/dev/null - grep '^pot-format-java1-1\.0/posub/foo-bar_de\.properties$' filelist >/dev/null - grep '^pot-format-java1-1\.0/posub/foo-bar-fr\.po$' filelist >/dev/null - grep '^pot-format-java1-1\.0/posub/foo-bar_fr\.properties$' filelist >/dev/null - if grep '^pot-format-java1-1\.0/posub/foo-bar-es\.po$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-java1-1\.0/posub/foo-bar_es\.properties$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-java1-1\.0/posub/foo-bar-de\.mo$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-java1-1\.0/posub/foo-bar-fr\.mo$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-java1-1\.0/posub/foo-bar-es\.mo$' filelist >/dev/null; then - exit 1 - fi + grep '^pot-format-java1-1\.0/posub/foo-bar-de\.po$' filelist + grep '^pot-format-java1-1\.0/posub/foo-bar_de\.properties$' filelist + grep '^pot-format-java1-1\.0/posub/foo-bar-fr\.po$' filelist + grep '^pot-format-java1-1\.0/posub/foo-bar_fr\.properties$' filelist + grep '^pot-format-java1-1\.0/posub/foo-bar-es\.po$' filelist && Exit 1 + grep '^pot-format-java1-1\.0/posub/foo-bar_es\.properties$' filelist && Exit 1 + grep '^pot-format-java1-1\.0/posub/foo-bar-de\.mo$' filelist && Exit 1 + grep '^pot-format-java1-1\.0/posub/foo-bar-fr\.mo$' filelist && Exit 1 + grep '^pot-format-java1-1\.0/posub/foo-bar-es\.mo$' filelist && Exit 1 rm -f filelist # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done done + +: diff --git a/tests/pot-format-java2.test b/tests/pot-format-java2.test index e05d08ca7..ef60cf7fa 100755 --- a/tests/pot-format-java2.test +++ b/tests/pot-format-java2.test @@ -18,7 +18,6 @@ # FIXME: Class names with a dash probably don't work. If so, it should be # mentioned in the documentation. -required='gzip' . ./defs || Exit 1 set -e @@ -126,18 +125,18 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir env $config_options $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make install" creates the expected .pot file, .po files # and .class files. # (They are created under $sourcedir, because the files are distributed. # Cf. the GNU standards, node "Makefile Basics".) - make install + $MAKE install test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -172,11 +171,11 @@ for builddir in . sub; do rm -f $sourcedir/posub/foo-bar.pot - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -192,33 +191,25 @@ for builddir in . sub; do # Check that the tarball contains posub/foo-bar-{de,fr}.{po,class} but not # the others, regardless whether LINGUAS was specified or not. gzip -d -c < pot-format-java2-1.0.tar.gz | tar tf - > filelist - grep '^pot-format-java2-1\.0/posub/foo-bar-de\.po$' filelist >/dev/null - grep '^pot-format-java2-1\.0/posub/foo-bar_de\.class$' filelist >/dev/null - grep '^pot-format-java2-1\.0/posub/foo-bar-fr\.po$' filelist >/dev/null - grep '^pot-format-java2-1\.0/posub/foo-bar_fr\.class$' filelist >/dev/null - if grep '^pot-format-java2-1\.0/posub/foo-bar-es\.po$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-java2-1\.0/posub/foo-bar_es\.class$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-java2-1\.0/posub/foo-bar-de\.mo$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-java2-1\.0/posub/foo-bar-fr\.mo$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-java2-1\.0/posub/foo-bar-es\.mo$' filelist >/dev/null; then - exit 1 - fi + grep '^pot-format-java2-1\.0/posub/foo-bar-de\.po$' filelist + grep '^pot-format-java2-1\.0/posub/foo-bar_de\.class$' filelist + grep '^pot-format-java2-1\.0/posub/foo-bar-fr\.po$' filelist + grep '^pot-format-java2-1\.0/posub/foo-bar_fr\.class$' filelist + grep '^pot-format-java2-1\.0/posub/foo-bar-es\.po$' filelist && Exit 1 + grep '^pot-format-java2-1\.0/posub/foo-bar_es\.class$' filelist && Exit 1 + grep '^pot-format-java2-1\.0/posub/foo-bar-de\.mo$' filelist && Exit 1 + grep '^pot-format-java2-1\.0/posub/foo-bar-fr\.mo$' filelist && Exit 1 + grep '^pot-format-java2-1\.0/posub/foo-bar-es\.mo$' filelist && Exit 1 rm -f filelist # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done done + +: diff --git a/tests/pot-format-qt1.test b/tests/pot-format-qt1.test index 797a3472e..ca6da0bc8 100755 --- a/tests/pot-format-qt1.test +++ b/tests/pot-format-qt1.test @@ -150,18 +150,18 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir env $config_options $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make install" creates the expected .pot file, .po files # and .qm files. # (They are created under $sourcedir, because the files are distributed. # Cf. the GNU standards, node "Makefile Basics".) - make install + $MAKE install test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -194,11 +194,11 @@ for builddir in . sub; do rm -f $sourcedir/posub/foo-bar.pot - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -212,33 +212,25 @@ for builddir in . sub; do # Check that the tarball contains posub/foo-bar-{de,fr}.{po,qm} but not # the others, regardless whether LINGUAS was specified or not. gzip -d -c < pot-format-qt1-1.0.tar.gz | tar tf - > filelist - grep '^pot-format-qt1-1\.0/posub/foo-bar-de\.po$' filelist >/dev/null - grep '^pot-format-qt1-1\.0/posub/foo-bar-de\.qm$' filelist >/dev/null - grep '^pot-format-qt1-1\.0/posub/foo-bar-fr\.po$' filelist >/dev/null - grep '^pot-format-qt1-1\.0/posub/foo-bar-fr\.qm$' filelist >/dev/null - if grep '^pot-format-qt1-1\.0/posub/foo-bar-es\.po$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-qt1-1\.0/posub/foo-bar-es\.qm$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-qt1-1\.0/posub/foo-bar-de\.mo$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-qt1-1\.0/posub/foo-bar-fr\.mo$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-qt1-1\.0/posub/foo-bar-es\.mo$' filelist >/dev/null; then - exit 1 - fi + grep '^pot-format-qt1-1\.0/posub/foo-bar-de\.po$' filelist + grep '^pot-format-qt1-1\.0/posub/foo-bar-de\.qm$' filelist + grep '^pot-format-qt1-1\.0/posub/foo-bar-fr\.po$' filelist + grep '^pot-format-qt1-1\.0/posub/foo-bar-fr\.qm$' filelist + grep '^pot-format-qt1-1\.0/posub/foo-bar-es\.po$' filelist && Exit 1 + grep '^pot-format-qt1-1\.0/posub/foo-bar-es\.qm$' filelist && Exit 1 + grep '^pot-format-qt1-1\.0/posub/foo-bar-de\.mo$' filelist && Exit 1 + grep '^pot-format-qt1-1\.0/posub/foo-bar-fr\.mo$' filelist && Exit 1 + grep '^pot-format-qt1-1\.0/posub/foo-bar-es\.mo$' filelist && Exit 1 rm -f filelist # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done done + +: diff --git a/tests/pot-format-tcl1.test b/tests/pot-format-tcl1.test index 109245e04..284b1ce1b 100755 --- a/tests/pot-format-tcl1.test +++ b/tests/pot-format-tcl1.test @@ -16,7 +16,6 @@ # Check the creation of compiled message catalogs in Tcl format. -required='gzip' . ./defs || Exit 1 set -e @@ -121,18 +120,18 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir env $config_options $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make install" creates the expected .pot file, .po files # and .msg files. # (They are created under $sourcedir, because the files are distributed. # Cf. the GNU standards, node "Makefile Basics".) - make install + $MAKE install test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -167,11 +166,11 @@ for builddir in . sub; do rm -f $sourcedir/posub/foo-bar.pot - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -187,33 +186,25 @@ for builddir in . sub; do # Check that the tarball contains posub/foo-bar-{de,fr}.{po,msg} but not # the others, regardless whether LINGUAS was specified or not. gzip -d -c < pot-format-tcl1-1.0.tar.gz | tar tf - > filelist - grep '^pot-format-tcl1-1\.0/posub/foo-bar-de\.po$' filelist >/dev/null - grep '^pot-format-tcl1-1\.0/posub/foo-bar/de\.msg$' filelist >/dev/null - grep '^pot-format-tcl1-1\.0/posub/foo-bar-fr_CA\.po$' filelist >/dev/null - grep '^pot-format-tcl1-1\.0/posub/foo-bar/fr_ca\.msg$' filelist >/dev/null - if grep '^pot-format-tcl1-1\.0/posub/foo-bar-es\.po$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-tcl1-1\.0/posub/foo-bar/es\.msg$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-tcl1-1\.0/posub/foo-bar-de\.mo$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-tcl1-1\.0/posub/foo-bar-fr_CA\.mo$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-format-tcl1-1\.0/posub/foo-bar-es\.mo$' filelist >/dev/null; then - exit 1 - fi + grep '^pot-format-tcl1-1\.0/posub/foo-bar-de\.po$' filelist + grep '^pot-format-tcl1-1\.0/posub/foo-bar/de\.msg$' filelist + grep '^pot-format-tcl1-1\.0/posub/foo-bar-fr_CA\.po$' filelist + grep '^pot-format-tcl1-1\.0/posub/foo-bar/fr_ca\.msg$' filelist + grep '^pot-format-tcl1-1\.0/posub/foo-bar-es\.po$' filelist && Exit 1 + grep '^pot-format-tcl1-1\.0/posub/foo-bar/es\.msg$' filelist && Exit 1 + grep '^pot-format-tcl1-1\.0/posub/foo-bar-de\.mo$' filelist && Exit 1 + grep '^pot-format-tcl1-1\.0/posub/foo-bar-fr_CA\.mo$' filelist && Exit 1 + grep '^pot-format-tcl1-1\.0/posub/foo-bar-es\.mo$' filelist && Exit 1 rm -f filelist # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done done + +: diff --git a/tests/pot-linguas.test b/tests/pot-linguas.test index 428152b09..dd7bc9481 100755 --- a/tests/pot-linguas.test +++ b/tests/pot-linguas.test @@ -22,7 +22,6 @@ # FIXME: Should "make install" really update the PO files and MO files? # Current po/Makefile.in.in does not do it. -required='gzip' . ./defs || Exit 1 set -e @@ -132,7 +131,7 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir env $config_options $sourcedir/configure --prefix="$instdir" - make + $MAKE cat > $sourcedir/src/main.c << 'END' #include @@ -148,11 +147,11 @@ END # (They are created under $sourcedir, because the files are distributed. # Cf. the GNU standards, node "Makefile Basics".) - make install + $MAKE install test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -177,11 +176,11 @@ END rm -f $sourcedir/posub/foo-bar.pot - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -193,16 +192,12 @@ END # Check that the tarball contains posub/foo-bar-{de,fr}.{po,mo} but not # the others, regardless whether LINGUAS was specified or not. gzip -d -c < pot-linguas-1.0.tar.gz | tar tf - > filelist - grep '^pot-linguas-1\.0/posub/foo-bar-de\.po$' filelist >/dev/null - grep '^pot-linguas-1\.0/posub/foo-bar-de\.mo$' filelist >/dev/null - grep '^pot-linguas-1\.0/posub/foo-bar-fr\.po$' filelist >/dev/null - grep '^pot-linguas-1\.0/posub/foo-bar-fr\.mo$' filelist >/dev/null - if grep '^pot-linguas-1\.0/posub/foo-bar-es\.po$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-linguas-1\.0/posub/foo-bar-es\.mo$' filelist >/dev/null; then - exit 1 - fi + grep '^pot-linguas-1\.0/posub/foo-bar-de\.po$' filelist + grep '^pot-linguas-1\.0/posub/foo-bar-de\.mo$' filelist + grep '^pot-linguas-1\.0/posub/foo-bar-fr\.po$' filelist + grep '^pot-linguas-1\.0/posub/foo-bar-fr\.mo$' filelist + grep '^pot-linguas-1\.0/posub/foo-bar-es\.po$' filelist && Exit 1 + grep '^pot-linguas-1\.0/posub/foo-bar-es\.mo$' filelist && Exit 1 rm -f filelist # Try modifying a source file. @@ -224,30 +219,31 @@ END cp -p $sourcedir/posub/foo-bar-fr.mo $sourcedir/posub/foo-bar-fr.mobak cp -p $sourcedir/posub/foo-bar-es.po $sourcedir/posub/foo-bar-es.pobak cp -p $sourcedir/posub/foo-bar-es.mo $sourcedir/posub/foo-bar-es.mobak - make + $MAKE diff $sourcedir/posub/foo-bar.potbak $sourcedir/posub/foo-bar.pot - cmp $sourcedir/posub/foo-bar-de.pobak $sourcedir/posub/foo-bar-de.po >/dev/null - cmp $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo >/dev/null - cmp $sourcedir/posub/foo-bar-fr.pobak $sourcedir/posub/foo-bar-fr.po >/dev/null - cmp $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo >/dev/null - cmp $sourcedir/posub/foo-bar-es.pobak $sourcedir/posub/foo-bar-es.po >/dev/null - cmp $sourcedir/posub/foo-bar-es.mobak $sourcedir/posub/foo-bar-es.mo >/dev/null + cmp $sourcedir/posub/foo-bar-de.pobak $sourcedir/posub/foo-bar-de.po + cmp $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo + cmp $sourcedir/posub/foo-bar-fr.pobak $sourcedir/posub/foo-bar-fr.po + cmp $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo + cmp $sourcedir/posub/foo-bar-es.pobak $sourcedir/posub/foo-bar-es.po + cmp $sourcedir/posub/foo-bar-es.mobak $sourcedir/posub/foo-bar-es.mo # Check that "make install" updates the POT file, the PO files, and the # MO files listed in the _LINGUAS variable, regardless whether LINGUAS # was specified or not. - make install - cat $sourcedir/posub/foo-bar.pot | grep great >/dev/null - cat $sourcedir/posub/foo-bar-de.po | grep great >/dev/null - if cmp $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo >/dev/null; then - exit 1 - fi - cat $sourcedir/posub/foo-bar-fr.po | grep great >/dev/null - if cmp $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo >/dev/null; then - exit 1 - fi - cmp $sourcedir/posub/foo-bar-es.pobak $sourcedir/posub/foo-bar-es.po >/dev/null - cmp $sourcedir/posub/foo-bar-es.mobak $sourcedir/posub/foo-bar-es.mo >/dev/null + $MAKE install + grep great $sourcedir/posub/foo-bar.pot + # NOTE: This is *not* a useless use of cat. The *.po files can contain + # non-ASCII characters, which might cause problems with some `grep' + # programs. BSD `grep' works from a pipe, but not a seekable file. + # GNU or BSD `grep -a' works on files, but is not portable. + cat $sourcedir/posub/foo-bar-de.po | grep great + cmp $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo && Exit 1 + # NOTE: This is *not* a useless use of cat. See comments above. + cat $sourcedir/posub/foo-bar-fr.po | grep great + cmp $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo && Exit 1 + cmp $sourcedir/posub/foo-bar-es.pobak $sourcedir/posub/foo-bar-es.po + cmp $sourcedir/posub/foo-bar-es.mobak $sourcedir/posub/foo-bar-es.mo # Check that "make dist" updates the POT file, the PO files, and the # MO files listed in the _LINGUAS variable, regardless whether LINGUAS @@ -257,30 +253,31 @@ END cp -p $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo cp -p $sourcedir/posub/foo-bar-fr.pobak $sourcedir/posub/foo-bar-fr.po cp -p $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo - make dist - cat $sourcedir/posub/foo-bar.pot | grep great >/dev/null - cat $sourcedir/posub/foo-bar-de.po | grep great >/dev/null - if cmp $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo >/dev/null; then - exit 1 - fi - cat $sourcedir/posub/foo-bar-fr.po | grep great >/dev/null - if cmp $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo >/dev/null; then - exit 1 - fi - cmp $sourcedir/posub/foo-bar-es.pobak $sourcedir/posub/foo-bar-es.po >/dev/null - cmp $sourcedir/posub/foo-bar-es.mobak $sourcedir/posub/foo-bar-es.mo >/dev/null + $MAKE dist + grep great $sourcedir/posub/foo-bar.pot + # NOTE: This is *not* a useless use of cat. See comments above. + cat $sourcedir/posub/foo-bar-de.po | grep great + cmp $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo && Exit 1 + # NOTE: This is *not* a useless use of cat. See comments above. + cat $sourcedir/posub/foo-bar-fr.po | grep great + cmp $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo && Exit 1 + cmp $sourcedir/posub/foo-bar-es.pobak $sourcedir/posub/foo-bar-es.po + cmp $sourcedir/posub/foo-bar-es.mobak $sourcedir/posub/foo-bar-es.mo # Check that the updated PO files contain 'previous msgid' fields. - cat $sourcedir/posub/foo-bar-de.po | grep '^#| msgid "Hello, world\.\\n"$' >/dev/null - cat $sourcedir/posub/foo-bar-fr.po | grep '^#| msgid "Hello, world\.\\n"$' >/dev/null + # NOTE: This is *not* a useless use of cat. See comments above. + cat $sourcedir/posub/foo-bar-de.po | grep '^#| msgid "Hello, world\.\\n"$' + cat $sourcedir/posub/foo-bar-fr.po | grep '^#| msgid "Hello, world\.\\n"$' # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - rm -f $sourcedir/posub/foo-bar.potbak $sourcedir/posub/*.pobak $sourcedir/posub/*.mobak - make distclean + rm -f $sourcedir/posub/foo-bar.potbak $sourcedir/posub/*.[mp]obak + $MAKE distclean rm -rf "$instdir" cd $sourcedir done done + +: diff --git a/tests/pot-macro-warn.test b/tests/pot-macro-warn.test index 41fb35f52..caecab42f 100755 --- a/tests/pot-macro-warn.test +++ b/tests/pot-macro-warn.test @@ -50,5 +50,6 @@ END $ACLOCAL # Check that there is no warning any more. +$AUTOMAKE -Werror -AUTOMAKE_run 0 -Werror +: diff --git a/tests/pot-msgidbugs.test b/tests/pot-msgidbugs.test index 1bf533419..3b3b954ee 100755 --- a/tests/pot-msgidbugs.test +++ b/tests/pot-msgidbugs.test @@ -85,13 +85,13 @@ for builddir in . sub1; do instdir="`pwd`/instdir" cd $builddir $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make dist" creates the expected .pot file. # (It is created under $sourcedir, because the .pot file is distributed. # Cf. the GNU standards, node "Makefile Basics".) - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot @@ -100,10 +100,10 @@ for builddir in . sub1; do rm -f actual # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done @@ -148,25 +148,27 @@ for builddir in . sub2; do instdir="`pwd`/instdir" cd $builddir $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make dist" creates the expected .pot file. # (It is created under $sourcedir, because the .pot file is distributed. # Cf. the GNU standards, node "Makefile Basics".) - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done + +: diff --git a/tests/pot-no-linguas.test b/tests/pot-no-linguas.test index f64588ade..86039d82d 100755 --- a/tests/pot-no-linguas.test +++ b/tests/pot-no-linguas.test @@ -102,7 +102,7 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir $sourcedir/configure --prefix="$instdir" - make + $MAKE cat > $sourcedir/src/main.c << 'END' #include @@ -117,11 +117,11 @@ END # (It is created under $sourcedir, because the .pot file is distributed. # Cf. the GNU standards, node "Makefile Basics".) - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -129,11 +129,11 @@ END # Check that "make install" creates the expected .pot file. - make install + $MAKE install test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -153,24 +153,26 @@ END # Check that "make" does not rebuild the POT file. cp -p $sourcedir/posub/foo-bar.pot $sourcedir/posub/foo-bar.potbak - make + $MAKE diff $sourcedir/posub/foo-bar.potbak $sourcedir/posub/foo-bar.pot # Check that "make dist" updates the POT file. - make dist - cat $sourcedir/posub/foo-bar.pot | grep great >/dev/null + $MAKE dist + grep great $sourcedir/posub/foo-bar.pot # Check that "make install" updates the POT file. cp -p $sourcedir/posub/foo-bar.potbak $sourcedir/posub/foo-bar.pot - make install - cat $sourcedir/posub/foo-bar.pot | grep great >/dev/null + $MAKE install + grep great $sourcedir/posub/foo-bar.pot # Sanity check. - make distcheck + $MAKE distcheck # Clean up. rm -f $sourcedir/posub/foo-bar.potbak - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done + +: diff --git a/tests/pot-noinst.test b/tests/pot-noinst.test index 9c1c9225a..047a3282d 100755 --- a/tests/pot-noinst.test +++ b/tests/pot-noinst.test @@ -19,7 +19,6 @@ # configure time has no effect. Otherwise, everything is the same as in the # pot-linguas test. -required='gzip' . ./defs || Exit 1 set -e @@ -129,7 +128,7 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir env $config_options $sourcedir/configure --prefix="$instdir" - make + $MAKE cat > $sourcedir/src/main.c << 'END' #include @@ -143,7 +142,7 @@ END # Check that "make install" does not create the .pot file and .mo files. # (They are not needed for installation.) - make install + $MAKE install test ! -f $sourcedir/posub/foo-bar.pot test ! -f $sourcedir/posub/foo-bar-de.mo @@ -159,11 +158,11 @@ END # (They are created under $sourcedir, because the files are distributed. # Cf. the GNU standards, node "Makefile Basics".) - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -175,16 +174,12 @@ END # Check that the tarball contains posub/foo-bar-{de,fr}.{po,mo} but not # the others, regardless whether LINGUAS was specified or not. gzip -d -c < pot-noinst-1.0.tar.gz | tar tf - > filelist - grep '^pot-noinst-1\.0/posub/foo-bar-de\.po$' filelist >/dev/null - grep '^pot-noinst-1\.0/posub/foo-bar-de\.mo$' filelist >/dev/null - grep '^pot-noinst-1\.0/posub/foo-bar-fr\.po$' filelist >/dev/null - grep '^pot-noinst-1\.0/posub/foo-bar-fr\.mo$' filelist >/dev/null - if grep '^pot-noinst-1\.0/posub/foo-bar-es\.po$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-noinst-1\.0/posub/foo-bar-es\.mo$' filelist >/dev/null; then - exit 1 - fi + grep '^pot-noinst-1\.0/posub/foo-bar-de\.po$' filelist + grep '^pot-noinst-1\.0/posub/foo-bar-de\.mo$' filelist + grep '^pot-noinst-1\.0/posub/foo-bar-fr\.po$' filelist + grep '^pot-noinst-1\.0/posub/foo-bar-fr\.mo$' filelist + grep '^pot-noinst-1\.0/posub/foo-bar-es\.po$' filelist && Exit 1 + grep '^pot-noinst-1\.0/posub/foo-bar-es\.mo$' filelist && Exit 1 rm -f filelist # Try modifying a source file. @@ -206,53 +201,57 @@ END cp -p $sourcedir/posub/foo-bar-fr.mo $sourcedir/posub/foo-bar-fr.mobak cp -p $sourcedir/posub/foo-bar-es.po $sourcedir/posub/foo-bar-es.pobak cp -p $sourcedir/posub/foo-bar-es.mo $sourcedir/posub/foo-bar-es.mobak - make + $MAKE diff $sourcedir/posub/foo-bar.potbak $sourcedir/posub/foo-bar.pot - cmp $sourcedir/posub/foo-bar-de.pobak $sourcedir/posub/foo-bar-de.po >/dev/null - cmp $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo >/dev/null - cmp $sourcedir/posub/foo-bar-fr.pobak $sourcedir/posub/foo-bar-fr.po >/dev/null - cmp $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo >/dev/null - cmp $sourcedir/posub/foo-bar-es.pobak $sourcedir/posub/foo-bar-es.po >/dev/null - cmp $sourcedir/posub/foo-bar-es.mobak $sourcedir/posub/foo-bar-es.mo >/dev/null + cmp $sourcedir/posub/foo-bar-de.pobak $sourcedir/posub/foo-bar-de.po + cmp $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo + cmp $sourcedir/posub/foo-bar-fr.pobak $sourcedir/posub/foo-bar-fr.po + cmp $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo + cmp $sourcedir/posub/foo-bar-es.pobak $sourcedir/posub/foo-bar-es.po + cmp $sourcedir/posub/foo-bar-es.mobak $sourcedir/posub/foo-bar-es.mo # Check that "make install" does not update the POT file, the PO files, # and the MO files. - make install + $MAKE install diff $sourcedir/posub/foo-bar.potbak $sourcedir/posub/foo-bar.pot - cmp $sourcedir/posub/foo-bar-de.pobak $sourcedir/posub/foo-bar-de.po >/dev/null - cmp $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo >/dev/null - cmp $sourcedir/posub/foo-bar-fr.pobak $sourcedir/posub/foo-bar-fr.po >/dev/null - cmp $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo >/dev/null - cmp $sourcedir/posub/foo-bar-es.pobak $sourcedir/posub/foo-bar-es.po >/dev/null - cmp $sourcedir/posub/foo-bar-es.mobak $sourcedir/posub/foo-bar-es.mo >/dev/null + cmp $sourcedir/posub/foo-bar-de.pobak $sourcedir/posub/foo-bar-de.po + cmp $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo + cmp $sourcedir/posub/foo-bar-fr.pobak $sourcedir/posub/foo-bar-fr.po + cmp $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo + cmp $sourcedir/posub/foo-bar-es.pobak $sourcedir/posub/foo-bar-es.po + cmp $sourcedir/posub/foo-bar-es.mobak $sourcedir/posub/foo-bar-es.mo # Check that "make dist" updates the POT file, the PO files, and the # MO files listed in the _LINGUAS variable, regardless whether LINGUAS # was specified or not. - make dist - cat $sourcedir/posub/foo-bar.pot | grep great >/dev/null - cat $sourcedir/posub/foo-bar-de.po | grep great >/dev/null - if cmp $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo >/dev/null; then - exit 1 - fi - cat $sourcedir/posub/foo-bar-fr.po | grep great >/dev/null - if cmp $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo >/dev/null; then - exit 1 - fi - cmp $sourcedir/posub/foo-bar-es.pobak $sourcedir/posub/foo-bar-es.po >/dev/null - cmp $sourcedir/posub/foo-bar-es.mobak $sourcedir/posub/foo-bar-es.mo >/dev/null + $MAKE dist + grep great $sourcedir/posub/foo-bar.pot + # NOTE: This is *not* a useless use of cat. The *.po files can contain + # non-ASCII characters, which might cause problems with some `grep' + # programs. BSD `grep' works from a pipe, but not a seekable file. + # GNU or BSD `grep -a' works on files, but is not portable. + cat $sourcedir/posub/foo-bar-de.po | grep great + cmp $sourcedir/posub/foo-bar-de.mobak $sourcedir/posub/foo-bar-de.mo && Exit 1 + # NOTE: This is *not* a useless use of cat. See comments above. + cat $sourcedir/posub/foo-bar-fr.po | grep great + cmp $sourcedir/posub/foo-bar-fr.mobak $sourcedir/posub/foo-bar-fr.mo && Exit 1 + cmp $sourcedir/posub/foo-bar-es.pobak $sourcedir/posub/foo-bar-es.po + cmp $sourcedir/posub/foo-bar-es.mobak $sourcedir/posub/foo-bar-es.mo # Check that the updated PO files contain 'previous msgid' fields. - cat $sourcedir/posub/foo-bar-de.po | grep '^#| msgid "Hello, world\.\\n"$' >/dev/null - cat $sourcedir/posub/foo-bar-fr.po | grep '^#| msgid "Hello, world\.\\n"$' >/dev/null + # NOTE: This is *not* a useless use of cat. See comments above. + cat $sourcedir/posub/foo-bar-de.po | grep '^#| msgid "Hello, world\.\\n"$' + cat $sourcedir/posub/foo-bar-fr.po | grep '^#| msgid "Hello, world\.\\n"$' # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - rm -f $sourcedir/posub/foo-bar.potbak $sourcedir/posub/*.pobak $sourcedir/posub/*.mobak - make distclean + rm -f $sourcedir/posub/foo-bar.potbak $sourcedir/posub/*.[mp]obak + $MAKE distclean rm -rf "$instdir" cd $sourcedir done done + +: diff --git a/tests/pot-override1.test b/tests/pot-override1.test index 6389f545e..bf51b8802 100755 --- a/tests/pot-override1.test +++ b/tests/pot-override1.test @@ -79,7 +79,7 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir $sourcedir/configure --prefix="$instdir" - make + $MAKE cat > $sourcedir/src/main.c << 'END' #include @@ -94,7 +94,7 @@ END # (It is created under $sourcedir, because the .pot file is distributed. # Cf. the GNU standards, node "Makefile Basics".) - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot @@ -104,7 +104,7 @@ END # Check that "make install" creates the expected .pot file. - make install + $MAKE install test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot @@ -122,24 +122,26 @@ END # Check that "make" does not rebuild the POT file. cp -p $sourcedir/posub/foo-bar.pot $sourcedir/posub/foo-bar.potbak - make + $MAKE diff $sourcedir/posub/foo-bar.potbak $sourcedir/posub/foo-bar.pot # Check that "make dist" updates the POT file. - make dist - cat $sourcedir/posub/foo-bar.pot | grep great >/dev/null + $MAKE dist + grep great $sourcedir/posub/foo-bar.pot # Check that "make install" updates the POT file. cp -p $sourcedir/posub/foo-bar.potbak $sourcedir/posub/foo-bar.pot - make install - cat $sourcedir/posub/foo-bar.pot | grep great >/dev/null + $MAKE install + grep great $sourcedir/posub/foo-bar.pot # Sanity check. - make distcheck + $MAKE distcheck # Clean up. rm -f $sourcedir/posub/foo-bar.potbak - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done + +: diff --git a/tests/pot-samedir.test b/tests/pot-samedir.test index 900be4fe1..6c321a96a 100755 --- a/tests/pot-samedir.test +++ b/tests/pot-samedir.test @@ -16,7 +16,6 @@ # Check that different .pot files in the same directory don't collide. -required='gzip' . ./defs || Exit 1 set -e @@ -158,23 +157,23 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make install" creates the expected .pot files and .mo files. # (They are created under $sourcedir, because the files are distributed. # Cf. the GNU standards, node "Makefile Basics".) - make install + $MAKE install test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected1 rm -f actual test -f $sourcedir/posub/foo-baz.pot test $builddir = '.' || test ! -f posub/foo-baz.pot - cat $sourcedir/posub/foo-baz.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-baz.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected2 rm -f actual @@ -192,42 +191,35 @@ for builddir in . sub; do test -f "$instdir"/share/locale/it/LC_MESSAGES/foo-baz.mo test ! -f "$instdir"/share/locale/fr/LC_MESSAGES/foo-baz.mo # Check that the two .mo files for the same language are different. - if cmp "$instdir"/share/locale/de/LC_MESSAGES/foo-bar.mo "$instdir"/share/locale/de/LC_MESSAGES/foo-baz.mo >/dev/null; then - exit 1 - fi + cmp "$instdir"/share/locale/de/LC_MESSAGES/foo-bar.mo \ + "$instdir"/share/locale/de/LC_MESSAGES/foo-baz.mo && Exit 1 - make dist + $MAKE dist # Check that the tarball contains the .po files and .mo files for the # specified languages, but not more. gzip -d -c < pot-samedir-1.0.tar.gz | tar tf - > filelist - grep '^pot-samedir-1\.0/posub/foo-bar-de\.po$' filelist >/dev/null - grep '^pot-samedir-1\.0/posub/foo-bar-de\.mo$' filelist >/dev/null - grep '^pot-samedir-1\.0/posub/foo-bar-fr\.po$' filelist >/dev/null - grep '^pot-samedir-1\.0/posub/foo-bar-fr\.mo$' filelist >/dev/null - if grep '^pot-samedir-1\.0/posub/foo-bar-it\.po$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-samedir-1\.0/posub/foo-bar-it\.mo$' filelist >/dev/null; then - exit 1 - fi - grep '^pot-samedir-1\.0/posub/foo-baz-de\.po$' filelist >/dev/null - grep '^pot-samedir-1\.0/posub/foo-baz-de\.mo$' filelist >/dev/null - grep '^pot-samedir-1\.0/posub/foo-baz-it\.po$' filelist >/dev/null - grep '^pot-samedir-1\.0/posub/foo-baz-it\.mo$' filelist >/dev/null - if grep '^pot-samedir-1\.0/posub/foo-baz-fr\.po$' filelist >/dev/null; then - exit 1 - fi - if grep '^pot-samedir-1\.0/posub/foo-baz-fr\.mo$' filelist >/dev/null; then - exit 1 - fi + grep '^pot-samedir-1\.0/posub/foo-bar-de\.po$' filelist + grep '^pot-samedir-1\.0/posub/foo-bar-de\.mo$' filelist + grep '^pot-samedir-1\.0/posub/foo-bar-fr\.po$' filelist + grep '^pot-samedir-1\.0/posub/foo-bar-fr\.mo$' filelist + grep '^pot-samedir-1\.0/posub/foo-bar-it\.po$' filelist && Exit 1 + grep '^pot-samedir-1\.0/posub/foo-bar-it\.mo$' filelist && Exit 1 + grep '^pot-samedir-1\.0/posub/foo-baz-de\.po$' filelist + grep '^pot-samedir-1\.0/posub/foo-baz-de\.mo$' filelist + grep '^pot-samedir-1\.0/posub/foo-baz-it\.po$' filelist + grep '^pot-samedir-1\.0/posub/foo-baz-it\.mo$' filelist + grep '^pot-samedir-1\.0/posub/foo-baz-fr\.po$' filelist && Exit 1 + grep '^pot-samedir-1\.0/posub/foo-baz-fr\.mo$' filelist && Exit 1 rm -f filelist # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done + +: diff --git a/tests/pot-topsrcdir.test b/tests/pot-topsrcdir.test index 7236eb543..442ea5635 100755 --- a/tests/pot-topsrcdir.test +++ b/tests/pot-topsrcdir.test @@ -20,7 +20,6 @@ # FIXME: Should "make install" really update the PO files and MO files? # Current po/Makefile.in.in does not do it. -required='gzip' . ./defs || Exit 1 set -e @@ -129,7 +128,7 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir env $config_options $sourcedir/configure --prefix="$instdir" - make + $MAKE cat > $sourcedir/src/main.c << 'END' #include @@ -145,11 +144,11 @@ END # (They are created under $sourcedir, because the files are distributed. # Cf. the GNU standards, node "Makefile Basics".) - make install + $MAKE install test -f $sourcedir/foo-bar.pot test $builddir = '.' || test ! -f foo-bar.pot - cat $sourcedir/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -174,11 +173,11 @@ END rm -f $sourcedir/foo-bar.pot - make dist + $MAKE dist test -f $sourcedir/foo-bar.pot test $builddir = '.' || test ! -f foo-bar.pot - cat $sourcedir/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual @@ -190,16 +189,12 @@ END # Check that the tarball contains foo-bar-{de,fr}.{po,mo} but not # the others, regardless whether LINGUAS was specified or not. gzip -d -c < pot-linguas-1.0.tar.gz | tar tf - > filelist - grep '^foo-bar-de\.po$' filelist >/dev/null - grep '^foo-bar-de\.mo$' filelist >/dev/null - grep '^foo-bar-fr\.po$' filelist >/dev/null - grep '^foo-bar-fr\.mo$' filelist >/dev/null - if grep '^foo-bar-es\.po$' filelist >/dev/null; then - exit 1 - fi - if grep '^foo-bar-es\.mo$' filelist >/dev/null; then - exit 1 - fi + grep '^foo-bar-de\.po$' filelist + grep '^foo-bar-de\.mo$' filelist + grep '^foo-bar-fr\.po$' filelist + grep '^foo-bar-fr\.mo$' filelist + grep '^foo-bar-es\.po$' filelist && Exit 1 + grep '^foo-bar-es\.mo$' filelist && Exit 1 rm -f filelist # Try modifying a source file. @@ -221,30 +216,31 @@ END cp -p $sourcedir/foo-bar-fr.mo $sourcedir/foo-bar-fr.mobak cp -p $sourcedir/foo-bar-es.po $sourcedir/foo-bar-es.pobak cp -p $sourcedir/foo-bar-es.mo $sourcedir/foo-bar-es.mobak - make + $MAKE diff $sourcedir/foo-bar.potbak $sourcedir/foo-bar.pot - cmp $sourcedir/foo-bar-de.pobak $sourcedir/foo-bar-de.po >/dev/null - cmp $sourcedir/foo-bar-de.mobak $sourcedir/foo-bar-de.mo >/dev/null - cmp $sourcedir/foo-bar-fr.pobak $sourcedir/foo-bar-fr.po >/dev/null - cmp $sourcedir/foo-bar-fr.mobak $sourcedir/foo-bar-fr.mo >/dev/null - cmp $sourcedir/foo-bar-es.pobak $sourcedir/foo-bar-es.po >/dev/null - cmp $sourcedir/foo-bar-es.mobak $sourcedir/foo-bar-es.mo >/dev/null + cmp $sourcedir/foo-bar-de.pobak $sourcedir/foo-bar-de.po + cmp $sourcedir/foo-bar-de.mobak $sourcedir/foo-bar-de.mo + cmp $sourcedir/foo-bar-fr.pobak $sourcedir/foo-bar-fr.po + cmp $sourcedir/foo-bar-fr.mobak $sourcedir/foo-bar-fr.mo + cmp $sourcedir/foo-bar-es.pobak $sourcedir/foo-bar-es.po + cmp $sourcedir/foo-bar-es.mobak $sourcedir/foo-bar-es.mo # Check that "make install" updates the POT file, the PO files, and the # MO files listed in the _LINGUAS variable, regardless whether LINGUAS # was specified or not. - make install - cat $sourcedir/foo-bar.pot | grep great >/dev/null - cat $sourcedir/foo-bar-de.po | grep great >/dev/null - if cmp $sourcedir/foo-bar-de.mobak $sourcedir/foo-bar-de.mo >/dev/null; then - exit 1 - fi - cat $sourcedir/foo-bar-fr.po | grep great >/dev/null - if cmp $sourcedir/foo-bar-fr.mobak $sourcedir/foo-bar-fr.mo >/dev/null; then - exit 1 - fi - cmp $sourcedir/foo-bar-es.pobak $sourcedir/foo-bar-es.po >/dev/null - cmp $sourcedir/foo-bar-es.mobak $sourcedir/foo-bar-es.mo >/dev/null + $MAKE install + grep great $sourcedir/foo-bar.pot + # NOTE: This is *not* a useless use of cat. The *.po files can contain + # non-ASCII characters, which might cause problems with some `grep' + # programs. BSD `grep' works from a pipe, but not a seekable file. + # GNU or BSD `grep -a' works on files, but is not portable. + cat $sourcedir/foo-bar-de.po | grep great + cmp $sourcedir/foo-bar-de.mobak $sourcedir/foo-bar-de.mo && Exit 1 + # NOTE: This is *not* a useless use of cat. See comments above. + cat $sourcedir/foo-bar-fr.po | grep great + cmp $sourcedir/foo-bar-fr.mobak $sourcedir/foo-bar-fr.mo && Exit 1 + cmp $sourcedir/foo-bar-es.pobak $sourcedir/foo-bar-es.po + cmp $sourcedir/foo-bar-es.mobak $sourcedir/foo-bar-es.mo # Check that "make dist" updates the POT file, the PO files, and the # MO files listed in the _LINGUAS variable, regardless whether LINGUAS @@ -254,30 +250,31 @@ END cp -p $sourcedir/foo-bar-de.mobak $sourcedir/foo-bar-de.mo cp -p $sourcedir/foo-bar-fr.pobak $sourcedir/foo-bar-fr.po cp -p $sourcedir/foo-bar-fr.mobak $sourcedir/foo-bar-fr.mo - make dist - cat $sourcedir/foo-bar.pot | grep great >/dev/null - cat $sourcedir/foo-bar-de.po | grep great >/dev/null - if cmp $sourcedir/foo-bar-de.mobak $sourcedir/foo-bar-de.mo >/dev/null; then - exit 1 - fi - cat $sourcedir/foo-bar-fr.po | grep great >/dev/null - if cmp $sourcedir/foo-bar-fr.mobak $sourcedir/foo-bar-fr.mo >/dev/null; then - exit 1 - fi - cmp $sourcedir/foo-bar-es.pobak $sourcedir/foo-bar-es.po >/dev/null - cmp $sourcedir/foo-bar-es.mobak $sourcedir/foo-bar-es.mo >/dev/null + $MAKE dist + grep great $sourcedir/foo-bar.pot + # NOTE: This is *not* a useless use of cat. See comments above. + cat $sourcedir/foo-bar-de.po | grep great + cmp $sourcedir/foo-bar-de.mobak $sourcedir/foo-bar-de.mo && Exit 1 + # NOTE: This is *not* a useless use of cat. See comments above. + cat $sourcedir/foo-bar-fr.po | grep great + cmp $sourcedir/foo-bar-fr.mobak $sourcedir/foo-bar-fr.mo && Exit 1 + cmp $sourcedir/foo-bar-es.pobak $sourcedir/foo-bar-es.po + cmp $sourcedir/foo-bar-es.mobak $sourcedir/foo-bar-es.mo # Check that the updated PO files contain 'previous msgid' fields. - cat $sourcedir/foo-bar-de.po | grep '^#| msgid "Hello, world\.\\n"$' >/dev/null - cat $sourcedir/foo-bar-fr.po | grep '^#| msgid "Hello, world\.\\n"$' >/dev/null + # NOTE: This is *not* a useless use of cat. See comments above. + cat $sourcedir/foo-bar-de.po | grep '^#| msgid "Hello, world\.\\n"$' + cat $sourcedir/foo-bar-fr.po | grep '^#| msgid "Hello, world\.\\n"$' # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - rm -f $sourcedir/foo-bar.potbak $sourcedir/*.pobak $sourcedir/*.mobak - make distclean + rm -f $sourcedir/foo-bar.potbak $sourcedir/*.[mp]obak + $MAKE distclean rm -rf "$instdir" cd $sourcedir done done + +: diff --git a/tests/pot-warn1.test b/tests/pot-warn1.test index 2c79fb697..d69f3f392 100755 --- a/tests/pot-warn1.test +++ b/tests/pot-warn1.test @@ -47,5 +47,6 @@ posub_foo_bar_pot_SOURCES = END # Check that there is no warning any more. +$AUTOMAKE -Werror -AUTOMAKE_run 0 -Werror +: diff --git a/tests/pot-warn2.test b/tests/pot-warn2.test index 605655a7e..724930b39 100755 --- a/tests/pot-warn2.test +++ b/tests/pot-warn2.test @@ -46,4 +46,6 @@ END # Check that there is no warning any more. -AUTOMAKE_run 0 -Werror +$AUTOMAKE -Werror + +: diff --git a/tests/pot-xgettext1.test b/tests/pot-xgettext1.test index d6cffcc46..740968576 100755 --- a/tests/pot-xgettext1.test +++ b/tests/pot-xgettext1.test @@ -82,25 +82,27 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make dist" creates the expected .pot file. # (It is created under $sourcedir, because the .pot file is distributed. # Cf. the GNU standards, node "Makefile Basics".) - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done + +: diff --git a/tests/pot-xgettext2.test b/tests/pot-xgettext2.test index 0c6e32651..d7b81b0e9 100755 --- a/tests/pot-xgettext2.test +++ b/tests/pot-xgettext2.test @@ -82,25 +82,27 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make dist" creates the expected .pot file. # (It is created under $sourcedir, because the .pot file is distributed. # Cf. the GNU standards, node "Makefile Basics".) - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done + +: diff --git a/tests/pot-xgettext3.test b/tests/pot-xgettext3.test index 285646f50..65d2deaca 100755 --- a/tests/pot-xgettext3.test +++ b/tests/pot-xgettext3.test @@ -97,25 +97,27 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make dist" creates the expected .pot file. # (It is created under $sourcedir, because the .pot file is distributed. # Cf. the GNU standards, node "Makefile Basics".) - make dist + $MAKE dist test -f $sourcedir/posub/foo-bar.pot test $builddir = '.' || test ! -f posub/foo-bar.pot - cat $sourcedir/posub/foo-bar.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/posub/foo-bar.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done + +: diff --git a/tests/pot-xgettext4.test b/tests/pot-xgettext4.test index a170525bd..6fd1cd4e0 100755 --- a/tests/pot-xgettext4.test +++ b/tests/pot-xgettext4.test @@ -92,25 +92,27 @@ for builddir in . sub; do instdir="`pwd`/instdir" cd $builddir $sourcedir/configure --prefix="$instdir" - make + $MAKE # Check that "make dist" creates the expected .pot file. # (It is created under $sourcedir, because the .pot file is distributed. # Cf. the GNU standards, node "Makefile Basics".) - make dist + $MAKE dist test -f $sourcedir/maude.pot test $builddir = '.' || test ! -f maude.pot - cat $sourcedir/maude.pot | grep -v 'POT-Creation-Date' | LC_ALL=C tr -d '\r' > actual + grep -v 'POT-Creation-Date' $sourcedir/maude.pot | LC_ALL=C tr -d '\r' > actual diff actual $sourcedir/expected rm -f actual # Sanity check. - make distcheck + $MAKE distcheck # Clean up. - make distclean + $MAKE distclean rm -rf "$instdir" cd $sourcedir done + +: