[3.14] gh-141600: Fix musl version detection on Void Linux (GH-141850)

(cherry picked from commit 08477dbf30)

Co-authored-by: Andrew J. Hesford <ajh@sideband.org>
This commit is contained in:
Miss Islington (bot) 2025-11-22 19:47:47 +01:00 committed by GitHub
parent 43d8b7f1ac
commit c9a4a3d502
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 11 additions and 4 deletions

View file

@ -199,7 +199,7 @@ def libc_ver(executable=None, lib='', version='', chunksize=16384):
| (GLIBC_([0-9.]+))
| (libc(_\w+)?\.so(?:\.(\d[0-9.]*))?)
| (musl-([0-9.]+))
| (libc.musl(?:-\w+)?.so(?:\.(\d[0-9.]*))?)
| ((?:libc\.|ld-)musl(?:-\w+)?.so(?:\.(\d[0-9.]*))?)
""",
re.ASCII | re.VERBOSE)
@ -238,7 +238,7 @@ def libc_ver(executable=None, lib='', version='', chunksize=16384):
elif V(glibcversion) > V(ver):
ver = glibcversion
elif so:
if lib != 'glibc':
if lib not in ('glibc', 'musl'):
lib = 'libc'
if soversion and (not ver or V(soversion) > V(ver)):
ver = soversion