| 20 |
dnl digits for minor numbers less than 10. There are unlikely to be |
dnl digits for minor numbers less than 10. There are unlikely to be |
| 21 |
dnl that many releases anyway. |
dnl that many releases anyway. |
| 22 |
|
|
| 23 |
PCRE_MAJOR=5 |
PCRE_MAJOR=6 |
| 24 |
PCRE_MINOR=0 |
PCRE_MINOR=0 |
| 25 |
PCRE_DATE=13-Sep-2004 |
PCRE_DATE=07-Jun-2005 |
| 26 |
PCRE_VERSION=${PCRE_MAJOR}.${PCRE_MINOR} |
PCRE_VERSION=${PCRE_MAJOR}.${PCRE_MINOR} |
| 27 |
|
|
| 28 |
dnl Default values for miscellaneous macros |
dnl Default values for miscellaneous macros |
| 34 |
|
|
| 35 |
PCRE_LIB_VERSION=0:1:0 |
PCRE_LIB_VERSION=0:1:0 |
| 36 |
PCRE_POSIXLIB_VERSION=0:0:0 |
PCRE_POSIXLIB_VERSION=0:0:0 |
| 37 |
|
PCRE_CPPLIB_VERSION=0:0:0 |
| 38 |
|
|
| 39 |
dnl Checks for programs. |
dnl Checks for programs. |
| 40 |
|
|
| 41 |
AC_PROG_CC |
AC_PROG_CC |
| 42 |
|
|
| 43 |
|
dnl For the C++ wrapper libpcrecpp. |
| 44 |
|
|
| 45 |
|
AC_PROG_CXX |
| 46 |
|
|
| 47 |
|
if test -n "$ac_cv_prog_ac_ct_CXX"; then |
| 48 |
|
MAYBE_CPP_TARGETS='$(CPP_TARGETS)' |
| 49 |
|
fi |
| 50 |
|
echo "Maybe-cpp-targets: '$ac_cv_prog_CXX' '$MAYBE_CPP_TARGETS'" #!! |
| 51 |
|
AC_SUBST(MAYBE_CPP_TARGETS) |
| 52 |
|
|
| 53 |
dnl The icc compiler has the same options as gcc, so let the rest of the |
dnl The icc compiler has the same options as gcc, so let the rest of the |
| 54 |
dnl configure script think it has gcc when setting up dnl options etc. |
dnl configure script think it has gcc when setting up dnl options etc. |
| 55 |
dnl This is a nasty hack which no longer seems necessary with the update |
dnl This is a nasty hack which no longer seems necessary with the update |
| 71 |
dnl run "configure". |
dnl run "configure". |
| 72 |
|
|
| 73 |
CC_FOR_BUILD=${CC_FOR_BUILD:-'$(CC)'} |
CC_FOR_BUILD=${CC_FOR_BUILD:-'$(CC)'} |
| 74 |
|
CXX_FOR_BUILD=${CXX_FOR_BUILD:-'$(CXX)'} |
| 75 |
CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD:-'$(CFLAGS)'} |
CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD:-'$(CFLAGS)'} |
| 76 |
|
CPPFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD:-'$(CPPFLAGS)'} |
| 77 |
|
CXXFLAGS_FOR_BUILD=${CXXFLAGS_FOR_BUILD:-'$(CXXFLAGS)'} |
| 78 |
BUILD_EXEEXT=${BUILD_EXEEXT:-'$(EXEEXT)'} |
BUILD_EXEEXT=${BUILD_EXEEXT:-'$(EXEEXT)'} |
| 79 |
BUILD_OBJEXT=${BUILD_OBJEXT:-'$(OBJEXT)'} |
BUILD_OBJEXT=${BUILD_OBJEXT:-'$(OBJEXT)'} |
| 80 |
|
|
| 83 |
AC_HEADER_STDC |
AC_HEADER_STDC |
| 84 |
AC_CHECK_HEADERS(limits.h) |
AC_CHECK_HEADERS(limits.h) |
| 85 |
|
|
| 86 |
|
dnl These are C++ header files |
| 87 |
|
|
| 88 |
|
AC_LANG_SAVE |
| 89 |
|
AC_LANG_CPLUSPLUS |
| 90 |
|
dnl I could be more clever here, given I'm doing AC_SUBST with this |
| 91 |
|
dnl (eg set a var to be the name of the include file I want). But I'm not |
| 92 |
|
dnl so it's easy to change back to 'regular' autoconf vars if we needed to. |
| 93 |
|
AC_CHECK_HEADERS(bits/type_traits.h, [pcre_has_bits_type_traits="1"], |
| 94 |
|
[pcre_has_bits_type_traits="0"]) |
| 95 |
|
AC_CHECK_HEADERS(type_traits.h, [pcre_has_type_traits="1"], |
| 96 |
|
[pcre_has_type_traits="0"]) |
| 97 |
|
dnl Using AC_SUBST eliminates the need to include config.h in a public .h file |
| 98 |
|
AC_SUBST(pcre_has_bits_type_traits) |
| 99 |
|
AC_SUBST(pcre_has_type_traits) |
| 100 |
|
AC_LANG_RESTORE |
| 101 |
|
|
| 102 |
dnl Checks for typedefs, structures, and compiler characteristics. |
dnl Checks for typedefs, structures, and compiler characteristics. |
| 103 |
|
|
| 104 |
AC_C_CONST |
AC_C_CONST |
| 105 |
AC_TYPE_SIZE_T |
AC_TYPE_SIZE_T |
| 106 |
|
|
| 107 |
|
AC_CHECK_TYPES([long long], [pcre_has_long_long="1"], [pcre_has_long_long="0"]) |
| 108 |
|
AC_CHECK_TYPES([unsigned long long], [pcre_has_ulong_long="1"], [pcre_has_ulong_long="0"]) |
| 109 |
|
AC_SUBST(pcre_has_long_long) |
| 110 |
|
AC_SUBST(pcre_has_ulong_long) |
| 111 |
|
|
| 112 |
dnl Checks for library functions. |
dnl Checks for library functions. |
| 113 |
|
|
| 114 |
AC_CHECK_FUNCS(bcopy memmove strerror) |
AC_CHECK_FUNCS(bcopy memmove strerror strtoq strtoll) |
| 115 |
|
|
| 116 |
dnl Handle --enable-utf8 |
dnl Handle --enable-utf8 |
| 117 |
|
|
| 192 |
MATCH_LIMIT=-DMATCH_LIMIT=$withval |
MATCH_LIMIT=-DMATCH_LIMIT=$withval |
| 193 |
) |
) |
| 194 |
|
|
|
dnl Now arrange to build libtool |
|
|
|
|
|
AC_PROG_LIBTOOL |
|
|
|
|
| 195 |
dnl Unicode character property support implies UTF-8 support |
dnl Unicode character property support implies UTF-8 support |
| 196 |
|
|
| 197 |
if test "$UCP" != "" ; then |
if test "$UCP" != "" ; then |
| 203 |
AC_SUBST(BUILD_EXEEXT) |
AC_SUBST(BUILD_EXEEXT) |
| 204 |
AC_SUBST(BUILD_OBJEXT) |
AC_SUBST(BUILD_OBJEXT) |
| 205 |
AC_SUBST(CC_FOR_BUILD) |
AC_SUBST(CC_FOR_BUILD) |
| 206 |
|
AC_SUBST(CXX_FOR_BUILD) |
| 207 |
AC_SUBST(CFLAGS_FOR_BUILD) |
AC_SUBST(CFLAGS_FOR_BUILD) |
| 208 |
|
AC_SUBST(CXXFLAGS_FOR_BUILD) |
| 209 |
AC_SUBST(EBCDIC) |
AC_SUBST(EBCDIC) |
| 210 |
AC_SUBST(HAVE_MEMMOVE) |
AC_SUBST(HAVE_MEMMOVE) |
| 211 |
AC_SUBST(HAVE_STRERROR) |
AC_SUBST(HAVE_STRERROR) |
| 219 |
AC_SUBST(PCRE_VERSION) |
AC_SUBST(PCRE_VERSION) |
| 220 |
AC_SUBST(PCRE_LIB_VERSION) |
AC_SUBST(PCRE_LIB_VERSION) |
| 221 |
AC_SUBST(PCRE_POSIXLIB_VERSION) |
AC_SUBST(PCRE_POSIXLIB_VERSION) |
| 222 |
|
AC_SUBST(PCRE_CPPLIB_VERSION) |
| 223 |
AC_SUBST(POSIX_MALLOC_THRESHOLD) |
AC_SUBST(POSIX_MALLOC_THRESHOLD) |
| 224 |
AC_SUBST(UCP) |
AC_SUBST(UCP) |
| 225 |
AC_SUBST(UTF8) |
AC_SUBST(UTF8) |
| 257 |
fi |
fi |
| 258 |
|
|
| 259 |
dnl This must be last; it determines what files are written as well as config.h |
dnl This must be last; it determines what files are written as well as config.h |
| 260 |
AC_OUTPUT(Makefile pcre.h:pcre.in pcre-config:pcre-config.in libpcre.pc:libpcre.pc.in RunTest:RunTest.in,[chmod a+x RunTest pcre-config]) |
AC_OUTPUT(Makefile pcre.h:pcre.in pcre-config:pcre-config.in libpcre.pc:libpcre.pc.in pcrecpp.h:pcrecpp.h.in pcre_stringpiece.h:pcre_stringpiece.h.in RunGrepTest:RunGrepTest.in RunTest:RunTest.in,[chmod a+x RunTest RunGrepTest pcre-config]) |