<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet"
        integrity="sha384-GLhlTQ8iRABdZLl6O3oVMWSktQOp6b7In1Zl3/Jr59b6EGGoI1aFkw7cmDA6j6gD" crossorigin="anonymous">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.3.0/css/all.min.css"
        integrity="sha512-SzlrxWUlpfuzQ+pcUCosxcglQRNAq/DZjVsC0lE40xsADsfeQoEypE+enwcOiGjk/bSuGGKHEyjSoQ1zVisanQ=="
        crossorigin="anonymous" referrerpolicy="no-referrer" />
</head>
</html>

ReI                 @   sY  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	 m
 Z d d l Z d d l m Z d d l Z d d l Z d d l m Z d d l Z d d l m Z d d	 l m Z d d
 l m Z e j e  Z d d   Z d d   Z d d   Z d d d  Z  d d d d d d d d i Z! d d   Z" e d k rUe    d S)zHCheck a project and backend by attempting to build using PEP 517 hooks.
    N)isfilejoin)TomlDecodeErrorload)CalledProcessError)mkdtemp   )enable_colourful_output)BuildEnvironment)Pep517HookCallerc          0   C   s  t    } y | j |  t j d  Wn# t k
 rO t j d  d SYn Xy# |  j i   } t j d |  Wn) t k
 r t j d d d d SYn Xy | j |  t j d  Wn# t k
 r t j d	  d SYn Xt   } t j d
 |  z y& |  j	 | i   } t j d |  Wn) t k
 rPt j d d d d SYn X| j
 d  stt j d |  d St | |  } t |  rt j d |  n t j d |  d St j |  rt j d  n t j d  d SWd  t j |  Xd SWd  QRXd  S)Nz#Installed static build dependenciesz+Failed to install static build dependenciesFzGot build requires: %sz'Failure in get_requires_for_build_sdistexc_infoTz$Installed dynamic build dependenciesz,Failed to install dynamic build dependencieszTrying to build sdist in %szbuild_sdist returned %rzFailure in build_sdistz.tar.gzz*Filename %s doesn't have .tar.gz extensionzOutput file %s existszOutput file %s does not existzOutput file is a tar filezOutput file is not a tar file)r
   pip_installloginfor   errorget_requires_for_build_sdist	Exceptionr   build_sdistendswithpjoinr   tarfile
is_tarfileshutilrmtree)hooksbuild_sys_requiresenvreqstdfilenamepath r!   /builddir/build/BUILDROOT/alt-python35-pip-20.2.4-5.el8.x86_64/opt/alt/python35/lib/python3.5/site-packages/pip/_vendor/pep517/check.pycheck_build_sdist   sV    					
r#   c          0   C   s  t    } y | j |  t j d  Wn# t k
 rO t j d  d SYn Xy# |  j i   } t j d |  Wn) t k
 r t j d d d d SYn Xy | j |  t j d  Wn# t k
 r t j d	  d SYn Xt   } t j d
 |  z y& |  j	 | i   } t j d |  Wn) t k
 rPt j d d d d SYn X| j
 d  stt j d |  d St | |  } t |  rt j d |  n t j d |  d St j |  rt j d  n t j d  d SWd  t j |  Xd SWd  QRXd  S)Nz#Installed static build dependenciesz+Failed to install static build dependenciesFzGot build requires: %sz'Failure in get_requires_for_build_sdistr   Tz$Installed dynamic build dependenciesz,Failed to install dynamic build dependencieszTrying to build wheel in %szbuild_wheel returned %rzFailure in build_wheelz.whlz'Filename %s doesn't have .whl extensionzOutput file %s existszOutput file %s does not existzOutput file is a zip filezOutput file is not a zip file)r
   r   r   r   r   r   get_requires_for_build_wheelr   r   build_wheelr   r   r   zipfile
is_zipfiler   r   )r   r   r   r   r   r   r    r!   r!   r"   check_build_wheelO   sT    					r(   c             C   s(  t  |  d  } t |  r+ t j d  n t j d  d Sy` t |   } t |  } Wd  QRX| d } | d } | d } | j d  } t j d	  Wn/ t t	 f k
 r t j d
 d d d SYn Xt
 |  | |  } t | |  }	 t | |  }
 |	 st j d  |
 s$t j d  |	 S)Nzpyproject.tomlzFound pyproject.tomlzMissing pyproject.tomlFzbuild-systemrequireszbuild-backendzbackend-pathzLoaded pyproject.tomlzInvalid pyproject.tomlr   Tz%Sdist checks failed; scroll up to seezWheel checks failed)r   r   r   r   r   open	toml_loadgetr   KeyErrorr   r#   r(   warning)
source_dir	pyprojectfZpyproject_dataZbuildsysr)   backendbackend_pathr   Zsdist_okZwheel_okr!   r!   r"   check   s0    


	r4   c             C   s   t  j   } | j d d d | j |   } t   t | j  } | r` t t d d   n  t t d d   t	 j
 d  d  S)	Nr/   helpz%A directory containing pyproject.tomlzChecks passedgreenzChecks failedredr   )argparseArgumentParseradd_argument
parse_argsr	   r4   r/   printansisysexit)argvZapargsokr!   r!   r"   main   s    rC   resetz[0mZboldz[1mr7   z[31mr6   z[32mc             C   sF   t  j d k r8 t j j   r8 t | t |   t d St |   Sd  S)NntrD   )osnamer>   stdoutisatty
ansi_codesstr)sattrr!   r!   r"   r=      s    r=   __main__)#__doc__r8   loggingrF   os.pathr   r   r   Zpip._vendor.tomlr   r   r+   r   
subprocessr   r>   r   tempfiler   r&   Zcolorlogr	   Zenvbuildr
   wrappersr   	getLogger__name__r   r#   r(   r4   rC   rJ   r=   r!   r!   r!   r"   <module>   s4   98"