summary refs log tree commit diff stats
path: root/tests/docker/docker.py
diff options
context:
space:
mode:
authorAlex Bennée <alex.bennee@linaro.org>2021-02-02 13:39:48 +0000
committerAlex Bennée <alex.bennee@linaro.org>2021-02-08 09:41:00 +0000
commitdffccf3d34467d7280212445e521f458d31ac6a2 (patch)
tree3a46e913b0824f1e88f4d00dd77b7ced3c28deb5 /tests/docker/docker.py
parentdc23bbc3df448d91727535067a05f686b8b29e63 (diff)
downloadfocaccia-qemu-dffccf3d34467d7280212445e521f458d31ac6a2.tar.gz
focaccia-qemu-dffccf3d34467d7280212445e521f458d31ac6a2.zip
tests/docker: make _copy_with_mkdir accept missing files
Depending on the linker/ldd setup we might get a file with no path.
Typically this is the psuedo library linux-vdso.so which doesn't
actually exist on the disk. Rather than try and catch these distro
specific edge cases just shout about it and try and continue.

Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20210202134001.25738-4-alex.bennee@linaro.org>
Diffstat (limited to 'tests/docker/docker.py')
-rwxr-xr-xtests/docker/docker.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/docker/docker.py b/tests/docker/docker.py
index 0b4f6167b3..fb3de41c0b 100755
--- a/tests/docker/docker.py
+++ b/tests/docker/docker.py
@@ -103,7 +103,12 @@ def _copy_with_mkdir(src, root_dir, sub_path='.'):
         pass
 
     dest_file = "%s/%s" % (dest_dir, os.path.basename(src))
-    copy(src, dest_file)
+
+    try:
+        copy(src, dest_file)
+    except FileNotFoundError:
+        print("Couldn't copy %s to %s" % (src, dest_file))
+        pass
 
 
 def _get_so_libs(executable):