§
    ZQd6  ã                   ó†  — d Z ddlZddlZddlZddlZddlZddlZddlmZ ddl	m
Z
 ddlmZmZmZmZmZmZmZmZmZmZmZmZm Z m!Z!m"Z"m#Z#m$Z$m%Z%m&Z&  e$¦   «         Z' ej(        de)d¬	¦  «         dd
„Z ee!d¬¦  «        Z* eee'¦  «        Z eee'¦  «        Z+dd„Z,dZ-	 esej.        Z-n# e/$ r Y nw xY wd„ Z0d„ Z1dd„Z2dd„Z3dS )a�  Provide access to Python's configuration information.  The specific
configuration variables available depend heavily on the platform and
configuration.  The values may be retrieved using
get_config_var(name), and the list of variables is available via
get_config_vars().keys().  Additional convenience functions are also
available.

Written by:   Fred L. Drake, Jr.
Email:        <fdrake@acm.org>
é    N)Úpartialé   )ÚDistutilsPlatformError)Ú_PREFIXÚ_BASE_PREFIXÚ_EXEC_PREFIXÚ_BASE_EXEC_PREFIXÚ_PROJECT_BASEÚ_PYTHON_BUILDÚ_init_posixÚparse_config_hÚ_init_non_posixÚ_variable_rxÚ_findvar1_rxÚ_findvar2_rxÚexpand_makefile_varsÚis_python_buildÚget_config_h_filenameÚget_config_varÚget_config_varsÚget_makefile_filenameÚget_python_versionzCThe distutils.sysconfig module is deprecated, use sysconfig insteadé   )Ú
stacklevelc                 ó$   — t          | |¬¦  «        S )N)Úvars)Úsysconfig_parse_config_h)ÚfpÚgs     ú*/usr/lib/python3.11/distutils/sysconfig.pyr   r   >   s   € Ý# B¨QÐ/Ñ/Ô/Ð/ó    T)Ú
check_homec                 ó4  — ddl m}  || dddd¬¦  «        }|€i }i }i }	 |                     ¦   «         }|€n©t          j        t
          |¦  «        }|rŒ|                     dd¦  «        \  }}	|	                     ¦   «         }	|	                     d	d
¦  «        }
d|
v r|	||<   n?	 t          |	¦  «        }	|	||<   n)# t          $ r |	                     d	d¦  «        ||<   Y nw xY wŒÀd}|�rÄt          |¦  «        D �]°}||         }t          j        t          |¦  «        pt          j        t          |¦  «        }|�rk|                     d¦  «        }d}||v rt          ||         ¦  «        }nz||v rd}ns|t           j        v rt           j        |         }nR||v rG|                     d¦  «        r|dd…         |v rd
}n*d|z   |v rd}n t          |d|z            ¦  «        }nd
x||<   }|r¼||                     ¦   «         d…         }|d|                     ¦   «         …         |z   |z   }d|v r|||<   �Œ8t          |¦  «        }|||<   n'# t          $ r |                     ¦   «         ||<   Y nw xY w||= |                     d¦  «        r|dd…         |v r|dd…         }||vr|||<   �Œ­||= �Œ²|�°Ä|                     ¦   «          |                     ¦   «         D ]1\  }}	t/          |	t          ¦  «        r|	                     ¦   «         ||<   Œ2|                     |¦  «         |S )zËParse a Makefile-style file.
    A dictionary containing name/value pairs is returned.  If an
    optional dictionary is passed in as the second argument, it is
    used instead of a new dictionary.
    r   )ÚTextFiler   Úsurrogateescape)Ústrip_commentsÚskip_blanksÚ
join_linesÚerrorsNTr   z$$Ú ú$)ÚCFLAGSÚLDFLAGSÚCPPFLAGSFÚPY_é   )Údistutils.text_filer$   ÚreadlineÚreÚmatchr   ÚgroupÚstripÚreplaceÚintÚ
ValueErrorÚlistÚsearchr   r   ÚstrÚosÚenvironÚ
startswithÚendÚstartÚcloseÚitemsÚ
isinstanceÚupdate)Úfnr   r$   r   ÚdoneÚnotdoneÚlineÚmÚnÚvÚtmpvÚrenamed_variablesÚnameÚvalueÚfoundÚitemÚafterÚks                     r    Úparse_makefilerU   I   s­  € ð -Ð,Ð,Ð,Ð,Ð,Ø	ˆ�" Q°AÀ!ÐL]Ð	^Ñ	^Ô	^€Bà€yØˆØ€DØ€Gð Ø�{Š{‰}Œ}ˆØˆ<ØÝŒH•\ 4Ñ(Ô(ˆØð 	 Ø—7’7˜1˜a‘=”=‰DˆAˆqØ—’‘	”	ˆAà—9’9˜T 2Ñ&Ô&ˆDà�dˆ{ˆ{Ø�˜‘
�
ð Ý˜A™œ�Að
  �D˜‘G�Gøõ	 "ð 3ð 3ð 3àŸiši¨¨cÑ2Ô2�D˜‘G�G�Gð3øøøð! ð4 :Ðð ñ 0"Ý˜‘M”Mð /	"ñ /	"ˆDØ˜D”MˆEÝ”	�,¨Ñ.Ô.ÐPµ"´)½LÈ%Ñ2PÔ2PˆAØñ ,"Ø—G’G˜A‘J”J�Ø�Ø˜�9�9Ý˜t Aœw™<œ<�D�DØ˜'�\�\à!�E�EØ�"œ*�_�_åœ: aœ=�D�DàÐ+Ð+Ð+Ø—’ uÑ-Ô-ð 4°$°q°r°r´(Ð>OÐ2OÐ2OØ!˜˜à ™ gÐ-Ð-Ø %˜˜õ  # 4¨°©	¤?Ñ3Ô3˜˜à%'Ð'�D˜‘G˜dØð 3Ø! !§%¢%¡'¤' ( (œO�EØ! * 1§7¢7¡9¤9 *Ô-°Ñ4°uÑ<�EØ˜e�|�|Ø(-˜ ™™å%(¨¡Z¤Z˜Uð */˜D ™J˜Jøõ  *ð 7ð 7ð 7Ø).¯ª©¬˜D ™J˜J˜Jð7øøøð $ D˜MàŸ?š?¨5Ñ1Ô1ð 3Ø $ Q R R¤Ð,=Ð =Ð =à#'¨¨¨¤8˜DØ#¨4Ð/Ð/Ø-2  T¡
ùð ˜D�M‘Mða ñ 0"ðd ‡H‚H�J„J€Jð —
’
‘”ð  ð  ‰ˆˆ1Ý�a�ÑÔð 	 Ø—g’g‘i”iˆD�‰Gøð ‡H‚HˆT�N„N€NØ€Hs$   Â!B6 Â6#CÃCÈ,IÉ!I%É$I%r*   c                 óR  — | j         dk    �rt          j        dk    rBt                               d¦  «        s(ddl}|                     t          ¦  «         dt          d<   t          ddd	d
ddddddd¦  «        \  }}}}}}}}	}
}}dt          j	        v rat          j	        d         }t          j        dk    r=dt          j	        vr/| 
                    |¦  «        r||t          |¦  «        d…         z   }|}dt          j	        v rt          j	        d         }t          j        ||gd¦  «        rB|                     dd¦  «        }|                     dd¦  «        }|                     dd¦  «        }dt          j	        v rt          j	        d         }dt          j	        v rt          j	        d         }n|dz   }dt          j	        v r|dz   t          j	        d         z   }n
|r|dz   |z   }d	t          j	        v r1|dz   t          j	        d	         z   }|dz   t          j	        d	         z   }n|r|dz   |z   }|dz   |z   }dt          j	        v rI|dz   t          j	        d         z   }|dz   t          j	        d         z   }|dz   t          j	        d         z   }n|
r|dz   |
z   }|dz   |
z   }|dz   |
z   }dt          j	        v rt          j	        d         }dt          j	        v r|dz   t          j	        d         z   }n|dz   |	z   }|dz   |z   }|                      |||dz   |z   ||||¬¦  «         || _        dS dS )zÄDo any platform-specific customization of a CCompiler instance.

    Mainly needed on Unix, so we can plug in the information that
    varies across Unices and is stored in Python's Makefile.
    ÚunixÚdarwinÚCUSTOMIZED_OSX_COMPILERr   NÚTrueÚCCÚCXXr,   ÚCCSHAREDÚLDSHAREDÚSHLIB_SUFFIXÚARÚARFLAGSÚCONFIGURE_CPPFLAGSÚCONFIGURE_CFLAGSÚCONFIGURE_LDFLAGSz	*-4.[0-8]z-fstack-protector-strongz-fstack-protectorÚCPPz -Er-   ú r.   )ÚpreprocessorÚcompilerÚcompiler_soÚcompiler_cxxÚ	linker_soÚ
linker_exeÚarchiver)Úcompiler_typeÚsysÚplatformÚ_config_varsÚgetÚ_osx_supportÚcustomize_compilerr   r=   r>   r?   ÚlenÚfnmatchÚfilterr7   Úset_executablesÚshared_lib_extension)rh   rs   ÚccÚcxxÚcflagsÚccsharedÚldsharedÚshlib_suffixÚarÚar_flagsÚconfigure_cppflagsÚconfigure_cflagsÚconfigure_ldflagsÚnewccÚcpprm   Úcc_cmds                    r    rt   rt   Â   s–  € ð Ô Ò'Ñ'ÝŒ<˜8Ò#Ð#õ  ×#Ò#Ð$=Ñ>Ô>ð AØ#Ð#Ð#Ð#Ø×/Ò/µÑ=Ô=Ð=Ø:@•Ð6Ñ7õ ˜D %¨Ø&¨
°NÀDÈ)Ø0Ð2DÐFYñ[ô [ñ	BˆˆS�&˜( H¨l¸BÀØ	Ð-Ð/@ð
 •2”:ÐÐÝ”J˜tÔ$ˆEÝ” Ò(Ð(Ø"­"¬*Ð4Ð4Ø ×+Ò+¨BÑ/Ô/ð 5ð ! 8­C°©G¬G¨H¨HÔ#5Ñ5�ØˆBØ•B”JÐÐÝ”*˜UÔ#ˆCÝŒ>˜2˜s˜) [Ñ1Ô1ð 	UØ/×7Ò7Ð8RÐTgÑhÔhÐØ×'Ò'Ð(BÐDWÑXÔXˆHØ—^’^Ð$>Ð@SÑTÔTˆFØ�œÐ#Ð#Ý”z *Ô-ˆHØ•B”JÐÐÝ”*˜UÔ#ˆCˆCà�u‘*ˆCØ�œ
Ð"Ð"Ø #‘~­¬
°9Ô(=Ñ=ˆHˆHØð 	:Ø #‘~Ð(9Ñ9ˆHØ•r”zÐ!Ð!Ø˜c‘\¥B¤J¨xÔ$8Ñ8ˆFØ #‘~­¬
°8Ô(<Ñ<ˆHˆHØð 	9Ø˜c‘\Ð$4Ñ4ˆFØ #‘~Ð(8Ñ8ˆHØ�œÐ#Ð#Ø˜‘)�bœj¨Ô4Ñ4ˆCØ˜c‘\¥B¤J¨zÔ$:Ñ:ˆFØ #‘~­¬
°:Ô(>Ñ>ˆHˆHØð 	;Ø˜‘)Ð0Ñ0ˆCØ˜c‘\Ð$6Ñ6ˆFØ #‘~Ð(:Ñ:ˆHØ•2”:ÐÐÝ”˜DÔ!ˆBØ�œ
Ð"Ð"Ø˜C‘x¥"¤*¨YÔ"7Ñ7ˆHˆHà˜C‘x (Ñ*ˆHà�c‘˜FÑ"ˆØ× Ò ØØØ ™ xÑ/ØØØØð 	!ñ 	ô 	ð 	ð )5ˆÔ%Ð%Ð%ð[ (Ð'r!   c                  ó`   — t           j        t           j        k    pt          t           d¦  «        S )NÚreal_prefix)ro   Úbase_prefixÚprefixÚhasattr© r!   r    Úis_virtual_environmentrŽ     s    € ÝŒ?�cœjÒ(ÐG­GµC¸Ñ,GÔ,GÐGr!   c                 ó  — |€| rt           pt          }t          j        dk    r¸t          rU| rt
          S t          j                             t          d¦  «        d¦  «        }t          j         	                    |¦  «        S dt          ¦   «         z   t          z   }t          s| rddl}|                     d¦  «        S t          j                             |d|¦  «        S t          j        d	k    rzt          rSt          j                             |d¦  «        t          j        j        z   t          j                             |d
¦  «        z   S t          j                             |d¦  «        S t          dt          j        z  ¦  «        ‚)a¤  Return the directory containing installed Python header files.

    If 'plat_specific' is false (the default), this is the path to the
    non-platform-specific header files, i.e. Python.h and so on;
    otherwise, this is the path to platform-specific header files
    (namely pyconfig.h).

    If 'prefix' is supplied, use it instead of sys.base_prefix or
    sys.base_exec_prefix -- i.e., ignore 'plat_specific'.
    NÚposixÚsrcdirÚIncludeÚpythonr   ÚplatincludeÚincludeÚntÚPCzFI don't know where Python installs its C header files on platform '%s')ÚBASE_EXEC_PREFIXÚBASE_PREFIXr=   rO   Úpython_buildÚproject_baseÚpathÚjoinr   Únormpathr   Úbuild_flagsÚ	sysconfigÚget_pathÚpathsepr   )Úplat_specificr‹   ÚincdirÚ
python_dirr    s        r    Úget_python_incr¦     sS  € ð €~ØÐ3Õ#3ÐBµ{ˆÝ	„w�'ÒÐÝð 
	0ð ð 0Ý#Ð#åœŸš¥n°XÑ&>Ô&>À	ÑJÔJ�Ý”w×'Ò'¨Ñ/Ô/Ð/ØÕ 2Ñ 4Ô 4Ñ4µ{ÑBˆ
Ýð 	5 ð 	5ØÐÐÐØ×%Ò% mÑ4Ô4Ð4ÝŒw�|Š|˜F I¨zÑ:Ô:Ð:Ý	Œ�DŠˆÝð 	0õ ”G—L’L ¨Ñ3Ô3µb´g´oÑEÝ”G—L’L ¨Ñ.Ô.ñ/ð 0åŒw�|Š|˜F IÑ.Ô.Ð.å$ðÝ!#¤ñ)ñ*ô *ð 	*r!   c                 óÄ  — | p t           j                             |¦  «        dv }|€#|r| rt          pt          }n| rt
          pt          }t           j        dk    r™| s|rt          j	        }nd}t           j         
                    ||dt          ¦   «         z   ¦  «        }|r|S |r0t          ¦   «         s"t           j         
                    |ddd¦  «        S t           j         
                    |d¦  «        S t           j        d	k    rC|r t           j         
                    |d
¦  «        S t           j         
                    |d
d¦  «        S t          dt           j        z  ¦  «        ‚)aS  Return the directory containing the Python library (standard or
    site additions).

    If 'plat_specific' is true, return the directory containing
    platform-specific modules, i.e. any module from a non-pure-Python
    module distribution; otherwise, return the platform-shared library
    directory.  If 'standard_lib' is true, return the directory
    containing standard Python library modules; otherwise, return the
    directory for site-specific modules.

    If 'prefix' is supplied, use it instead of sys.base_prefix or
    sys.base_exec_prefix -- i.e., ignore 'plat_specific'.
    )z/usrz
/usr/localNr�   Úlibr“   Úpython3zdist-packageszsite-packagesr–   ÚLibz?I don't know where Python installs its library on platform '%s')r=   rœ   rž   r˜   r™   ÚEXEC_PREFIXÚPREFIXrO   ro   Ú
platlibdirr�   r   rŽ   r   )r£   Ústandard_libr‹   Úis_default_prefixÚlibdirÚ	libpythons         r    Úget_python_libr²   G  sd  € ð #˜
ÐX¥b¤g×&6Ò&6°vÑ&>Ô&>ÐBXÐ&XÐØ€~Øð 	=Ø"Ð7Õ'7ÐF½;ˆFˆFà"Ð2¥{Ð<µfˆFå	„w�'ÒÐØð 	˜Lð 	õ ”^ˆFˆFð ˆFÝ”G—L’L ¨Ø!)Õ,>Ñ,@Ô,@Ñ!@ñBô Bˆ	àð 	<ØÐØð 	<Õ'=Ñ'?Ô'?ð 	<Ý”7—<’< ¨¨y¸/ÑJÔJÐJå”7—<’< 	¨?Ñ;Ô;Ð;Ý	Œ�DŠˆØð 	@Ý”7—<’< ¨Ñ.Ô.Ð.å”7—<’< ¨¨Ñ?Ô?Ð?å$ðÝ!#¤ñ)ñ*ô *ð 	*r!   )N)r   N)r   r   N)4Ú__doc__Ú_impr=   r3   ro   Úwarningsrv   Ú	functoolsr   r)   r   r    r   r¬   r   r™   r   r«   r	   r˜   r
   r›   r   rš   r   Úsysconfig_init_posixr   r   r   r   r   r   r   r   r   r   r   r   r   rq   ÚwarnÚDeprecationWarningÚ_python_buildÚ_init_ntrU   rŸ   ÚabiflagsÚAttributeErrorrt   rŽ   r¦   r²   r�   r!   r    ú<module>r¾      sl  ðð	ð 	ð €€€Ø 	€	€	€	Ø 	€	€	€	Ø 
€
€
€
Ø €€€Ø €€€à Ð Ð Ð Ð Ð à *Ð *Ð *Ð *Ð *Ð *ðð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð ð: ˆÑ Ô €à €„ØIØØðñ ô ð ð0ð 0ð 0ð 0ð �˜°DÐ9Ñ9Ô9€ØˆgÐ*¨LÑ9Ô9€Øˆ7�? LÑ1Ô1€ð
fð fð fð fð^ €ð	Øð #Ø”lˆøøØð 	ð 	ð 	ð 	€Dð	øøøðS5ð S5ð S5ðlHð Hð Hð(*ð (*ð (*ð (*ðV-*ð -*ð -*ð -*ð -*ð -*s   Â	B( Â(B0Â/B0