summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwlestes <wlestes>2008-12-28 15:46:20 +0000
committerwlestes <wlestes>2008-12-28 15:46:20 +0000
commit133dd1bd70d30813d6669a91da88740474dd3ddd (patch)
tree9e568b26e5c2e9f9583faac30ac5097a6744d7f1
parent618eccaf6b3dab2ca95bfdc24fdcc6698ef1db27 (diff)
downloadflex-133dd1bd70d30813d6669a91da88740474dd3ddd.tar.gz
check for regex.h; resolves bug #2337486
-rw-r--r--configure.in3
-rw-r--r--flexdef.h2
2 files changed, 4 insertions, 1 deletions
diff --git a/configure.in b/configure.in
index 969c515..c03e258 100644
--- a/configure.in
+++ b/configure.in
@@ -84,7 +84,8 @@ fi
AC_FUNC_ALLOCA
AC_HEADER_STDC
AC_HEADER_SYS_WAIT
-AC_CHECK_HEADERS([inttypes.h libintl.h limits.h locale.h malloc.h netinet/in.h stddef.h stdlib.h string.h strings.h unistd.h])
+AC_CHECK_HEADERS([inttypes.h libintl.h limits.h locale.h malloc.h
+netinet/in.h stddef.h stdlib.h string.h strings.h unistd.h regex.h])
AC_CHECK_LIB(m, log10)
# The test test-pthread uses libpthread, so we check for it here, but
diff --git a/flexdef.h b/flexdef.h
index d038952..7282711 100644
--- a/flexdef.h
+++ b/flexdef.h
@@ -91,7 +91,9 @@ char *alloca ();
#define true 1
#define false 0
#endif
+#ifdef HAVE_REGEX_H
#include <regex.h>
+#endif
#include "flexint.h"
/* We use gettext. So, when we write strings which should be translated, we mark them with _() */