version 1.1, 2012/02/21 23:05:51
|
version 1.1.1.5, 2014/06/15 19:46:03
|
Line 9 dnl The PCRE_PRERELEASE feature is for identifying rel
|
Line 9 dnl The PCRE_PRERELEASE feature is for identifying rel
|
dnl be defined as -RC2, for example. For real releases, it should be empty. |
dnl be defined as -RC2, for example. For real releases, it should be empty. |
|
|
m4_define(pcre_major, [8]) |
m4_define(pcre_major, [8]) |
m4_define(pcre_minor, [21]) | m4_define(pcre_minor, [34]) |
m4_define(pcre_prerelease, []) |
m4_define(pcre_prerelease, []) |
m4_define(pcre_date, [2011-12-12]) | m4_define(pcre_date, [2013-12-15]) |
|
|
|
# NOTE: The CMakeLists.txt file searches for the above variables in the first |
|
# 50 lines of this file. Please update that if the variables above are moved. |
|
|
# Libtool shared library interface versions (current:revision:age) |
# Libtool shared library interface versions (current:revision:age) |
m4_define(libpcre_version, [0:1:0]) | m4_define(libpcre_version, [3:2:2]) |
m4_define(libpcreposix_version, [0:0:0]) | m4_define(libpcre16_version, [2:2:2]) |
| m4_define(libpcre32_version, [0:2:0]) |
| m4_define(libpcreposix_version, [0:2:0]) |
m4_define(libpcrecpp_version, [0:0:0]) |
m4_define(libpcrecpp_version, [0:0:0]) |
|
|
AC_PREREQ(2.57) |
AC_PREREQ(2.57) |
AC_INIT(PCRE, pcre_major.pcre_minor[]pcre_prerelease, , pcre) |
AC_INIT(PCRE, pcre_major.pcre_minor[]pcre_prerelease, , pcre) |
AC_CONFIG_SRCDIR([pcre.h.in]) |
AC_CONFIG_SRCDIR([pcre.h.in]) |
AM_INIT_AUTOMAKE([dist-bzip2 dist-zip]) |
AM_INIT_AUTOMAKE([dist-bzip2 dist-zip]) |
|
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) |
AC_CONFIG_HEADERS(config.h) |
AC_CONFIG_HEADERS(config.h) |
|
|
|
# This is a new thing required to stop a warning from automake 1.12 |
|
m4_ifdef([AM_PROG_AR], [AM_PROG_AR]) |
|
|
# This was added at the suggestion of libtoolize (03-Jan-10) |
# This was added at the suggestion of libtoolize (03-Jan-10) |
AC_CONFIG_MACRO_DIR([m4]) |
AC_CONFIG_MACRO_DIR([m4]) |
|
|
Line 42 remember_set_CXXFLAGS="$CXXFLAGS"
|
Line 51 remember_set_CXXFLAGS="$CXXFLAGS"
|
|
|
AC_PROG_CC |
AC_PROG_CC |
AC_PROG_CXX |
AC_PROG_CXX |
|
AM_PROG_CC_C_O |
|
|
if test "x$remember_set_CFLAGS" = "x" |
if test "x$remember_set_CFLAGS" = "x" |
then |
then |
Line 79 AC_LIBTOOL_WIN32_DLL
|
Line 89 AC_LIBTOOL_WIN32_DLL
|
LT_INIT |
LT_INIT |
AC_PROG_LN_S |
AC_PROG_LN_S |
|
|
|
# Check for GCC visibility feature |
|
|
|
PCRE_VISIBILITY |
|
|
|
# Versioning |
|
|
PCRE_MAJOR="pcre_major" |
PCRE_MAJOR="pcre_major" |
PCRE_MINOR="pcre_minor" |
PCRE_MINOR="pcre_minor" |
PCRE_PRERELEASE="pcre_prerelease" |
PCRE_PRERELEASE="pcre_prerelease" |
Line 104 then
|
Line 120 then
|
htmldir='${docdir}/html' |
htmldir='${docdir}/html' |
fi |
fi |
|
|
|
# Handle --disable-pcre8 (enabled by default) |
|
AC_ARG_ENABLE(pcre8, |
|
AS_HELP_STRING([--disable-pcre8], |
|
[disable 8 bit character support]), |
|
, enable_pcre8=unset) |
|
AC_SUBST(enable_pcre8) |
|
|
|
# Handle --enable-pcre16 (disabled by default) |
|
AC_ARG_ENABLE(pcre16, |
|
AS_HELP_STRING([--enable-pcre16], |
|
[enable 16 bit character support]), |
|
, enable_pcre16=unset) |
|
AC_SUBST(enable_pcre16) |
|
|
|
# Handle --enable-pcre32 (disabled by default) |
|
AC_ARG_ENABLE(pcre32, |
|
AS_HELP_STRING([--enable-pcre32], |
|
[enable 32 bit character support]), |
|
, enable_pcre32=unset) |
|
AC_SUBST(enable_pcre32) |
|
|
# Handle --disable-cpp. The substitution of enable_cpp is needed for use in |
# Handle --disable-cpp. The substitution of enable_cpp is needed for use in |
# pcre-config. |
# pcre-config. |
AC_ARG_ENABLE(cpp, |
AC_ARG_ENABLE(cpp, |
AS_HELP_STRING([--disable-cpp], |
AS_HELP_STRING([--disable-cpp], |
[disable C++ support]), |
[disable C++ support]), |
, enable_cpp=yes) | , enable_cpp=unset) |
AC_SUBST(enable_cpp) |
AC_SUBST(enable_cpp) |
|
|
# Handle --enable-jit (disabled by default) |
# Handle --enable-jit (disabled by default) |
Line 133 AC_ARG_ENABLE(rebuild-chartables,
|
Line 170 AC_ARG_ENABLE(rebuild-chartables,
|
# Handle --enable-utf8 (disabled by default) |
# Handle --enable-utf8 (disabled by default) |
AC_ARG_ENABLE(utf8, |
AC_ARG_ENABLE(utf8, |
AS_HELP_STRING([--enable-utf8], |
AS_HELP_STRING([--enable-utf8], |
[enable UTF-8 support (incompatible with --enable-ebcdic)]), | [another name for --enable-utf. Kept only for compatibility reasons]), |
, enable_utf8=unset) |
, enable_utf8=unset) |
|
|
|
# Handle --enable-utf (disabled by default) |
|
AC_ARG_ENABLE(utf, |
|
AS_HELP_STRING([--enable-utf], |
|
[enable UTF-8/16/32 support (incompatible with --enable-ebcdic)]), |
|
, enable_utf=unset) |
|
|
# Handle --enable-unicode-properties |
# Handle --enable-unicode-properties |
AC_ARG_ENABLE(unicode-properties, |
AC_ARG_ENABLE(unicode-properties, |
AS_HELP_STRING([--enable-unicode-properties], |
AS_HELP_STRING([--enable-unicode-properties], |
[enable Unicode properties support (implies --enable-utf8)]), | [enable Unicode properties support (implies --enable-utf)]), |
, enable_unicode_properties=no) |
, enable_unicode_properties=no) |
|
|
# Handle --enable-newline=NL | # Handle newline options |
dnl AC_ARG_ENABLE(newline, | |
dnl AS_HELP_STRING([--enable-newline=NL], | |
dnl [use NL as newline (lf, cr, crlf, anycrlf, any; default=lf)]), | |
dnl , enable_newline=lf) | |
| |
# Separate newline options | |
ac_pcre_newline=lf |
ac_pcre_newline=lf |
AC_ARG_ENABLE(newline-is-cr, |
AC_ARG_ENABLE(newline-is-cr, |
AS_HELP_STRING([--enable-newline-is-cr], |
AS_HELP_STRING([--enable-newline-is-cr], |
Line 181 AC_ARG_ENABLE(bsr-anycrlf,
|
Line 218 AC_ARG_ENABLE(bsr-anycrlf,
|
# Handle --enable-ebcdic |
# Handle --enable-ebcdic |
AC_ARG_ENABLE(ebcdic, |
AC_ARG_ENABLE(ebcdic, |
AS_HELP_STRING([--enable-ebcdic], |
AS_HELP_STRING([--enable-ebcdic], |
[assume EBCDIC coding rather than ASCII; incompatible with --enable-utf8; use only in (uncommon) EBCDIC environments; it implies --enable-rebuild-chartables]), | [assume EBCDIC coding rather than ASCII; incompatible with --enable-utf; use only in (uncommon) EBCDIC environments; it implies --enable-rebuild-chartables]), |
, enable_ebcdic=no) |
, enable_ebcdic=no) |
|
|
|
# Handle --enable-ebcdic-nl25 |
|
AC_ARG_ENABLE(ebcdic-nl25, |
|
AS_HELP_STRING([--enable-ebcdic-nl25], |
|
[set EBCDIC code for NL to 0x25 instead of 0x15; it implies --enable-ebcdic]), |
|
, enable_ebcdic_nl25=no) |
|
|
# Handle --disable-stack-for-recursion |
# Handle --disable-stack-for-recursion |
AC_ARG_ENABLE(stack-for-recursion, |
AC_ARG_ENABLE(stack-for-recursion, |
AS_HELP_STRING([--disable-stack-for-recursion], |
AS_HELP_STRING([--disable-stack-for-recursion], |
Line 208 AC_ARG_WITH(pcregrep-bufsize,
|
Line 251 AC_ARG_WITH(pcregrep-bufsize,
|
[pcregrep buffer size (default=20480)]), |
[pcregrep buffer size (default=20480)]), |
, with_pcregrep_bufsize=20480) |
, with_pcregrep_bufsize=20480) |
|
|
|
# Handle --enable-pcretest-libedit |
|
AC_ARG_ENABLE(pcretest-libedit, |
|
AS_HELP_STRING([--enable-pcretest-libedit], |
|
[link pcretest with libedit]), |
|
, enable_pcretest_libedit=no) |
|
|
# Handle --enable-pcretest-libreadline |
# Handle --enable-pcretest-libreadline |
AC_ARG_ENABLE(pcretest-libreadline, |
AC_ARG_ENABLE(pcretest-libreadline, |
AS_HELP_STRING([--enable-pcretest-libreadline], |
AS_HELP_STRING([--enable-pcretest-libreadline], |
Line 226 AC_ARG_WITH(link-size,
|
Line 275 AC_ARG_WITH(link-size,
|
[internal link size (2, 3, or 4 allowed; default=2)]), |
[internal link size (2, 3, or 4 allowed; default=2)]), |
, with_link_size=2) |
, with_link_size=2) |
|
|
|
# Handle --with-parens-nest-limit=N |
|
AC_ARG_WITH(parens-nest-limit, |
|
AS_HELP_STRING([--with-parens-nest-limit=N], |
|
[nested parentheses limit (default=250)]), |
|
, with_parens_nest_limit=250) |
|
|
# Handle --with-match-limit=N |
# Handle --with-match-limit=N |
AC_ARG_WITH(match-limit, |
AC_ARG_WITH(match-limit, |
AS_HELP_STRING([--with-match-limit=N], |
AS_HELP_STRING([--with-match-limit=N], |
Line 245 AC_ARG_WITH(match-limit-recursion,
|
Line 300 AC_ARG_WITH(match-limit-recursion,
|
[default limit on internal recursion (default=MATCH_LIMIT)]), |
[default limit on internal recursion (default=MATCH_LIMIT)]), |
, with_match_limit_recursion=MATCH_LIMIT) |
, with_match_limit_recursion=MATCH_LIMIT) |
|
|
# Make sure that if enable_unicode_properties was set, that UTF-8 support | # Handle --enable-valgrind |
# is enabled. | AC_ARG_ENABLE(valgrind, |
# | AS_HELP_STRING([--enable-valgrind], |
| [valgrind support]), |
| , enable_valgrind=no) |
| |
| # Enable code coverage reports using gcov |
| AC_ARG_ENABLE(coverage, |
| AS_HELP_STRING([--enable-coverage], |
| [enable code coverage reports using gcov]), |
| , enable_coverage=no) |
| |
| # Copy enable_utf8 value to enable_utf for compatibility reasons |
| if test "x$enable_utf8" != "xunset" |
| then |
| if test "x$enable_utf" != "xunset" |
| then |
| AC_MSG_ERROR([--enable/disable-utf8 is kept only for compatibility reasons and its value is copied to --enable/disable-utf. Newer code must use --enable/disable-utf alone.]) |
| fi |
| enable_utf=$enable_utf8 |
| fi |
| |
| # Set the default value for pcre8 |
| if test "x$enable_pcre8" = "xunset" |
| then |
| enable_pcre8=yes |
| fi |
| |
| # Set the default value for pcre16 |
| if test "x$enable_pcre16" = "xunset" |
| then |
| enable_pcre16=no |
| fi |
| |
| # Set the default value for pcre32 |
| if test "x$enable_pcre32" = "xunset" |
| then |
| enable_pcre32=no |
| fi |
| |
| # Make sure enable_pcre8 or enable_pcre16 was set |
| if test "x$enable_pcre8$enable_pcre16$enable_pcre32" = "xnonono" |
| then |
| AC_MSG_ERROR([At least one of 8, 16 or 32 bit pcre library must be enabled]) |
| fi |
| |
| # Make sure that if enable_unicode_properties was set, that UTF support is enabled. |
if test "x$enable_unicode_properties" = "xyes" |
if test "x$enable_unicode_properties" = "xyes" |
then |
then |
if test "x$enable_utf8" = "xno" | if test "x$enable_utf" = "xno" |
then |
then |
AC_MSG_ERROR([support for Unicode properties requires UTF-8 support]) | AC_MSG_ERROR([support for Unicode properties requires UTF-8/16/32 support]) |
fi |
fi |
enable_utf8=yes | enable_utf=yes |
fi |
fi |
|
|
if test "x$enable_utf8" = "xunset" | # enable_utf is disabled by default. |
| if test "x$enable_utf" = "xunset" |
then |
then |
enable_utf8=no | enable_utf=no |
fi |
fi |
|
|
# Make sure that if enable_ebcdic is set, rebuild_chartables is also enabled. | # enable_cpp copies the value of enable_pcre8 by default |
# Also check that UTF-8 support is not requested, because PCRE cannot handle | if test "x$enable_cpp" = "xunset" |
# EBCDIC and UTF-8 in the same build. To do so it would need to use different | |
# character constants depending on the mode. | |
# | |
if test "x$enable_ebcdic" = "xyes" | |
then |
then |
enable_rebuild_chartables=yes | enable_cpp=$enable_pcre8 |
if test "x$enable_utf8" = "xyes" | fi |
| |
| # Make sure that if enable_cpp was set, that enable_pcre8 support is enabled |
| if test "x$enable_cpp" = "xyes" |
| then |
| if test "x$enable_pcre8" = "xno" |
then |
then |
AC_MSG_ERROR([support for EBCDIC and UTF-8 cannot be enabled at the same time]) | AC_MSG_ERROR([C++ library requires pcre library with 8 bit characters]) |
fi |
fi |
fi |
fi |
|
|
# Convert the newline identifier into the appropriate integer value. | # Convert the newline identifier into the appropriate integer value. The first |
| # three are ASCII values 0x0a, 0x0d, and 0x0d0a, but if EBCDIC is enabled, they |
| # are changed below. |
| |
case "$enable_newline" in |
case "$enable_newline" in |
lf) ac_pcre_newline_value=10 ;; |
lf) ac_pcre_newline_value=10 ;; |
cr) ac_pcre_newline_value=13 ;; |
cr) ac_pcre_newline_value=13 ;; |
Line 288 case "$enable_newline" in
|
Line 392 case "$enable_newline" in
|
;; |
;; |
esac |
esac |
|
|
|
# --enable-ebcdic-nl25 implies --enable-ebcdic |
|
if test "x$enable_ebcdic_nl25" = "xyes"; then |
|
enable_ebcdic=yes |
|
fi |
|
|
|
# Make sure that if enable_ebcdic is set, rebuild_chartables is also enabled, |
|
# and the newline value is adjusted appropriately (CR is still 13, but LF is |
|
# 21 or 37). Also check that UTF support is not requested, because PCRE cannot |
|
# handle EBCDIC and UTF in the same build. To do so it would need to use |
|
# different character constants depending on the mode. |
|
# |
|
if test "x$enable_ebcdic" = "xyes"; then |
|
enable_rebuild_chartables=yes |
|
|
|
if test "x$enable_utf" = "xyes"; then |
|
AC_MSG_ERROR([support for EBCDIC and UTF-8/16/32 cannot be enabled at the same time]) |
|
fi |
|
|
|
if test "x$enable_ebcdic_nl25" = "xno"; then |
|
case "$ac_pcre_newline_value" in |
|
10) ac_pcre_newline_value=21 ;; |
|
3338) ac_pcre_newline_value=3349 ;; |
|
esac |
|
else |
|
case "$ac_pcre_newline_value" in |
|
10) ac_pcre_newline_value=37 ;; |
|
3338) ac_pcre_newline_value=3365 ;; |
|
esac |
|
fi |
|
fi |
|
|
# Check argument to --with-link-size |
# Check argument to --with-link-size |
case "$with_link_size" in |
case "$with_link_size" in |
2|3|4) ;; |
2|3|4) ;; |
Line 297 case "$with_link_size" in
|
Line 432 case "$with_link_size" in
|
esac |
esac |
|
|
AH_TOP([ |
AH_TOP([ |
/* On Unix-like systems config.h.in is converted by "configure" into config.h. | /* PCRE is written in Standard C, but there are a few non-standard things it |
Some other environments also support the use of "configure". PCRE is written in | can cope with, allowing it to run on SunOS4 and other "close to standard" |
Standard C, but there are a few non-standard things it can cope with, allowing | systems. |
it to run on SunOS4 and other "close to standard" systems. | |
|
|
If you are going to build PCRE "by hand" on a system without "configure" you | In environments that support the GNU autotools, config.h.in is converted into |
should copy the distributed config.h.generic to config.h, and then set up the | config.h by the "configure" script. In environments that use CMake, |
macro definitions the way you need them. You must then add -DHAVE_CONFIG_H to | config-cmake.in is converted into config.h. If you are going to build PCRE "by |
all of your compile commands, so that config.h is included at the start of | hand" without using "configure" or CMake, you should copy the distributed |
every source. | config.h.generic to config.h, and edit the macro definitions to be the way you |
| need them. You must then add -DHAVE_CONFIG_H to all of your compile commands, |
| so that config.h is included at the start of every source. |
|
|
Alternatively, you can avoid editing by using -D on the compiler command line |
Alternatively, you can avoid editing by using -D on the compiler command line |
to set the macro values. In this case, you do not have to set -DHAVE_CONFIG_H. | to set the macro values. In this case, you do not have to set -DHAVE_CONFIG_H, |
| but if you do, default values will be taken from config.h for non-boolean |
| macros that are not defined on the command line. |
|
|
PCRE uses memmove() if HAVE_MEMMOVE is set to 1; otherwise it uses bcopy() if | Boolean macros such as HAVE_STDLIB_H and SUPPORT_PCRE8 should either be defined |
HAVE_BCOPY is set to 1. If your system has neither bcopy() nor memmove(), set | (conventionally to 1) for TRUE, and not defined at all for FALSE. All such |
them both to 0; an emulation function will be used. */]) | macros are listed as a commented #undef in config.h.generic. Macros such as |
| MATCH_LIMIT, whose actual value is relevant, have defaults defined, but are |
| surrounded by #ifndef/#endif lines so that the value can be overridden by -D. |
|
|
|
PCRE uses memmove() if HAVE_MEMMOVE is defined; otherwise it uses bcopy() if |
|
HAVE_BCOPY is defined. If your system has neither bcopy() nor memmove(), make |
|
sure both macros are undefined; an emulation function will then be used. */]) |
|
|
# Checks for header files. |
# Checks for header files. |
AC_HEADER_STDC |
AC_HEADER_STDC |
AC_CHECK_HEADERS(limits.h sys/types.h sys/stat.h dirent.h windows.h) |
AC_CHECK_HEADERS(limits.h sys/types.h sys/stat.h dirent.h windows.h) |
Line 322 AC_CHECK_HEADERS(limits.h sys/types.h sys/stat.h diren
|
Line 466 AC_CHECK_HEADERS(limits.h sys/types.h sys/stat.h diren
|
# The files below are C++ header files. |
# The files below are C++ header files. |
pcre_have_type_traits="0" |
pcre_have_type_traits="0" |
pcre_have_bits_type_traits="0" |
pcre_have_bits_type_traits="0" |
|
|
|
if test "x$enable_cpp" = "xyes" -a -z "$CXX"; then |
|
AC_MSG_ERROR([You need a C++ compiler for C++ support.]) |
|
fi |
|
|
if test "x$enable_cpp" = "xyes" -a -n "$CXX" |
if test "x$enable_cpp" = "xyes" -a -n "$CXX" |
then |
then |
AC_LANG_PUSH(C++) |
AC_LANG_PUSH(C++) |
Line 410 AC_SUBST(pcre_have_type_traits)
|
Line 559 AC_SUBST(pcre_have_type_traits)
|
AC_SUBST(pcre_have_bits_type_traits) |
AC_SUBST(pcre_have_bits_type_traits) |
|
|
# Conditional compilation |
# Conditional compilation |
|
AM_CONDITIONAL(WITH_PCRE8, test "x$enable_pcre8" = "xyes") |
|
AM_CONDITIONAL(WITH_PCRE16, test "x$enable_pcre16" = "xyes") |
|
AM_CONDITIONAL(WITH_PCRE32, test "x$enable_pcre32" = "xyes") |
AM_CONDITIONAL(WITH_PCRE_CPP, test "x$enable_cpp" = "xyes") |
AM_CONDITIONAL(WITH_PCRE_CPP, test "x$enable_cpp" = "xyes") |
AM_CONDITIONAL(WITH_REBUILD_CHARTABLES, test "x$enable_rebuild_chartables" = "xyes") |
AM_CONDITIONAL(WITH_REBUILD_CHARTABLES, test "x$enable_rebuild_chartables" = "xyes") |
AM_CONDITIONAL(WITH_JIT, test "x$enable_jit" = "xyes") |
AM_CONDITIONAL(WITH_JIT, test "x$enable_jit" = "xyes") |
AM_CONDITIONAL(WITH_UTF8, test "x$enable_utf8" = "xyes") | AM_CONDITIONAL(WITH_UTF, test "x$enable_utf" = "xyes") |
| AM_CONDITIONAL(WITH_VALGRIND, test "x$enable_valgrind" = "xyes") |
|
|
# Checks for typedefs, structures, and compiler characteristics. |
# Checks for typedefs, structures, and compiler characteristics. |
|
|
Line 465 LIBS="$OLD_LIBS"
|
Line 618 LIBS="$OLD_LIBS"
|
|
|
# Check for the availabiity of libreadline |
# Check for the availabiity of libreadline |
|
|
AC_CHECK_HEADERS([readline/readline.h], [HAVE_READLINE_H=1]) | if test "$enable_pcretest_libreadline" = "yes"; then |
AC_CHECK_HEADERS([readline/history.h], [HAVE_HISTORY_H=1]) | AC_CHECK_HEADERS([readline/readline.h], [HAVE_READLINE_H=1]) |
AC_CHECK_LIB([readline], [readline], [HAVE_LIB_READLINE=1]) | AC_CHECK_HEADERS([readline/history.h], [HAVE_HISTORY_H=1]) |
| AC_CHECK_LIB([readline], [readline], [LIBREADLINE="-lreadline"], |
| [unset ac_cv_lib_readline_readline; |
| AC_CHECK_LIB([readline], [readline], [LIBREADLINE="-ltinfo"], |
| [unset ac_cv_lib_readline_readline; |
| AC_CHECK_LIB([readline], [readline], [LIBREADLINE="-lcurses"], |
| [unset ac_cv_lib_readline_readline; |
| AC_CHECK_LIB([readline], [readline], [LIBREADLINE="-lncurses"], |
| [unset ac_cv_lib_readline_readline; |
| AC_CHECK_LIB([readline], [readline], [LIBREADLINE="-lncursesw"], |
| [unset ac_cv_lib_readline_readline; |
| AC_CHECK_LIB([readline], [readline], [LIBREADLINE="-ltermcap"], |
| [LIBREADLINE=""], |
| [-ltermcap])], |
| [-lncursesw])], |
| [-lncurses])], |
| [-lcurses])], |
| [-ltinfo])]) |
| AC_SUBST(LIBREADLINE) |
| if test -n "$LIBREADLINE"; then |
| if test "$LIBREADLINE" != "-lreadline"; then |
| echo "-lreadline needs $LIBREADLINE" |
| LIBREADLINE="-lreadline $LIBREADLINE" |
| fi |
| fi |
| fi |
|
|
|
|
|
# Check for the availability of libedit. Different distributions put its |
|
# headers in different places. Try to cover the most common ones. |
|
|
|
if test "$enable_pcretest_libedit" = "yes"; then |
|
AC_CHECK_HEADERS([editline/readline.h], [HAVE_EDITLINE_READLINE_H=1], |
|
[AC_CHECK_HEADERS([edit/readline/readline.h], [HAVE_READLINE_READLINE_H=1], |
|
[AC_CHECK_HEADERS([readline/readline.h], [HAVE_READLINE_READLINE_H=1])])]) |
|
AC_CHECK_LIB([edit], [readline], [LIBEDIT="-ledit"]) |
|
fi |
|
|
# This facilitates -ansi builds under Linux |
# This facilitates -ansi builds under Linux |
dnl AC_DEFINE([_GNU_SOURCE], [], [Enable GNU extensions in glibc]) |
dnl AC_DEFINE([_GNU_SOURCE], [], [Enable GNU extensions in glibc]) |
|
|
PCRE_STATIC_CFLAG="" |
PCRE_STATIC_CFLAG="" |
if test "x$enable_shared" = "xno" ; then |
if test "x$enable_shared" = "xno" ; then |
AC_DEFINE([PCRE_STATIC], [1], [ |
AC_DEFINE([PCRE_STATIC], [1], [ |
Define if linking statically (TODO: make nice with Libtool)]) | Define to any value if linking statically (TODO: make nice with Libtool)]) |
PCRE_STATIC_CFLAG="-DPCRE_STATIC" |
PCRE_STATIC_CFLAG="-DPCRE_STATIC" |
fi |
fi |
AC_SUBST(PCRE_STATIC_CFLAG) |
AC_SUBST(PCRE_STATIC_CFLAG) |
|
|
# Here is where pcre specific defines are handled |
# Here is where pcre specific defines are handled |
|
|
|
if test "$enable_pcre8" = "yes"; then |
|
AC_DEFINE([SUPPORT_PCRE8], [], [ |
|
Define to any value to enable the 8 bit PCRE library.]) |
|
fi |
|
|
|
if test "$enable_pcre16" = "yes"; then |
|
AC_DEFINE([SUPPORT_PCRE16], [], [ |
|
Define to any value to enable the 16 bit PCRE library.]) |
|
fi |
|
|
|
if test "$enable_pcre32" = "yes"; then |
|
AC_DEFINE([SUPPORT_PCRE32], [], [ |
|
Define to any value to enable the 32 bit PCRE library.]) |
|
fi |
|
|
if test "$enable_jit" = "yes"; then |
if test "$enable_jit" = "yes"; then |
|
AX_PTHREAD([], [AC_MSG_ERROR([JIT support requires pthreads])]) |
|
CC="$PTHREAD_CC" |
|
CFLAGS="$PTHREAD_CFLAGS $CFLAGS" |
|
LIBS="$PTHREAD_LIBS $LIBS" |
AC_DEFINE([SUPPORT_JIT], [], [ |
AC_DEFINE([SUPPORT_JIT], [], [ |
Define to enable support for Just-In-Time compiling.]) | Define to any value to enable support for Just-In-Time compiling.]) |
else |
else |
enable_pcregrep_jit="no" |
enable_pcregrep_jit="no" |
fi |
fi |
|
|
if test "$enable_pcregrep_jit" = "yes"; then |
if test "$enable_pcregrep_jit" = "yes"; then |
AC_DEFINE([SUPPORT_PCREGREP_JIT], [], [ |
AC_DEFINE([SUPPORT_PCREGREP_JIT], [], [ |
Define to enable JIT support in pcregrep.]) | Define to any value to enable JIT support in pcregrep.]) |
fi |
fi |
|
|
if test "$enable_utf8" = "yes"; then | if test "$enable_utf" = "yes"; then |
AC_DEFINE([SUPPORT_UTF8], [], [ | AC_DEFINE([SUPPORT_UTF], [], [ |
Define to enable support for the UTF-8 Unicode encoding. This will | Define to any value to enable support for the UTF-8/16/32 Unicode encoding. |
work even in an EBCDIC environment, but it is incompatible with | This will work even in an EBCDIC environment, but it is incompatible |
the EBCDIC macro. That is, PCRE can support *either* EBCDIC code | with the EBCDIC macro. That is, PCRE can support *either* EBCDIC |
*or* ASCII/UTF-8, but not both at once.]) | code *or* ASCII/UTF-8/16/32, but not both at once.]) |
fi |
fi |
|
|
if test "$enable_unicode_properties" = "yes"; then |
if test "$enable_unicode_properties" = "yes"; then |
AC_DEFINE([SUPPORT_UCP], [], [ |
AC_DEFINE([SUPPORT_UCP], [], [ |
Define to enable support for Unicode properties.]) | Define to any value to enable support for Unicode properties.]) |
fi |
fi |
|
|
if test "$enable_stack_for_recursion" = "no"; then |
if test "$enable_stack_for_recursion" = "no"; then |
AC_DEFINE([NO_RECURSE], [], [ |
AC_DEFINE([NO_RECURSE], [], [ |
PCRE uses recursive function calls to handle backtracking while |
PCRE uses recursive function calls to handle backtracking while |
matching. This can sometimes be a problem on systems that have |
matching. This can sometimes be a problem on systems that have |
stacks of limited size. Define NO_RECURSE to get a version that | stacks of limited size. Define NO_RECURSE to any value to get a |
doesn't use recursion in the match() function; instead it creates | version that doesn't use recursion in the match() function; instead |
its own stack by steam using pcre_recurse_malloc() to obtain memory | it creates its own stack by steam using pcre_recurse_malloc() to obtain |
from the heap. For more detail, see the comments and other stuff | memory from the heap. For more detail, see the comments and other stuff |
just above the match() function. On systems that support it, | just above the match() function.]) |
"configure" can be used to set this in the Makefile | |
(use --disable-stack-for-recursion).]) | |
fi |
fi |
|
|
if test "$enable_pcregrep_libz" = "yes"; then |
if test "$enable_pcregrep_libz" = "yes"; then |
AC_DEFINE([SUPPORT_LIBZ], [], [ |
AC_DEFINE([SUPPORT_LIBZ], [], [ |
Define to allow pcregrep to be linked with libz, so that it is | Define to any value to allow pcregrep to be linked with libz, so that it is |
able to handle .gz files.]) |
able to handle .gz files.]) |
fi |
fi |
|
|
if test "$enable_pcregrep_libbz2" = "yes"; then |
if test "$enable_pcregrep_libbz2" = "yes"; then |
AC_DEFINE([SUPPORT_LIBBZ2], [], [ |
AC_DEFINE([SUPPORT_LIBBZ2], [], [ |
Define to allow pcregrep to be linked with libbz2, so that it is | Define to any value to allow pcregrep to be linked with libbz2, so that it |
able to handle .bz2 files.]) | is able to handle .bz2 files.]) |
fi |
fi |
|
|
if test $with_pcregrep_bufsize -lt 8192 ; then |
if test $with_pcregrep_bufsize -lt 8192 ; then |
Line 537 if test $with_pcregrep_bufsize -lt 8192 ; then
|
Line 743 if test $with_pcregrep_bufsize -lt 8192 ; then
|
fi |
fi |
|
|
AC_DEFINE_UNQUOTED([PCREGREP_BUFSIZE], [$with_pcregrep_bufsize], [ |
AC_DEFINE_UNQUOTED([PCREGREP_BUFSIZE], [$with_pcregrep_bufsize], [ |
The value of PCREGREP_BUFSIZE determines the size of buffer used by | The value of PCREGREP_BUFSIZE determines the size of buffer used by pcregrep |
pcregrep to hold parts of the file it is searching. On systems that | to hold parts of the file it is searching. This is also the minimum value. |
support it, "configure" can be used to override the default, which is | The actual amount of memory used by pcregrep is three times this number, |
8192. This is also the minimum value. The actual amount of memory used by | because it allows for the buffering of "before" and "after" lines.]) |
pcregrep is three times this number, because it allows for the buffering of | |
"before" and "after" lines.]) | |
|
|
if test "$enable_pcretest_libreadline" = "yes"; then | if test "$enable_pcretest_libedit" = "yes"; then |
| AC_DEFINE([SUPPORT_LIBEDIT], [], [ |
| Define to any value to allow pcretest to be linked with libedit.]) |
| LIBREADLINE="$LIBEDIT" |
| elif test "$enable_pcretest_libreadline" = "yes"; then |
AC_DEFINE([SUPPORT_LIBREADLINE], [], [ |
AC_DEFINE([SUPPORT_LIBREADLINE], [], [ |
Define to allow pcretest to be linked with libreadline.]) | Define to any value to allow pcretest to be linked with libreadline.]) |
fi |
fi |
|
|
AC_DEFINE_UNQUOTED([NEWLINE], [$ac_pcre_newline_value], [ |
AC_DEFINE_UNQUOTED([NEWLINE], [$ac_pcre_newline_value], [ |
The value of NEWLINE determines the newline character sequence. On | The value of NEWLINE determines the default newline character sequence. PCRE |
systems that support it, "configure" can be used to override the | client programs can override this by selecting other values at run time. In |
default, which is 10. The possible values are 10 (LF), 13 (CR), | ASCII environments, the value can be 10 (LF), 13 (CR), or 3338 (CRLF); in |
3338 (CRLF), -1 (ANY), or -2 (ANYCRLF).]) | EBCDIC environments the value can be 21 or 37 (LF), 13 (CR), or 3349 or 3365 |
| (CRLF) because there are two alternative codepoints (0x15 and 0x25) that are |
| used as the NL line terminator that is equivalent to ASCII LF. In both ASCII |
| and EBCDIC environments the value can also be -1 (ANY), or -2 (ANYCRLF).]) |
|
|
if test "$enable_bsr_anycrlf" = "yes"; then |
if test "$enable_bsr_anycrlf" = "yes"; then |
AC_DEFINE([BSR_ANYCRLF], [], [ |
AC_DEFINE([BSR_ANYCRLF], [], [ |
By default, the \R escape sequence matches any Unicode line ending |
By default, the \R escape sequence matches any Unicode line ending |
character or sequence of characters. If BSR_ANYCRLF is defined, this is | character or sequence of characters. If BSR_ANYCRLF is defined (to any |
changed so that backslash-R matches only CR, LF, or CRLF. The build- | value), this is changed so that backslash-R matches only CR, LF, or CRLF. |
time default can be overridden by the user of PCRE at runtime. On | The build-time default can be overridden by the user of PCRE at runtime.]) |
systems that support it, "configure" can be used to override the | |
default.]) | |
fi |
fi |
|
|
AC_DEFINE_UNQUOTED([LINK_SIZE], [$with_link_size], [ |
AC_DEFINE_UNQUOTED([LINK_SIZE], [$with_link_size], [ |
Line 570 AC_DEFINE_UNQUOTED([LINK_SIZE], [$with_link_size], [
|
Line 779 AC_DEFINE_UNQUOTED([LINK_SIZE], [$with_link_size], [
|
links as offsets within the compiled regex. The default is 2, which |
links as offsets within the compiled regex. The default is 2, which |
allows for compiled patterns up to 64K long. This covers the vast |
allows for compiled patterns up to 64K long. This covers the vast |
majority of cases. However, PCRE can also be compiled to use 3 or 4 |
majority of cases. However, PCRE can also be compiled to use 3 or 4 |
bytes instead. This allows for longer patterns in extreme cases. On | bytes instead. This allows for longer patterns in extreme cases.]) |
systems that support it, "configure" can be used to override this default.]) | |
|
|
AC_DEFINE_UNQUOTED([POSIX_MALLOC_THRESHOLD], [$with_posix_malloc_threshold], [ |
AC_DEFINE_UNQUOTED([POSIX_MALLOC_THRESHOLD], [$with_posix_malloc_threshold], [ |
When calling PCRE via the POSIX interface, additional working storage |
When calling PCRE via the POSIX interface, additional working storage |
Line 580 AC_DEFINE_UNQUOTED([POSIX_MALLOC_THRESHOLD], [$with_po
|
Line 788 AC_DEFINE_UNQUOTED([POSIX_MALLOC_THRESHOLD], [$with_po
|
interface provides only two. If the number of expected substrings is |
interface provides only two. If the number of expected substrings is |
small, the wrapper function uses space on the stack, because this is |
small, the wrapper function uses space on the stack, because this is |
faster than using malloc() for each call. The threshold above which |
faster than using malloc() for each call. The threshold above which |
the stack is no longer used is defined by POSIX_MALLOC_THRESHOLD. On | the stack is no longer used is defined by POSIX_MALLOC_THRESHOLD.]) |
systems that support it, "configure" can be used to override this | |
default.]) | |
|
|
|
AC_DEFINE_UNQUOTED([PARENS_NEST_LIMIT], [$with_parens_nest_limit], [ |
|
The value of PARENS_NEST_LIMIT specifies the maximum depth of nested |
|
parentheses (of any kind) in a pattern. This limits the amount of system |
|
stack that is used while compiling a pattern.]) |
|
|
AC_DEFINE_UNQUOTED([MATCH_LIMIT], [$with_match_limit], [ |
AC_DEFINE_UNQUOTED([MATCH_LIMIT], [$with_match_limit], [ |
The value of MATCH_LIMIT determines the default number of times the |
The value of MATCH_LIMIT determines the default number of times the |
internal match() function can be called during a single execution of |
internal match() function can be called during a single execution of |
Line 591 AC_DEFINE_UNQUOTED([MATCH_LIMIT], [$with_match_limit],
|
Line 802 AC_DEFINE_UNQUOTED([MATCH_LIMIT], [$with_match_limit],
|
limit. The limit exists in order to catch runaway regular |
limit. The limit exists in order to catch runaway regular |
expressions that take for ever to determine that they do not match. |
expressions that take for ever to determine that they do not match. |
The default is set very large so that it does not accidentally catch |
The default is set very large so that it does not accidentally catch |
legitimate cases. On systems that support it, "configure" can be | legitimate cases.]) |
used to override this default default.]) | |
|
|
AC_DEFINE_UNQUOTED([MATCH_LIMIT_RECURSION], [$with_match_limit_recursion], [ |
AC_DEFINE_UNQUOTED([MATCH_LIMIT_RECURSION], [$with_match_limit_recursion], [ |
The above limit applies to all calls of match(), whether or not they |
The above limit applies to all calls of match(), whether or not they |
Line 603 AC_DEFINE_UNQUOTED([MATCH_LIMIT_RECURSION], [$with_mat
|
Line 813 AC_DEFINE_UNQUOTED([MATCH_LIMIT_RECURSION], [$with_mat
|
MATCH_LIMIT_RECURSION applies only to recursive calls of match(). To |
MATCH_LIMIT_RECURSION applies only to recursive calls of match(). To |
have any useful effect, it must be less than the value of |
have any useful effect, it must be less than the value of |
MATCH_LIMIT. The default is to use the same value as MATCH_LIMIT. |
MATCH_LIMIT. The default is to use the same value as MATCH_LIMIT. |
There is a runtime method for setting a different limit. On systems | There is a runtime method for setting a different limit.]) |
that support it, "configure" can be used to override the default.]) | |
|
|
AC_DEFINE([MAX_NAME_SIZE], [32], [ |
AC_DEFINE([MAX_NAME_SIZE], [32], [ |
This limit is parameterized just in case anybody ever wants to |
This limit is parameterized just in case anybody ever wants to |
Line 620 AH_VERBATIM([PCRE_EXP_DEFN], [
|
Line 829 AH_VERBATIM([PCRE_EXP_DEFN], [
|
/* If you are compiling for a system other than a Unix-like system or |
/* If you are compiling for a system other than a Unix-like system or |
Win32, and it needs some magic to be inserted before the definition |
Win32, and it needs some magic to be inserted before the definition |
of a function that is exported by the library, define this macro to |
of a function that is exported by the library, define this macro to |
contain the relevant magic. If you do not define this macro, it | contain the relevant magic. If you do not define this macro, a suitable |
defaults to "extern" for a C compiler and "extern C" for a C++ | __declspec value is used for Windows systems; in other environments |
compiler on non-Win32 systems. This macro apears at the start of | "extern" is used for a C compiler and "extern C" for a C++ compiler. |
every exported function that is part of the external API. It does | This macro apears at the start of every exported function that is part |
not appear on functions that are "external" in the C sense, but | of the external API. It does not appear on functions that are "external" |
which are internal to the library. */ | in the C sense, but which are internal to the library. */ |
#undef PCRE_EXP_DEFN]) |
#undef PCRE_EXP_DEFN]) |
|
|
if test "$enable_ebcdic" = "yes"; then |
if test "$enable_ebcdic" = "yes"; then |
AC_DEFINE_UNQUOTED([EBCDIC], [], [ |
AC_DEFINE_UNQUOTED([EBCDIC], [], [ |
If you are compiling for a system that uses EBCDIC instead of ASCII |
If you are compiling for a system that uses EBCDIC instead of ASCII |
character codes, define this macro as 1. On systems that can use | character codes, define this macro to any value. You must also edit the |
"configure", this can be done via --enable-ebcdic. PCRE will then | NEWLINE macro below to set a suitable EBCDIC newline, commonly 21 (0x15). |
assume that all input strings are in EBCDIC. If you do not define | On systems that can use "configure" or CMake to set EBCDIC, NEWLINE is |
this macro, PCRE will assume input strings are ASCII or UTF-8 Unicode. | automatically adjusted. When EBCDIC is set, PCRE assumes that all input |
It is not possible to build a version of PCRE that supports both | strings are in EBCDIC. If you do not define this macro, PCRE will assume |
EBCDIC and UTF-8.]) | input strings are ASCII or UTF-8/16/32 Unicode. It is not possible to build |
| a version of PCRE that supports both EBCDIC and UTF-8/16/32.]) |
fi |
fi |
|
|
|
if test "$enable_ebcdic_nl25" = "yes"; then |
|
AC_DEFINE_UNQUOTED([EBCDIC_NL25], [], [ |
|
In an EBCDIC environment, define this macro to any value to arrange for |
|
the NL character to be 0x25 instead of the default 0x15. NL plays the role |
|
that LF does in an ASCII/Unicode environment. The value must also be set in |
|
the NEWLINE macro below. On systems that can use "configure" or CMake to |
|
set EBCDIC_NL25, the adjustment of NEWLINE is automatic.]) |
|
fi |
|
|
|
if test "$enable_valgrind" = "yes"; then |
|
AC_DEFINE_UNQUOTED([SUPPORT_VALGRIND], [], [ |
|
Define to any value for valgrind support to find invalid memory reads.]) |
|
fi |
|
|
# Platform specific issues |
# Platform specific issues |
NO_UNDEFINED= |
NO_UNDEFINED= |
EXPORT_ALL_SYMBOLS= |
EXPORT_ALL_SYMBOLS= |
Line 657 esac
|
Line 881 esac
|
EXTRA_LIBPCRE_LDFLAGS="$EXTRA_LIBPCRE_LDFLAGS \ |
EXTRA_LIBPCRE_LDFLAGS="$EXTRA_LIBPCRE_LDFLAGS \ |
$NO_UNDEFINED -version-info libpcre_version" |
$NO_UNDEFINED -version-info libpcre_version" |
|
|
|
EXTRA_LIBPCRE16_LDFLAGS="$EXTRA_LIBPCRE16_LDFLAGS \ |
|
$NO_UNDEFINED -version-info libpcre16_version" |
|
|
|
EXTRA_LIBPCRE32_LDFLAGS="$EXTRA_LIBPCRE32_LDFLAGS \ |
|
$NO_UNDEFINED -version-info libpcre32_version" |
|
|
EXTRA_LIBPCREPOSIX_LDFLAGS="$EXTRA_LIBPCREPOSIX_LDFLAGS \ |
EXTRA_LIBPCREPOSIX_LDFLAGS="$EXTRA_LIBPCREPOSIX_LDFLAGS \ |
$NO_UNDEFINED -version-info libpcreposix_version" |
$NO_UNDEFINED -version-info libpcreposix_version" |
|
|
Line 665 EXTRA_LIBPCRECPP_LDFLAGS="$EXTRA_LIBPCRECPP_LDFLAGS \
|
Line 895 EXTRA_LIBPCRECPP_LDFLAGS="$EXTRA_LIBPCRECPP_LDFLAGS \
|
$EXPORT_ALL_SYMBOLS" |
$EXPORT_ALL_SYMBOLS" |
|
|
AC_SUBST(EXTRA_LIBPCRE_LDFLAGS) |
AC_SUBST(EXTRA_LIBPCRE_LDFLAGS) |
|
AC_SUBST(EXTRA_LIBPCRE16_LDFLAGS) |
|
AC_SUBST(EXTRA_LIBPCRE32_LDFLAGS) |
AC_SUBST(EXTRA_LIBPCREPOSIX_LDFLAGS) |
AC_SUBST(EXTRA_LIBPCREPOSIX_LDFLAGS) |
AC_SUBST(EXTRA_LIBPCRECPP_LDFLAGS) |
AC_SUBST(EXTRA_LIBPCRECPP_LDFLAGS) |
|
|
# When we run 'make distcheck', use these arguments. | # When we run 'make distcheck', use these arguments. Turning off compiler |
DISTCHECK_CONFIGURE_FLAGS="--enable-jit --enable-cpp --enable-unicode-properties" | # optimization makes it run faster. |
| DISTCHECK_CONFIGURE_FLAGS="CFLAGS='' CXXFLAGS='' --enable-pcre16 --enable-pcre32 --enable-jit --enable-cpp --enable-unicode-properties" |
AC_SUBST(DISTCHECK_CONFIGURE_FLAGS) |
AC_SUBST(DISTCHECK_CONFIGURE_FLAGS) |
|
|
# Check that, if --enable-pcregrep-libz or --enable-pcregrep-libbz2 is |
# Check that, if --enable-pcregrep-libz or --enable-pcregrep-libbz2 is |
Line 703 AC_SUBST(LIBBZ2)
|
Line 936 AC_SUBST(LIBBZ2)
|
|
|
# Similarly for --enable-pcretest-readline |
# Similarly for --enable-pcretest-readline |
|
|
|
if test "$enable_pcretest_libedit" = "yes"; then |
|
if test "$enable_pcretest_libreadline" = "yes"; then |
|
echo "** Cannot use both --enable-pcretest-libedit and --enable-pcretest-readline" |
|
exit 1 |
|
fi |
|
if test "$HAVE_EDITLINE_READLINE_H" != "1" -a \ |
|
"$HAVE_READLINE_READLINE_H" != "1"; then |
|
echo "** Cannot --enable-pcretest-libedit because neither editline/readline.h" |
|
echo "** nor readline/readline.h was found." |
|
exit 1 |
|
fi |
|
if test -z "$LIBEDIT"; then |
|
echo "** Cannot --enable-pcretest-libedit because libedit library was not found." |
|
exit 1 |
|
fi |
|
fi |
|
|
if test "$enable_pcretest_libreadline" = "yes"; then |
if test "$enable_pcretest_libreadline" = "yes"; then |
if test "$HAVE_READLINE_H" != "1"; then |
if test "$HAVE_READLINE_H" != "1"; then |
echo "** Cannot --enable-pcretest-readline because readline/readline.h was not found." |
echo "** Cannot --enable-pcretest-readline because readline/readline.h was not found." |
Line 712 if test "$enable_pcretest_libreadline" = "yes"; then
|
Line 962 if test "$enable_pcretest_libreadline" = "yes"; then
|
echo "** Cannot --enable-pcretest-readline because readline/history.h was not found." |
echo "** Cannot --enable-pcretest-readline because readline/history.h was not found." |
exit 1 |
exit 1 |
fi |
fi |
LIBREADLINE="-lreadline" | if test -z "$LIBREADLINE"; then |
| echo "** Cannot --enable-pcretest-readline because readline library was not found." |
| exit 1 |
| fi |
fi |
fi |
AC_SUBST(LIBREADLINE) |
|
|
|
|
# Handle valgrind support |
|
|
|
if test "$enable_valgrind" = "yes"; then |
|
m4_ifdef([PKG_CHECK_MODULES], |
|
[PKG_CHECK_MODULES([VALGRIND],[valgrind])], |
|
[AC_MSG_ERROR([pkg-config not supported])]) |
|
fi |
|
|
|
# Handle code coverage reporting support |
|
if test "$enable_coverage" = "yes"; then |
|
if test "x$GCC" != "xyes"; then |
|
AC_MSG_ERROR([Code coverage reports can only be generated when using GCC]) |
|
fi |
|
|
|
# ccache is incompatible with gcov |
|
AC_PATH_PROG([SHTOOL],[shtool],[false]) |
|
case `$SHTOOL path $CC` in |
|
*ccache*) cc_ccache=yes;; |
|
*) cc_ccache=no;; |
|
esac |
|
|
|
if test "$cc_ccache" = "yes"; then |
|
if test -z "$CCACHE_DISABLE" -o "$CCACHE_DISABLE" != "1"; then |
|
AC_MSG_ERROR([must export CCACHE_DISABLE=1 to disable ccache for code coverage]) |
|
fi |
|
fi |
|
|
|
AC_ARG_VAR([LCOV],[the ltp lcov program]) |
|
AC_PATH_PROG([LCOV],[lcov],[false]) |
|
if test "x$LCOV" = "xfalse"; then |
|
AC_MSG_ERROR([lcov not found]) |
|
fi |
|
|
|
AC_ARG_VAR([GENHTML],[the ltp genhtml program]) |
|
AC_PATH_PROG([GENHTML],[genhtml],[false]) |
|
if test "x$GENHTML" = "xfalse"; then |
|
AC_MSG_ERROR([genhtml not found]) |
|
fi |
|
|
|
# Set flags needed for gcov |
|
GCOV_CFLAGS="-O0 -ggdb3 -fprofile-arcs -ftest-coverage" |
|
GCOV_CXXFLAGS="-O0 -ggdb3 -fprofile-arcs -ftest-coverage" |
|
GCOV_LIBS="-lgcov" |
|
AC_SUBST([GCOV_CFLAGS]) |
|
AC_SUBST([GCOV_CXXFLAGS]) |
|
AC_SUBST([GCOV_LIBS]) |
|
fi # enable_coverage |
|
|
|
AM_CONDITIONAL([WITH_GCOV],[test "x$enable_coverage" = "xyes"]) |
|
|
# Produce these files, in addition to config.h. |
# Produce these files, in addition to config.h. |
AC_CONFIG_FILES( |
AC_CONFIG_FILES( |
Makefile |
Makefile |
libpcre.pc |
libpcre.pc |
libpcreposix.pc | libpcre16.pc |
| libpcre32.pc |
| libpcreposix.pc |
libpcrecpp.pc |
libpcrecpp.pc |
pcre-config |
pcre-config |
pcre.h |
pcre.h |
Line 737 AC_CONFIG_COMMANDS([delete-old-chartables], [rm -f pcr
|
Line 1041 AC_CONFIG_COMMANDS([delete-old-chartables], [rm -f pcr
|
|
|
AC_OUTPUT |
AC_OUTPUT |
|
|
# Print out a nice little message after configure is run displaying your | # Print out a nice little message after configure is run displaying the |
# chosen options. |
# chosen options. |
|
|
|
ebcdic_nl_code=n/a |
|
if test "$enable_ebcdic_nl25" = "yes"; then |
|
ebcdic_nl_code=0x25 |
|
elif test "$enable_ebcdic" = "yes"; then |
|
ebcdic_nl_code=0x15 |
|
fi |
|
|
cat <<EOF |
cat <<EOF |
|
|
$PACKAGE-$VERSION configuration summary: |
$PACKAGE-$VERSION configuration summary: |
Line 751 $PACKAGE-$VERSION configuration summary:
|
Line 1062 $PACKAGE-$VERSION configuration summary:
|
C++ compiler .................... : ${CXX} |
C++ compiler .................... : ${CXX} |
Linker .......................... : ${LD} |
Linker .......................... : ${LD} |
C preprocessor flags ............ : ${CPPFLAGS} |
C preprocessor flags ............ : ${CPPFLAGS} |
C compiler flags ................ : ${CFLAGS} | C compiler flags ................ : ${CFLAGS} ${VISIBILITY_CFLAGS} |
C++ compiler flags .............. : ${CXXFLAGS} | C++ compiler flags .............. : ${CXXFLAGS} ${VISIBILITY_CXXFLAGS} |
Linker flags .................... : ${LDFLAGS} |
Linker flags .................... : ${LDFLAGS} |
Extra libraries ................. : ${LIBS} |
Extra libraries ................. : ${LIBS} |
|
|
|
Build 8 bit pcre library ........ : ${enable_pcre8} |
|
Build 16 bit pcre library ....... : ${enable_pcre16} |
|
Build 32 bit pcre library ....... : ${enable_pcre32} |
Build C++ library ............... : ${enable_cpp} |
Build C++ library ............... : ${enable_cpp} |
Enable JIT compiling support .... : ${enable_jit} |
Enable JIT compiling support .... : ${enable_jit} |
Enable UTF-8 support ............ : ${enable_utf8} | Enable UTF-8/16/32 support ...... : ${enable_utf} |
Unicode properties .............. : ${enable_unicode_properties} |
Unicode properties .............. : ${enable_unicode_properties} |
Newline char/sequence ........... : ${enable_newline} |
Newline char/sequence ........... : ${enable_newline} |
\R matches only ANYCRLF ......... : ${enable_bsr_anycrlf} |
\R matches only ANYCRLF ......... : ${enable_bsr_anycrlf} |
EBCDIC coding ................... : ${enable_ebcdic} |
EBCDIC coding ................... : ${enable_ebcdic} |
|
EBCDIC code for NL .............. : ${ebcdic_nl_code} |
Rebuild char tables ............. : ${enable_rebuild_chartables} |
Rebuild char tables ............. : ${enable_rebuild_chartables} |
Use stack recursion ............. : ${enable_stack_for_recursion} |
Use stack recursion ............. : ${enable_stack_for_recursion} |
POSIX mem threshold ............. : ${with_posix_malloc_threshold} |
POSIX mem threshold ............. : ${with_posix_malloc_threshold} |
Internal link size .............. : ${with_link_size} |
Internal link size .............. : ${with_link_size} |
|
Nested parentheses limit ........ : ${with_parens_nest_limit} |
Match limit ..................... : ${with_match_limit} |
Match limit ..................... : ${with_match_limit} |
Match limit recursion ........... : ${with_match_limit_recursion} |
Match limit recursion ........... : ${with_match_limit_recursion} |
Build shared libs ............... : ${enable_shared} |
Build shared libs ............... : ${enable_shared} |
Line 775 $PACKAGE-$VERSION configuration summary:
|
Line 1091 $PACKAGE-$VERSION configuration summary:
|
Buffer size for pcregrep ........ : ${with_pcregrep_bufsize} |
Buffer size for pcregrep ........ : ${with_pcregrep_bufsize} |
Link pcregrep with libz ......... : ${enable_pcregrep_libz} |
Link pcregrep with libz ......... : ${enable_pcregrep_libz} |
Link pcregrep with libbz2 ....... : ${enable_pcregrep_libbz2} |
Link pcregrep with libbz2 ....... : ${enable_pcregrep_libbz2} |
|
Link pcretest with libedit ...... : ${enable_pcretest_libedit} |
Link pcretest with libreadline .. : ${enable_pcretest_libreadline} |
Link pcretest with libreadline .. : ${enable_pcretest_libreadline} |
|
Valgrind support ................ : ${enable_valgrind} |
|
Code coverage ................... : ${enable_coverage} |
|
|
EOF |
EOF |
|
|