]> arthur.barton.de Git - ngircd-alex.git/commitdiff
configure: make implicit declarations fatal
authorFlorian Westphal <fw@strlen.de>
Sat, 29 May 2010 11:06:19 +0000 (13:06 +0200)
committerAlexander Barton <alex@barton.de>
Wed, 9 Jun 2010 09:49:57 +0000 (11:49 +0200)
from bugzilla #105:
"ngircd-16 works great under openbsd4.7/i386, but it segfaults on
openbsd4.7/amd64."

Caused by missing function prototypes and the resulting truncation of
pointer to int.

Lets try to catch these bugs during compilation instead of SIGSEGV.

configure.in

index 6d9312d4d7cac169b174f13863271b3812135e57..8526af60e93e782b70afb1195f7d317672017ff4 100644 (file)
@@ -542,6 +542,7 @@ AC_DEFINE_UNQUOTED(TARGET_OS, "$target_os" )
 
 # Add additional CFLAGS, eventually specified on the command line, but after
 # running this configure script. Useful for "-Werror" for example.
+test "$GCC" = "yes" && CFLAGS="$CFLAGS -Werror=implicit-function-declaration"
 test -n "$CFLAGS_END" && CFLAGS="$CFLAGS $CFLAGS_END"
 
 # -- Generate files --