bitbake-1.4/lib/bb/cache.py:
authorHolger Hans Peter Freyther <zecke@selfish.org>
Sat, 29 Apr 2006 17:49:49 +0000 (17:49 +0000)
committerHolger Hans Peter Freyther <zecke@selfish.org>
Sat, 29 Apr 2006 17:49:49 +0000 (17:49 +0000)
    Check directory exists befor chdir this patch was taken
    from attachment http://bugs.openembedded.org/attachment.cgi?id=691&action=view
    of bug #918

lib/bb/cache.py

index e3e0d6a..921a9f7 100644 (file)
@@ -271,7 +271,8 @@ class Cache:
         #data.setVar('TOPDIR', topdir, cfg)
         # go there
         oldpath = os.path.abspath(os.getcwd())
-        os.chdir(topdir)
+        if self.mtime(topdir):
+            os.chdir(topdir)
         bb_data = data.init_db(cooker.configuration.data)
         try:
             parse.handle(bbfile, bb_data) # read .bb data