Merge pull request #2594 from ffontaine/master

lxc: fix build with --disable-werror
This commit is contained in:
Christian Brauner 2018-09-08 20:39:05 +01:00 committed by GitHub
commit 1ea1496dfd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -53,7 +53,7 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
#define CLANG_VERSION \
(__clang_major__ * 10000 + __clang_minor__ * 100 + __clang_patchlevel__)
#if GCC_VERSION < 40600 && CLANG_VERSION < 10000
#if GCC_VERSION < 40700 && CLANG_VERSION < 10000
#error Sorry, your compiler is too old - please upgrade it
#endif
]])], [valid_compiler=yes], [valid_compiler=no])
@ -683,8 +683,9 @@ AC_PROG_SED
# See if we support thread-local storage.
LXC_CHECK_TLS
CFLAGS="$CFLAGS -Wvla -std=gnu11"
if test "x$enable_werror" = "xyes"; then
CFLAGS="$CFLAGS -Werror -Wvla -std=gnu11"
CFLAGS="$CFLAGS -Werror"
fi
AC_ARG_ENABLE([thread-safety],