Blame SOURCES/0038-intg-fix-configure-failure-with-strict-cflags.patch

ecf709
From 076bd32668f7ea194389ddd526ea81f9bf12fb0e Mon Sep 17 00:00:00 2001
ecf709
From: Lukas Slebodnik <lslebodn@redhat.com>
ecf709
Date: Tue, 28 Mar 2017 12:18:13 +0200
ecf709
Subject: [PATCH 38/54] intg: fix configure failure with strict cflags
ecf709
MIME-Version: 1.0
ecf709
Content-Type: text/plain; charset=UTF-8
ecf709
Content-Transfer-Encoding: 8bit
ecf709
ecf709
The warning -Wstrict-prototypes is a part of AM_CFLAGS which was appended
ecf709
for CFLAGS in make target intgcheck-prepare. And combination with
ecf709
strict CFLAGS in environment variable (e.g. -Werror) caused failures.
ecf709
ecf709
sh$ CFLAGS="-Werror" make intgcheck-prepare
ecf709
ecf709
checking for gcc... gcc
ecf709
checking whether the C compiler works... no
ecf709
configure: error: in `/home/build/sssd/ci-build-debug/intg/bld':
ecf709
configure: error: C compiler cannot create executables
ecf709
ecf709
configure:3719: checking whether the C compiler works
ecf709
configure:3741: gcc -g3 -O2 -Werror -D_FILE_OFFSET_BITS=64
ecf709
                -D_LARGEFILE_SOURCE -Wall -Wshadow -Wstrict-prototypes
ecf709
                -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings
ecf709
                -Wundef -Werror-implicit-function-declaration
ecf709
                -Winit-self -Wmissing-include-dirs -fno-strict-aliasing
ecf709
                -std=gnu99 -DKCM_PEER_UID=1000   conftest.c  >&5
ecf709
conftest.c:11:1: error: function declaration isn't a prototype [-Werror=strict-prototypes]
ecf709
 main ()
ecf709
 ^~~~
ecf709
cc1: all warnings being treated as errors
ecf709
ecf709
Reviewed-by: Pavel Březina <pbrezina@redhat.com>
ecf709
---
ecf709
 Makefile.am | 2 +-
ecf709
 1 file changed, 1 insertion(+), 1 deletion(-)
ecf709
ecf709
diff --git a/Makefile.am b/Makefile.am
ecf709
index 91afdd669aa11a3cc316588d3b51d7e8e9c91cb8..359feddef298b0013c726409b7ba8b86504abf09 100644
ecf709
--- a/Makefile.am
ecf709
+++ b/Makefile.am
ecf709
@@ -3486,7 +3486,7 @@ intgcheck-prepare:
ecf709
 	    --without-semanage \
ecf709
 	    --enable-files-domain \
ecf709
 	    $(INTGCHECK_CONFIGURE_FLAGS) \
ecf709
-	    CFLAGS="$$CFLAGS $(AM_CFLAGS) -DKCM_PEER_UID=$$(id -u)"; \
ecf709
+	    CFLAGS="$$CFLAGS -DKCM_PEER_UID=$$(id -u)"; \
ecf709
 	$(MAKE) $(AM_MAKEFLAGS) ; \
ecf709
 	: Force single-thread install to workaround concurrency issues; \
ecf709
 	$(MAKE) $(AM_MAKEFLAGS) -j1 install; \
ecf709
-- 
ecf709
2.9.3
ecf709