summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2013-11-08 22:13:38 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-11-12 10:15:00 +0000
commit59612905e9bb865762667aa7b3cb06e53c3a4071 (patch)
tree91e0923c158cb5c4fd2312f486d1520431b343bb
parent8b90ed084d59b4e07aa547255d327b25cfb2ee2b (diff)
downloadopenembedded-core-59612905e9bb865762667aa7b3cb06e53c3a4071.tar.gz
openembedded-core-59612905e9bb865762667aa7b3cb06e53c3a4071.tar.bz2
openembedded-core-59612905e9bb865762667aa7b3cb06e53c3a4071.zip
lib/oe/path: Fixup handling of .* files in top level paths for copyhardlinktree()
Files named .* in the top level of directories handled by this function were getting lost after the directory copying command was fixed. Rather than complicate the function further, use cpio instead. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/lib/oe/path.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/meta/lib/oe/path.py b/meta/lib/oe/path.py
index d0588baf15..46783f8668 100644
--- a/meta/lib/oe/path.py
+++ b/meta/lib/oe/path.py
@@ -95,9 +95,7 @@ def copyhardlinktree(src, dst):
# writers try and create a directory at the same time
cmd = 'cd %s; find . -type d -print | tar -cf - -C %s -p --files-from - --no-recursion | tar -xf - -C %s' % (src, src, dst)
check_output(cmd, shell=True, stderr=subprocess.STDOUT)
- if os.path.isdir(src):
- src = src + "/*"
- cmd = 'cp -afl %s %s' % (src, dst)
+ cmd = 'cd %s; find . -print0 | cpio --null -pdlu %s' % (src, dst)
check_output(cmd, shell=True, stderr=subprocess.STDOUT)
else:
copytree(src, dst)