]> code.ossystems Code Review - openembedded-core.git/commitdiff
oe/lib/package: handle shlibs files disappearing
authorRoss Burton <ross.burton@intel.com>
Wed, 13 Jul 2016 14:34:53 +0000 (15:34 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Wed, 20 Jul 2016 09:24:52 +0000 (10:24 +0100)
During a parallel build it's possible for unrelated shlib files to be removed if
the recipe they came from is about to be rebuilt.  They can't be involved in the
dependency chains as otherwise they wouldn't be removed, so just silently handle
files disappearing.

[ YOCTO #8555 ]

Signed-off-by: Ross Burton <ross.burton@intel.com>
meta/lib/oe/package.py

index faa0ab2edb43a19513b8718c2e417feac547b668..02642f29f039637dfd9ece6bd00d652836509eda 100644 (file)
@@ -114,7 +114,12 @@ def read_shlib_providers(d):
             m = list_re.match(file)
             if m:
                 dep_pkg = m.group(1)
-                fd = open(os.path.join(dir, file))
+                try:
+                    fd = open(os.path.join(dir, file))
+                except IOError:
+                    # During a build unrelated shlib files may be deleted, so
+                    # handle files disappearing between the listdirs and open.
+                    continue
                 lines = fd.readlines()
                 fd.close()
                 for l in lines: