[oe-commits] [openembedded-core] 17/61: rootfs: don't use oe.cachedpath

git at git.openembedded.org git at git.openembedded.org
Sat Dec 28 23:26:30 UTC 2019


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch master
in repository openembedded-core.

commit 765e0c3410d6bf3b4a50c4a036f555eae760acd2
Author: Ross Burton <ross.burton at intel.com>
AuthorDate: Thu Dec 5 21:12:52 2019 +0000

    rootfs: don't use oe.cachedpath
    
    Unless cachedpath is used correctly then it's just a glorified clone of
    os.walk, but without any of the recent optimisations in os.walk.  In
    this codepath there is no point to using cachedpath.
    
    Signed-off-by: Ross Burton <ross.burton at intel.com>
---
 meta/lib/oe/rootfs.py | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/meta/lib/oe/rootfs.py b/meta/lib/oe/rootfs.py
index c62fa5f..cd65e62 100644
--- a/meta/lib/oe/rootfs.py
+++ b/meta/lib/oe/rootfs.py
@@ -126,17 +126,16 @@ class Rootfs(object, metaclass=ABCMeta):
             bb.utils.mkdirhier(self.image_rootfs + os.path.dirname(dir))
             shutil.copytree(self.image_rootfs + '-orig' + dir, self.image_rootfs + dir, symlinks=True)
 
-        cpath = oe.cachedpath.CachedPath()
         # Copy files located in /usr/lib/debug or /usr/src/debug
         for dir in ["/usr/lib/debug", "/usr/src/debug"]:
             src = self.image_rootfs + '-orig' + dir
-            if cpath.exists(src):
+            if os.path.exists(src):
                 dst = self.image_rootfs + dir
                 bb.utils.mkdirhier(os.path.dirname(dst))
                 shutil.copytree(src, dst)
 
         # Copy files with suffix '.debug' or located in '.debug' dir.
-        for root, dirs, files in cpath.walk(self.image_rootfs + '-orig'):
+        for root, dirs, files in os.walk(self.image_rootfs + '-orig'):
             relative_dir = root[len(self.image_rootfs + '-orig'):]
             for f in files:
                 if f.endswith('.debug') or '/.debug' in relative_dir:

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list