X-Git-Url: http://www.privoxy.org/gitweb/?p=privoxy.git;a=blobdiff_plain;f=configure.in;h=87b0a4f8de0eb648613d39c812df54e05e0c817d;hp=0cb78e2690dd249ea4717c01b7e9be1ff12aed88;hb=3f82e08bed52a1e3fb64f629e06ce986a372e074;hpb=5bc5146d881691b23bbf195715ef95f7d8ace2e1 diff --git a/configure.in b/configure.in index 0cb78e26..87b0a4f8 100644 --- a/configure.in +++ b/configure.in @@ -1,6 +1,6 @@ dnl Process this file with autoconf to produce a configure script. dnl -dnl $Id: configure.in,v 1.6 2001/06/29 21:56:40 oes Exp $ +dnl $Id: configure.in,v 1.8 2001/07/15 17:54:29 jongfoster Exp $ dnl dnl Written by and Copyright (C) 2001 the SourceForge dnl IJBSWA team. http://ijbswa.sourceforge.net @@ -28,6 +28,28 @@ dnl or write to the Free Software Foundation, Inc., 59 dnl Temple Place - Suite 330, Boston, MA 02111-1307, USA. dnl dnl $Log: configure.in,v $ +dnl Revision 1.8 2001/07/15 17:54:29 jongfoster +dnl Renaming #define STATIC to STATIC_PCRE +dnl Adding new #define FEATURE_PTHREAD that will be used to enable +dnl POSIX threads support. +dnl +dnl Revision 1.7 2001/07/13 13:58:05 oes +dnl Completely reorganized the selection scheme for +dnl pcre, pcreposix, pcrs and gnu_regex: +dnl +dnl The presence of shared pcre, pcreposix or pcrs +dnl libraried is now autodetected. Additionally, the +dnl user can enforce using the built-in static variants +dnl by specifying --disable-dynamic-(pcre|pcrs). +dnl Care is taken to avoid that pcre is dyn, while pcreposix +dnl is static, if both are used and that pcrs is static if +dnl pcrs is. +dnl +dnl The choice between pcre, gnu or no regex for actionsfile +dnl URL matching is now via +dnl --(enable|disable)-regex-matching[=(gnu|pcre|no)] with the +dnl default being pcre. +dnl dnl Revision 1.6 2001/06/29 21:56:40 oes dnl Version -> 2.9.5 dnl @@ -155,9 +177,11 @@ AC_EXEEXT AC_OBJEXT dnl Checks for libraries. -AC_CHECK_LIB(pcre, pcre_compile, [have_pcre=yes], [have_pcre=no]) -AC_CHECK_LIB(pcreposix, regcomp, [have_pcreposix=yes], [have_pcreposix=no], -lpcre) -AC_CHECK_LIB(pcrs, pcrs_compile, [have_pcrs=yes], [have_pcrs=no]) +dnl Note: Some systems have the library but not the system header file, +dnl so we must check for both. +AC_CHECK_LIB(pcre, pcre_compile, [AC_CHECK_HEADER(pcre.h, [have_pcre=yes], [have_pcre=no])], [have_pcre=no]) +AC_CHECK_LIB(pcreposix, regcomp, [AC_CHECK_HEADER(pcreposix.h, [have_pcreposix=yes], [have_pcreposix=no])], [have_pcreposix=no], -lpcre) +AC_CHECK_LIB(pcrs, pcrs_compile, [AC_CHECK_HEADER(pcrs.h, [have_pcrs=yes], [have_pcre=no])], [have_pcrs=no]) dnl Checks for header files. AC_HEADER_STDC @@ -178,37 +202,46 @@ AC_CHECK_FUNCS(strerror bcopy memmove) dnl Build type +dnl Note: PTHREAD_LIB is always set, even if pthread is disabled. + AC_ARG_ENABLE(mingw32, [ --enable-mingw32 Use mingw32 for a Windows GUI], [if test $enableval = yes; then WIN_ONLY= CYGWIN_FLAGS="-mwindows -mno-cygwin" + PTHREAD_LIB=-lpthreadGC echo "Using mingw32 (Win32 GUI)" else WIN_ONLY=# if test "$CYGWIN" = "yes"; then CYGWIN_FLAGS="-mno-win32" + PTHREAD_LIB= echo "Using Cygnus (Win32 command line)" else CYGWIN_FLAGS= + PTHREAD_LIB=-lpthread fi fi], [if test "$MINGW32" = "yes"; then WIN_ONLY= CYGWIN_FLAGS="-mwindows -mno-cygwin" + PTHREAD_LIB=-lpthreadGC echo "Using mingw32 (Win32 GUI)" else WIN_ONLY=# if test "$CYGWIN" = "yes"; then CYGWIN_FLAGS="-mno-win32" + PTHREAD_LIB= echo "Using Cygnus (Win32 command line)" else CYGWIN_FLAGS= + PTHREAD_LIB=-lpthread fi fi]) AC_SUBST(WIN_ONLY) AC_SUBST(CYGWIN_FLAGS) +AC_SUBST(PTHREAD_LIB) SOLARIS_ONLY=# AC_SUBST(SOLARIS_ONLY) @@ -221,6 +254,18 @@ AC_ARG_ENABLE(toggle, AC_DEFINE(TOGGLE) fi],AC_DEFINE(TOGGLE)) +AC_ARG_ENABLE(pthread, +[ --disable-pthread Don't use POSIX threads (pthreads)], +[if test $enableval = yes; then + PTHREAD_ONLY= + AC_DEFINE(FEATURE_PTHREAD) +else + PTHREAD_ONLY=# +fi],[AC_DEFINE(FEATURE_PTHREAD) + PTHREAD_ONLY= +]) +AC_SUBST(PTHREAD_ONLY) + AC_ARG_ENABLE(gzip, [ --enable-gzip Allow gzip'ed transfer of documents. Note that this will make content modification impossible.], [if test $enableval = "no"; then @@ -344,7 +389,7 @@ if test $have_pcre = "yes" -a $dont_miss_pcreposix = "yes"; then else echo "using built-in static pcre" pcre_dyn=no - AC_DEFINE(STATIC) + AC_DEFINE(STATIC_PCRE) STATIC_PCRE_ONLY= fi