Sindbad~EG File Manager

Current Path : /usr/local/lib/python3.12/site-packages/pip/_internal/utils/__pycache__/
Upload File :
Current File : //usr/local/lib/python3.12/site-packages/pip/_internal/utils/__pycache__/glibc.cpython-312.pyc

�

4Μg���p�ddlZddlZddlmZmZdeefd�Zdeefd�Zdeefd�Zdeeeffd�Z	y)�N)�Optional�Tuple�returnc�.�t�xs
t�S)z9Returns glibc version string, or None if not using glibc.)�glibc_version_string_confstr�glibc_version_string_ctypes���D/usr/local/lib/python3.12/site-packages/pip/_internal/utils/glibc.py�glibc_version_stringrs��'�)�J�-H�-J�Jr
c��tjdk(ry	tjd�}|�y|j	�\}}|S#t
ttf$rYywxYw)z@Primary implementation of glibc_version_string using os.confstr.�win32N�CS_GNU_LIBC_VERSION)�sys�platform�os�confstr�split�AttributeError�OSError�
ValueError)�gnu_libc_version�_�versions   rrrse���|�|�w�����:�:�&;�<���#��%�+�+�-�
��7��N��
�G�Z�0����s�A�A�A�Ac��	ddl}	|jd�}	|j}|j|_|�}t|t�s|jd�}|S#t$rYywxYw#t$rYywxYw#t
$rYywxYw)z=Fallback implementation of glibc_version_string using ctypes.rN�ascii)�ctypes�ImportError�CDLLr�gnu_get_libc_versionr�c_char_p�restype�
isinstance�str�decode)r�process_namespacer �version_strs    rrrs�����"�"�K�K��-���0�E�E��$*�?�?�� �+�-�K��k�3�'�!�(�(��1�����G�����$�����
����s3�A �A/�A>� 	A,�+A,�/	A;�:A;�>	B
�	B
c�$�t�}|�yd|fS)z�Try to determine the glibc version

    Returns a tuple of strings (lib, version) which default to empty strings
    in case the lookup fails.
    )�r)�glibc)r)�
glibc_versions r�libc_verr,[s ��)�*�M������'�'r
)
rr�typingrrr$rrrr,r	r
r�<module>r.sU��	�
�"�K�h�s�m�K�
�h�s�m��((�X�c�]�(�x
(�%��S��/�
(r

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists