elfutils: Fix GNU_HASH QA Issue

Submitted by Khem Raj on Sept. 2, 2020, 3:22 a.m. | Patch ID: 175910

Details

Message ID 20200902032241.3586810-1-raj.khem@gmail.com
State Master Next
Commit fd4f7c989c7c746246fb6c2d21748eee929c9069
Headers show

Commit Message

Khem Raj Sept. 2, 2020, 3:22 a.m.
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 .../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

Patch hide | download patch | download mbox

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 <raj.khem@gmail.com>
+
+--- 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 \

Comments

Ross Burton Sept. 2, 2020, 9:41 a.m.
On 02/09/2020 04:22, Khem Raj wrote:
> Signed-off-by: Khem Raj <raj.khem@gmail.com>
> ---
>   .../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

Did you re-run the test suite?  That binary is explicitly compiled with 
minimal flags, so adding the LDFLAGS might actually break the test.  For 
the same reason, you can set Upstream-Status to Inappropriate.

I've a fix here for the same issue that uses INSANE_SKIP instead.

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

View/Reply Online (#142103): https://lists.openembedded.org/g/openembedded-core/message/142103
Mute This Topic: https://lists.openembedded.org/mt/76575778/3617530
Group Owner: openembedded-core+owner@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  [oe-patchwork@oe-patch.openembedded.org]
-=-=-=-=-=-=-=-=-=-=-=-
Khem Raj Sept. 2, 2020, 3:22 p.m.
On Wed, Sep 2, 2020 at 2:41 AM Ross Burton <ross@burtonini.com> wrote:
>
> On 02/09/2020 04:22, Khem Raj wrote:
> > Signed-off-by: Khem Raj <raj.khem@gmail.com>
> > ---
> >   .../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
>
> Did you re-run the test suite?  That binary is explicitly compiled with
> minimal flags, so adding the LDFLAGS might actually break the test.  For
> the same reason, you can set Upstream-Status to Inappropriate.
>

I have executed on qemu and it worked ok.

> I've a fix here for the same issue that uses INSANE_SKIP instead.
>
> Ross
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#142123): https://lists.openembedded.org/g/openembedded-core/message/142123
Mute This Topic: https://lists.openembedded.org/mt/76575778/3617530
Group Owner: openembedded-core+owner@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  [oe-patchwork@oe-patch.openembedded.org]
-=-=-=-=-=-=-=-=-=-=-=-