| 6 |
dnl be defined as -RC2, for example. For real releases, it should be defined |
dnl be defined as -RC2, for example. For real releases, it should be defined |
| 7 |
dnl empty. |
dnl empty. |
| 8 |
|
|
| 9 |
m4_define(pcre_major, [8]) |
m4_define(pcre_major, [7]) |
| 10 |
m4_define(pcre_minor, [0]) |
m4_define(pcre_minor, [9]) |
| 11 |
m4_define(pcre_prerelease, [-RC1]) |
m4_define(pcre_prerelease, []) |
| 12 |
m4_define(pcre_date, [2008-07-01]) |
m4_define(pcre_date, [2009-04-11]) |
| 13 |
|
|
| 14 |
# Libtool shared library interface versions (current:revision:age) |
# Libtool shared library interface versions (current:revision:age) |
| 15 |
m4_define(libpcre_version, [0:1:0]) |
m4_define(libpcre_version, [0:1:0]) |
| 102 |
# Handle --enable-utf8 (disabled by default) |
# Handle --enable-utf8 (disabled by default) |
| 103 |
AC_ARG_ENABLE(utf8, |
AC_ARG_ENABLE(utf8, |
| 104 |
AS_HELP_STRING([--enable-utf8], |
AS_HELP_STRING([--enable-utf8], |
| 105 |
[enable UTF-8 support]), |
[enable UTF-8 support (incompatible with --enable-ebcdic)]), |
| 106 |
, enable_utf8=unset) |
, enable_utf8=unset) |
| 107 |
|
|
| 108 |
# Handle --enable-unicode-properties |
# Handle --enable-unicode-properties |
| 150 |
# Handle --enable-ebcdic |
# Handle --enable-ebcdic |
| 151 |
AC_ARG_ENABLE(ebcdic, |
AC_ARG_ENABLE(ebcdic, |
| 152 |
AS_HELP_STRING([--enable-ebcdic], |
AS_HELP_STRING([--enable-ebcdic], |
| 153 |
[assume EBCDIC coding rather than ASCII; use this only in (uncommon) EBCDIC environments; it implies --enable-rebuild-chartables]), |
[assume EBCDIC coding rather than ASCII; incompatible with --enable-utf8; use only in (uncommon) EBCDIC environments; it implies --enable-rebuild-chartables]), |
| 154 |
, enable_ebcdic=no) |
, enable_ebcdic=no) |
| 155 |
|
|
| 156 |
# Handle --disable-stack-for-recursion |
# Handle --disable-stack-for-recursion |
| 226 |
fi |
fi |
| 227 |
|
|
| 228 |
# Make sure that if enable_ebcdic is set, rebuild_chartables is also enabled. |
# Make sure that if enable_ebcdic is set, rebuild_chartables is also enabled. |
| 229 |
|
# Also check that UTF-8 support is not requested, because PCRE cannot handle |
| 230 |
|
# EBCDIC and UTF-8 in the same build. To do so it would need to use different |
| 231 |
|
# character constants depending on the mode. |
| 232 |
# |
# |
| 233 |
if test "x$enable_ebcdic" = "xyes" |
if test "x$enable_ebcdic" = "xyes" |
| 234 |
then |
then |
| 235 |
enable_rebuild_chartables=yes |
enable_rebuild_chartables=yes |
| 236 |
|
if test "x$enable_utf8" = "xyes" |
| 237 |
|
then |
| 238 |
|
AC_MSG_ERROR([support for EBCDIC and UTF-8 cannot be enabled at the same time]) |
| 239 |
|
fi |
| 240 |
fi |
fi |
| 241 |
|
|
| 242 |
# Convert the newline identifier into the appropriate integer value. |
# Convert the newline identifier into the appropriate integer value. |
| 388 |
|
|
| 389 |
if test "$enable_utf8" = "yes"; then |
if test "$enable_utf8" = "yes"; then |
| 390 |
AC_DEFINE([SUPPORT_UTF8], [], [ |
AC_DEFINE([SUPPORT_UTF8], [], [ |
| 391 |
Define to enable support for the UTF-8 Unicode encoding.]) |
Define to enable support for the UTF-8 Unicode encoding. This will |
| 392 |
|
work even in an EBCDIC environment, but it is incompatible with |
| 393 |
|
the EBCDIC macro. That is, PCRE can support *either* EBCDIC code |
| 394 |
|
*or* ASCII/UTF-8, but not both at once.]) |
| 395 |
fi |
fi |
| 396 |
|
|
| 397 |
if test "$enable_unicode_properties" = "yes"; then |
if test "$enable_unicode_properties" = "yes"; then |
| 512 |
AC_DEFINE_UNQUOTED([EBCDIC], [], [ |
AC_DEFINE_UNQUOTED([EBCDIC], [], [ |
| 513 |
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 |
| 514 |
character codes, define this macro as 1. On systems that can use |
character codes, define this macro as 1. On systems that can use |
| 515 |
"configure", this can be done via --enable-ebcdic.]) |
"configure", this can be done via --enable-ebcdic. PCRE will then |
| 516 |
|
assume that all input strings are in EBCDIC. If you do not define |
| 517 |
|
this macro, PCRE will assume input strings are ASCII or UTF-8 Unicode. |
| 518 |
|
It is not possible to build a version of PCRE that supports both |
| 519 |
|
EBCDIC and UTF-8.]) |
| 520 |
fi |
fi |
| 521 |
|
|
| 522 |
# Platform specific issues |
# Platform specific issues |
| 553 |
AC_SUBST(DISTCHECK_CONFIGURE_FLAGS) |
AC_SUBST(DISTCHECK_CONFIGURE_FLAGS) |
| 554 |
|
|
| 555 |
# Check that, if --enable-pcregrep-libz or --enable-pcregrep-libbz2 is |
# Check that, if --enable-pcregrep-libz or --enable-pcregrep-libbz2 is |
| 556 |
# specified, the relevant library is available. If so, add it to LIBS. |
# specified, the relevant library is available. |
| 557 |
|
|
| 558 |
if test "$enable_pcregrep_libz" = "yes"; then |
if test "$enable_pcregrep_libz" = "yes"; then |
| 559 |
if test "$HAVE_ZLIB_H" != "1"; then |
if test "$HAVE_ZLIB_H" != "1"; then |
| 564 |
echo "** Cannot --enable-pcregrep-libz because libz was not found" |
echo "** Cannot --enable-pcregrep-libz because libz was not found" |
| 565 |
exit 1 |
exit 1 |
| 566 |
fi |
fi |
| 567 |
if test "$LIBS" = ""; then LIBS=-lz; else LIBS="$LIBS -lz"; fi |
LIBZ="-lz" |
| 568 |
fi |
fi |
| 569 |
|
AC_SUBST(LIBZ) |
| 570 |
|
|
| 571 |
if test "$enable_pcregrep_libbz2" = "yes"; then |
if test "$enable_pcregrep_libbz2" = "yes"; then |
| 572 |
if test "$HAVE_BZLIB_H" != "1"; then |
if test "$HAVE_BZLIB_H" != "1"; then |
| 577 |
echo "** Cannot --enable-pcregrep-libbz2 because libbz2 was not found" |
echo "** Cannot --enable-pcregrep-libbz2 because libbz2 was not found" |
| 578 |
exit 1 |
exit 1 |
| 579 |
fi |
fi |
| 580 |
if test "$LIBS" = ""; then LIBS=-lbz2; else LIBS="$LIBS -lbz2"; fi |
LIBBZ2="-lbz2" |
| 581 |
fi |
fi |
| 582 |
|
AC_SUBST(LIBBZ2) |
| 583 |
|
|
| 584 |
# Similarly for --enable-pcretest-readline |
# Similarly for --enable-pcretest-readline |
| 585 |
|
|
| 592 |
echo "** Cannot --enable-pcretest-readline because readline/history.h was not found." |
echo "** Cannot --enable-pcretest-readline because readline/history.h was not found." |
| 593 |
exit 1 |
exit 1 |
| 594 |
fi |
fi |
| 595 |
if test "$LIBS" = ""; then LIBS=-lreadline; else LIBS="$LIBS -lreadline"; fi |
LIBREADLINE="-lreadline" |
| 596 |
fi |
fi |
| 597 |
|
AC_SUBST(LIBREADLINE) |
| 598 |
|
|
| 599 |
# Produce these files, in addition to config.h. |
# Produce these files, in addition to config.h. |
| 600 |
AC_CONFIG_FILES( |
AC_CONFIG_FILES( |