diff --git a/configure.ac b/configure.ac index 0386d11f527a82af1875cb7dce90ea39bedf9737..b8268b392881096cb2f9284682b10aebbdad92e2 100644 --- a/configure.ac +++ b/configure.ac @@ -3364,12 +3364,11 @@ LIBCURL_LIBS=$LIBS AC_SUBST(LIBCURL_LIBS) AC_SUBST(CURL_NETWORK_LIBS) AC_SUBST(CURL_NETWORK_AND_TIME_LIBS) -dnl LIBS is a magic variable that's used for every link -dnl BLANK_AT_MAKETIME might be used in some of our Makefile.am files to -dnl blank LIBS variable used in generated makefile at makefile processing -dnl time. Our test server's Makefile.am uses this to prevent global LIBS -dnl from being used for any test server build target. +dnl BLANK_AT_MAKETIME may be used in our Makefile.am files to blank +dnl LIBS variable used in generated makefile at makefile processing +dnl time. Doing this functionally prevents LIBS from being used for +dnl all link targets in given makefile. BLANK_AT_MAKETIME= AC_SUBST(BLANK_AT_MAKETIME) diff --git a/docs/examples/Makefile.am b/docs/examples/Makefile.am index 49c20361f5fda22c87a82aa6575410a406700e30..865f0937123813814210b14e093d747578726453 100644 --- a/docs/examples/Makefile.am +++ b/docs/examples/Makefile.am @@ -48,7 +48,7 @@ if USE_CPPFLAG_CURL_STATICLIB AM_CPPFLAGS += -DCURL_STATICLIB endif -# Prevent global LIBS from influencing examples build targets +# Prevent LIBS from being used for all link targets LIBS = $(BLANK_AT_MAKETIME) # Dependencies diff --git a/lib/Makefile.am b/lib/Makefile.am index c8a88cd1383e0639dc856726eb3b828ec9f882cf..91790267a55cfdc8e8b94ab793d345cbdbb2b9a5 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -132,7 +132,7 @@ if VERSIONED_SYMBOLS VERSIONED_SYMBOLS = -Wl,--version-script=libcurl.vers endif -# Prevent global LIBS from influencing lib build targets +# Prevent LIBS from being used for all link targets LIBS = $(BLANK_AT_MAKETIME) libcurl_la_LDFLAGS = $(UNDEF) $(VERSIONINFO) $(MIMPURE) $(VERSIONED_SYMBOLS) $(LIBCURL_LIBS) diff --git a/src/Makefile.am b/src/Makefile.am index 7839904d53cc11ad932ed3c86b53f701ede6c584..6de750114e06129510303cb9ffce52966fe71b72 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -54,7 +54,7 @@ include Makefile.inc # This might hold -Werror CFLAGS += @CURL_CFLAG_EXTRAS@ @LIBMETALINK_CFLAGS@ -# Prevent global LIBS from influencing src build targets +# Prevent LIBS from being used for all link targets LIBS = $(BLANK_AT_MAKETIME) if USE_EXPLICIT_LIB_DEPS diff --git a/tests/libtest/Makefile.am b/tests/libtest/Makefile.am index a9d0b90310c529791561cba6b143de1874f5c0b8..df13df1110dbffb70dbf32310c97412be898ffb5 100644 --- a/tests/libtest/Makefile.am +++ b/tests/libtest/Makefile.am @@ -55,8 +55,7 @@ test1022.pl Makefile.inc notexists.pl CFLAG_CURL_SYMBOL_HIDING = @CFLAG_CURL_SYMBOL_HIDING@ -# Prevent global LIBS from influencing libtest build targets -BLANK_AT_MAKETIME = @BLANK_AT_MAKETIME@ +# Prevent LIBS from being used for all link targets LIBS = $(BLANK_AT_MAKETIME) if USE_EXPLICIT_LIB_DEPS diff --git a/tests/server/Makefile.am b/tests/server/Makefile.am index 85e0c097c1fb177b49ec5469407655cca3a66fef..d4ef252db13f697919931c52ed009c326f2a6e78 100644 --- a/tests/server/Makefile.am +++ b/tests/server/Makefile.am @@ -50,8 +50,7 @@ AM_CPPFLAGS = -I$(top_builddir)/include/curl \ -I$(top_srcdir)/lib endif -# Prevent global LIBS from influencing test server build targets -BLANK_AT_MAKETIME = @BLANK_AT_MAKETIME@ +# Prevent LIBS from being used for all link targets LIBS = $(BLANK_AT_MAKETIME) if DOING_NATIVE_WINDOWS diff --git a/tests/unit/Makefile.am b/tests/unit/Makefile.am index 0582168141fd05d0d63828785c16845925f857b9..eb29241ad43cfdd867d698b9388512486c470071 100644 --- a/tests/unit/Makefile.am +++ b/tests/unit/Makefile.am @@ -54,7 +54,10 @@ endif EXTRA_DIST = Makefile.inc -LDADD = $(top_builddir)/lib/libcurlu.la @LDFLAGS@ @LIBCURL_LIBS@ @LIBS@ +# Prevent LIBS from being used for all link targets +LIBS = $(BLANK_AT_MAKETIME) + +LDADD = $(top_builddir)/lib/libcurlu.la @LDFLAGS@ @LIBCURL_LIBS@ DEPENDENCIES = $(top_builddir)/lib/libcurlu.la AM_CPPFLAGS += -DUNITTESTS