7fddlZddlZddlmZmZdeefdZdeefdZdeefdZdeeeffdZ dS)N)OptionalTuplereturnc:tp tS)z9Returns glibc version string, or None if not using glibc.)glibc_version_string_confstrglibc_version_string_ctypesy/builddir/build/BUILD/imunify360-venv-2.3.5/opt/imunify360/venv/lib/python3.11/site-packages/pip/_internal/utils/glibc.pyglibc_version_stringr s ' ) ) J-H-J-JJr ctjdkrdS tjd}|dS|\}}n#t t tf$rYdSwxYw|S)z@Primary implementation of glibc_version_string using os.confstr.win32NCS_GNU_LIBC_VERSION)sysplatformosconfstrsplitAttributeErrorOSError ValueError)gnu_libc_version_versions r rr s~  |wt:&;<<  #4%++-- 77 GZ 0tt NsAAAAc8 ddl}n#t$rYdSwxYw |d}n#t$rYdSwxYw |j}n#t $rYdSwxYw|j|_|}t|ts| d}|S)z=Fallback implementation of glibc_version_string using ctypes.rNascii) ctypes ImportErrorCDLLrgnu_get_libc_versionrc_char_prestype isinstancestrdecode)rprocess_namespacer version_strs r rrs tt "KK-- tt0E tt $*? ++--K k3 ' '2!((11 s* / ==A AAc.t}|dSd|fS)zTry to determine the glibc version Returns a tuple of strings (lib, version) which default to empty strings in case the lookup fails. N)r)glibc)r ) glibc_versions r libc_verr,[s% )**Mx''r ) rrtypingrrr$r rrr,r r r r.s """"""""KhsmKKKK hsm((Xc]((((x (%S/ ( ( ( ( ( (r