fix to AM_WITH_REGEX
authorTom Tromey <tromey@redhat.com>
Wed, 4 Dec 1996 08:28:28 +0000 (08:28 +0000)
committerTom Tromey <tromey@redhat.com>
Wed, 4 Dec 1996 08:28:28 +0000 (08:28 +0000)
ChangeLog
m4/regex.m4

index f8c112d..700adc9 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,13 @@
 Wed Dec  4 00:41:23 1996  Tom Tromey  <tromey@cygnus.com>
 
+       * m4/regex.m4 (AM_WITH_REGEX): Check for GNU regex in libc.  From
+       Andreas Schwab.
+
+       * automake.in (parse_arguments): Removed --strictness.
+       (handle_dist_worker): Don't use --strictness.
+       (handle_configure): Ditto.
+       (initialize_global_constants): Don't mention --strictness.
+
        * automake.in (handle_merge_targets): Use all-recursive-am instead
        of all-recursive-hack.  The latter is ugly, according to Joel
        Weber.
index 3d15c75..007b166 100644 (file)
@@ -23,7 +23,12 @@ AC_ARG_WITH(regex,
 if test -n "$am_with_regex"; then
   AC_MSG_RESULT(regex)
   AC_DEFINE(WITH_REGEX)
-  LIBOBJS="$LIBOBJS regex.o"
+  AC_CACHE_CHECK([for GNU regex in libc], am_cv_gnu_regex,
+    AC_TRY_LINK([], [extern int re_max_failures; re_max_failures = 1],
+               am_cv_gnu_regex=yes, am_cv_gnu_regex=no))
+  if test $am_cv_gnu_regex = no; then
+    LIBOBJS="$LIBOBJS regex.o"
+  fi
 else
   AC_MSG_RESULT(rx)
   AC_CHECK_FUNC(re_rx_search, , [LIBOBJS="$LIBOBJS rx.o"])