[oe-commits] Phil Blundell : insane: Don't try to run objdump on symlinks

git at git.openembedded.org git at git.openembedded.org
Wed Oct 17 14:36:06 UTC 2012


Module: openembedded-core.git
Branch: master-next
Commit: e025b6df9e886d644d3e5ddffe8cb385fa58a7be
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=e025b6df9e886d644d3e5ddffe8cb385fa58a7be

Author: Phil Blundell <philb at gnu.org>
Date:   Mon Oct 15 11:28:00 2012 +0100

insane: Don't try to run objdump on symlinks

If the link is absolute then we might end up reading from a host binary
or a nonexistent path, neither of which will produce useful results and
may result in objdump failure and python backtrace spew.  If the link
does point to a binary within the installation root then we will scan the
pointed-to file at some point anyway so there is no need to do it again.

Signed-off-by: Phil Blundell <pb at pbcl.net>
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>

---

 meta/classes/insane.bbclass |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/meta/classes/insane.bbclass b/meta/classes/insane.bbclass
index b0727b5..21a014c 100644
--- a/meta/classes/insane.bbclass
+++ b/meta/classes/insane.bbclass
@@ -143,6 +143,9 @@ def package_qa_check_rpath(file,name, d, elf, messages):
     if not elf:
         return
 
+    if os.path.islink(file):
+        return
+
     bad_dirs = [d.getVar('TMPDIR', True) + "/work", d.getVar('STAGING_DIR_TARGET', True)]
     bad_dir_test = d.getVar('TMPDIR', True)
 
@@ -172,6 +175,9 @@ def package_qa_check_useless_rpaths(file, name, d, elf, messages):
     if not elf:
         return
 
+    if os.path.islink(file):
+        return
+
     libdir = d.getVar("libdir", True)
     base_libdir = d.getVar("base_libdir", True)
 





More information about the Openembedded-commits mailing list