summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <rpurdie@linux.intel.com>2010-09-03 15:28:11 +0100
committerRichard Purdie <rpurdie@linux.intel.com>2010-09-03 15:28:27 +0100
commita6ce10e83ed637c0e39cd4fcf567042f75cd1157 (patch)
tree07140f10fccb0b44983020ece00ee1c9e9f73938
parent7e36135a7e39e0ddb7298ffdec31b0f2be011788 (diff)
downloadpoky-a6ce10e83ed637c0e39cd4fcf567042f75cd1157.tar.gz
sstate: Handle symlink directory entries correctly
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
-rw-r--r--meta/classes/sstate.bbclass6
1 files changed, 4 insertions, 2 deletions
diff --git a/meta/classes/sstate.bbclass b/meta/classes/sstate.bbclass
index 57deaed18c..4668e57b32 100644
--- a/meta/classes/sstate.bbclass
+++ b/meta/classes/sstate.bbclass
@@ -170,8 +170,10 @@ def sstate_clean_manifest(manifest, d):
170 entry = entry.strip() 170 entry = entry.strip()
171 bb.debug(2, "Removing manifest: %s" % entry) 171 bb.debug(2, "Removing manifest: %s" % entry)
172 if entry.endswith("/"): 172 if entry.endswith("/"):
173 if os.path.exists(entry) and len(os.listdir(entry)) == 0: 173 if os.path.islink(entry[:-1]):
174 os.rmdir(entry) 174 os.remove(entry[:-1])
175 elif os.path.exists(entry) and len(os.listdir(entry)) == 0:
176 os.rmdir(entry[:-1])
175 else: 177 else:
176 oe.path.remove(entry) 178 oe.path.remove(entry)
177 179