From: Randy Witt Date: Fri, 16 Mar 2012 05:01:18 +0000 (-0400) Subject: configure.ac: Move link only flags out of CFLAGS and into LDFLAGS. X-Git-Tag: v7~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1701b1b46f049b3e0f27e8857eb0948767255b62;p=thirdparty%2Fkmod.git configure.ac: Move link only flags out of CFLAGS and into LDFLAGS. On the ARM gcc 4.2.2 I'm using I get many "--as-needed: linker input file unused because linking not done" style errors when libtool is using compile mode. In order to silence these warnings and be "correct", the flags that only make sense for linking were moved into LDFLAGS. --- diff --git a/configure.ac b/configure.ac index 7c04a4a5..d35141cc 100644 --- a/configure.ac +++ b/configure.ac @@ -126,9 +126,11 @@ CC_CHECK_CFLAGS_APPEND([ \ -fdiagnostics-show-option \ -fvisibility=hidden \ -ffunction-sections \ - -fdata-sections \ - -Wl,--as-needed \ - -Wl,--gc-sections]) + -fdata-sections]) + +CC_CHECK_LDFLAGS_APPEND([ \ + -Wl,--as-needed \ + -Wl,--gc-sections]) AC_CONFIG_HEADERS(config.h) AC_CONFIG_FILES([