]> code.ossystems Code Review - openembedded-core.git/commitdiff
package.bbclass: fix path for relative links on elf files, when moved to debugdir
authorHenning Heinold <heinold@inf.fu-berlin.de>
Sun, 20 Nov 2011 21:32:53 +0000 (22:32 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 21 Nov 2011 15:49:50 +0000 (15:49 +0000)
* 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

Signed-off-by: Henning Heinold <heinold@inf.fu-berlin.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/package.bbclass

index 6775fda48029d8a80225cc1b4e1c6de55b471622..c351f26db0356eea1526dd5693c9e736f1a410b7 100644 (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)