summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorPaolo Bonzini <bonzini@gnu.org>2004-11-03 08:24:20 +0000
committerPaolo Bonzini <bonzini@gnu.org>2008-01-09 16:10:46 +0100
commitfdf570a5964e25f83529efc095ae797e35554a18 (patch)
tree8fa6e2e6642c149bd095bd574335cbe1da743911 /configure.ac
parent8219cef2eb7e825d414a46639a3c1123ba0f7fa5 (diff)
downloadsed-fdf570a5964e25f83529efc095ae797e35554a18.tar.gz
always enable regex tests when included regex is used
2004-11-03 Paolo Bonzini <bonzini@gnu * bug-regex11.c: Improve portability. * bug-regex12.c: Improve portability. * bug-regex13.c: Improve portability. * bug-regex14.c: Improve portability. * bug-regex21.c: Improve portability. * bug-regex9.c: Improve portability. * tst-boost.c: Improve portability. * tst-pcre.c: Improve portability. * tst-regex.c: Improve portability. * tst-rxspencer.c: Improve portability. git-archimport-id: bonzini@gnu.org--2004b/sed--stable--4.1--patch-9
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac18
1 files changed, 11 insertions, 7 deletions
diff --git a/configure.ac b/configure.ac
index e08c9a3..2a866b8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -43,7 +43,8 @@ int main()
AC_HEADER_DIRENT
AC_CHECK_HEADERS(io.h limits.h locale.h stdarg.h alloca.h stddef.h errno.h \
- wchar.h wctype.h sys/file.h, [], [], [AC_INCLUDES_DEFAULT])
+ wchar.h wctype.h sys/file.h mcheck.h, [], [],
+ [AC_INCLUDES_DEFAULT])
AC_C_CONST
AC_TYPE_SIZE_T
AC_CHECK_TYPE(ssize_t, int)
@@ -74,10 +75,6 @@ AC_ARG_WITH(included-regex,
[ --with-included-regex use included regex matcher (default=yes)], ,
with_included_regex=yes)
-AC_ARG_ENABLE(regex-tests,
-[ --enable-regex-tests enable regex matcher regression tests (default=no)], ,
-enable_regex_tests=no)
-
if test "x$with_included_regex" = xno; then
AC_CHECK_HEADERS(regex.h)
AC_CHECK_LIB(regex, re_search)
@@ -88,15 +85,22 @@ if test "x$with_included_regex" = xno; then
fi
fi
-if test "x$with_included_regex" = xno; then
+AC_ARG_ENABLE(regex-tests,
+[ --enable-regex-tests enable regex matcher regression tests (default=no)],
+[if test "x$with_included_regex" = xno; then
enable_regex_tests=no
-fi
+fi],
+enable_regex_tests=$with_included_regex)
AM_CONDITIONAL(TEST_REGEX, test "x$enable_regex_tests" != xno)
if test "x$with_included_regex" != xno; then
AC_CONFIG_LINKS(lib/regex.h:lib/regex_.h)
AC_LIBOBJ(regex)
fi
+if test "x$enable_regex_tests" = xyes; then
+ AC_DEFINE_UNQUOTED(_REGEX_RE_COMP, 1,
+ [Include BSD functions in regex, used by the testsuite])
+fi
AC_ARG_ENABLE(html,
[ --enable-html build HTML manual (default=no)], ,