From edd3772643df88df7032d00a81163e6398394a3d Mon Sep 17 00:00:00 2001 From: Prasanna Santhanam Date: Thu, 20 Sep 2012 12:40:37 +0530 Subject: [PATCH] distclean target for waf to remove old build artifacts --- wscript | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/wscript b/wscript index f1c9b6274c1..ff38ed25d45 100644 --- a/wscript +++ b/wscript @@ -83,6 +83,14 @@ for pattern in ["**/.project","**/.classpath","**/.pydevproject"]: Node.exclude_ # Support functions +def distclean(ctx): + """Clear the build artifacts""" + for root, folder, files in os.walk(blddir): + for f in files: + path = os.path.join(root, f) + print "Removing artifact %s"%path + os.remove(path) + def inspectobj(x): """Look inside an object""" for m in dir(x): print m,": ",getattr(x,m)