]> arthur.barton.de Git - ngircd-alex.git/blob - configure.in
INSTALL: update GNU automake/autoconf requirements
[ngircd-alex.git] / configure.in
1 #
2 # ngIRCd -- The Next Generation IRC Daemon
3 # Copyright (c)2001-2012 Alexander Barton (alex@barton.de) and Contributors
4 #
5 # This program is free software; you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation; either version 2 of the License, or
8 # (at your option) any later version.
9 # Please read the file COPYING, README and AUTHORS for more information.
10 #
11
12 define(VERSION_ID,esyscmd(git describe|sed -e 's/rel-//g'|sed -e 's/-/~/'|tr -d \\n))
13
14 m4_ifdef([AM_SILENT_RULES],
15         [m4_define([ng_color_tests], [color-tests])],
16         [m4_define([ng_color_tests], [])])
17
18 # -- Initialisation --
19
20 AC_PREREQ([2.61])
21 AC_INIT([ngIRCd], VERSION_ID,
22         [ngircd-ml@ngircd.barton.de], [ngircd], [http://ngircd.barton.de/])
23
24 AC_CONFIG_SRCDIR([src/ngircd/ngircd.c])
25 AC_CONFIG_HEADER([src/config.h])
26 AC_CANONICAL_HOST
27
28 AM_INIT_AUTOMAKE([-Wall 1.10 ]ng_color_tests)
29
30 m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
31
32 # -- Templates for config.h --
33
34 AH_TEMPLATE([DEBUG], [Define if debug-mode should be enabled])
35 AH_TEMPLATE([HAVE_sockaddr_in_len], [Define if sockaddr_in.sin_len exists])
36 AH_TEMPLATE([HAVE_socklen_t], [Define if socklen_t exists])
37 AH_TEMPLATE([IDENTAUTH], [Define if the server should do IDENT requests])
38 AH_TEMPLATE([IRCPLUS], [Define if IRC+ protocol should be used])
39 AH_TEMPLATE([PAM], [Define if PAM should be used])
40 AH_TEMPLATE([SNIFFER], [Define if IRC sniffer should be enabled])
41 AH_TEMPLATE([STRICT_RFC], [Define if ngIRCd should behave strict RFC compliant])
42 AH_TEMPLATE([SYSLOG], [Define if syslog should be used for logging])
43 AH_TEMPLATE([TCPWRAP], [Define if TCP wrappers should be used])
44 AH_TEMPLATE([WANT_IPV6], [Define if IPV6 protocol should be enabled])
45 AH_TEMPLATE([ZLIB], [Define if zlib compression should be enabled])
46
47 AH_TEMPLATE([HOST_OS], [Target operating system name])
48 AH_TEMPLATE([HOST_VENDOR], [Target system vendor])
49 AH_TEMPLATE([HOST_CPU], [Target CPU name])
50
51 # -- C Compiler --
52
53 AC_PROG_CC
54 AC_PROG_CC_STDC
55
56 # -- Helper programs --
57
58 AC_PROG_AWK
59 AC_PROG_INSTALL
60 AC_PROG_LN_S
61 AC_PROG_MAKE_SET
62 AC_PROG_RANLIB
63
64 # -- Compiler Features --
65
66 AC_C_CONST
67 AC_C_INLINE
68 AM_C_PROTOTYPES
69
70 # -- Hard coded system and compiler dependencies/features/options ... --
71
72 AC_DEFUN([GCC_STACK_PROTECT_CC],[
73   ssp_cc=yes
74   # we use -fstack-protector-all for the test to enfoce the use of the guard variable 
75   AC_MSG_CHECKING([whether ${CC} accepts -fstack-protector])
76   ssp_old_cflags="$CFLAGS"
77   CFLAGS="$CFLAGS -fstack-protector-all"
78   AC_TRY_LINK(,,, ssp_cc=no)
79   echo $ssp_cc
80   CFLAGS="$ssp_old_cflags"
81   if test "X$ssp_cc" = "Xyes"; then
82       CFLAGS="$CFLAGS -fstack-protector"
83       AC_DEFINE([ENABLE_SSP_CC], 1, [Define if SSP C support is enabled.])
84   fi
85 ])
86
87 if test "$GCC" = "yes"; then
88         # We are using the GNU C compiler. Good!
89         CFLAGS="$CFLAGS -pipe -W -Wall -Wpointer-arith -Wstrict-prototypes"
90
91         GCC_STACK_PROTECT_CC
92 fi
93
94 case "$host_os" in
95         hpux*)
96                 # This is HP/UX, we need to define _XOPEN_SOURCE_EXTENDED
97                 # (tested with HP/UX 11.11)
98                 CFLAGS="$CFLAGS -D_XOPEN_SOURCE_EXTENDED"
99                 ;;
100 esac
101
102 # Add additional CFLAGS, eventually specified on the command line:
103 test -n "$CFLAGS_ADD" && CFLAGS="$CFLAGS $CFLAGS_ADD"
104
105 CFLAGS="$CFLAGS -DSYSCONFDIR='\"\$(sysconfdir)\"'"
106
107 # -- Headers --
108
109 AC_HEADER_STDC
110 AC_HEADER_SYS_WAIT
111 AC_HEADER_TIME
112
113 # Required header files
114 AC_CHECK_HEADERS([ \
115         fcntl.h netdb.h netinet/in.h netinet/in_systm.h stdlib.h string.h \
116         strings.h sys/socket.h sys/time.h unistd.h \
117         ],,AC_MSG_ERROR([required C header missing!]))
118
119 # Optional header files
120 AC_CHECK_HEADERS_ONCE([ \
121         arpa/inet.h inttypes.h malloc.h netinet/ip.h stdbool.h stddef.h \
122         stdint.h varargs.h \
123         ])
124
125 # -- Datatypes --
126
127 AC_MSG_CHECKING(whether socklen_t exists)
128 AC_TRY_COMPILE([
129 #include <sys/types.h>
130 #include <sys/socket.h>
131         ],[
132         socklen_t a, b;
133         a = 2; b = 4; a += b;
134         ],[
135         AC_DEFINE(HAVE_socklen_t) AC_MSG_RESULT(yes)
136         ],[
137         AC_MSG_RESULT(no)
138 ])
139
140 AC_TYPE_PID_T
141 AC_TYPE_SIGNAL
142 AC_TYPE_SIZE_T
143 AC_TYPE_SSIZE_T
144 AC_TYPE_UID_T
145 AC_TYPE_UINT16_T
146 AC_TYPE_UINT32_T
147 AC_TYPE_UINT8_T
148
149 AC_CHECK_MEMBER([struct sockaddr_in.sin_len], AC_DEFINE(HAVE_sockaddr_in_len),,
150  [#include <arpa/inet.h>])
151
152 # -- Libraries --
153
154 # memmove: A/UX libUTIL
155 AC_SEARCH_LIBS([memmove], [UTIL], [], [
156         AC_MSG_ERROR([unable to find the memmove() function])
157 ])
158 # gethostbyname: Solaris libnsl
159 AC_SEARCH_LIBS([gethostbyname], [nsl], [], [
160         AC_MSG_ERROR([unable to find the gethostbyname() function])
161 ])
162 # bind: SVR4 libsocket
163 AC_SEARCH_LIBS([bind], [socket], [], [
164         AC_MSG_ERROR([unable to find the bind() function])
165 ])
166
167 # -- Functions --
168
169 AC_FUNC_FORK
170 AC_FUNC_STRFTIME
171
172 # Required functions
173 AC_CHECK_FUNCS([ \
174         alarm dup2 endpwent gethostbyaddr gethostbyname gethostname \
175         gettimeofday inet_ntoa memmove memset setsid socket strcasecmp \
176         strchr strcspn strerror strncasecmp strrchr strspn strstr \
177         ],,
178         AC_MSG_ERROR([required function missing!]))
179
180 # Optional functions
181 AC_CHECK_FUNCS_ONCE([ \
182         gai_strerror getaddrinfo getnameinfo inet_aton sigaction sigprocmask \
183         snprintf vsnprintf strdup strlcpy strlcat strtok_r waitpid])
184
185 # -- Configuration options --
186
187 # use syslog?
188
189 x_syslog_on=no
190 AC_ARG_WITH(syslog,
191         AS_HELP_STRING([--without-syslog],
192                        [disable syslog (autodetected by default)]),
193         [       if test "$withval" != "no"; then
194                         if test "$withval" != "yes"; then
195                                 CFLAGS="-I$withval/include $CFLAGS"
196                                 CPPFLAGS="-I$withval/include $CPPFLAGS"
197                                 LDFLAGS="-L$withval/lib $LDFLAGS"
198                         fi
199                         AC_SEARCH_LIBS([syslog], [be], [x_syslog_on=yes], [
200                                 AC_MSG_ERROR([Can't enable syslog!])
201                         ])
202                 fi
203         ],
204         [       AC_SEARCH_LIBS([syslog], [be], [x_syslog_on=yes])
205         ]
206 )
207 if test "$x_syslog_on" = "yes"; then
208         AC_DEFINE(SYSLOG, 1)
209         AC_CHECK_HEADERS(syslog.h,,AC_MSG_ERROR([required C header missing!]))
210 fi
211
212 # use zlib compression?
213
214 x_zlib_on=no
215 AC_ARG_WITH(zlib,
216         AS_HELP_STRING([--without-zlib],
217                        [disable zlib compression (autodetected by default)]),
218         [       if test "$withval" != "no"; then
219                         if test "$withval" != "yes"; then
220                                 CFLAGS="-I$withval/include $CFLAGS"
221                                 CPPFLAGS="-I$withval/include $CPPFLAGS"
222                                 LDFLAGS="-L$withval/lib $LDFLAGS"
223                         fi
224                         AC_CHECK_LIB(z, deflate)
225                         AC_CHECK_FUNCS(deflate, x_zlib_on=yes,
226                                 AC_MSG_ERROR([Can't enable zlib!])
227                         )
228                 fi
229         ],
230         [       AC_CHECK_LIB(z, deflate)
231                 AC_CHECK_FUNCS(deflate, x_zlib_on=yes)
232         ]
233 )
234 if test "$x_zlib_on" = "yes"; then
235         AC_DEFINE(ZLIB, 1)
236         AC_CHECK_HEADERS(zlib.h,,AC_MSG_ERROR([required C header missing!]))
237 fi
238
239 # detect which IO API to use:
240
241 x_io_backend=none
242
243 AC_ARG_WITH(select,
244         AS_HELP_STRING([--without-select],
245                        [disable select IO support (autodetected by default)]),
246         [       if test "$withval" != "no"; then
247                         if test "$withval" != "yes"; then
248                                 CFLAGS="-I$withval/include $CFLAGS"
249                                 CPPFLAGS="-I$withval/include $CPPFLAGS"
250                                 LDFLAGS="-L$withval/lib $LDFLAGS"
251                         fi
252                         AC_CHECK_FUNCS(select, x_io_select=yes,
253                                 AC_MSG_ERROR([Can't enable select IO support!])
254                         )
255                 fi
256         ],
257         [
258                 AC_CHECK_FUNCS(select, x_io_select=yes)
259         ]
260 )
261
262 AC_ARG_WITH(poll,
263         AS_HELP_STRING([--without-poll],
264                        [disable poll support (autodetected by default)]),
265         [       if test "$withval" != "no"; then
266                         if test "$withval" != "yes"; then
267                                 CFLAGS="-I$withval/include $CFLAGS"
268                                 CPPFLAGS="-I$withval/include $CPPFLAGS"
269                                 LDFLAGS="-L$withval/lib $LDFLAGS"
270                         fi
271                         AC_CHECK_FUNCS(poll, [
272                                 AC_CHECK_HEADERS(poll.h,
273                                         x_io_backend=poll\(\),
274                                         AC_MSG_ERROR(
275                                              [Can't enable poll IO support!])
276                                 )
277                         ], [
278                                 AC_MSG_ERROR([Can't enable poll IO support!])
279                         ])
280                 fi
281         ],
282         [
283                 AC_CHECK_FUNCS(poll, [
284                         AC_CHECK_HEADERS(poll.h, x_io_backend=poll\(\))
285                 ])
286         ]
287 )
288
289 AC_ARG_WITH(devpoll,
290         AS_HELP_STRING([--without-devpoll],
291                        [disable /dev/poll IO support (autodetected by default)]),
292         [       if test "$withval" != "no"; then
293                         if test "$withval" != "yes"; then
294                                 CFLAGS="-I$withval/include $CFLAGS"
295                                 CPPFLAGS="-I$withval/include $CPPFLAGS"
296                                 LDFLAGS="-L$withval/lib $LDFLAGS"
297                         fi
298
299                                 AC_CHECK_HEADERS(sys/devpoll.h,,AC_MSG_ERROR([required C header missing!]))
300                 fi
301         ],
302         [
303                 AC_CHECK_HEADERS(sys/devpoll.h, x_io_backend=/dev/poll)
304         ]
305 )
306
307 AC_ARG_WITH(epoll,
308         AS_HELP_STRING([--without-epoll],
309                        [disable epoll IO support (autodetected by default)]),
310         [       if test "$withval" != "no"; then
311                         if test "$withval" != "yes"; then
312                                 CFLAGS="-I$withval/include $CFLAGS"
313                                 CPPFLAGS="-I$withval/include $CPPFLAGS"
314                                 LDFLAGS="-L$withval/lib $LDFLAGS"
315                         fi
316                         AC_CHECK_FUNCS(epoll_create, x_io_epoll=yes,
317                                 AC_MSG_ERROR([Can't enable epoll IO support!])
318                         )
319                 fi
320         ],
321         [
322                 AC_CHECK_FUNCS(epoll_create, x_io_epoll=yes)
323         ]
324 )
325
326 AC_ARG_WITH(kqueue,
327         AS_HELP_STRING([--without-kqueue],
328                        [disable kqueue IO support (autodetected by default)]),
329         [       if test "$withval" != "no"; then
330                         if test "$withval" != "yes"; then
331                                 CFLAGS="-I$withval/include $CFLAGS"
332                                 CPPFLAGS="-I$withval/include $CPPFLAGS"
333                                 LDFLAGS="-L$withval/lib $LDFLAGS"
334                         fi
335                         AC_CHECK_FUNCS(kqueue, x_io_backend=kqueue\(\),
336                                 AC_MSG_ERROR([Can't enable kqueue IO support!])
337                         )
338                 fi
339         ],
340         [
341                 AC_CHECK_FUNCS(kqueue, x_io_backend=kqueue\(\))
342         ]
343 )
344
345 if test "$x_io_epoll" = "yes" -a "$x_io_select" = "yes"; then
346         # when epoll() and select() are available, we'll use both!
347         x_io_backend="epoll(), select()"
348 else
349         if test "$x_io_epoll" = "yes"; then
350                 # we prefere epoll() if it is available
351                 x_io_backend="epoll()"
352         else
353                 if test "$x_io_select" = "yes" -a "$x_io_backend" = "none"; then
354                         # we'll use select, when available and no "better"
355                         # interface has been detected ...
356                         x_io_backend="select()"
357                 fi
358         fi
359 fi
360
361 if test "$x_io_backend" = "none"; then
362         AC_MSG_ERROR([No useable IO API activated/found!?])
363 fi
364
365 # use SSL?
366
367 AC_ARG_WITH(openssl,
368         AS_HELP_STRING([--with-openssl],
369                        [enable SSL support using OpenSSL]),
370         [       if test "$withval" != "no"; then
371                         if test "$withval" != "yes"; then
372                                 CFLAGS="-I$withval/include $CFLAGS"
373                                 CPPFLAGS="-I$withval/include $CPPFLAGS"
374                                 LDFLAGS="-L$withval/lib $LDFLAGS"
375                         fi
376                         AC_CHECK_LIB(crypto, BIO_s_mem)
377                         AC_CHECK_LIB(ssl, SSL_library_init)
378                         AC_CHECK_FUNCS(SSL_library_init, x_ssl_openssl=yes,
379                                 AC_MSG_ERROR([Can't enable openssl])
380                         )
381                 fi
382         ]
383 )
384
385 AC_ARG_WITH(gnutls,
386         AS_HELP_STRING([--with-gnutls],
387                        [enable SSL support using gnutls]),
388         [       if test "$withval" != "no"; then
389                         if test "$withval" != "yes"; then
390                                 CFLAGS="-I$withval/include $CFLAGS"
391                                 CPPFLAGS="-I$withval/include $CPPFLAGS"
392                                 LDFLAGS="-L$withval/lib $LDFLAGS"
393                         fi
394                         AC_CHECK_LIB(gnutls, gnutls_global_init)
395                         AC_CHECK_FUNCS(gnutls_global_init, x_ssl_gnutls=yes,
396                                 AC_MSG_ERROR([Can't enable gnutls])
397                         )
398                 fi
399         ]
400 )
401
402 x_ssl_lib="no"
403 if test "$x_ssl_gnutls" = "yes"; then
404         if test "$x_ssl_openssl" = "yes";then
405                 AC_MSG_ERROR([Cannot enable both gnutls and openssl])
406         fi
407         x_ssl_lib=gnutls
408 fi
409 if test "$x_ssl_openssl" = "yes"; then
410         x_ssl_lib=openssl
411 fi
412
413 # use TCP wrappers?
414
415 x_tcpwrap_on=no
416 AC_ARG_WITH(tcp-wrappers,
417         AS_HELP_STRING([--with-tcp-wrappers],
418                        [enable TCP wrappers support]),
419         [       if test "$withval" != "no"; then
420                         if test "$withval" != "yes"; then
421                                 CFLAGS="-I$withval/include $CFLAGS"
422                                 CPPFLAGS="-I$withval/include $CPPFLAGS"
423                                 LDFLAGS="-L$withval/lib $LDFLAGS"
424                         fi
425                         AC_MSG_CHECKING(for hosts_access)
426                         LIBS="-lwrap $LIBS"
427                         AC_TRY_LINK([
428 #include <tcpd.h>
429 int allow_severity = 0;
430 int deny_severity = 0;
431                                 ],[
432                                 tcpd_warn("link test");
433                                 ],[
434                                 AC_MSG_RESULT(yes)
435                                 AC_DEFINE(TCPWRAP, 1)
436                                 x_tcpwrap_on=yes
437                                 ],[
438                                 AC_MSG_RESULT(no)
439                                 AC_MSG_ERROR([Can't enable TCP wrappers!])
440                         ])
441                 fi
442         ]
443 )
444
445 # do IDENT requests using libident?
446
447 x_identauth_on=no
448 AC_ARG_WITH(ident,
449         AS_HELP_STRING([--with-ident],
450                        [enable "IDENT" ("AUTH") protocol support]),
451         [       if test "$withval" != "no"; then
452                         if test "$withval" != "yes"; then
453                                 CFLAGS="-I$withval/include $CFLAGS"
454                                 CPPFLAGS="-I$withval/include $CPPFLAGS"
455                                 LDFLAGS="-L$withval/lib $LDFLAGS"
456                         fi
457                         AC_CHECK_LIB(ident, ident_id)
458                         AC_CHECK_FUNCS(ident_id, x_identauth_on=yes,
459                                 AC_MSG_ERROR([Can't enable IDENT support!])
460                         )
461                 fi
462         ]
463 )
464 if test "$x_identauth_on" = "yes"; then
465         AC_DEFINE(IDENTAUTH, 1)
466         AC_CHECK_HEADERS(ident.h,,AC_MSG_ERROR([required C header missing!]))
467 fi
468
469 # compile in PAM support?
470
471 x_pam_on=no
472 AC_ARG_WITH(pam,
473         AS_HELP_STRING([--with-pam],
474                        [enable user authentication using PAM]),
475         [       if test "$withval" != "no"; then
476                         if test "$withval" != "yes"; then
477                                 CFLAGS="-I$withval/include $CFLAGS"
478                                 CPPFLAGS="-I$withval/include $CPPFLAGS"
479                                 LDFLAGS="-L$withval/lib $LDFLAGS"
480                         fi
481                         AC_CHECK_LIB(pam, pam_authenticate)
482                         AC_CHECK_FUNCS(pam_authenticate, x_pam_on=yes,
483                                 AC_MSG_ERROR([Can't enable PAM support!])
484                         )
485                 fi
486         ]
487 )
488 if test "$x_pam_on" = "yes"; then
489         AC_DEFINE(PAM, 1)
490         AC_CHECK_HEADERS(security/pam_appl.h,pam_ok=yes)
491         if test "$pam_ok" != "yes"; then
492                 AC_CHECK_HEADERS(pam/pam_appl.h,pam_ok=yes,
493                         AC_MSG_ERROR([required C header missing!]))
494         fi
495 fi
496
497 # compile in IRC+ protocol support?
498
499 x_ircplus_on=yes
500 AC_ARG_ENABLE(ircplus,
501         AS_HELP_STRING([--disable-ircplus],
502                        [disable IRC+ protocol]),
503         if test "$enableval" = "no"; then x_ircplus_on=no; fi
504 )
505 if test "$x_ircplus_on" = "yes"; then
506         AC_DEFINE(IRCPLUS, 1)
507 fi
508
509 # enable support for IPv6?
510 x_ipv6_on=no
511 AC_ARG_ENABLE(ipv6,
512         AS_HELP_STRING([--enable-ipv6],
513                        [enable IPv6 protocol support]),
514         if test "$enableval" = "yes"; then x_ipv6_on=yes; fi
515 )
516 if test "$x_ipv6_on" = "yes"; then
517         # getaddrinfo() and getnameinfo() are optional when not compiling
518         # with IPv6 support, but are required for IPv6 to work!
519         AC_CHECK_FUNCS([ \
520                 getaddrinfo getnameinfo \
521                 ],,AC_MSG_ERROR([required function missing for IPv6 support!]))
522         AC_DEFINE(WANT_IPV6, 1)
523 fi
524
525 # compile in IRC "sniffer"?
526
527 x_sniffer_on=no; x_debug_on=no
528 AC_ARG_ENABLE(sniffer,
529         AS_HELP_STRING([--enable-sniffer],
530                        [enable IRC traffic sniffer (enables debug mode)]),
531         if test "$enableval" = "yes"; then
532                 AC_DEFINE(SNIFFER, 1)
533                 x_sniffer_on=yes; x_debug_on=yes
534         fi
535 )
536
537 # enable additional debugging code?
538
539 AC_ARG_ENABLE(debug,
540         AS_HELP_STRING([--enable-debug],
541                        [show additional debug output]),
542         if test "$enableval" = "yes"; then x_debug_on=yes; fi
543 )
544 if test "$x_debug_on" = "yes"; then
545         AC_DEFINE(DEBUG, 1)
546         test "$GCC" = "yes" && CFLAGS="-pedantic $CFLAGS"
547         AC_CHECK_FUNCS(mtrace)
548 fi
549
550 # enable "strict RFC rules"?
551
552 x_strict_rfc_on=no
553 AC_ARG_ENABLE(strict-rfc,
554         AS_HELP_STRING([--enable-strict-rfc],
555                        [strict RFC conformance -- may break clients!]),
556         if test "$enableval" = "yes"; then
557                 AC_DEFINE(STRICT_RFC, 1)
558                 x_strict_rfc_on=yes
559         fi
560 )
561
562 # -- Definitions --
563
564 AC_DEFINE_UNQUOTED(HOST_CPU, "$host_cpu" )
565 AC_DEFINE_UNQUOTED(HOST_VENDOR, "$host_vendor" )
566 AC_DEFINE_UNQUOTED(HOST_OS, "$host_os" )
567
568 # Add additional CFLAGS, eventually specified on the command line, but after
569 # running this configure script. Useful for "-Werror" for example.
570 test -n "$CFLAGS_END" && CFLAGS="$CFLAGS $CFLAGS_END"
571
572 # -- Generate files --
573
574 AC_CONFIG_FILES([ \
575         Makefile \
576         contrib/Anope/Makefile \
577         contrib/Debian/Makefile \
578         contrib/MacOSX/Makefile \
579         contrib/MacOSX/ngIRCd.pmdoc/Makefile \
580         contrib/MacOSX/ngIRCd.xcodeproj/Makefile \
581         contrib/Makefile \
582         doc/Makefile \
583         doc/src/Makefile \
584         man/Makefile \
585         src/ipaddr/Makefile \
586         src/Makefile \
587         src/ngircd/Makefile \
588         src/portab/Makefile \
589         src/testsuite/Makefile \
590         src/tool/Makefile \
591 ])
592
593 AC_OUTPUT
594
595 type dpkg >/dev/null 2>&1
596 if test $? -eq 0; then
597         # Generate debian/ link if the dpkg command exists
598         # (read: if we are running on a debian compatible system)
599         echo "creating Debian-specific links ..."
600         test -f debian/rules || ln -s contrib/Debian debian
601 fi
602
603 # -- Result --
604
605 echo
606 echo "ngIRCd $PACKAGE_VERSION has been configured with the following options:"
607 echo
608
609 # Someone please show me a better way :)  [borrowed by OpenSSH]
610 B=`eval echo ${bindir}` ; B=`eval echo ${B}`
611 S=`eval echo ${sbindir}` ; S=`eval echo ${S}`
612 C=`eval echo ${sysconfdir}` ; C=`eval echo ${C}`
613 M=`eval echo ${mandir}` ; M=`eval echo ${M}`
614 D=`eval echo ${docdir}` ; D=`eval echo ${D}`
615
616 echo "               Host: ${host}"
617 echo "           Compiler: ${CC}"
618 test -n "$CFLAGS"       && echo "     Compiler flags: ${CFLAGS}"
619 test -n "$CPPFLAGS"     && echo " Preprocessor flags: ${CPPFLAGS}"
620 test -n "$LDFLAGS"      && echo "       Linker flags: ${LDFLAGS}"
621 test -n "$LIBS"         && echo "          Libraries: ${LIBS}"
622 echo
623 echo "    'ngircd' binary: $S"
624 echo " Configuration file: $C"
625 echo "       Manual pages: $M"
626 echo "      Documentation: $D"
627 echo
628
629 echo $ECHO_N "     Syslog support: $ECHO_C"
630 test "$x_syslog_on" = "yes" \
631         && echo $ECHO_N "yes   $ECHO_C" \
632         || echo $ECHO_N "no    $ECHO_C"
633 echo $ECHO_N "  Enable debug code: $ECHO_C"
634 test "$x_debug_on" = "yes" \
635         && echo "yes" \
636         || echo "no"
637
638 echo $ECHO_N "   zlib compression: $ECHO_C"
639 test "$x_zlib_on" = "yes" \
640         && echo $ECHO_N "yes   $ECHO_C" \
641         || echo $ECHO_N "no    $ECHO_C"
642 echo $ECHO_N "        IRC sniffer: $ECHO_C"
643 test "$x_sniffer_on" = "yes" \
644         && echo "yes" \
645         || echo "no"
646
647 echo $ECHO_N "   Use TCP Wrappers: $ECHO_C"
648 test "$x_tcpwrap_on" = "yes" \
649         && echo $ECHO_N "yes   $ECHO_C" \
650         || echo $ECHO_N "no    $ECHO_C"
651 echo $ECHO_N "    Strict RFC mode: $ECHO_C"
652 test "$x_strict_rfc_on" = "yes" \
653         && echo "yes" \
654         || echo "no"
655
656 echo $ECHO_N "      IDENT support: $ECHO_C"
657 test "$x_identauth_on" = "yes" \
658         && echo $ECHO_N "yes   $ECHO_C" \
659         || echo $ECHO_N "no    $ECHO_C"
660 echo $ECHO_N "      IRC+ protocol: $ECHO_C"
661 test "$x_ircplus_on" = "yes" \
662         && echo "yes" \
663         || echo "no"
664
665 echo $ECHO_N "      IPv6 protocol: $ECHO_C"
666 test "$x_ipv6_on" = "yes" \
667         && echo $ECHO_N "yes   $ECHO_C" \
668         || echo $ECHO_N "no    $ECHO_C"
669 echo $ECHO_N "        I/O backend: $ECHO_C"
670         echo "\"$x_io_backend\""
671
672 echo $ECHO_N "        PAM support: $ECHO_C"
673 test "$x_pam_on" = "yes" \
674         && echo $ECHO_N "yes   $ECHO_C" \
675         || echo $ECHO_N "no    $ECHO_C"
676 echo $ECHO_N "        SSL support: $ECHO_C"
677 echo "$x_ssl_lib"
678
679 echo
680
681 # -eof-