+
     h|%  c                  s  a  0 t $ ^ RIHt ^ RIt^ RIt^ RIt^ RIt^ RIt^ RIt^ RI	t	^ RI
HtHtHtHt ^RIHtHtHtHt RtRtRt]P.                  R R	 l4       tR
 R ltR R ltR R lt]P8                  ! R 4      tR]R&    ! R R]4      tR R lt R R lt!R R lt"R R lt#]PH                  R R l4       t%R R  lt&R&R!R'R"R(R#/t'R$ R% lt(R# ))i    )annotationsN)	GeneratorIterator
NamedTupleSequence)EIClassEIDataELFFileEMachinel      ~ i   i   c                    V ^8  d   QhRRRR/# )   pathstrreturnz%Generator[ELFFile | None, None, None] format   "9/usr/lib/python3.14/site-packages/packaging/_manylinux.py__annotate__r      s      S B     c              #  s   "    \        V R 4      ;_uu_ 4       p\        V4      x  RRR4       R#   + '       g   i     R# ; i  \        \        \        3 d	    Rx   R# i ; i5i)ZrbN)Zopenr   OSErrorZ	TypeError
ValueError)r   f   & r   
_parse_elfr      sK     $!* Y
+ 
sE   A%A 0A A%A	A A%A A"A%!A""A%c               r	   r
   
executabler   r   boolr   r   r   r   r   r      s     
 
 
 
r   c                s   \        V 4      ;_uu_ 4       pVR J;'       d    VP                  \        P                  8H  ;'       d    VP                  \
        P                  8H  ;'       dj    VP                  \        P                  8H  ;'       dE    VP                  \        ,          \        8H  ;'       d    VP                  \        ,          \        8H   uuR R R 4       #   + '       g   i     R # ; iN)r   capacityr   C32encodingr   Lsbmachiner   ZArmZflagsEF_ARM_ABIMASKEF_ARM_ABI_VER5EF_ARM_ABI_FLOAT_HARDr   r   r   r   _is_linux_armhfr'      s     
J		1TM I I

gkk)I I

fjj(I I 		X\\)I I .(O;	I I
 //3HH	
 
 			s#   0C$C*$C%C5CC0	c               r	   r   r   r   r   r   r   r   -   s     
 
s 
t 
r   c                sN   \        V 4      ;_uu_ 4       pVR J;'       dh    VP                  \        P                  8H  ;'       dC    VP                  \
        P                  8H  ;'       d    VP                  \        P                  8H   uuR R R 4       #   + '       g   i     R # ; ir   )
r   r   r   r   r    r   r!   r"   r   ZI386r&   r   r   _is_linux_i686r(   -   sz    	J		1TM + +

gkk)+ +

fjj(+ + 		X]]*		
 
 			s   0B$B*BB$	c               $    V ^8  d   QhRRRRRR/# )r
   r   r   archsSequence[str]r   r   r   r   r   r   r   r   7   s!     8 8S 8 84 8r   c                s   a R V9   d   \        V 4      # RV9   d   \        V 4      # 0 Rmo\        ;QJ d    V3R lV 4       F  '       g   K   R# 	  R# ! V3R lV 4       4      # )Zarmv7li686c              3  s,   <"   T F	  qS9   x  K  	  R # 5ir   r   )Z.0archallowed_archss   & r   Z	<genexpr>Z'_have_compatible_abi.<locals>.<genexpr>E   s     7}$s   TF>   Zppc64Zs390xx86_64Zaarch64Zppc64leZriscv64Zloongarch64)r'   r(   Zany)r   r*   r.   s   &&@r   _have_compatible_abir0   7   sZ    5z**j))M 3773373737777r   c                 s    ^2# )i2   r   r   r   r   <lambda>r1   M   s    Br   zdict[int, int]_LAST_GLIBC_MINORc                  s,    ] tR t^Pt$ R]R&   R]R&   RtR# )_GLibCVersionintmajorminorr   N)Z__name__Z
__module__Z__qualname__Z__firstlineno____annotations__Z__static_attributes__r   r   r   r3   r3   P   s    JJr   r3   c                   V ^8  d   QhRR/# r
   r   z
str | Noner   r   r   r   r   r   U   s      z r   c                 s     \         P                  ! R4      p V P                  4       w  rV#   \        \        \
        \        3 d     R# i ; i)zB
Primary implementation of glibc_version_string using os.confstr.
ZCS_GNU_LIBC_VERSIONN)osZconfstrZrsplitZAssertionErrorAttributeErrorr   r   )Zversion_string_versions      r   _glibc_version_string_confstrr>   U   sJ    %'ZZ0E%F#**,
 N NGZ@ s   (, A
Ac               r8   r9   r   r   r   r   r   r   h   s     ) )j )r   c                 s8    ^ RI p  T P                  R4      p TP                  pT P                  Tn        T! 4       p\        T\        4      '       g   TP                  R4      pT#   \         d     R# i ; i  \         d     R# i ; i  \
         d     R# i ; i)z?
Fallback implementation of glibc_version_string using ctypes.
NZascii)ctypesImportErrorZCDLLr   gnu_get_libc_versionr;   Zc_char_pZrestypeZ
isinstancer   Zdecode)r?   Zprocess_namespacerA   version_strs       r   _glibc_version_string_ctypesrC   h   s    ""KK-0EE $*?? +-Kk3''!((1G  $  
   s3   A& A8 B
 &A54A58BB
BBc               r8   r9   r   r   r   r   r   r      s     M Mz Mr   c                 s:    \        4       ;'       g    \        4       # )z9Returns glibc version string, or None if not using glibc.)r>   rC   r   r   r   _glibc_version_stringrD      s    (*LL.J.LLr   c               r	   )r
   rB   r   r   tuple[int, int]r   r   r   r   r   r      s     8 8c 8o 8r   c                s    \         P                  ! RV 4      pV'       g#   \        P                  ! RV  2\        ^R7       R# \        VP                  R4      4      \        VP                  R4      4      3# )a  Parse glibc version.

We use a regexp instead of str.split because we want to discard any
random junk that might come after the minor version -- this might happen
in patched/forked versions of glibc (e.g. Linaro's version of glibc
uses version strings like "2.20-2014.11"). See gh-3588.
z$(?P<major>[0-9]+)\.(?P<minor>[0-9]+)z;Expected glibc version with 2 components major.minor, got: )Z
stacklevelr5   r6   rG   )reZmatchwarningsZwarnZRuntimeWarningr4   Zgroup)rB   Zmr   r   _parse_glibc_versionrJ      sb     	8+FAI+W	

 qwww #aggg&6"777r   c               r8   )r
   r   rE   r   r   r   r   r   r      s     - -O -r   c                 s8    \        4       p V f   R# \        V 4      # )NrF   )rD   rJ   )rB   s    r   _get_glibc_versionrK      s     ')K,,r   c               r)   )r
   r-   r   r=   r3   r   r   r   r   r   r   r   r      s!       }  r   c                s0   \        4       pW!8  d   R #  ^ RIp\        TR4      '       d3   TP	                  T^ ,          T^,          T 4      pTe   \        T4      # R# T\        ^^4      8X  d(   \        TR4      '       d   \        TP                  4      # T\        ^^4      8X  d(   \        TR4      '       d   \        TP                  4      # T\        ^^4      8X  d(   \        TR4      '       d   \        TP                  4      # R#   \         d     R# i ; i)FNTmanylinux_compatiblemanylinux1_compatiblemanylinux2010_compatiblemanylinux2014_compatible)
rK   
_manylinuxr@   ZhasattrrL   r   r3   rM   rN   rO   )r-   r=   Z	sys_glibcrP   Zresults   &&   r   _is_compatiblerQ      s    "$I z12200WQZN<-1%%:677
8899-2&&:9::
;;<<-2&&:9::
;;<<!  s   D DDZmanylinux2014Zmanylinux2010Z
manylinux1c               r	   )r
   r*   r+   r   zIterator[str]r   r   r   r   r   r      s     -5 -5 -5= -5r   c              #  s  "   \        \        P                  V 4      '       g   R# \        ^^4      p\	        V 4      RR0,          '       d   \        ^^4      p\        \        4       !  pV.p\        VP                  ^,
          ^R4       F*  p\        V,          pVP                  \        WE4      4       K,  	  V  F  pV F  pVP                  VP                  8X  d   VP                  pMRp\        VP                  VR4       Fy  p\        VP                  V4      p	RP                  ! V	!  p
\        Wi4      '       d
   V
 RV 2x  V	\        9   g   KP  \        V	,          p\        Wi4      '       g   Kp  V RV 2x  K{  	  K  	  K  	  R# 5i)a  Generate manylinux tags compatible to the current platform.

:param archs: Sequence of compatible architectures.
    The first one shall be the closest to the actual architecture and be the part of
    platform tag after the ``linux_`` prefix, e.g. ``x86_64``.
    The ``linux_`` prefix is assumed as a prerequisite for the current platform to
    be manylinux-compatible.

:returns: An iterator of compatible manylinux tags.
Nr/   r,   zmanylinux_{}_{}r<   rG   )r0   sysr   r3   ZsetrK   Zranger5   r2   Zappendr6   r   rQ   _LEGACY_MANYLINUX_MAP)r*   Ztoo_old_glibc2Zcurrent_glibcZglibc_max_listZglibc_majorZglibc_minorr-   Z	glibc_maxZ	min_minorZglibc_versionZtagZ
legacy_tags   &           r   platform_tagsrT      sU      66"1b)N
5zXv&&&&q!,!#5#78M#_N ]0014a<'4mKEF = 'I."6"66*00	 	$Y__iD -ioo{ K'..>!$66 E4&/) $99!6}!EJ%d::!+AdV44  E ( s   EF	F	2F	)r
   i   )r
   i   )r
   i   ))__conditional_annotations__Z
__future__r    ZcollectionsZ
contextlibZ	functoolsr:   rH   rR   rI   Ztypingr   r   r   r   Z_elffiler   r   r   r   r#   r$   r%   Zcontextmanagerr   r'   r(   r0   Zdefaultdictr2   r7   r3   r>   rC   rD   rJ   Z	lru_cacherK   rQ   rS   rT   )rU   s   @r   <module>rV      s    " "    	 	 
  < < 8 8" 
  

8, %0$;$;J$G > GJ 
&)XM
8& - -8 __
L -5r   