commit:     141f1b5254fdbb263ba1d3a5697da791f359ffc7
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Mon Sep  7 14:30:53 2020 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Mon Sep  7 14:36:12 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=141f1b52

net-misc/oidc-agent: fix LDFLAGS propagation

Upstream uses three different sets of linker flags: one for
liboidc-agent.so (declared inline), one for oidc-token (CLIENT_LFLAGS)
and one for everything else (LFLAGS). The previous version of the
toolchain patch only injected LDFLAGS into the latter, hence QA warnings
for the former two.

Closes: https://bugs.gentoo.org/740778
Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 .../oidc-agent-3.3.1_makefile-toolchain-vars.patch     | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)

diff --git 
a/net-misc/oidc-agent/files/oidc-agent-3.3.1_makefile-toolchain-vars.patch 
b/net-misc/oidc-agent/files/oidc-agent-3.3.1_makefile-toolchain-vars.patch
index 0cdf44fba8c..1441cdc1319 100644
--- a/net-misc/oidc-agent/files/oidc-agent-3.3.1_makefile-toolchain-vars.patch
+++ b/net-misc/oidc-agent/files/oidc-agent-3.3.1_makefile-toolchain-vars.patch
@@ -28,3 +28,21 @@
  endif
  ifdef HAS_CJSON
        LFLAGS += -lcjson
+@@ -81,7 +81,7 @@
+ ifdef MAC_OS
+ CLIENT_LFLAGS = -L$(APILIB) -largp -loidc-agent.$(LIBVERSION)
+ else
+-CLIENT_LFLAGS = -L$(APILIB) -l:$(SHARED_LIB_NAME_FULL) -lseccomp
++CLIENT_LFLAGS = $(LDFLAGS) -L$(APILIB) -l:$(SHARED_LIB_NAME_FULL) -lseccomp
+ endif
+ ifdef HAS_CJSON
+       CLIENT_LFLAGS += -lcjson
+@@ -478,7 +478,7 @@
+ ifdef MAC_OS
+       @gcc -dynamiclib -fpic -Wl, -o $@ $(PIC_OBJECTS) -lc
+ else
+-      @gcc -shared -fpic -Wl,-soname,$(SONAME) -o $@ $(PIC_OBJECTS) -lc
++      @gcc -shared -fpic -Wl,-soname,$(SONAME) $(LDFLAGS) -o $@ 
$(PIC_OBJECTS) -lc
+ endif
+ 
+ .PHONY: shared_lib

Reply via email to