package.bbclass: fix path for relative links on elf files, when moved to debugdir

* relative links for elf files like ../foo.so ends up in the
  debugdir with ../.debug/foo.so, this causes infinite fileaccessloops
  fix it by adding an extra "../" to the link path

(From OE-Core rev: 27cf695f1cf259f8c79214e95a0c4bc2c0779b81)

Signed-off-by: Henning Heinold <heinold@inf.fu-berlin.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Henning Heinold 2011-11-20 22:32:53 +01:00 committed by Richard Purdie
parent 85162b7463
commit fc744a789d
1 changed files with 2 additions and 0 deletions

View File

@ -778,6 +778,8 @@ python split_and_strip_files () {
if lpath and lpath != ".":
ftarget += lpath + debugdir + "/"
ftarget += lbase + debugappend
if lpath.startswith(".."):
ftarget = os.path.join("..", ftarget)
bb.mkdirhier(os.path.dirname(fpath))
#bb.note("Symlink %s -> %s" % (fpath, ftarget))
os.symlink(ftarget, fpath)