From 388c3143acea4cba29f3c7d8cf6408e22ea2ae46 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Thu, 12 Mar 2015 10:45:17 +0100 Subject: [PATCH] xbps-src: tweak the order of LDFLAGS set in templates. Rather than appending to the final LDFLAGS, add it to the head, this way packages that use LDFLAGS="-lfoo" will still work with --as-needed. This fixes hsetroot build, at least. --- common/xbps-src/shutils/common.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/xbps-src/shutils/common.sh b/common/xbps-src/shutils/common.sh index 60f6d919f6..21c69c17b3 100644 --- a/common/xbps-src/shutils/common.sh +++ b/common/xbps-src/shutils/common.sh @@ -363,7 +363,7 @@ setup_pkg() { export CFLAGS="$XBPS_TARGET_CFLAGS $XBPS_CFLAGS $XBPS_CROSS_CFLAGS $CFLAGS $dbgflags" export CXXFLAGS="$XBPS_TARGET_CXXFLAGS $XBPS_CXXFLAGS $XBPS_CROSS_CXXFLAGS $CXXFLAGS $dbgflags" export CPPFLAGS="$XBPS_TARGET_CPPFLAGS $XBPS_CPPFLAGS $XBPS_CROSS_CPPFLAGS $CPPFLAGS" - export LDFLAGS="$XBPS_TARGET_LDFLAGS $XBPS_LDFLAGS $XBPS_CROSS_LDFLAGS $LDFLAGS" + export LDFLAGS="$LDFLAGS $XBPS_TARGET_LDFLAGS $XBPS_LDFLAGS $XBPS_CROSS_LDFLAGS" if [ -n "$broken_as_needed" ]; then LDFLAGS="${LDFLAGS/-Wl,--as-needed/}"