[12/14] zdtm: fix collecting libraries on Alpine Linux

Submitted by Andrey Vagin on June 1, 2018, 9:03 p.m.

Details

Message ID 20180601210304.30164-13-avagin@virtuozzo.com
State Accepted
Series "More changes to be compatible with python 3"
Commit 195ef99187cfef61010dc60e1607b7b82239f767
Headers show

Commit Message

Andrey Vagin June 1, 2018, 9:03 p.m.
Here is an example of ldd output:

/musl # ldd /usr/lib/libxtables.so.12
	ldd (0x7fae8e06c000)
	libc.musl-x86_64.so.1 => ldd (0x7fae8e06c000)

We need to skip the "ldd (0x7fae8e06c000)" line.

Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
---
 test/zdtm.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/test/zdtm.py b/test/zdtm.py
index 2b64f419d..76473ab5f 100755
--- a/test/zdtm.py
+++ b/test/zdtm.py
@@ -191,7 +191,7 @@  class ns_flavor:
 
 	def __copy_libs(self, binary):
 		ldd = subprocess.Popen(["ldd", binary], stdout = subprocess.PIPE)
-		xl = re.compile('^(linux-gate.so|linux-vdso(64)?.so|not a dynamic)')
+		xl = re.compile('^(linux-gate.so|linux-vdso(64)?.so|not a dynamic|.*\s*ldd\s)')
 
 		# This Mayakovsky-style code gets list of libraries a binary
 		# needs minus vdso and gate .so-s