All of lore.kernel.org
 help / color / mirror / Atom feed
From: Koen Kooi <k.kooi@student.utwente.nl>
To: openembedded-devel@lists.openembedded.org
Subject: Re: [PATCH] insane bbclass: extend RPATH check to cover sysroots as well
Date: Wed, 19 Jan 2011 20:58:03 +0100	[thread overview]
Message-ID: <ih7fob$ltd$1@dough.gmane.org> (raw)
In-Reply-To: <4D373CFC.8010400@balister.org>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 19-01-11 20:35, Philip Balister wrote:
> On 01/19/2011 11:21 AM, Koen Kooi wrote:
>> * Having rpath to sysroot is just as bad as one to workdir
> 
> When you do a build with this, how many recipes have issues?

At least udev:

ERROR: QA Issue with udev: package udev contains bad RPATH
/OE/angstrom-setup-scripts/build/tmp-angstrom_2008_1/sysroots/armv7a-angstrom-linux-gnueabi/usr/lib
in file
/OE/angstrom-setup-scripts/build/tmp-angstrom_2008_1/work/armv7a-angstrom-linux-gnueabi/udev-165-r0/packages-split/udev/lib/udev/udev-acl
ERROR: QA Issue with udev: package udev contains bad RPATH
/OE/angstrom-setup-scripts/build/tmp-angstrom_2008_1/sysroots/armv7a-angstrom-linux-gnueabi/usr/lib
in file
/OE/angstrom-setup-scripts/build/tmp-angstrom_2008_1/work/armv7a-angstrom-linux-gnueabi/udev-165-r0/packages-split/udev/lib/udev/hid2hci
ERROR: QA Issue with udev: package udev contains bad RPATH
/OE/angstrom-setup-scripts/build/tmp-angstrom_2008_1/sysroots/armv7a-angstrom-linux-gnueabi/usr/lib
in file
/OE/angstrom-setup-scripts/build/tmp-angstrom_2008_1/work/armv7a-angstrom-linux-gnueabi/udev-165-r0/packages-split/udev/lib/udev/mobile-action-modeswitch

 I'm doing a build from scratch now to see what will fail first.
Richard and Scott have fixed a number of those in yocto, so I'll be
working with them and Khem to 'port' those over to OE.

This patch is merely here to have people realize how buggered OE
currently is with stray RPATHs

regards,

Koen


> 
> Philip
> 
> 
>>
>> Based on insane.bbclass from yocto
>>
>> Signed-off-by: Koen Kooi<koen@openembedded.org>
>> ---
>>   classes/insane.bbclass |   11 ++++++-----
>>   1 files changed, 6 insertions(+), 5 deletions(-)
>>
>> diff --git a/classes/insane.bbclass b/classes/insane.bbclass
>> index 677db27..50752b5 100644
>> --- a/classes/insane.bbclass
>> +++ b/classes/insane.bbclass
>> @@ -160,20 +160,21 @@ def package_qa_check_rpath(file,name,d, elf):
>>       import bb, os
>>       sane = True
>>       scanelf =
>> os.path.join(bb.data.getVar('STAGING_BINDIR_NATIVE',d,True),'scanelf')
>> -    bad_dir = bb.data.getVar('TMPDIR', d, True) + "/work"
>> +    bad_dirs = [bb.data.getVar('TMPDIR', d, True) + "/work",
>> bb.data.getVar('STAGING_DIR_TARGET', d, True)]
>>       bad_dir_test = bb.data.getVar('TMPDIR', d, True)
>>       if not os.path.exists(scanelf):
>>           bb.fatal("Can not check RPATH, scanelf (part of
>> pax-utils-native) not found")
>>
>> -    if not bad_dir in bb.data.getVar('WORKDIR', d, True):
>> +    if not bad_dirs[0] in bb.data.getVar('WORKDIR', d, True):
>>           bb.fatal("This class assumed that WORKDIR is
>> ${TMPDIR}/work... Not doing any check")
>>
>>       output = os.popen("%s -B -F%%r#F '%s'" % (scanelf,file))
>>       txt    = output.readline().split()
>>       for line in txt:
>> -        if bad_dir in line:
>> -            error_msg = "package %s contains bad RPATH %s in file %s"
>> % (name, line, file)
>> -            sane = package_qa_handle_error(1, error_msg, name, file, d)
>> +        for dir in bad_dirs:
>> +            if dir in line:
>> +                error_msg = "package %s contains bad RPATH %s in file
>> %s" % (name, line, file)
>> +                sane = sane + package_qa_handle_error(1, error_msg,
>> name, file, d)
>>
>>       return sane
>>

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)

iD8DBQFNN0JLMkyGM64RGpERAlmoAKC4ydMPfud8DpW5RZOEtiB+z+o0DACeO2jb
dmskeJB73C+waA899CHri2w=
=q33T
-----END PGP SIGNATURE-----




  reply	other threads:[~2011-01-19 19:58 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-19 19:21 [PATCH] insane bbclass: extend RPATH check to cover sysroots as well Koen Kooi
2011-01-19 19:35 ` Philip Balister
2011-01-19 19:58   ` Koen Kooi [this message]
2011-01-20  7:10   ` Koen Kooi
2011-01-25 13:41   ` Koen Kooi
2011-01-25 14:38     ` Martin Jansa
2011-01-25 14:40     ` Frans Meulenbroeks
2011-01-25 14:50       ` Koen Kooi
2011-01-25 15:31         ` Frans Meulenbroeks
2011-01-25 22:21           ` Frans Meulenbroeks
2011-01-25 16:12         ` Martin Jansa
2011-01-26 18:20     ` Frans Meulenbroeks

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='ih7fob$ltd$1@dough.gmane.org' \
    --to=k.kooi@student.utwente.nl \
    --cc=openembedded-devel@lists.openembedded.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.