3
Q'ícÍ ã @ s d dl Z d dlZd dlZd dlmZ d dlmZmZmZmZ ddl m
Z
dddd gZG d
d dZdddZ
dddZdd
d Zdd Ze dS )é N)Ú
StrictVersion)Ú
PKG_DIRECTORYÚPY_COMPILEDÚ PY_SOURCEÚ PY_FROZENé )ÚBytecodeÚRequireÚfind_moduleÚget_module_constantÚextract_constantc @ sH e Zd ZdZdddZdd Zdd ZdddZdd
dZdddZ dS )r z7A prerequisite to building or installing a distributionÚ Nc C sF |d kr|d k rt }|d k r0||}|d kr0d}| jjt | `d S )NÚ__version__)r Ú__dict__ÚupdateÚlocalsÚself)r ÚnameÚrequested_versionÚmoduleZhomepageÚ attributeÚformat© r ú8/tmp/pip-build-l_bcah40/setuptools/setuptools/depends.pyÚ__init__ s zRequire.__init__c C s | j dk rd| j| j f S | jS )z0Return full package/distribution name, w/versionNz%s-%s)r r )r r r r Ú full_name s
zRequire.full_namec C s* | j dkp(| jdkp(t|dko(|| jkS )z%Is 'version' sufficiently up-to-date?NÚunknown)r r Ústrr )r Úversionr r r Ú
version_ok&