]> jfr.im git - irc/ircd-hybrid/bopm.git/blob - configure.in
Fixed missing ; in config-parser.y
[irc/ircd-hybrid/bopm.git] / configure.in
1 dnl Process this file with autoconf to produce a configure script.
2 AC_INIT(bopm, [3.0])
3 AC_CONFIG_SRCDIR(src/opercmd.h)
4 AM_CONFIG_HEADER(src/setup.h)
5 AM_INIT_AUTOMAKE()
6 AC_PREFIX_DEFAULT([\${HOME}/bopm])
7 AM_MAINTAINER_MODE
8
9 AC_ARG_WITH(select,
10 AC_HELP_STRING([--with-select], [use select() instead of poll()]),
11 [with_select="yes"], [with_select="no"])
12 AC_ARG_WITH(unreal,
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"])
20
21
22 dnl ipv6?
23 AC_ARG_ENABLE(ipv6,
24 AC_HELP_STRING([--enable-ipv6], [Enable IPV6 support]),
25 [ac_cv_ipv6=$enableval], [ac_cv_ipv6="no"])
26
27 AC_MSG_CHECKING([whether to enable IPv6 features])
28
29 if test "$ac_cv_ipv6" = "yes" ; then
30 AC_DEFINE(IPV6, 1, [Use Ipv6 Support])
31 AC_MSG_RESULT([yes])
32 else
33 AC_MSG_RESULT([no])
34 fi
35
36 dnl Checks for programs.
37 AC_PROG_CC
38
39 dnl Checks for libraries.
40
41 dnl Checks for header files.
42 AC_HEADER_STDC
43
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])
47 else
48 AC_CHECK_HEADERS(sys/poll.h, have_poll_sys_h=yes, have_sys_poll_h=no)
49 fi
50
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)])
54 fi
55
56 AC_CHECK_HEADERS(fcntl.h sys/time.h unistd.h strings.h)
57
58 dnl Checks for typedefs, structures, and compiler characteristics.
59 AC_C_CONST
60 AC_TYPE_SIZE_T
61 AC_HEADER_TIME
62 AC_STRUCT_TM
63
64 dnl Checks for library functions.
65 AC_TYPE_SIGNAL
66 AC_FUNC_STRFTIME
67
68 dnl check for yacc
69 AC_PROG_INSTALL
70 AC_PROG_YACC
71
72 dnl check for lexx
73 AM_PROG_LEX
74
75
76
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])
83 fi
84 fi
85
86 AC_CHECK_FUNCS(inet_aton inet_pton socket strdup strstr)
87
88 dnl Check if we can use gethostbyname2 for ipv6
89 AC_CHECK_FUNCS(gethostbyname gethostbyname2)
90
91 dnl AIX fun
92 AC_C_BIGENDIAN
93
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]))
97
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
101 echo $ECHO_N ".\a"
102 sleep 1
103 done
104 AC_MSG_RESULT([ http://www.blitzed.org/goat_winter_2001.phtml])
105
106 AC_CONFIG_SUBDIRS(src/libopm)
107 AC_OUTPUT(Makefile src/Makefile)
108
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."
113 echo
114 echo "bopm will be installed in ${prefix}. To change this, run:"
115 echo " ./configure --prefix=DIRECTORY"
116 echo
117 echo "If possible, PLEASE CONTRIBUTE TO OUR DNSBL BY REPORTING YOUR PROXIES!!"
118 echo
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."
123 echo
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."
129 echo
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."
141 echo
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 "##############################################################################"
145 echo