"Fossies" - the Fresh Open Source Software Archive

Member "libgcgi.a-0.9.5/configure.in" (22 Jun 2002, 2345 Bytes) of package /linux/www/old/gcgi-0.9.5.tar.gz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 # Process this file with autoconf to produce a configure script.
    2 AC_INIT(src/gcgi.c)
    3 AC_CONFIG_AUX_DIR(config)
    4 AM_CONFIG_HEADER(config.h)
    5 
    6 GCGI_MAJOR=0
    7 GCGI_MINOR=9
    8 GCGI_PATCH=5
    9 GCGI_VERSION="$GCGI_MAJOR.$GCGI_MINOR.$GCGI_PATCH"
   10 VERSION=$GCGI_VERSION
   11 
   12 AM_INIT_AUTOMAKE(libgcgi.a, [$VERSION])
   13 
   14 # Checks for programs.
   15 AC_PROG_CC
   16 AC_STDC_HEADERS
   17 AC_PROG_MAKE_SET
   18 AM_PROG_LIBTOOL
   19 
   20 # Checks for libraries.
   21 AC_CHECK_LIB([m], [floor])
   22 
   23 # Checks for header files.
   24 AC_HEADER_STDC
   25 AC_CHECK_HEADERS([errno.h stdlib.h string.h unistd.h regex.h ctype.h math.h sys/types.h strings.h])
   26 
   27 # Checks for typedefs, structures, and compiler characteristics.
   28 AC_C_CONST
   29 AC_TYPE_MODE_T
   30 AC_TYPE_OFF_T
   31 AC_TYPE_SIZE_T
   32 
   33 # Checks for library functions.
   34 AC_CHECK_FUNCS([floor memset regcomp setenv strcasecmp strncasecmp strtol malloc strtod])
   35 
   36 dnl ##########################################################################
   37 dnl Enable SSL?
   38 dnl ##########################################################################
   39 
   40 AC_ARG_WITH(openssl, [  --with-openssl          Enable OpenSSL [default=no]],[
   41         with_ssl=$withval
   42 ],[
   43         with_ssl=no
   44 ])
   45 
   46 AC_MSG_CHECKING([whether to build OpenSSL support])
   47 if test "x$with_ssl" != xno  ; then
   48    if test -d $with_ssl && test -f "$with_ssl/include/openssl/evp.h" ; then
   49       ssldir=$with_ssl
   50    else
   51         AC_TRY_COMPILE([#include <openssl/evp.h>], ,
   52                         ssldir=default,
   53                         ssldir="")
   54         if test "x$ssldir" = x ; then
   55            for prefixdir in /usr /usr/local /usr/lib /usr/pkg /var /opt; do
   56                for dir in $prefixdir $prefixdir/openssl $prefixdir/ssl; do
   57                    if test -f "$dir/include/openssl/evp.h"; then
   58                       ssldir=$dir
   59                    fi
   60                done
   61            done
   62         fi
   63    fi
   64 fi
   65 
   66 if test "x$with_ssl" != xno; then
   67    if test -z "$ssldir"; then
   68       AC_MSG_ERROR([OpenSSL requested but no headers found.])
   69    else
   70         AC_MSG_RESULT(yes)
   71         LIBS="$LIBS -lssl -lcrypto"
   72         if test "x$ssldir" != xdefault ; then
   73 		LDFLAGS="-L${ssldir}/lib $LDFLAGS"
   74                 CPPFLAGS="-I${ssldir}/include $CPPFLAGS"
   75         fi
   76 	AC_DEFINE(USE_SSL, 1,[Use OpenSSL to encrypt cookies.])
   77    fi
   78 else
   79    AC_MSG_RESULT(no)
   80 fi
   81 
   82 AC_SUBST(ac_aux_dir)
   83 
   84 AC_OUTPUT([
   85 Makefile
   86 src/Makefile
   87 examples/Makefile
   88 doc/Makefile
   89 ])