1 dnl Process this file with autoconf to produce a configure script.
3 dnl $Id: configure.in,v 1.26 2002/01/09 14:29:49 oes Exp $
5 dnl Written by and Copyright (C) 2001 the SourceForge
6 dnl IJBSWA team. http://ijbswa.sourceforge.net
8 dnl Based on the Internet Junkbuster originally written
9 dnl by and Copyright (C) 1997 Anonymous Coders and
10 dnl Junkbusters Corporation. http://www.junkbusters.com
12 dnl This program is free software; you can redistribute it
13 dnl and/or modify it under the terms of the GNU General
14 dnl Public License as published by the Free Software
15 dnl Foundation; either version 2 of the License, or (at
16 dnl your option) any later version.
18 dnl This program is distributed in the hope that it will
19 dnl be useful, but WITHOUT ANY WARRANTY; without even the
20 dnl implied warranty of MERCHANTABILITY or FITNESS FOR A
21 dnl PARTICULAR PURPOSE. See the GNU General Public
22 dnl License for more details.
24 dnl The GNU General Public License should be included with
25 dnl this file. If not, you can view it at
26 dnl http://www.gnu.org/copyleft/gpl.html
27 dnl or write to the Free Software Foundation, Inc., 59
28 dnl Temple Place - Suite 330, Boston, MA 02111-1307, USA.
30 dnl $Log: configure.in,v $
31 dnl Revision 1.26 2002/01/09 14:29:49 oes
32 dnl - Added AC_CHECK_FUNC tests for the availability of
33 dnl gethostbyname_r, gethostbyaddr_r, gmtime_r and
34 dnl localtime_r, as well as AC_TRY_COMPILE tests to
35 dnl determine their signatures.
37 dnl - Fixed a bug with the init of CFLAGS that was
38 dnl reported by barsnick
40 dnl Revision 1.25 2002/01/04 15:27:18 oes
41 dnl Changed quoting of CODE_STATUS for use in make
43 dnl Revision 1.24 2001/12/30 14:07:31 steudten
44 dnl - Add signal handling (unix)
45 dnl - Add SIGHUP handler (unix)
46 dnl - Add creation of pidfile (unix)
47 dnl - Add action 'top' in rc file (RH)
48 dnl - Add entry 'SIGNALS' to manpage
49 dnl - Add exit message to logfile (unix)
51 dnl Revision 1.23 2001/12/09 20:24:42 david__schmidt
52 dnl Change from "alpha" to "beta" in configure.in
54 dnl Revision 1.22 2001/12/01 11:24:01 jongfoster
55 dnl Renaming Makefile.in to GNUmakefile.in so that non-GNU versions of
56 dnl make break in a more obvious way.
58 dnl Revision 1.21 2001/11/30 21:35:54 jongfoster
59 dnl Bumping version number to 2.9.10
61 dnl Revision 1.20 2001/10/23 21:24:09 jongfoster
62 dnl Support for FEATURE_CGI_EDIT_ACTIONS
64 dnl Revision 1.19 2001/10/07 15:33:14 oes
65 dnl Removed FEATURE_DENY_GZIP
66 dnl Bumped up version number
68 dnl Revision 1.18 2001/09/13 13:10:24 steudten
70 dnl PreWork for Debug Interface.
71 dnl Add new option "--with-debug" to enable debugging (flags aso.)
73 dnl Revision 1.17 2001/09/12 23:44:55 david__schmidt
74 dnl Mac OSX (Darwin) support added.
76 dnl Revision 1.16 2001/09/12 22:55:45 joergs
77 dnl AmigaOS support added.
79 dnl Revision 1.15 2001/09/12 17:28:59 david__schmidt
81 dnl OS/2 port: update autoconf'd support for the platform.
83 dnl Revision 1.14 2001/07/30 22:12:11 jongfoster
84 dnl Fixing Solaris build (I hope) and tidying up #defines:
85 dnl - All feature #defines are now of the form FEATURE_xxx
86 dnl - Permanently turned off WIN_GUI_EDIT
87 dnl - Permanently turned on WEBDAV and SPLIT_PROXY_ARGS
89 dnl Revision 1.13 2001/07/29 17:09:17 jongfoster
90 dnl Major changes to build system in order to fix these bugs:
91 dnl - pthreads under Linux was broken - changed -lpthread to -pthread
92 dnl - Compiling in MinGW32 mode under CygWin now correctly detects
93 dnl which shared libraries are available
94 dnl - Solaris support (?) (Not tested under Solaris yet)
96 dnl Revision 1.12 2001/07/25 19:16:27 oes
97 dnl Bumping version number to 2.9.8
99 dnl Revision 1.11 2001/07/21 18:00:07 jongfoster
100 dnl Bumping version number to 2.9.7
102 dnl Revision 1.10 2001/07/18 17:25:04 oes
105 dnl Revision 1.9 2001/07/15 19:45:13 jongfoster
106 dnl Added support for linking with POSIX threads library
108 dnl Revision 1.8 2001/07/15 17:54:29 jongfoster
109 dnl Renaming #define STATIC to STATIC_PCRE
110 dnl Adding new #define FEATURE_PTHREAD that will be used to enable
111 dnl POSIX threads support.
113 dnl Revision 1.7 2001/07/13 13:58:05 oes
114 dnl Completely reorganized the selection scheme for
115 dnl pcre, pcreposix, pcrs and gnu_regex:
117 dnl The presence of shared pcre, pcreposix or pcrs
118 dnl libraried is now autodetected. Additionally, the
119 dnl user can enforce using the built-in static variants
120 dnl by specifying --disable-dynamic-(pcre|pcrs).
121 dnl Care is taken to avoid that pcre is dyn, while pcreposix
122 dnl is static, if both are used and that pcrs is static if
125 dnl The choice between pcre, gnu or no regex for actionsfile
126 dnl URL matching is now via
127 dnl --(enable|disable)-regex-matching[=(gnu|pcre|no)] with the
128 dnl default being pcre.
130 dnl Revision 1.6 2001/06/29 21:56:40 oes
133 dnl Revision 1.5 2001/06/29 13:26:27 oes
134 dnl Introduced #define CODE_STATUS
136 dnl Revision 1.4 2001/05/29 09:50:24 jongfoster
137 dnl Unified blocklist/imagelist/permissionslist.
138 dnl File format is still under discussion, but the internal changes
139 dnl are (mostly) done.
141 dnl Also modified interceptor behaviour:
142 dnl - We now intercept all URLs beginning with one of the following
143 dnl prefixes (and *only* these prefixes):
145 dnl * http://ijbswa.sf.net/config/
146 dnl * http://ijbswa.sourceforge.net/config/
147 dnl - New interceptors "home page" - go to http://i.j.b/ to see it.
148 dnl - Internal changes so that intercepted and fast redirect pages
149 dnl are not replaced with an image.
150 dnl - Interceptors now have the option to send a binary page direct
151 dnl to the client. (i.e. ijb-send-banner uses this)
152 dnl - Implemented show-url-info interceptor. (Which is why I needed
153 dnl the above interceptors changes - a typical URL is
154 dnl "http://i.j.b/show-url-info?url=www.somesite.com/banner.gif".
155 dnl The previous mechanism would not have intercepted that, and
156 dnl if it had been intercepted then it then it would have replaced
157 dnl it with an image.)
159 dnl Revision 1.3 2001/05/22 18:46:04 oes
161 dnl - Enabled filtering banners by size rather than URL
162 dnl by adding patterns that replace all standard banner
163 dnl sizes with the "Junkbuster" gif to the re_filterfile
165 dnl - Enabled filtering WebBugs by providing a pattern
166 dnl which kills all 1x1 images
168 dnl - Added support for PCRE_UNGREEDY behaviour to pcrs,
169 dnl which is selected by the (nonstandard and therefore
170 dnl capital) letter 'U' in the option string.
171 dnl It causes the quantifiers to be ungreedy by default.
172 dnl Appending a ? turns back to greedy (!).
174 dnl - Added a new interceptor ijb-send-banner, which
175 dnl sends back the "Junkbuster" gif. Without imagelist or
176 dnl MSIE detection support, or if tinygif = 1, or the
177 dnl URL isn't recognized as an imageurl, a lame HTML
178 dnl explanation is sent instead.
180 dnl - Added new feature, which permits blocking remote
181 dnl script redirects and firing back a local redirect
183 dnl The feature is conditionally compiled, i.e. it
184 dnl can be disabled with --disable-fast-redirects,
185 dnl plus it must be activated by a "fast-redirects"
186 dnl line in the config file, has its own log level
187 dnl and of course wants to be displayed by show-proxy-args
188 dnl Note: Boy, all the #ifdefs in 1001 locations and
189 dnl all the fumbling with configure.in and acconfig.h
190 dnl were *way* more work than the feature itself :-(
192 dnl - Because a generic redirect template was needed for
193 dnl this, tinygif = 3 now uses the same.
195 dnl - Moved GIFs, and other static HTTP response templates
198 dnl - Some minor fixes
200 dnl - Removed some >400 CRs again (Jon, you really worked
203 dnl Revision 1.2 2001/05/20 01:21:20 jongfoster
204 dnl Version 2.9.4 checkin.
205 dnl - Merged popupfile and cookiefile, and added control over PCRS
206 dnl filtering, in new "permissionsfile".
207 dnl - Implemented LOG_LEVEL_FATAL, so that if there is a configuration
208 dnl file error you now get a message box (in the Win32 GUI) rather
209 dnl than the program exiting with no explanation.
210 dnl - Made killpopup use the PCRS MIME-type checking and HTTP-header
212 dnl - Removed tabs from "config"
213 dnl - Moved duplicated url parsing code in "loaders.c" to a new funcition.
214 dnl - Bumped up version number.
216 dnl Revision 1.1.1.1 2001/05/15 13:58:50 oes
217 dnl Initial import of version 2.9.3 source tree
222 dnl =================================================================
223 dnl AutoConf Initialization
224 dnl =================================================================
226 AC_REVISION($Revision: 1.26 $)
228 AC_CONFIG_HEADER(config.h)
232 dnl =================================================================
233 dnl Application version number
234 dnl =================================================================
241 dnl CODE_STATUS can be "alpha", "beta", or "stable", and will be
242 dnl used for CGI output
244 dnl =================================================================
245 dnl Substitute the version numbers
246 dnl =================================================================
248 AC_SUBST(VERSION_MAJOR)
249 AC_SUBST(VERSION_MINOR)
250 AC_SUBST(VERSION_POINT)
251 AC_SUBST(CODE_STATUS)
254 AC_DEFINE_UNQUOTED(VERSION_MAJOR,${VERSION_MAJOR})
255 AC_DEFINE_UNQUOTED(VERSION_MINOR,${VERSION_MINOR})
256 AC_DEFINE_UNQUOTED(VERSION_POINT,${VERSION_POINT})
257 AC_DEFINE_UNQUOTED(VERSION,"${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_POINT}")
258 AC_DEFINE_UNQUOTED(CODE_STATUS,"${CODE_STATUS}")
260 dnl =================================================================
261 dnl pid file only for unix
262 dnl =================================================================
264 PID_FILE_PATH="\"/etc/junkbuster"\"
266 dnl =================================================================
267 dnl Checks for programs needed to build.
268 dnl =================================================================
275 dnl RANLIB is for PCRE:
278 AC_CHECK_PROG(GDB,gdb,yes,no)
280 dnl =================================================================
281 dnl debug, gcc and gdb support
282 dnl =================================================================
285 [ --with-debug Enable debug mode],
287 if test "x$withval" != "$xno" ; then
288 if test $ac_cv_prog_cc_g = yes; then
289 if test "$GCC" = yes; then
295 CFLAGS="$CFLAGS -Wshadow -Wconversion"
300 CFLAGS="$CFLAGS -D_DEBUG"
304 if test "X$CFLAGS" = "X"; then # if CFLAGS are unset
305 if test "$GCC" = yes; then
314 dnl =================================================================
315 dnl additional gcc flags
316 dnl =================================================================
319 CFLAGS="-pipe $CFLAGS"
323 dnl =================================================================
325 dnl =================================================================
327 dnl Must do this first.
329 dnl Reason: This sets CFLAGS in order to switch the Cygwin compiler
330 dnl into Cygwin or MinGW32 modes. Depending on the mode selected,
331 dnl the compiler will use completely different sets of library
332 dnl and include files.
334 dnl =================================================================
339 if test "$MINGW32" = "yes"; then
342 if test "$CYGWIN" = "yes"; then
349 dnl Decide what to do based on target_type
350 dnl Note: PTHREAD_LIB is always set, even if pthread is disabled.
351 dnl This is because we don't know yet whether pthread is enabled.
353 AC_ARG_ENABLE(mingw32,
354 [ --enable-mingw32 Use mingw32 for a Windows GUI],
355 [if test $enableval = yes; then
359 if test $target_type = mingw; then
361 SPECIAL_CFLAGS="-mwindows -mno-cygwin"
362 PTHREAD_LIB=-lpthreadGC
363 echo "Using mingw32 (Win32 GUI)"
366 if test $target_type = cygwin; then
367 SPECIAL_CFLAGS="-mno-win32"
369 echo "Using Cygnus (Win32 command line)"
372 PTHREAD_LIB=-lpthread
378 dnl Save old CFLAGS so we can restore them later, then add SPECIAL_CFLAGS
379 old_CFLAGS_nospecial=$CFLAGS
380 CFLAGS="$CFLAGS $SPECIAL_CFLAGS"
382 # Hack to force AutoConf to use the CFLAGS we just set
383 dnl Warning: This may break with a future version of Autoconf
384 dnl Tested with autoconf 2.13
385 ac_cpp='$CPP $CPPFLAGS $SPECIAL_CFLAGS'
386 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
387 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
390 dnl =================================================================
392 dnl =================================================================
394 AC_CHECK_HEADER(pthread.h, [have_pthread=yes], [have_pthread=no])
396 AC_ARG_ENABLE(pthread,
397 [ --disable-pthread Don't use POSIX threads (pthreads)],
398 [if test $enableval = no; then
403 if test $have_pthread = yes; then
405 AC_DEFINE(FEATURE_PTHREAD)
406 echo Using POSIX threads
407 if test "$GCC" = "yes"; then
408 # Set a GCC specific switch:
409 if test "$target_type" = "unix"; then
410 # This compiler switch makes Linux thread-safe
411 # Don't know about other OS's? Is this switch
414 SPECIAL_CFLAGS="-pthread"
419 echo Using native threads
422 AC_SUBST(PTHREAD_ONLY)
424 dnl =================================================================
425 dnl Support for thread-safe versions of gethostbyaddr, gethostbyname,
426 dnl gmtime and localtime
427 dnl =================================================================
429 AC_CHECK_FUNC(gethostbyaddr_r, [
430 AC_MSG_CHECKING([signature of gethostbyaddr_r])
434 struct hostent *h, *hp;
437 (void) gethostbyaddr_r(a, l, t, h, b, bl, &hp, &e)
439 AC_DEFINE(HAVE_GETHOSTBYADDR_R_8_ARGS)
440 AC_MSG_RESULT([8 args])
448 (void) gethostbyaddr_r(a, l, t, h, b, bl, &e)
450 AC_DEFINE(HAVE_GETHOSTBYADDR_R_7_ARGS)
451 AC_MSG_RESULT([7 args])
456 struct hostent_data *d;
460 (void) gethostbyaddr_r(a, l, t, h, d)
462 AC_DEFINE(HAVE_GETHOSTBYADDR_R_5_ARGS)
463 AC_MSG_RESULT([5 args])
465 AC_MSG_RESULT(unrecognised)
473 AC_CHECK_FUNC(gethostbyname_r, [
474 AC_MSG_CHECKING([signature of gethostbyname_r])
478 struct hostent *h, *r;
481 (void) gethostbyname_r(n, h, b, bl, &r, &e)
483 AC_DEFINE(HAVE_GETHOSTBYNAME_R_6_ARGS)
484 AC_MSG_RESULT([6 args])
492 (void) gethostbyname_r(n, h, b, bl, &e)
494 AC_DEFINE(HAVE_GETHOSTBYNAME_R_5_ARGS)
495 AC_MSG_RESULT([5 args])
500 struct hostent_data *d;
503 (void) gethostbyname_r(n, h, d)
505 AC_DEFINE(HAVE_GETHOSTBYNAME_R_3_ARGS)
506 AC_MSG_RESULT([3 args])
508 AC_MSG_RESULT(unrecognised)
516 AC_CHECK_FUNC(gmtime_r, [
517 AC_MSG_CHECKING([signature of gmtime_r])
523 (void) gmtime_r(t, tm)
526 AC_DEFINE(HAVE_GMTIME_R)
528 AC_MSG_RESULT(unrecognised)
534 AC_CHECK_FUNC(localtime_r, [
535 AC_MSG_CHECKING([signature of localtime_r])
541 (void) localtime_r(t, tm)
544 AC_DEFINE(HAVE_LOCALTIME_R)
546 AC_MSG_RESULT(unrecognised)
552 dnl =================================================================
554 dnl FIXME: Not tested on Solaris yet...
555 dnl =================================================================
561 *-solaris*) SOCKET_LIB="-lsocket -lnsl"
562 AC_DEFINE(__EXTENSIONS__)
563 if test "$GCC" = "yes"; then
564 # Set a GCC specific switch:
565 # This compiler switch makes Solaris thread-safe
567 SPECIAL_CFLAGS="-pthreads"
569 # What do we do without GCC? Guess this:
570 SPECIAL_CFLAGS="-D_REENTRANT"
577 dnl =================================================================
579 dnl =================================================================
582 *-os2-emx*) SOCKET_LIB=-lsocket
588 dnl =================================================================
590 dnl =================================================================
595 *-amigaos) AMIGAOS_ONLY=
599 AC_SUBST(AMIGAOS_ONLY)
601 dnl =================================================================
602 dnl Check for standard compiler stuff
603 dnl =================================================================
610 AC_CHECK_SIZEOF(int, 4)
611 AC_CHECK_SIZEOF(char *, 4)
612 AC_CHECK_SIZEOF(long, 4)
613 AC_CHECK_SIZEOF(long long, 8)
614 AC_CHECK_SIZEOF(size_t, 4)
616 dnl Checks for header files.
617 dnl AC_HEADER_SYS_WAIT
618 dnl AC_CHECK_HEADERS(fcntl.h limits.h malloc.h sys/time.h unistd.h)
620 dnl Checks for library functions.
622 dnl AC_CHECK_FUNC(strstr)
623 dnl bcopy and memmove are for PCRE
624 AC_CHECK_FUNCS(strerror bcopy memmove)
627 dnl =================================================================
628 dnl Checks for libraries.
629 dnl =================================================================
630 dnl Note: Some systems may have the library but not the system header
631 dnl file, so we must check for both.
632 AC_CHECK_LIB(pcre, pcre_compile, [AC_CHECK_HEADER(pcre.h, [have_pcre=yes], [have_pcre=no])], [have_pcre=no])
633 AC_CHECK_LIB(pcreposix, regcomp, [AC_CHECK_HEADER(pcreposix.h, [have_pcreposix=yes], [have_pcreposix=no])], [have_pcreposix=no], -lpcre)
634 AC_CHECK_LIB(pcrs, pcrs_compile, [AC_CHECK_HEADER(pcrs.h, [have_pcrs=yes], [have_pcrs=no])], [have_pcrs=no])
637 dnl =================================================================
639 dnl =================================================================
643 dnl =================================================================
645 dnl =================================================================
647 AC_ARG_ENABLE(toggle,
648 [ --disable-toggle Don't support temporary disable],
649 [if test $enableval = yes; then
650 AC_DEFINE(FEATURE_TOGGLE)
651 fi],AC_DEFINE(FEATURE_TOGGLE))
654 [ --disable-force Don't allow single-page disable],
655 [if test $enableval = yes; then
656 AC_DEFINE(FEATURE_FORCE_LOAD)
657 fi],AC_DEFINE(FEATURE_FORCE_LOAD))
659 AC_ARG_ENABLE(fast-redirects,
660 [ --disable-fast-redirects Don't support fast redirects],
661 [if test $enableval = yes; then
662 AC_DEFINE(FEATURE_FAST_REDIRECTS)
663 fi], AC_DEFINE(FEATURE_FAST_REDIRECTS))
665 AC_ARG_ENABLE(killpopup,
666 [ --disable-killpopup Never block popups],
667 [if test $enableval = yes; then
668 AC_DEFINE(FEATURE_KILL_POPUPS)
669 fi],AC_DEFINE(FEATURE_KILL_POPUPS))
672 [ --disable-stats Don't keep statistics],
673 [if test $enableval = yes; then
674 AC_DEFINE(FEATURE_STATISTICS)
675 fi],AC_DEFINE(FEATURE_STATISTICS))
677 AC_ARG_ENABLE(ie-images,
678 [ --disable-ie-images Don't auto-detect whether a request from MS Internet
679 Explorer is for an image or HTML.],
680 [if test $enableval = yes; then
681 AC_DEFINE(FEATURE_IMAGE_DETECT_MSIE)
683 AC_DEFINE(FEATURE_IMAGE_DETECT_MSIE))
685 AC_ARG_ENABLE(image-blocking,
686 [ --disable-image-blocking Don't try to figure out whether a request is
687 for an image or HTML - assume HTML.],
688 [if test $enableval = yes; then
689 AC_DEFINE(FEATURE_IMAGE_BLOCKING)
691 AC_DEFINE(FEATURE_IMAGE_BLOCKING))
693 AC_ARG_ENABLE(acl-files,
694 [ --disable-acl-files Prevents the use of ACL files to control access to
695 the proxy by IP address.],
696 [if test $enableval = yes; then
697 AC_DEFINE(FEATURE_ACL)
699 AC_DEFINE(FEATURE_ACL))
701 AC_ARG_ENABLE(trust-files,
702 [ --disable-trust-files Prevents the use of trust files.],
703 [if test $enableval = yes; then
704 AC_DEFINE(FEATURE_TRUST)
706 AC_DEFINE(FEATURE_TRUST))
708 AC_ARG_ENABLE(jar-files,
709 [ --disable-jar-files Prevents the use of jar files to capture cookies.],
710 [if test $enableval = yes; then
711 AC_DEFINE(FEATURE_COOKIE_JAR)
713 AC_DEFINE(FEATURE_COOKIE_JAR))
715 AC_ARG_ENABLE(editor,
716 [ --disable-editor Prevents the use of the web-based actions file
717 editor and web-based temporary disable setting.],
718 [if test $enableval = yes; then
719 AC_DEFINE(FEATURE_CGI_EDIT_ACTIONS)
721 AC_DEFINE(FEATURE_CGI_EDIT_ACTIONS))
723 dnl pcre/pcrs is needed for CGI anyway, so
724 dnl the choice is only between static and
727 AC_ARG_ENABLE(regex-matching,
728 [ --enable-regex-matching=pcre Use perl-compatible regex for actionsfile
729 pattern matching (default)
730 --enable-regex-matching=gnu Use gnu style regex for actionsfile pattern
731 matching (-> bigger binary)
732 --disable-regex-matching Don't use regex matching, compare URL
733 prefix instead (won't shrink birary)],
734 [ regex_matching=$enableval ],
735 [ regex_matching=pcre ])
737 AC_ARG_ENABLE(dynamic-pcre,
738 [ --disable-dynamic-pcre Use the built-in, static pcre, even if
739 libpcre is available],
740 [ if test $enableval = "no"; then have_pcre=no; fi ])
742 AC_ARG_ENABLE(dynamic-pcrs,
743 [ --disable-dynamic-pcrs Use the built-in, static pcrs, even if
744 libpcrs is available],
745 [ if test $enableval = "no"; then have_pcrs=no; fi ])
748 # Is the regex URL matching based on libpcreposix, but we
749 # don't have that library?
751 if test $have_pcreposix = "yes" -o $regex_matching != "pcre"; then
752 dont_miss_pcreposix=yes
754 dont_miss_pcreposix=no
757 # If we have libpcre and either we also have pcreposix or
758 # we don't need pcreposix, then link pcre dynamically; else
759 # build it and link statically
761 if test $have_pcre = "yes" -a $dont_miss_pcreposix = "yes"; then
767 echo "using built-in static pcre"
769 AC_DEFINE(STATIC_PCRE)
773 # If we have libpcrs and pcre is linked dynamically
774 # then also link pcrs dynamically, else build and link
777 if test $have_pcrs = "yes" -a $pcre_dyn = "yes"; then
782 echo "using built-in static pcrs"
783 AC_DEFINE(STATIC_PCRS)
787 # Which method should be used for URL matching?
788 # pcre, gnu regex or prefix matching?
790 if test $regex_matching = "gnu"; then
791 echo "using gnu regex for URL matching"
795 elif test $regex_matching = "pcre"; then
796 echo "using pcre regex for URL matching"
797 AC_DEFINE(REGEX_PCRE)
800 if test $pcre_dyn = "yes"; then
801 LIBS="$LIBS -lpcreposix"
804 echo -e "using prefix matching for URLs\nHint: This does NOT make the executable any smaller!"
809 AC_SUBST(GNU_REGEX_ONLY)
810 AC_SUBST(PCRE_REGEX_ONLY)
811 AC_SUBST(STATIC_PCRE_ONLY)
812 AC_SUBST(STATIC_PCRS_ONLY)
814 dnl =================================================================
815 dnl Final cleanup and output
816 dnl =================================================================
818 dnl Remove the SPECIAL_CFLAGS stuff from CFLAGS, and add it seperately
820 CFLAGS=$old_CFLAGS_nospecial
821 AC_SUBST(SPECIAL_CFLAGS)
823 AC_SUBST(PID_FILE_PATH)
824 AC_DEFINE_UNQUOTED(PID_FILE_PATH,${PID_FILE_PATH})
826 AC_SUBST(PTHREAD_LIB)
828 AC_OUTPUT(GNUmakefile)