Signed-off-by: Khem Raj <[email protected]>
---
 .../recipes-devtools/elfutils/elfutils_0.180.bb |  1 +
 .../elfutils/files/ldflags.patch                | 17 +++++++++++++++++
 2 files changed, 18 insertions(+)
 create mode 100644 meta/recipes-devtools/elfutils/files/ldflags.patch

diff --git a/meta/recipes-devtools/elfutils/elfutils_0.180.bb 
b/meta/recipes-devtools/elfutils/elfutils_0.180.bb
index 9f8bfc24f3..d3ee750725 100644
--- a/meta/recipes-devtools/elfutils/elfutils_0.180.bb
+++ b/meta/recipes-devtools/elfutils/elfutils_0.180.bb
@@ -20,6 +20,7 @@ SRC_URI = 
"https://sourceware.org/elfutils/ftp/${PV}/${BP}.tar.bz2 \
            file://run-ptest \
            file://ptest.patch \
            
file://0001-tests-Makefile.am-compile-test_nlist-with-standard-C.patch \
+           file://ldflags.patch \
            "
 SRC_URI_append_libc-musl = " \
            file://0001-musl-obstack-fts.patch \
diff --git a/meta/recipes-devtools/elfutils/files/ldflags.patch 
b/meta/recipes-devtools/elfutils/files/ldflags.patch
new file mode 100644
index 0000000000..ef1d65e2c3
--- /dev/null
+++ b/meta/recipes-devtools/elfutils/files/ldflags.patch
@@ -0,0 +1,17 @@
+Pass linker flags along to CCLD, this ensures proper linking
+w.r.t. hash_style selection during cross-compile
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <[email protected]>
+
+--- a/tests/Makefile.am
++++ b/tests/Makefile.am
+@@ -86,7 +86,7 @@ backtrace-child-biarch$(EXEEXT): backtra
+ test-nlist$(EXEEXT): test-nlist.c
+       $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
+         $(AM_CPPFLAGS) $(CPPFLAGS) \
+-        $(CFLAGS) $(test_nlist_LDADD) -o $@ $<
++        $(CFLAGS) $(test_nlist_LDADD) $(LDFLAGS) -o $@ $<
+ 
+ TESTS = run-arextract.sh run-arsymtest.sh run-ar.sh newfile test-nlist \
+       update1 update2 update3 update4 \
-- 
2.28.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#142093): 
https://lists.openembedded.org/g/openembedded-core/message/142093
Mute This Topic: https://lists.openembedded.org/mt/76575778/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to