1 dnl Process this file with autoconf to produce a configure script.
3 AC_CONFIG_SRCDIR(src/opercmd.h)
4 AM_CONFIG_HEADER(src/setup.h)
6 AC_PREFIX_DEFAULT([\${HOME}/bopm])
10 AC_HELP_STRING([--with-select], [use select() instead of poll()]),
11 [with_select="yes"], [with_select="no"])
13 AC_HELP_STRING([--with-unreal],
14 [you need this if you are using Unreal ircd (any version)]),
15 [with_unreal="yes"], [with_unreal="no"])
16 AC_ARG_WITH(extra-fascism,
17 AC_HELP_STRING([--with-extra-fascism],
18 [Add extra gcc3-specific warning flags]),
19 [CFLAGS="$CFLAGS -g -ggdb -O0 -W -Wfloat-equal -Wbad-function-cast -Wconversion -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wredundant-decls -Wnested-externs"])
24 AC_HELP_STRING([--enable-ipv6], [Enable IPV6 support]),
25 [ac_cv_ipv6=$enableval], [ac_cv_ipv6="no"])
27 AC_MSG_CHECKING([whether to enable IPv6 features])
29 if test "$ac_cv_ipv6" = "yes" ; then
30 AC_DEFINE(IPV6, 1, [Use Ipv6 Support])
36 dnl Checks for programs.
39 dnl Checks for libraries.
41 dnl Checks for header files.
44 if test "$with_select" = "yes"; then
45 echo "use of select() forced, skipping poll() checks..."
46 AC_DEFINE(WITH_SELECT, 1, [Define if you wish to force use of select() even when poll() may be present])
48 AC_CHECK_HEADERS(sys/poll.h, have_poll_sys_h=yes, have_sys_poll_h=no)
51 if test "$with_unreal" = "yes"; then
52 echo "configuring for Unreal ircd"
53 AC_DEFINE(WITH_UNREAL, 1, [Define if you are using Unreal ircd (any version)])
56 AC_CHECK_HEADERS(fcntl.h sys/time.h unistd.h strings.h)
58 dnl Checks for typedefs, structures, and compiler characteristics.
64 dnl Checks for library functions.
77 dnl if they want select() or they don't have poll() then we need to check
78 dnl that we actually have select()
79 if test "$with_select" = "yes" || test "$have_sys_poll_h" = "no"; then
80 AC_CHECK_FUNCS(select, have_select=yes, have_select=no)
81 if test "$have_select" = "no"; then
82 AC_MSG_ERROR([No select() implementation found])
86 AC_CHECK_FUNCS(inet_aton inet_pton socket strdup strstr)
88 dnl Check if we can use gethostbyname2 for ipv6
89 AC_CHECK_FUNCS(gethostbyname gethostbyname2)
94 dnl Solaris has to be weird doesn't it...
95 AC_CHECK_LIB(socket, socket, AC_SUBST(LSOCKET, [-lsocket]))
96 AC_CHECK_LIB(nsl, gethostbyname, AC_SUBST(LNSL, [-lnsl]))
98 dnl teehee - taken from MRTG / Tobias Oetiker
99 echo $ECHO_N "checking for POSIX-compliant goat $ECHO_C"
100 for bleh in 1 2 3; do
104 AC_MSG_RESULT([ http://www.blitzed.org/goat_winter_2001.phtml])
106 AC_CONFIG_SUBDIRS(src/libopm)
107 AC_OUTPUT(Makefile src/Makefile)
109 echo "##############################################################################"
110 echo "Everything is now configured, but you can find some more (infrequently"
111 echo "changed) options in options.h. To compile BOPM now, just type make. It"
112 echo "requires GNU Make, which may be installed as gmake on your system."
114 echo "bopm will be installed in ${prefix}. To change this, run:"
115 echo " ./configure --prefix=DIRECTORY"
117 echo "If possible, PLEASE CONTRIBUTE TO OUR DNSBL BY REPORTING YOUR PROXIES!!"
119 echo "o What is DNSBL?"
120 echo " It's the database of open proxies we provide and your BOPM checks"
121 echo " against BEFORE bothering to scan the client, therefore killing KNOWN"
122 echo " proxies faster and more efficiently."
124 echo "o Why should my network contribute?"
125 echo " Because the more that do, the more proxies we know about and the"
126 echo " better the service becomes for all BOPM users including YOU! People"
127 echo " are also using our DNSBL to block spam (spammers use open proxies"
128 echo " too!) so you'd be helping the whole Internet."
130 echo "o Sounds complicated, what do you need?"
131 echo " BOPM is already designed to report the proxies you find, but it is"
132 echo " turned off by default. To enable it all you have to do is:"
133 echo " - Set DNSBL_FROM to a unique email address that we can contact you"
134 echo " at if there is ever any problem with your reports."
135 echo " - Email us now at opm@lists.blitzed.org to tell us what you have"
136 echo " set your DNSBL_FROM to."
137 echo " - Set DNSBL_TO to proxy-report@blitzed.org."
138 echo " - Set SENDMAIL to contain the path to your sendmail binary (even"
139 echo " if you don't use sendmail you will have a binary named sendmail in"
140 echo " /usr/sbin or /usr/lib."
142 echo "For more info about the people who already report their proxies, please"
143 echo "see http://www.blitzed.org/bopm/ - Thank you!"
144 echo "##############################################################################"