OSSP CVS Repository

ossp - ossp-pkg/pcre/configure.in
Not logged in
[Honeypot]  [Browse]  [Directory]  [Home]  [Login
[Reports]  [Search]  [Ticket]  [Timeline
  [Raw

ossp-pkg/pcre/configure.in
dnl ##
dnl ##   Autoconf specification for PCRE library
dnl ##

AC_PREREQ(2.12)dnl
AC_REVISION($Revision: 1.7 $)

SHTOOL="./shtool"
AC_SUBST(SHTOOL)
T_MD=`$SHTOOL echo -e %B 2>/dev/null`
T_ME=`$SHTOOL echo -e %b 2>/dev/null`
PCRE_MAJOR=`grep '#define PCRE_MAJOR' pcre.h | awk '{ print $3; }'`
PCRE_MINOR=`grep '#define PCRE_MINOR' pcre.h | awk '{ print $3; }'`
PCRE_VERSION="$PCRE_MAJOR.$PCRE_MINOR"
AC_SUBST(PCRE_VERSION)
echo "Configuring ${T_MD}OSSP pcre${T_ME} (Perl-Compatible Regular Expressions) ${T_MD}${PCRE_VERSION}${T_ME}"
echo "Copyright (c) 1997-2000 Philip Hazel <ph10@cam.ac.uk>, All rights reserved."
echo "Copyright (c) 1997-2000 University of Cambridge, All rights reserved."
echo "Copyright (c) 1999-2000 Ralf S. Engelschall <rse@engelschall.com>"
PLATFORM=`$SHTOOL guessos`
echo "Platform: ${T_MD}${PLATFORM}${T_ME}"
echo ""

AC_INIT(README)
AC_CONFIG_HEADER(config.h)
AC_PREFIX_DEFAULT(/usr/local)

AC_PROG_CC
AC_PROG_CPP
AC_SET_MAKE

AC_ARG_ENABLE(utf8,dnl
[  --enable-utf8           enable UTF8 support (incomplete)],
enable_utf8="$enableval",
enable_utf8=yes
)dnl
if test ".$enable_utf8" = .yes; then
    if test ".$CFLAGS" = .; then
        CFLAGS="-DSUPPORT_UTF8"
    else
        CFLAGS="$CFLAGS -DSUPPORT_UTF8"
    fi
fi

AC_ARG_ENABLE(static,dnl
[  --enable-static         build static libraries (default=yes)],
enable_static="$enableval",
enable_static=yes
)dnl
AC_ARG_ENABLE(shared,dnl
[  --enable-shared         build shared libraries (default=yes)],
enable_shared="$enableval",
enable_shared=yes
)dnl
libtool_flags=''
test "$enable_static"     = no  && libtool_flags="$libtool_flags --disable-static"
test "$enable_shared"     = no  && libtool_flags="$libtool_flags --disable-shared"
test "$ac_cv_prog_gcc"    = yes && libtool_flags="$libtool_flags --with-gcc"
test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" LD="$LD" \
${CONFIG_SHELL-/bin/sh} ltconfig --no-reexec \
$libtool_flags --no-verify ltmain.sh $PLATFORM ||\
AC_MSG_ERROR([libtool configuration failed])
LIBTOOL="./libtool"
AC_SUBST(LIBTOOL)

AC_CHECK_FUNCS(memmove strerror)

AC_OUTPUT(dnl
Makefile dnl
pcre-config dnl
,dnl
chmod a+x pcre-config
)dnl


CVSTrac 2.0.1