]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
tests: Add test for Debian bug#764580
authorDaiki Ueno <ueno@gnu.org>
Fri, 10 Oct 2014 03:56:42 +0000 (12:56 +0900)
committerDaiki Ueno <ueno@gnu.org>
Fri, 10 Oct 2014 03:57:07 +0000 (12:57 +0900)
* gettext-tools/tests/autopoint-2: Check if m4_assert is properly
redefined while tracing.

gettext-tools/tests/ChangeLog
gettext-tools/tests/autopoint-2

index 22fdc63c0b593537a37ddcecdd334c1f7aece8ed..07fc0f861b787c3a1ad7ce5915fb628a545e530e 100644 (file)
@@ -1,3 +1,9 @@
+2014-10-10  Daiki Ueno  <ueno@gnu.org>
+
+       tests: Add test for Debian bug#764580
+       * autopoint-2: Check if m4_assert is properly redefined while
+       tracing.
+
 2014-10-08  Daiki Ueno  <ueno@gnu.org>
 
        tests: Improve test coverage of C and Vala scanners
index 30cc4e0be8d050d6c6719df4b8759fd51121ba97..fe6ff9c6899fe23c7fe6fd90955a8b144e3cb1e0 100755 (executable)
@@ -136,3 +136,35 @@ test -f m4/po.m4 || exit 1
 test -f po/Makefile.in.in || exit 1
 
 rm -fr m4 po
+
+# Check for certain built-in macros are not in effect when tracing:
+# <https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=764580>
+cat <<EOF >configure.ac
+AC_INIT
+AC_CONFIG_SRCDIR(hello.c)
+
+dnl m4_shiftn internally calls m4_assert, which is disabled by autopoint
+m4_define([_gt_recurse],
+[m4_ifblank([\$1], , [_gt_recurse(m4_shiftn(1, \$@))])])
+_gt_recurse([a], [b], , [c])
+
+AC_PROG_CC
+AM_GNU_GETTEXT([external])
+AM_GNU_GETTEXT_VERSION([$required_gettext_version])
+
+AC_CONFIG_FILES([Makefile])
+AC_CONFIG_FILES([po/Makefile.in])
+AC_OUTPUT
+EOF
+
+$gettext_datadir/autopoint >/dev/null 2>autopoint.err
+test $? = 0 || { cat autopoint.err; exit 1; }
+
+test ! -d intl || exit 1
+test -d m4 || exit 1
+test -d po || exit 1
+
+test -f m4/po.m4 || exit 1
+test -f po/Makefile.in.in || exit 1
+
+rm -fr m4 po