summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: aaa30a3)
raw | patch | inline | side by side (parent: aaa30a3)
author | Florian Forster <octo@leeloo.lan.home.verplant.org> | |
Sat, 1 May 2010 07:53:12 +0000 (09:53 +0200) | ||
committer | Florian Forster <octo@leeloo.lan.home.verplant.org> | |
Sat, 1 May 2010 07:53:12 +0000 (09:53 +0200) |
Previously, the check was done without "-Werror" which resulted in a
warning and success. When the daemon was later built with "-Werror" set,
that warning would result in an error and abort the build.
Thanks to Aurélien Reynaud for reporting the problem.
warning and success. When the daemon was later built with "-Werror" set,
that warning would result in an error and abort the build.
Thanks to Aurélien Reynaud for reporting the problem.
configure.in | patch | blob | history |
diff --git a/configure.in b/configure.in
index 6b66b2ac92373ed0edbcafa6edf066319e1ca69f..c0ffb03c4eb66f9ba13ea92588b49b5b378773d1 100644 (file)
--- a/configure.in
+++ b/configure.in
@@ -459,6 +459,13 @@ AC_CHECK_FUNCS(gettimeofday select strdup strtol getaddrinfo getnameinfo strchr
AC_FUNC_STRERROR_R
+SAVE_CFLAGS="$CFLAGS"
+# Emulate behavior of src/Makefile.am
+if test "x$GCC" = "xyes"
+then
+ CFLAGS="$CFLAGS -Wall -Werror"
+fi
+
AC_CACHE_CHECK([for strtok_r],
[c_cv_have_strtok_r_default],
AC_LINK_IFELSE(
if test "x$c_cv_have_strtok_r_default" = "xno"
then
- SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -D_REENTRANT=1"
AC_CACHE_CHECK([if strtok_r needs _REENTRANT],
)
fi
+CFLAGS="$SAVE_CFLAGS"
+if test "x$c_cv_have_strtok_r_reentrant" = "xyes"
+then
+ CFLAGS="$CFLAGS -D_REENTRANT=1"
+fi
+
AC_CHECK_FUNCS(getpwnam_r getgrnam_r setgroups regcomp regerror regexec regfree)
socket_needs_socket="no"