[oe-commits] Richard Purdie : chrpath.bbclass: Ensure we only process tmpdir in paths which actually contain that path
git at git.openembedded.org
git at git.openembedded.org
Fri Aug 17 16:50:01 UTC 2012
Module: openembedded-core.git
Branch: master
Commit: 73e2c12534856f14c1a94fb51874e9ba1655f07b
URL: http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=73e2c12534856f14c1a94fb51874e9ba1655f07b
Author: Richard Purdie <richard.purdie at linuxfoundation.org>
Date: Fri Aug 17 16:37:47 2012 +0000
chrpath.bbclass: Ensure we only process tmpdir in paths which actually contain that path
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 <richard.purdie at linuxfoundation.org>
---
meta/classes/chrpath.bbclass | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/meta/classes/chrpath.bbclass b/meta/classes/chrpath.bbclass
index 8922248..659db31 100644
--- a/meta/classes/chrpath.bbclass
+++ b/meta/classes/chrpath.bbclass
@@ -60,10 +60,12 @@ def process_dir (directory, d):
# NOTE: This will not work reliably for cross packages, particularly in the case
# where your TMPDIR is a short path (i.e. /usr/poky) as chrpath cannot insert an
# rpath longer than that which is already set.
- else:
+ elif rpath.find(tmpdir) != -1:
depth = fpath.rpartition(tmpdir)[2].count('/')
libpath = rpath.partition(tmpdir)[2].strip()
-
+ else:
+ new_rpaths.append(rpath.strip())
+ continue
base = "$ORIGIN"
while depth > 1:
base += "/.."
More information about the Openembedded-commits
mailing list