+
    i'                        ^ RI Ht ^ RIHtHt ^ RIHt ^ RIt^ RIt^ RI	t	^ RI
t
^RIHtHtHt  ! R R4      t ! R R	]4      tR
 t ! R R]4      t ! R R]4      tR# )    )annotations)CallableOptional)OrderedDictN)find_binary_of_commandunique_listCompileErrorc                      ] tR t^t$ RtR]R&   R]R&   RtR]R&   R]R&   R	]R
&   R]R&   R]R&   RR lt]RR l4       t	R t
R tRtR# )CompilerRunnera  CompilerRunner base class.

Parameters
==========

sources : list of str
    Paths to sources.
out : str
flags : iterable of str
    Compiler flags.
run_linker : bool
compiler_name_exe : (str, str) tuple
    Tuple of compiler name &  command to call.
cwd : str
    Path of root of relative paths.
include_dirs : list of str
    Include directories.
libraries : list of str
    Libraries to link against.
library_dirs : list of str
    Paths to search for shared libraries.
std : str
    Standard string, e.g. ``'c++11'``, ``'c99'``, ``'f2003'``.
define: iterable of strings
    macros to define
undef : iterable of strings
    macros to undefine
preferred_vendor : string
    name of preferred vendor e.g. 'gnu' or 'intel'

Methods
=======

run():
    Invoke compilation as a subprocess.

strenviron_key_compilerenviron_key_flagsLDFLAGSenviron_key_ldflagszdict[str, str]compiler_dictztuple[None | str, ...]	standardsz)dict[str, Callable[[Optional[str]], str]]std_formatercompiler_name_vendor_mappingNc                	
   \        V\        4      '       d   \        R 4      h\        V4      V n        W n        T;'       g    . V n        \        P                  P                  V P                  4      '       dG   V ;P                  \        P                  V P                  ,          P                  4       ,          un        W`n        V'       d   Vw  V n        V n        EM\        P                  P                  V P                  4      '       d   \        P                  V P                  ,          V n        V P                   P#                  4        F(  w  ppVV P                  9   g   K  VV n        VV n         EM	  \        V P                   P#                  4       4      ^ ,          w  V n        V n        \&        P(                  ! RV P                  : RV P                  : 24       MVf!   \        P                  P                  RR4      pV P+                  V4      w  V n        V n        V n        V P                  fB   \        RP-                  RP/                  V P                   P1                  4       4      4      4      hT;'       g    . V n        T;'       g    . V n        T;'       g    . V n        T;'       g    . V n        T	;'       g    . V n        T
;'       g    V P<                  ^ ,          V n        W@n         V P@                  '       d'   \        \C        R V P                  4      4      V n        M,RV P                  9  d   V P                  PE                  R4       V P>                  '       dG   V P                  PE                  V PF                  V P                  ,          ! V P>                  4      4       T;'       g    . \I        \        PJ                  \        P                  P                  V PL                  R	4      P                  4       4       Uu. uF  pVR	8w  g   K  VNK  	  up,           V n'        VEe)   \P        PR                  ! R
4      p\P        PR                  ! R4      pVRJ dk   \U        \I        VPV                  V4      4      '       d   \Y        R4      h\U        \I        VPV                  V4      4      '       d   R# VPE                  R4       R# VRJ dk   \U        \I        VPV                  V4      4      '       d   R# \U        \I        VPV                  V4      4      '       d   \Y        R4      hVPE                  R4       R# Rp\        VP-                  V4      4      hR# u upi )z2Expected argument sources to be a list of strings.z*failed to determine what kind of compiler z is, assuming NSYMPY_COMPILER_VENDORz No compiler found (searched: {})z, c                    V R 8g  # )-c xs   &b/var/www/html/photoedit/myenv/lib/python3.14/site-packages/sympy/utilities/_compilation/runners.py<lambda>)CompilerRunner.__init__.<locals>.<lambda>o   s    qDy    r    zno-strict-aliasing$zstrict-aliasing$Tz4Strict aliasing cannot be both enforced and disabledz-fstrict-aliasingFz-fno-strict-aliasingz:Expected argument strict_aliasing to be True/False, got {})-
isinstancer   
ValueErrorlistsourcesoutflagsosenvirongetr   splitcwdcompiler_namecompiler_binaryr   r   itemscompiler_vendorwarningswarnfind_compilerformatjoinvaluesdefineundefinclude_dirs	librarieslibrary_dirsr   std
run_linkerfilterappendr   mapstripr   linklinerecompileanymatchr	   )selfr$   r%   r&   r<   compilerr+   r8   r9   r:   r;   r6   r7   strict_aliasingpreferred_vendorrA   kwargskvlfnsa_resa_remsgs   &&&&&&&&&&&&&&&&,      r   __init__CompilerRunner.__init__G   s    gs##QRRG}[[b
::>>$0011JJ"**T%;%;<BBDDJ7?4D 4ZZ^^D5566#%::d.G.G#HD **0021,,,+,D()*D&	 3 <@@R@R@X@X@Z;[\];^8$d&8#33T5G5GI J  '#%::>>2I4#P MQM_M_`pMqJD 4d6J##+ !C!J!J499UYUgUgUnUnUpKq!rssll[[b
(..B"b(..B++$..+$???f%8$**EFDJ4::%

!!$'888JJd//""$$(HH. / "RIIrzz~~d&>&>CIIK:
 , :
22X -/B :
 ,  &ZZ 56FJJ12E$&s6<</00&']^^U[[%011LL!45 E)s6<</003u{{E233*+abb%;<R O!<==) '	,s   	U U c                <   \        V P                  P                  4       4      pV'       d,   W9   d   V.V,           pM\        RP	                  V4      4      h\        V Uu. uF  q0P                  V,          NK  	  up4      w  rEWEV P                  V,          3# u upi )z.Identify a suitable C/fortran/other compiler. zUnknown vendor {})r#   r   keysr"   r3   r   r   )clsrI   
candidatesr   namepaths   &&    r   r2   CompilerRunner.find_compiler   s     #++0023
-./
:
 !4!;!;<L!MNN+:,V:a->->q-A-A:,VW
3;;DAAA -Ws    Bc                f   V P                   .V P                  ,           V P                   Uu. uF  pRV,           NK  	  up,           V P                   Uu. uF  pRV,           NK  	  up,           V P                   Uu. uF  pRV,           NK  	  up,           V P
                  ,           pV P                  '       dc   Y P                   Uu. uF  pRV,           NK  	  upV P                   Uu. uF  pRV,           NK  	  up,           V P                  ,           ,          p. p\        P                  ! RRP                  V4      4       FP  p\        P                  ! V4      e   K  WC9  g   K%  VP                  V4       RP!                  V4      p\#        V4      h	  V# u upi u upi u upi u upi u upi )	zCList of arguments (str) to be passed to e.g. ``subprocess.Popen``. z-Uz-Dz-Iz-Lz-lz\$\{(\w+)\} z$Environment variable '{}' undefined.)r-   r&   r7   r6   r8   r$   r<   r:   r9   rA   rB   findallr4   r'   getenvr>   r3   r	   )rF   r   cmdcountedenvvarrP   s   &     r   r^   CompilerRunner.cmd   st    !!"JJ!ZZ(ZT!VVZ() "[[)[T!VV[)* "../.T!VV./	0
 LL 	 ???%6%67%6T!VV%67%)^^4^T!VV^45MM" #C jj#?Fyy ((NN6*@GGOC&s++ @ 
! ))/ 84s   FF<F$F)*F.c           
     	   \        V P                  4      V n        V P                  P                  R V P                  .4       \        P
                  P                  4       pV P                  VR&   \        P                  ! RP                  V P                  4       4      RV P                  \        P                  \        P                  \        P                  VR7      pVP                  4       p V^ ,          P                  R4      V n        VP$                  V n        V P&                  ^ 8w  dd   RP)                  RP                  V P                  4       4      V P                  \+        V P&                  4      V P                   4      p\-        V4      hV P                   V P&                  3#   \"         d!    T^ ,          P                  R4      T n         Li ; i)z-oPWDr[   T)shellr+   stdinstdoutstderrenvzutf-8z
iso-8859-1z3Error executing '{}' in {} (exited status {}):
 {}
)r   r&   extendr%   r'   r(   copyr+   
subprocessPopenr4   r^   PIPESTDOUTcommunicatedecode
cmd_outerrUnicodeDecodeError
returncodecmd_returncoder3   r   r	   )rF   rh   pcommrP   s   &    r   runCompilerRunner.run   sY    ,
 	

4*+jjooXXE
 SXXdhhj1#'!%#-??$.OO$.$5$5!$& }}	;"1gnnW5DO  ll !#IPP$dhhD4G4G0H$//C s## 3 333 " 	;"1gnn\:DO	;s   .F( ((GG)rq   rt   r-   r,   r/   r+   r6   r&   r8   r9   r:   rA   r%   r<   r$   r;   r7   )NTN.NNNNNNNNN)N)__name__
__module____qualname____firstlineno____doc____annotations__r   rQ   classmethodr2   r^   rw   __static_attributes__r   r   r   r   r      sh    $L (( "! &% <; #10I>V 	B 	B.4r   r   c                      ] tR t^tRtRt]! . RO4      tRtRR	P                  RR	P                  RR	P                  /t
RRRRRR/tR
tR# )CCompilerRunnerCCCFLAGSgnugccinteliccllvmclang-std={}r   N))r   r   )r   r   )r   r   )c89c90c99c11rz   r{   r|   r}   r   r   r   r   r   r3   r   r   r   r   r   r   r   r      sg      ! M -I 	yy!!L 	uw$ r   r   c                8   a a R R/oS S9   d
   V V3R lpV# R pV# )g++c                :   < SS,           F  pW9   g   K   R # 	  R# )FTr   )r   nw
cmplr_namenot_welcomes   & r   fltr_mk_flag_filter.<locals>.fltr   s"    !*--7  . r   c                    R # )Tr   r   s   &r   r   r      s    r   )zWimplicit-interfacer   )r   r   r   s   f @r   _mk_flag_filterr      s,    23K[ 	 K	Kr   c                      ] tR t^tRtRt]! . RO4      tRtRR	P                  RR	P                  RR	P                  /t
RRRRRR/tR
tR# )CppCompilerRunnerCXXCXXFLAGSr   r   r   icpcr   clang++r   r   N))r   r   )r   r   )r   r   )zc++98zc++0xr   r   r   r   r   r      sg     " ! M #I 	y	  9##L 	u6$ r   r   c                  R    ] tR tRtRtRtRtRR RR /t]! RR.4      t	RR	RR
/t
RtR# )FortranCompilerRunneri  FCFFLAGSNgfortranc                	B    V f   R# V R8X  d   R# RP                  V 4      # )Nz-std=gnuf77z-std=legacyr   r3   r   s   &r   r   FortranCompilerRunner.<lambda>!  s)    AIjoAQVJ=o\e\l\lmn\oor   ifortc                	6    V f   R# RP                  V RR  4      # )Nz
-stand f08z
-stand f{}r   r   s   &r   r   r   "  s#    19<U,:M:MaPRPSf:UUr   r   r   r   )Nr   f95f2003f2008)r   r   )r   r   )rz   r{   r|   r}   r   r   r   r   r   r   r   r   r   r   r   r   r     sS     6I 	oUL
  ! M 	E$ r   r   )
__future__r   typingr   r   collectionsr   r'   rB   rk   r0   utilr   r   r	   r   r   r   r   r   r   r   r   <module>r      sZ    " % # 	 	   
D4 D4Nn 4 6N r   