§
    ZQd4  ã                   óx   — d Z ddlZddlZddlZddlmZmZ ddlmZ ddl	m
Z
 ej        dk    rdadad
d„Zdd	„ZdS )zìdistutils.spawn

Provides the 'spawn()' function, a front-end to various platform-
specific functions for launching another program in a sub-process.
Also provides the 'find_executable()' to search the path for a given
executable name.
é    N)ÚDistutilsPlatformErrorÚDistutilsExecError)ÚDEBUG)ÚlogÚdarwiné   c                 óþ  — t          | ¦  «        } t          j        d                     | ¦  «        ¦  «         |rdS |rt	          | d         ¦  «        }|�|| d<   d}t
          j        dk    r÷t          €Hddlm	} | 
                    d¦  «        pdat          r$d„ t                               d	¦  «        D ¦   «         at          r¡t          j                             dt          ¦  «        }d
„ |                     d	¦  «        D ¦   «         }t          dd…         ddgk    r-|dd…         ddgk     rd|›dt          ›d�}	t!          |	¦  «        ‚t#          t          j        |¬¦  «        }	 t%          j        | |¬¦  «        }
|
                     ¦   «          |
j        }nB# t,          $ r5}t.          s| d         } t1          d| ›d|j        d         ›�¦  «        |‚d}~ww xY w|r$t.          s| d         } t1          d| ›d|›�¦  «        ‚dS )a�  Run another program, specified as a command list 'cmd', in a new process.

    'cmd' is just the argument list for the new process, ie.
    cmd[0] is the program to run and cmd[1:] are the rest of its arguments.
    There is no way to run a program with a name different from that of its
    executable.

    If 'search_path' is true (the default), the system's executable
    search path will be used to find the program; otherwise, cmd[0]
    must be the exact path to the executable.  If 'dry_run' is true,
    the command will not actually be run.

    Raise DistutilsExecError if running the program fails in any way; just
    return on success.
    ú Nr   r   )Ú	sysconfigÚMACOSX_DEPLOYMENT_TARGETÚ c                 ó,   — g | ]}t          |¦  «        ‘ŒS © ©Úint©Ú.0Úxs     ú&/usr/lib/python3.11/distutils/spawn.pyú
<listcomp>zspawn.<locals>.<listcomp><   s   € Ð$LÐ$LÐ$L°¥S¨¡V¤VÐ$LÐ$LÐ$Ló    ú.c                 ó,   — g | ]}t          |¦  «        ‘ŒS r   r   r   s     r   r   zspawn.<locals>.<listcomp>D   s   € ÐFÐFÐF¨1¥ A¡¤ÐFÐFÐFr   é   é
   é   z)$MACOSX_DEPLOYMENT_TARGET mismatch: now "z" but "z)" during configure;must use 10.3 or later)r   )Úenvzcommand z	 failed: éÿÿÿÿz failed with exit code )Úlistr   ÚinfoÚjoinÚfind_executableÚsysÚplatformÚ_cfg_targetÚ	distutilsr   Úget_config_varÚsplitÚ_cfg_target_splitÚosÚenvironÚgetr   ÚdictÚ
subprocessÚPopenÚwaitÚ
returncodeÚOSErrorr   r   Úargs)ÚcmdÚsearch_pathÚverboseÚdry_runÚ
executabler   r   Ú
cur_targetÚcur_target_splitÚmy_msgÚprocÚexitcodeÚexcs                r   Úspawnr?      sn  € õ$ ˆs‰)Œ)€Cå„HˆS�XŠX�c‰]Œ]ÑÔÐØð Øˆàð  Ý$ S¨¤VÑ,Ô,ˆ
ØÐ!ØˆC�‰Fà
€CÝ
„|�xÒÐåÐØ+Ð+Ð+Ð+Ð+Ð+Ø#×2Ò2Ø"<ñ>ô >ð DØACð åð MØ$LÐ$Lµ[×5FÒ5FÀsÑ5KÔ5KÐ$LÑ$LÔ$LÐ!Ýð 	<õ œŸšÐ(BÅKÑPÔPˆJØFÐF°
×0@Ò0@ÀÑ0EÔ0EÐFÑFÔFÐÝ   ! Ô$¨¨Q¨Ò/Ð/Ð4DÀRÀaÀRÔ4HÈBÐPQÈ7Ò4RÐ4RÐ4Rð $. : :­{¨{¨{ð<�õ -¨VÑ4Ô4Ð4Ý•r”zØ0:ð<ñ <ô <ˆCðDÝÔ ¨Ð-Ñ-Ô-ˆØ�	Š	‰ŒˆØ”?ˆˆøÝð Dð Dð DÝð 	Ø�a”&ˆCÝ Ð Ø'* s s¨C¬H°R¬L¨LÐ9ñ;ô ;Ø@Cð	DøøøøðDøøøð ð GÝð 	Ø�a”&ˆCÝ Ð Ø7:°s°s¸H¸HÐEñGô Gð 	GðGð Gs   Å#1F Æ
GÆ0GÇGc                 óR  — t           j                             | ¦  «        \  }}t          j        dk    r|dk    r| dz   } t           j                             | ¦  «        r| S |€[t           j                             dd¦  «        }|€9	 t          j        d¦  «        }n## t          t          f$ r t           j        }Y nw xY w|sdS |                     t           j        ¦  «        }|D ]E}t           j                             || ¦  «        }t           j                             |¦  «        r|c S ŒFdS )zÚTries to find 'executable' in the directories listed in 'path'.

    A string listing directories separated by 'os.pathsep'; defaults to
    os.environ['PATH'].  Returns the complete filename or None if not found.
    Úwin32z.exeNÚPATHÚCS_PATH)r*   ÚpathÚsplitextr#   r$   Úisfiler+   r,   ÚconfstrÚAttributeErrorÚ
ValueErrorÚdefpathr(   Úpathsepr!   )r8   rD   Ú_ÚextÚpathsÚpÚfs          r   r"   r"   _   s)  € õ ŒW×Ò˜jÑ)Ô)�F€A€sÝŒ˜ÒÐ c¨V¢m mØ &Ñ(ˆ
å	„w‡~‚~�jÑ!Ô!ð ØÐà€|ÝŒz�~Š~˜f dÑ+Ô+ˆØˆ<ð"Ý”z )Ñ,Ô,��øÝ"¥JÐ/ð "ð "ð "å”z���ð"øøøð ð Øˆtà�JŠJ•r”zÑ"Ô"€EØð ð ˆÝŒG�LŠL˜˜JÑ'Ô'ˆÝŒ7�>Š>˜!ÑÔð 	àˆHˆHˆHð	ð ˆ4s   ÂB ÂB9Â8B9)r   r   r   )N)Ú__doc__r#   r*   r.   Údistutils.errorsr   r   Údistutils.debugr   r&   r   r$   r%   r)   r?   r"   r   r   r   ú<module>rT      sÀ   ððð ð €
€
€
Ø 	€	€	€	Ø Ð Ð Ð à GÐ GÐ GÐ GÐ GÐ GÐ GÐ GØ !Ð !Ð !Ð !Ð !Ð !Ø Ð Ð Ð Ð Ð ð „<�8ÒÐØ€KØÐðEGð EGð EGð EGðP"ð "ð "ð "ð "ð "r   