[oe] [PATCH] package.bbclass: when running 'file', be explicit about the path to the magic

Koen Kooi k.kooi at student.utwente.nl
Mon Mar 1 09:17:05 UTC 2010


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

Hi,

I don't have 'file/' in STAGING_DATADIR_NATIVE so I now have lots of
unstripped stuff (150MB libxul.so). Could you please add an extra check
to see if file/magic exists?

regards,

Koen

On 19-02-10 19:47, Chris Larson wrote:
> From: Tom Rini <tom_rini at mentor.com>
> 
> This works around one relocation issue.
> 
> Signed-off-by: Tom Rini <tom_rini at mentor.com>
> Signed-off-by: Chris Larson <chris_larson at mentor.com>
> ---
>  classes/package.bbclass |    5 +++--
>  1 files changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/classes/package.bbclass b/classes/package.bbclass
> index 062f782..72c9053 100644
> --- a/classes/package.bbclass
> +++ b/classes/package.bbclass
> @@ -155,11 +155,12 @@ def runstrip(file, d):
>      import commands, stat
>  
>      pathprefix = "export PATH=%s; " % bb.data.getVar('PATH', d, True)
> +    magicfile = "%s/file/magic" % bb.data.getVar('STAGING_DATADIR_NATIVE', d, True) 
>  
> -    ret, result = commands.getstatusoutput("%sfile '%s'" % (pathprefix, file))
> +    ret, result = commands.getstatusoutput("%sfile -m %s '%s'" % (pathprefix, magicfile, file))
>  
>      if ret:
> -        bb.error("runstrip: 'file %s' failed (forced strip)" % file)
> +        bb.error("runstrip: 'file -m %s %s' failed (forced strip)" % (magicfile, file))
>  
>      if "not stripped" not in result:
>          bb.debug(1, "runstrip: skip %s" % file)

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

iD8DBQFLi4YRMkyGM64RGpERAoPBAKCdNJV1xR2zZTGU6XSn/jHIDfrNCQCbBFWS
DrZI2u7qsGPg1ABHQh4loHU=
=spj2
-----END PGP SIGNATURE-----





More information about the Openembedded-devel mailing list