[OE-core] [PATCH 2/2] libtool: normalize link paths before considering for RPATH

Andy Ross andy.ross at windriver.com
Mon Aug 20 16:59:20 UTC 2012


On 08/19/2012 03:06 AM, Richard Purdie wrote:
> On Fri, 2012-08-17 at 08:53 -0700, Andy Ross wrote:
>> ++                libdir_norm=`echo $libdir \
>> ++                  | sed 's/\/\+\.\(\/\+\|$\)/\//g' \
>> ++                  | sed 's/[^\/]\+\/\+\.\.\(\/\+\|$\)//g' \
>> ++                  | sed 's/\/\+/\//g' \
>> ++                  | sed 's/\(.\)\/$/\1/g'`
>
> Can't we use func_norm_abspath here?

I have to admit I got a little confused reading that code (not that my
sed mess is significantly better, but at least I trust it because I
wrote it); but it looks to me like it's an abspath implementation on
the host filesystem (not the use of `pwd` in a few places).  That will
work for pruning in this case, since the problem case is already an
absolute path to a host directory.  But I don't see how it won't in
principle break things by expanding host paths.

Andy




More information about the Openembedded-core mailing list