From c53608b220a8b5acb2ba867cfdba10c2ede479a6 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Mon, 20 Oct 2008 14:19:36 +0000 Subject: bitbake utils.py: Merge prunedir symlink fix from bitbake upstream git-svn-id: https://svn.o-hand.com/repos/poky/trunk@5551 311d38ba-8fff-0310-9ca6-ca027cbcb966 --- bitbake-dev/lib/bb/utils.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'bitbake-dev/lib/bb') diff --git a/bitbake-dev/lib/bb/utils.py b/bitbake-dev/lib/bb/utils.py index ad1a51529..33a0c1765 100644 --- a/bitbake-dev/lib/bb/utils.py +++ b/bitbake-dev/lib/bb/utils.py @@ -389,5 +389,8 @@ def prunedir(topdir): for name in files: os.remove(os.path.join(root, name)) for name in dirs: - os.rmdir(os.path.join(root, name)) + if os.path.islink(os.path.join(root, name)): + os.remove(os.path.join(root, name)) + else: + os.rmdir(os.path.join(root, name)) os.rmdir(topdir) -- cgit v1.2.3