summaryrefslogtreecommitdiff
path: root/meta/classes
diff options
context:
space:
mode:
authorRichard Purdie <rpurdie@linux.intel.com>2010-08-05 12:21:33 +0100
committerRichard Purdie <rpurdie@linux.intel.com>2010-08-12 14:41:31 +0100
commite4c1c8c92e4f47b69a9d7dcccb32ee3bb1ad7d18 (patch)
tree6fb3ce1b0bb8b7600e4db0da9c51026d358d7a5e /meta/classes
parent19be6b407c6595f1d975d249bee3bf4271f0946f (diff)
downloadopenembedded-core-e4c1c8c92e4f47b69a9d7dcccb32ee3bb1ad7d18.tar.gz
openembedded-core-e4c1c8c92e4f47b69a9d7dcccb32ee3bb1ad7d18.tar.bz2
openembedded-core-e4c1c8c92e4f47b69a9d7dcccb32ee3bb1ad7d18.tar.xz
openembedded-core-e4c1c8c92e4f47b69a9d7dcccb32ee3bb1ad7d18.zip
utility-tasks.bbclass: Use python functions for do_clean instead of os.system, remove pointless [dirs] flag
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'meta/classes')
-rw-r--r--meta/classes/utility-tasks.bbclass10
1 files changed, 4 insertions, 6 deletions
diff --git a/meta/classes/utility-tasks.bbclass b/meta/classes/utility-tasks.bbclass
index 20b50ab8d..32333baf1 100644
--- a/meta/classes/utility-tasks.bbclass
+++ b/meta/classes/utility-tasks.bbclass
@@ -11,18 +11,16 @@ python do_listtasks() {
}
addtask clean
-do_clean[dirs] = "${TOPDIR}"
do_clean[nostamp] = "1"
python do_clean() {
"""clear the build and temp directories"""
dir = bb.data.expand("${WORKDIR}", d)
- if dir == '//': raise bb.build.FuncFailed("wrong DATADIR")
- bb.note("removing " + dir)
- os.system('rm -rf ' + dir)
+ bb.note("Removing " + dir)
+ oe.path.remove(dir)
dir = "%s.*" % bb.data.expand(bb.data.getVar('STAMP', d), d)
- bb.note("removing " + dir)
- os.system('rm -f '+ dir)
+ bb.note("Removing " + dir)
+ oe.path.remove(dir)
}
addtask rebuild after do_${BB_DEFAULT_TASK}