summaryrefslogtreecommitdiff
path: root/ext/pcre/config.m4
blob: eef4563d313f36212383652faa108c640d529fbd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
dnl $Id$
dnl config.m4 for extension pcre

dnl By default we'll compile and link against the bundled PCRE library
dnl if DIR is supplied, we'll use that for linking

AC_MSG_CHECKING(whether to include PCRE support)
AC_ARG_WITH(pcre-regex,
[  --without-pcre-regex    Don't include Perl Compatible Regular Expressions support],[
  if test "$withval" = "yes"; then
    EXTRA_LIBS="-L$abs_builddir/ext/pcre/pcrelib -lpcre $EXTRA_LIBS"
    PCRE_SUBDIR="pcrelib"
    AC_DEFINE(HAVE_PCRE, 1)
    AC_MSG_RESULT(yes)
    PHP_EXTENSION(pcre)
  else
    AC_MSG_RESULT(no)
  fi
],[
  EXTRA_LIBS="-L$abs_builddir/ext/pcre/pcrelib -lpcre $EXTRA_LIBS"
  PCRE_SUBDIR="pcrelib"
  AC_DEFINE(HAVE_PCRE, 1)
  AC_MSG_RESULT(yes)
  PHP_EXTENSION(pcre)
]) 
AC_SUBST(PCRE_SUBDIR)