Openembedded Core Discussions
 help / color / mirror / Atom feed
From: "Yu, Mingli" <mingli.yu@windriver.com>
To: <richard.purdie@linuxfoundation.org>,
	<openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH v2] elfutils: fix ptest failures
Date: Wed, 29 May 2019 10:59:47 +0800	[thread overview]
Message-ID: <5CEDF5A3.9030403@windriver.com> (raw)
In-Reply-To: <5a62beea5ad46e24bc1e59c5cf9938799c0e3d12.camel@linuxfoundation.org>



On 2019年05月28日 18:01, richard.purdie@linuxfoundation.org wrote:
> On Tue, 2019-05-28 at 17:40 +0800, mingli.yu@windriver.com wrote:
>> From: Mingli Yu <Mingli.Yu@windriver.com>
>>
>> * Add missing -ptest package dependencies (needs
>>    ${PN}-dev)
>>
>> * Add missing files which needed by ptest test
>>    to fix the ptest failures such as:
>>    | sh: ../src/elflint: No such file or directory
>>    | FAIL: asm-tst4
>>
>> * Rework 0001-skip-the-test-when-gcc-not-deployed.patch
>>    to skip the tests which depend on gcc
>>
>> * Don't split the -debug package for elfutils as
>>    most cases needs the binary to have .symtab.
>
> Can you provide more details on what this last item means?

That means elfutils tests need the binary not stripped, so we need below 
logic:

INHIBIT_PACKAGE_STRIP = "1"
INHIBIT_PACKAGE_DEBUG_SPLIT = "1"

>
> Do you mean elfutils is generally broken without the symtab section?
> That seems unusual? Or do you mean the tests need it to be present?

Not sure whether elfutils is broken, but at least it is broken with 
regard to test part. If strip the binary, the test result:
--------------------------------------------
     Recipe   | Passed    | Failed   | Skipped
     --------------------------------------------
     elfutils | 184       | 15        | 4
--------------------------------------------

And all the failed case as below is because the binary is stripped.
 

FAIL: test-nlist
FAIL: run-strip-reloc.sh
FAIL: run-strip-strmerge.sh
FAIL: run-nm-self.sh
FAIL: run-readelf-self.sh
FAIL: run-varlocs-self.sh
FAIL: run-exprlocs-self.sh
FAIL: run-backtrace-native.sh
FAIL: run-backtrace-data.sh
FAIL: run-backtrace-native-core.sh
FAIL: run-deleted.sh
FAIL: run-dwarf-die-addr-die.sh
FAIL: run-get-units-invalid.sh
FAIL: run-get-units-split.sh
FAIL: run-unit-info.sh

For the test-nlist, the upstream also said the binary cannot be stripped 
to guarantee the test pass as 
https://sourceware.org/ml/elfutils-devel/2019-q2/msg00098.html and 
https://sourceware.org/ml/elfutils-devel/2019-q2/msg00103.html


So to fix this kind of below failures, we need to make the binary not 
stripped.

runtest /usr/lib64/elfutils/ptest/tests/..//src/strip
/usr/bin/eu-readelf: cannot get debug context descriptor: No DWARF 
information found
*** failure readelf -w debugfile1 
/usr/lib64/elfutils/ptest/tests/..//src/strip
/usr/bin/eu-readelf: cannot get debug context descriptor: No DWARF 
information found
*** failure readelf -w debugfile2 
/usr/lib64/elfutils/ptest/tests/..//src/strip
runtest /usr/lib64/elfutils/ptest/tests/..//src/strip.o
runtest strip-uncompressed.o
runtest strip-compressed.o
runtest testfile-debug-rel-ppc64.o
runtest testfile-debug-rel-ppc64-z.o
runtest testfile-debug-rel-ppc64-g.o
FAIL: run-strip-reloc.sh

/usr/lib64/elfutils/ptest/tests/..//tests/elfstrmerge: 
/usr/lib64/elfutils/ptest/tests/..//tests/elfstrmerge: couldn't get 
symtab data: no error
FAIL: run-strip-strmerge.sh

/usr/bin/eu-nm: /usr/lib64/elfutils/ptest/tests/..//src/nm: no symbols
FAIL: run-nm-self.sh

>
> Not striping the binary at all is likely to cause a significant size
> increase for elfutils and we want to avoid that, particularly if its
> only to fix tests. We will probably have to find a different solution
> (e.g. second copy with the symtab section in the ptest package, added
> to PATH in the runner?)

During my test, if we strip the debug info to elfutils-dbg, first we 
need to make elfutils-ptest rdepends on elfutils-dbg and second the test 
still fails as above even the elfutils-dbg package deployed as below:
# pwd
/usr/lib64/elfutils/ptest
root@qemux86-64:/usr/lib64/elfutils/ptest# ls src/strip
src/strip
root@qemux86-64:/usr/lib64/elfutils/ptest# ls src/.debug/strip
src/.debug/strip
/.debug/strip64:/usr/lib64/elfutils/ptest# rpm -qf 
/usr/lib64/elfutils/ptest/src/.debug/strip
elfutils-dbg-0.176-r0.core2_64

Thanks,

>
> Cheers,
>
> Richard
>
>
>
>


  reply	other threads:[~2019-05-29  2:53 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-22  9:11 [PATCH] elfutils: fix ptest failures mingli.yu
2019-05-25 20:16 ` richard.purdie
2019-05-28  9:31   ` Yu, Mingli
2019-05-28  9:40   ` [PATCH v2] " mingli.yu
2019-05-28 10:01     ` richard.purdie
2019-05-29  2:59       ` Yu, Mingli [this message]
2019-05-29  8:55       ` [PATCH v3] " mingli.yu
2019-05-29 10:13         ` richard.purdie
2019-05-30  6:03           ` Yu, Mingli
2019-05-30  6:11           ` [PATCH v4] " mingli.yu
2019-05-30 20:49             ` richard.purdie
2019-05-30 22:16               ` Richard Purdie
2019-05-31  6:40               ` Yu, Mingli
2019-05-31  8:48                 ` richard.purdie
2019-05-31  9:44                   ` [PATCH v5] " mingli.yu
2019-05-29 18:40         ` [PATCH v3] " richard.purdie
2019-05-30  6:04           ` Yu, Mingli

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5CEDF5A3.9030403@windriver.com \
    --to=mingli.yu@windriver.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=richard.purdie@linuxfoundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox