]> arthur.barton.de Git - ngircd-alex.git/blobdiff - configure.ng
ngIRCd Release 27
[ngircd-alex.git] / configure.ng
index 195e4067beda5d12e6b0e58032c6848313ee548e..0dccfbc5d466ad0f908909ab4b9a4c2ee7cb8ce7 100644 (file)
@@ -23,7 +23,7 @@ m4_ifdef([AM_SILENT_RULES],
 # -- Initialisation --
 
 AC_PREREQ([2.61])
-AC_INIT([ngIRCd],[VERSION_ID],[ngircd-ml@ngircd.barton.de],[ngircd],[http://ngircd.barton.de/])
+AC_INIT([ngIRCd],[VERSION_ID],[ngircd@lists.barton.de],[ngircd],[https://ngircd.barton.de/])
 
 AC_CONFIG_SRCDIR([src/ngircd/ngircd.c])
 AC_CONFIG_HEADER([src/config.h])
@@ -125,6 +125,20 @@ main(int argc, char **argv)
        ])
 ])
 
+AC_DEFUN([GCC_W_NO_FORMAT_TRUNC],[
+       result=yes
+       AC_MSG_CHECKING([whether ${CC} accepts -Wno-format-truncation])
+       old_cflags="$CFLAGS"
+       CFLAGS="$CFLAGS -Werror -Wno-format-truncation"
+       AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],[],[result=no])
+       echo $result
+       if test "X$result" = "Xyes"; then
+               CFLAGS="$old_cflags -Wno-format-truncation"
+       else
+               CFLAGS="$old_cflags"
+       fi
+])
+
 # -- Hard coded system and compiler dependencies/features/options ... --
 
 if test "$GCC" = "yes"; then
@@ -132,6 +146,7 @@ if test "$GCC" = "yes"; then
        CFLAGS="$CFLAGS -pipe -W -Wall -Wpointer-arith -Wstrict-prototypes"
 
        GCC_STACK_PROTECT_CC
+       GCC_W_NO_FORMAT_TRUNC
 fi
 
 case "$host_os" in
@@ -177,6 +192,8 @@ AC_CHECK_HEADERS_ONCE([ \
        stdbool.h \
        stddef.h \
        stdint.h \
+       sys/resource.h \
+       sys/un.h \
        varargs.h \
 ])
 
@@ -259,6 +276,7 @@ AC_CHECK_FUNCS_ONCE([
        getnameinfo \
        inet_aton \
        setgroups \
+       setrlimit \
        sigaction \
        sigprocmask \
        snprintf \