*** empty log message ***
authorJim Blandy <jimb@red-bean.com>
Thu, 24 Dec 1992 06:48:09 +0000 (06:48 +0000)
committerJim Blandy <jimb@red-bean.com>
Thu, 24 Dec 1992 06:48:09 +0000 (06:48 +0000)
configure.in
regex.h

index f0fc780250952567ae8f309b32c9a2c70e72e4db..2491a2036d02b030a8f555cbd8e1aa4b00e6ac6a 100644 (file)
@@ -1,6 +1,9 @@
 dnl Process this file with autoconf to produce a configure script.
 AC_INIT(regex.c)
 
+dnl Because regex may or may not be used with Autoconf, we need to know.
+AC_DEFINE(USING_AUTOCONF)
+
 AC_PROG_CC
 AC_PROG_INSTALL
 
diff --git a/regex.h b/regex.h
index 8217fc0ea01892322835aa6604c85311d9e4059c..ea701231c20dabaee197c8404581c8fd96b811e0 100644 (file)
--- a/regex.h
+++ b/regex.h
@@ -393,12 +393,25 @@ typedef struct
    already been defined, as by Autoconf's AC_CONST, don't do anything.  */
 
 #if __STDC__
+
 #define _RE_ARGS(args) args
+
 #else /* not __STDC__ */
+
 #define _RE_ARGS(args) ()
-#if !const && !HAVE_CONST
+
+#ifndef USING_AUTOCONF
+
+#ifndef HAVE_CONST
 #define const
+#else
+#if !HAVE_CONST
+#define const
+#endif
 #endif
+
+#endif /* not USING_AUTOCONF */
+
 #endif /* not __STDC__ */
 
 /* Sets the current default syntax to SYNTAX, and return the old syntax.