]> git.ipfire.org Git - thirdparty/lldpd.git/commitdiff
build: let AC_SEARCH_LIBS modify LIBS
authorVincent Bernat <vincent@bernat.im>
Sun, 13 Dec 2015 08:52:43 +0000 (09:52 +0100)
committerVincent Bernat <vincent@bernat.im>
Sun, 13 Dec 2015 08:52:43 +0000 (09:52 +0100)
Users is expected to be able to modify CFLAGS and LDFLAGS. We don't care
about other variables like LIBS.

configure.ac

index 3e3461d4ce12f50ce532a5bccab3e39582e565a4..d3bf3c13dc70213bdc2418a57a9cf3a95fcd2be5 100644 (file)
@@ -160,6 +160,9 @@ AC_REPLACE_FUNCS([strlcpy
 # Optional functions
 AC_CHECK_FUNCS([setresuid setresgid])
 
+CFLAGS="$_save_CFLAGS"
+LIBS="$_save_LIBS"
+
 # Check for res_init. On OSX, res_init is a symbol in libsystem_info
 # and a macro in resolv.h. We need to ensure we test with resolv.h.
 m4_pushdef([AC_LANG_CALL(C)], [
@@ -170,9 +173,6 @@ AC_SEARCH_LIBS([res_init], resolv bind,
                [Define to indicate that res_init() exists]))
 m4_popdef([AC_LANG_CALL(C)])
 
-CFLAGS="$_save_CFLAGS"
-LIBS="$_save_LIBS"
-
 AC_CACHE_SAVE
 
 ## Unit tests wich check