<feed xmlns='http://www.w3.org/2005/Atom'>
<title>openembedded-core.git/meta/classes/chrpath.bbclass, branch fido</title>
<subtitle>Mirror of openembedded-core</subtitle>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/'/>
<entry>
<title>chrpath.bbclass: handle RUNPATH as well as RPATH</title>
<updated>2015-03-16T17:38:35+00:00</updated>
<author>
<name>Andre McCurdy</name>
<email>armccurdy@gmail.com</email>
</author>
<published>2015-03-11T00:56:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=46ceb4d035e4f49e6b4a3a83bf604944d2b991c1'/>
<id>46ceb4d035e4f49e6b4a3a83bf604944d2b991c1</id>
<content type='text'>
Binaries linked with gold may contain a RUNPATH instead of an RPATH.
Update chrpath.bbclass process_file_linux() to handle both cases.

Signed-off-by: Andre McCurdy &lt;armccurdy@gmail.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Binaries linked with gold may contain a RUNPATH instead of an RPATH.
Update chrpath.bbclass process_file_linux() to handle both cases.

Signed-off-by: Andre McCurdy &lt;armccurdy@gmail.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>chrpath: Drop warning from darwn builds</title>
<updated>2014-08-17T09:01:30+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2014-08-17T08:52:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=d0be4b37743492fc9c178fd6f9ef73a5eb2fd9c3'/>
<id>d0be4b37743492fc9c178fd6f9ef73a5eb2fd9c3</id>
<content type='text'>
This was old debug which can safely be removed for less noisy builds.

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This was old debug which can safely be removed for less noisy builds.

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>chrpath: properly handle rootdir with '..' in path</title>
<updated>2014-05-11T11:24:21+00:00</updated>
<author>
<name>Matt Cowell</name>
<email>matt.cowell@nsn.com</email>
</author>
<published>2014-04-17T19:23:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=753cfcadd8cc683e69b6707b823dc49dfb34ab0b'/>
<id>753cfcadd8cc683e69b6707b823dc49dfb34ab0b</id>
<content type='text'>
When there is a '..' in the rootdir path, rootdir will not be a substring of
fpath.  This causes an incorrect rpath of the difference between the workdir
and the sysroot to be computed, which is incorrect.  Normalizing basedir
fixes this issue.

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When there is a '..' in the rootdir path, rootdir will not be a substring of
fpath.  This causes an incorrect rpath of the difference between the workdir
and the sysroot to be computed, which is incorrect.  Normalizing basedir
fixes this issue.

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>chrpath: Improve crazy code</title>
<updated>2013-11-27T12:03:18+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2013-11-26T22:14:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=feea54df6768036649ca6c57524e2a1f480ad249'/>
<id>feea54df6768036649ca6c57524e2a1f480ad249</id>
<content type='text'>
The current code is a little bit overcomplicated, deficient and also
possibly broken.

Issues include:

a) Not maximally optisming rpaths (e.g. a lib in usr/lib might get an
   rpath of $ORIGIN/../../usr/lib)
b) The return in the middle of the for loop look suspiciously like
   it might break on some binaries
c) The depth function, loops of "../" prepending and so on can
   be replaced with a call to os.path.relpath

This patch cleans up the above issues.

Running binaries should result in less "../" resolutions which can't
hurt performance either.

[YOCTO #3989]

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The current code is a little bit overcomplicated, deficient and also
possibly broken.

Issues include:

a) Not maximally optisming rpaths (e.g. a lib in usr/lib might get an
   rpath of $ORIGIN/../../usr/lib)
b) The return in the middle of the for loop look suspiciously like
   it might break on some binaries
c) The depth function, loops of "../" prepending and so on can
   be replaced with a call to os.path.relpath

This patch cleans up the above issues.

Running binaries should result in less "../" resolutions which can't
hurt performance either.

[YOCTO #3989]

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>chrpath: Add support for relocating darwin binaries</title>
<updated>2013-08-22T17:30:07+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2013-08-22T11:07:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=ed5ace3437eb0f751172e6b93399639c94b89e59'/>
<id>ed5ace3437eb0f751172e6b93399639c94b89e59</id>
<content type='text'>
On darwin, install_name_tool can be used to relocate binaries/libraries. This
adds support for adjusting them with relative paths rather than hardcoded ones.
The Linux code is factored out into a function but is otherwise unchanged.

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
On darwin, install_name_tool can be used to relocate binaries/libraries. This
adds support for adjusting them with relative paths rather than hardcoded ones.
The Linux code is factored out into a function but is otherwise unchanged.

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>chrpath.bbclass: Normalize rpath only of it doesn't contain ORIGIN variable</title>
<updated>2012-12-14T08:50:06+00:00</updated>
<author>
<name>Andrei Gherzan</name>
<email>andrei.gherzan@windriver.com</email>
</author>
<published>2012-12-14T02:15:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=46dc514ff5a3d2693546cf95c5481e0539c43580'/>
<id>46dc514ff5a3d2693546cf95c5481e0539c43580</id>
<content type='text'>
If we normalize a rpath which contains ORIGIN variable, the binary will end
up without those rpaths at all. So check first if rpath contains ORIGIN variable
and if not, move on and normalize it.

Signed-off-by: Andrei Gherzan &lt;andrei.gherzan@windriver.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If we normalize a rpath which contains ORIGIN variable, the binary will end
up without those rpaths at all. So check first if rpath contains ORIGIN variable
and if not, move on and normalize it.

Signed-off-by: Andrei Gherzan &lt;andrei.gherzan@windriver.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>chrpath: normalize the paths</title>
<updated>2012-12-13T15:27:38+00:00</updated>
<author>
<name>Saul Wold</name>
<email>sgw@linux.intel.com</email>
</author>
<published>2012-12-12T01:40:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=50327f2bba9f479dd209cdc54646b9d551e84c59'/>
<id>50327f2bba9f479dd209cdc54646b9d551e84c59</id>
<content type='text'>
By normalizing the paths the path comparing code works correct
to generate the right RPATH even when there is a A/../A in TMPDIR

[YOCTO #3408]

Signed-off-by: Saul Wold &lt;sgw@linux.intel.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
By normalizing the paths the path comparing code works correct
to generate the right RPATH even when there is a A/../A in TMPDIR

[YOCTO #3408]

Signed-off-by: Saul Wold &lt;sgw@linux.intel.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>chrpath.bbclass: Account for case when ORIGIN is in RPATH</title>
<updated>2012-08-17T16:44:57+00:00</updated>
<author>
<name>Khem Raj</name>
<email>raj.khem@gmail.com</email>
</author>
<published>2012-08-16T03:15:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=43600df0d4efc976a9451163dd334b4763937932'/>
<id>43600df0d4efc976a9451163dd334b4763937932</id>
<content type='text'>
This fixes a case when RPATH embedded in program have one of
its path already relative to ORIGIN. We were losing that path
if such a path existed. This patch appends it to the new edited
rpath being created when we see it.

so RPATH like below

(RPATH)              Library rpath:
[$ORIGIN/../lib/amd64/jli:$ORIGIN/../jre/lib/amd64/jli]

would end up being empty

but after this patch its kept intact

Signed-off-by: Khem Raj &lt;raj.khem@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This fixes a case when RPATH embedded in program have one of
its path already relative to ORIGIN. We were losing that path
if such a path existed. This patch appends it to the new edited
rpath being created when we see it.

so RPATH like below

(RPATH)              Library rpath:
[$ORIGIN/../lib/amd64/jli:$ORIGIN/../jre/lib/amd64/jli]

would end up being empty

but after this patch its kept intact

Signed-off-by: Khem Raj &lt;raj.khem@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>chrpath.bbclass: Ensure we only process tmpdir in paths which actually contain that path</title>
<updated>2012-08-17T16:42:37+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2012-08-17T16:37:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=73e2c12534856f14c1a94fb51874e9ba1655f07b'/>
<id>73e2c12534856f14c1a94fb51874e9ba1655f07b</id>
<content type='text'>
Without this change, a path to "/lib/xxx" or "/usr/lib/xxx" would also
attempt to be remapped to be relative to $ORIGIN which makes no sense.

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Without this change, a path to "/lib/xxx" or "/usr/lib/xxx" would also
attempt to be remapped to be relative to $ORIGIN which makes no sense.

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>classes/chrpath: improve chrpath failure handling</title>
<updated>2012-08-17T14:25:01+00:00</updated>
<author>
<name>Paul Eggleton</name>
<email>paul.eggleton@linux.intel.com</email>
</author>
<published>2012-08-17T13:26:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=99815eddd4e1eb5d939831704231537dd5a995ad'/>
<id>99815eddd4e1eb5d939831704231537dd5a995ad</id>
<content type='text'>
When chrpath fails, prefix the error message with the name of the recipe
that is being processed, and include the the output from chrpath, as
well as making the calling task actually fail.

Signed-off-by: Paul Eggleton &lt;paul.eggleton@linux.intel.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When chrpath fails, prefix the error message with the name of the recipe
that is being processed, and include the the output from chrpath, as
well as making the calling task actually fail.

Signed-off-by: Paul Eggleton &lt;paul.eggleton@linux.intel.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
