Skip to content

Commit 3a2dc4f

Browse files
committed
fix libc detection in edge cases
1 parent c3b99cf commit 3a2dc4f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/auditwheel/lddtree.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -510,13 +510,13 @@ def ldd(
510510
if _first:
511511
# get the libc based on dependencies
512512
for soname in needed:
513-
if soname.startswith("libc.musl-"):
513+
if soname.startswith(("libc.musl-", "ld-musl-")):
514514
if libc is None:
515515
libc = Libc.MUSL
516516
if libc != Libc.MUSL:
517517
msg = f"found a dependency on MUSL but the libc is already set to {libc}"
518518
raise InvalidLibc(msg)
519-
elif soname == "libc.so.6":
519+
elif soname == "libc.so.6" or soname.startswith(("ld-linux-", "ld64.so.")):
520520
if libc is None:
521521
libc = Libc.GLIBC
522522
if libc != Libc.GLIBC:

0 commit comments

Comments
 (0)