From: Christian Brauner Date: Tue, 5 Feb 2019 19:31:20 +0000 (+0100) Subject: compiler: -Wmissing-include-dirs hardening X-Git-Tag: lxc-3.2.0~166^2~9 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cc0c3a061298b0c74377195a7b7a94671affb9cb;p=thirdparty%2Flxc.git compiler: -Wmissing-include-dirs hardening Warn if a user-supplied include directory does not exist. This already surfaced a bug that is fixed by this commit. Signed-off-by: Christian Brauner --- diff --git a/configure.ac b/configure.ac index 6aee94be3..5918bc5e4 100644 --- a/configure.ac +++ b/configure.ac @@ -702,6 +702,7 @@ AX_CHECK_COMPILE_FLAG([-g], [CFLAGS="$CFLAGS -g"],,[-Werror]) AX_CHECK_COMPILE_FLAG([--mcet -fcf-protection], [CFLAGS="$CFLAGS --mcet -fcf-protection"],,[-Werror]) AX_CHECK_COMPILE_FLAG([-Werror=implicit-function-declaration], [CFLAGS="$CFLAGS -Werror=implicit-function-declaration"],,[-Werror]) AX_CHECK_COMPILE_FLAG([-Wlogical-op], [CFLAGS="$CFLAGS -Wlogical-op"],,[-Werror]) +AX_CHECK_COMPILE_FLAG([-Wmissing-include-dirs], [CFLAGS="$CFLAGS -Wmissing-include-dirs"],,[-Werror]) AX_CHECK_LINK_FLAG([-z relro], [LDLAGS="$LDLAGS -z relro"],,[]) AX_CHECK_LINK_FLAG([-z now], [LDLAGS="$LDLAGS -z now"],,[]) diff --git a/src/tests/Makefile.am b/src/tests/Makefile.am index f03d61eb8..842708c44 100644 --- a/src/tests/Makefile.am +++ b/src/tests/Makefile.am @@ -48,7 +48,6 @@ AM_CFLAGS=-DLXCROOTFSMOUNT=\"$(LXCROOTFSMOUNT)\" \ -DRUNTIME_PATH=\"$(RUNTIME_PATH)\" \ -I $(top_srcdir)/src \ -I $(top_srcdir)/src/lxc \ - -I $(top_srcdir)/src/lxc/bdev \ -I $(top_srcdir)/src/lxc/cgroups \ -I $(top_srcdir)/src/lxc/tools \ -pthread