ok

Mini Shell

Direktori : /usr/lib/python2.7/site-packages/setuptools/command/
Upload File :
Current File : //usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyc

�
�Yc@s�dZddlZddlZddlZddlZddlZddlZddlZddlZddl	Z	ddl
Z
ddlmZddlZddl
mZmZddlmZddlmZmZy,ddlmZmZd�Zd	�ZWn9ek
r=dd
lmZmZd�Zd�ZnXdd
lmZddlmZm Z ddl!m"Z"m#Z#m$Z$m%Z%ddl&m'Z'm(Z(ddl)m*Z*ddl+m,Z,ddl-m.Z.ddl-m/Z/ddl)m0Z0m1Z1ddl2m3Z3m4Z4m5Z5m6Z6m7Z7m8Z8ddlm9Z9m:Z:m;Z;m<Z<m=Z=m>Z>m?Z?m@Z@mAZAmBZBmCZCmDZDmEZEmFZFmGZGdejHkr�ejHdZInejJjKejL�ZIddddddgZMddlNZNejOdko�eNjPZQddlRZRd �ZSd!�ZTejUd"fkr:d#�ZVd$�ZWnd%�ZVd&�ZWdefd'��YZXd(�ZYd)�ZZd*�Z[d+�Z\d,�Z]de?fd-��YZ^eIe_d.�Z`d/�Zad0�Zbd1�Zcd2d3�Zdd4�Zed5�Zfd6�Zgydd7lmhZiWnek
r&d8�ZinXd9�Zhd:�ZjeIe_d;�Zkd<�Zld=�Zme_ead>�Znd?�Zod@�ZpeqdA�ZrdS(BsEasy Install
------------

A tool for doing automatic download/extract/build of distutils-based Python
packages.  For detailed documentation, see the accompanying EasyInstall.txt
file, or visit the `EasyInstall home page`__.

__ https://pythonhosted.org/setuptools/easy_install.html

i����N(tglob(tCommandt_dont_write_bytecode(t	run_setup(tlogtdir_util(tget_config_varstget_pathcCs
td�S(Ntplatlib(R(((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt_get_platlibscCs
td�S(Ntpurelib(R(((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt_get_purelib!s(Rtget_python_libcCs
tt�S(N(RtTrue(((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR	%scCs
tt�S(N(RtFalse(((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR's(tget_platform(tconvert_patht
subst_vars(tDistutilsArgErrortDistutilsOptionErrortDistutilsErrortDistutilsPlatformError(tINSTALL_SCHEMEStSCHEME_KEYS(tsetopt(tunpack_archive(tPackageIndex(t
URL_SCHEME(t	bdist_eggtegg_info(t	iteritemstmaxsizetxranget
basestringtunicodetreraise(tyield_linestnormalize_pathtresource_stringtensure_directorytget_distributiontfind_distributionstEnvironmenttRequirementtDistributiontPathMetadatatEggMetadatat
WorkingSettDistributionNotFoundtVersionConflicttDEVELOP_DISTt__VENV_LAUNCHER__tsamefileteasy_installtPthDistributionstextract_wininst_cfgtmaintget_exe_prefixess2.6cCstjd�dkS(NtPi(tstructtcalcsize(((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytis_64bitKscCs�ttjd�rItjj|�rItjj|�rItjj||�Stjjtjj|��tjjtjj|��kS(NR4(thasattrtostpathtexistsR4tnormpathtnormcase(tp1tp2((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR4Ns
$icCs|S(N((ts((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt	_to_asciiYscCs.yt|d�tSWntk
r)tSXdS(Ntascii(R"R
tUnicodeErrorR(RF((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytisascii[s


cCs
|jd�S(NRH(tencode(RF((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRGbscCs.y|jd�tSWntk
r)tSXdS(NRH(RKR
RIR(RF((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRJds


cBs�eZdZdZeZdzd{d|d}d~dd�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�gZdddd
ddd"d1d4d:d=gZe	r�ej
dAdydBejf�ej
dA�nidd+6Z
eZdC�ZdD�ZdE�ZdF�ZdG�ZdH�ZdI�ZdJ�ZdK�ZdL�ZdM�ZdN�ZdO�ZdP�ZdQ�ZdR�Ze dS�Z!e dT�Z"dU�Z#edV�Z$dW�Z%dX�Z&dY�Z'dydZ�Z(d[d�d\�Z)d]�Z*d^�Z+d_�Z,d`�Z-da�Z.db�Z/dc�Z0ddde�Z1df�Z2dg�Z3dh�Z4di�Z5dj�Z6dk�Z7dl�Z8dm�Z9dn�Z:do�Z;dp�Z<e=dqe=drdsdtdu��Z>e=drdvdtdw�Z?dx�Z@RS(�s'Manage a download/build/install processs Find/get/install Python packagessprefix=sinstallation prefixszip-oktzsinstall package as a zipfiles
multi-versiontms%make apps have to require() a versiontupgradetUs1force upgrade (searches PyPI for latest versions)sinstall-dir=tdsinstall package to DIRsscript-dir=RFsinstall scripts to DIRsexclude-scriptstxsDon't install scriptssalways-copytas'Copy all needed packages to install dirs
index-url=tis base URL of Python Package Indexsfind-links=tfs(additional URL(s) to search for packagessdelete-conflictingtDs no longer needed; don't use thissignore-conflicts-at-my-risksbuild-directory=tbs/download/extract/build in DIR; keep the resultss	optimize=tOslalso compile with optimization: -O1 for "python -O", -O2 for "python -OO", and -O0 to disable [default: -O0]srecord=s3filename in which to record list of installed filessalways-unziptZs*don't install as a zipfile, no matter whats
site-dirs=tSs)list of directories where .pth files workteditabletes+Install specified packages in editable formsno-depstNsdon't install dependenciessallow-hosts=tHs$pattern(s) that hostnames must matchslocal-snapshots-oktls(allow building eggs from local checkoutstversions"print version information and exits
no-find-linkss9Don't load find-links defined in packages being installedtusers!install in user site-package '%s'cCs�tr0tjjt�}|jtj�|_n	d|_d|_
|_d|_|_
|_d|_d|_d|_d|_d|_|_d|_|_|_d|_|_|_d|_|_|_d|_d|_d|_ d|_!d|_"d|_#d|_$d|_%d|_&trKtj'|_(tj|_)nd|_(d|_)d|_*d|_+d|_,|_-d|_.d|_/d|_0i|_1t2|_3d|_4|j5j6|_6|j5j7||j5j8d��dS(NiR5(9t
HAS_USER_SITER?R@tabspatht__file__t
startswithtsitet	USER_SITER`tNonetzip_oktlocal_snapshots_oktinstall_dirt
script_dirtexclude_scriptst	index_urlt
find_linkstbuild_directorytargstoptimizetrecordRNtalways_copyt
multi_versionRZtno_depstallow_hoststroottprefixt	no_reportR_tinstall_purelibtinstall_platlibtinstall_headerstinstall_libtinstall_scriptstinstall_datatinstall_basetinstall_platbaset	USER_BASEtinstall_userbasetinstall_usersitet
no_find_linkst
package_indextpth_filetalways_copy_fromtdelete_conflictingtignore_conflicts_at_my_riskt	site_dirstinstalled_projectsRtsitepy_installedt_dry_runtdistributiontverboset_set_command_optionstget_option_dict(tselftwhereami((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytinitialize_options�sP																									cCs�x�|D]�}tjj|�s1tjj|�rtjd|�|js�tjj|�r|tjj|�r|t|�q�tj	|�q�qqWdS(NsDeleting %s(
R?R@RAtislinkRtinfotdry_runtisdirtrmtreetunlink(R�tblockerstfilename((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytdelete_blockers�s
$	%
c
	Cs�|jr(dtd�jGHtj�ntjj�d}tdd�\}}i|jj�d6|jj�d6|jj	�d6|d	6|dd
!d6|d|dd
6|d6|d6|d6|d6t
tdd�d6|_tr	|j
|jd<|j|jd<n|jr�tr�|j�|j
dkr@td��n|j
|_|_tjdkrr|jd�q�|jtjd�n|j�|j�|jdddd�|jdkr�|j|_n|jdkr�t|_n|jdd,�|jdd-�|jr9|j r9|j |_|j!|_n|jdd.�t"t#tj$�}t%�|_&|j'dk	r!g|j'jd �D]}tj$j(|j)��^q�}xq|D]f}tj$j*|�s�t+j,d!|�q�t#|�|krt-|d"��q�|j&j.t#|��q�Wn|j/s7|j0�n|j1pCd#|_1|j&|_2xE|jt#|j�fD]+}||j2kro|j2j3d|�qoqoW|j4dk	r�g|j4jd �D]}|j)�^q�}	n	d$g}	|j5dkr|j6|j1d%|j2d&|	�|_5nt7|j2tj$�|_8|j9dk	rlt:|j9t;�ru|j9j�|_9qun	g|_9|j<r�|j5j=|j2tj$�n|js�|j5j>|j9�n|jdd/�t:|j?t@�s=y>t@|j?�|_?d|j?kodknstA�nWq=tAk
r9t-d(��q=Xn|jBr^|jCr^t-d)��n|j/r�|jDr�tEd*��n|jFs�tEd+��ng|_GdS(0Ns
setuptools %st
setuptoolsiRxtexec_prefixt	dist_nametdist_versiont
dist_fullnamet
py_versionitpy_version_shortitpy_version_nodott
sys_prefixtsys_exec_prefixtabiflagsttuserbasetusersites$User base directory is not specifiedtposixt	unix_usert_userRjRkRoR�R}R~tinstallRrt,s"%s (in --site-dirs) does not exists$ (in --site-dirs) is not on sys.pathshttps://pypi.python.org/simplet*tsearch_paththostsRqs--optimize must be 0, 1, or 2sVCan't use both --delete-conflicting and --ignore-conflicts-at-my-risk at the same times9Must specify a build directory (-b) when using --editables:No urls, filenames, or requirements specified (see --help)(sinstall_dirsinstall_dir(sinstall_dirs
script_dir(srecordsrecord(soptimizesoptimize(HR_R(tsystexittsplitRR�tget_nametget_versiontget_fullnametgetattrtconfig_varsRaR�R�R`tcreate_home_pathRgRR�R�R?tnamet
select_schemetexpand_basedirstexpand_dirst_expandRkRjR�Rtset_undefined_optionsRzR~tmapR%R@t
get_site_dirst
all_site_dirsR�t
expandusertstripR�RtwarnRtappendRZtcheck_site_dirRmtshadow_pathtinsertRvR�tcreate_indexR*tlocal_indexRnt
isinstanceR!Ritscan_egg_linkstadd_find_linksRqtintt
ValueErrorR�R�RoRRptoutputs(
R�R�RxR�RBRFR�RPt	path_itemR�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytfinalize_options�s�	



		7
	

.	!			

	cCs�x�|D]y}t||�}|dk	rtjdksFtjdkr[tjj|�}nt||j�}t|||�qqWdS(NR�tnt(	R�RgR?R�R@R�RR�tsetattr(R�tattrstattrtval((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt
_expand_attrscs
cCs|jdddg�dS(sNCalls `os.path.expanduser` on install_base, install_platbase and
        root.R�R�RwN(R�(R�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR�lscCs#|jddddddg�dS(s+Calls `os.path.expanduser` on install dirs.RzR{R}R|R~RN(R�(R�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR�qscCs|j|jjkr(tj|j�nz�x%|jD]}|j||j�q5W|jr�|j}|j	r�t
|j	�}x/tt
|��D]}|||||<q�Wnddlm
}|j|j|j|fd|j�n|j�Wdtj|jj�XdS(Ni����(t	file_utils'writing list of installed files to '%s'(R�R�Rt
set_verbosityRpR5RuRrR�RwtlenR t	distutilsR�texecutet
write_filetwarn_deprecated_options(R�tspecR�troot_lentcounterR�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytrunws$			cCsFytj�}Wntjdt�}nXtjj|jd|�S(s�Return a pseudo-tempname base in the install directory.
        This code is intentionally naive; if a malicious party can write to
        the target directory you're already in deep doodoo.
        istest-easy-install-%s(R?tgetpidtrandomtrandintRR@tjoinRj(R�tpid((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytpseudo_tempname�s
cCs&|js|jr"tjd�ndS(NswNote: The -D, --delete-conflicting and --ignore-conflicts-at-my-risk no longer have any purpose and should not be used.(R�R�RR�(R�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR��scCs�t|j�}tjj|d�}||jk}|rS|jrS|j�}n�|j�d}tjj	|�}y:|r�tj
|�nt|d�j�tj
|�Wn!t
tfk
r�|j�nX|r�|jr�t|j���n|r)|jdkr2t||j�|_q2n	d|_tjjdd�jtj�}|ttg|D]}|rc|^qc�kr�t|_n1|jr�tjj	|�r�t|_d|_n||_dS(s;Verify that self.install_dir is .pth-capable dir, if neededseasy-install.pths.write-testtwt
PYTHONPATHR�N(R%RjR?R@R�R�Rttcheck_pth_processingR�RAR�topentclosetOSErrortIOErrortcant_write_to_targetRtno_default_version_msgR�RgR6tenvirontgetR�tpathsepR�R
R�(R�tinstdirR�tis_site_dirttestfilettest_existsR�t_f((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR��s6	!.	cCsYdtj�d|jf}tjj|j�s?|d7}n
|d7}t|��dS(Nscan't create or remove files in install directory

The following error occurred while trying to add or remove files in the
installation directory:

    %s

The installation directory you specified (via --install-dir, --prefix, or
the distutils default setting) was:

    %s
is�
This directory does not currently exist.  Please create it and try again, or
choose a different installation directory (using the -d or --install-dir
option).
sK
Perhaps your account does not have write access to this directory?  If the
installation directory is a system-owned directory, you may need to sign in
as the administrator or "root" account.  If you do not have administrative
access to this machine, you may wish to choose a different installation
directory, preferably one that is listed in your PYTHONPATH environment
variable.

For information on other options, you may wish to consult the
documentation at:

  https://pythonhosted.org/setuptools/easy_install.html

Please make the appropriate changes for your system and try again.
(R�texc_infoRjR?R@RAR(R�tmsg((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR��s
cCs-|j}tjd|�|j�d}|d}tjj|�}y]|r^tj|�ntjj|�}tjj|�s�tj	|�nt
|d�}Wn!ttfk
r�|j
�nHXz�|jd|f�|j�d}tj}tjdkrbtjj|�\}}tjj|d�}	|j�dkrbtjj|	�rb|	}qbnd	d
lm}
|
|ddd
gd�tjj|�r�tjd|�tSWd|r�|j�ntjj|�r�tj|�ntjj|�rtj|�nX|js)tjd|�ntS(s@Empirically verify whether .pth files are supported in inst. dirs Checking .pth file support in %ss.pths.okR�s7import os; f = open(%r, 'w'); f.write('OK'); f.close()
R�spythonw.exes
python.exei����(tspawns-Es-ctpassis-TEST PASSED: %s appears to support .pth filesNs+TEST FAILED: %s does NOT support .pth files(RjRR�R�R?R@RAR�tdirnametmakedirsR�R�R�R�twriteR�RgR�t
executableR�R�R�tlowertdistutils.spawnRR
RtR�R(R�R�R�tok_filet	ok_existsRRTRtbasenametaltR((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR��sP	

	$
	cCs�|jro|jd�roxS|jd�D]?}|jd|�rHq)n|j|||jd|��q)Wn|j|�dS(s=Write all the scripts for `dist`, unless scripts are excludedtscriptssscripts/N(Rltmetadata_isdirtmetadata_listdirtinstall_scripttget_metadatatinstall_wrapper_scripts(R�tdisttscript_name((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytinstall_egg_scriptsscCs|tjj|�rhxctj|�D]?\}}}x-|D]%}|jjtjj||��q8Wq"Wn|jj|�dS(N(R?R@R�twalkR�R�R�(R�R@tbasetdirstfilesR�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt
add_output-s

*cCs#|jrtd|f��ndS(NsjInvalid argument %r: you can't use filenames or URLs with --editable (except via the --find-links option).(RZR(R�R�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytnot_editable5s	cCsW|js
dStjjtjj|j|j��rStd|j|jf��ndS(Ns2%r already exists in %s; can't do a checkout there(RZR?R@RAR�RotkeyR(R�R�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytcheck_editable=s	'cCs�tjdd�}d}|js.|j�nzYt|t�s�t|�r�|j|�|j	j
||�}|jd|||t�St
jj|�r�|j|�|jd|||t�St|�}n|j|�|j	j|||j|j|j|j�}|dkrDd|}|jr5|d7}nt|��nB|jtkrm|j|||d�|S|j||j||�SWdt
jj|�r�t|�nXdS(NRxs
easy_install-s+Could not find suitable distribution for %rs2 (--always-copy skips system and development eggs)tUsing(ttempfiletmkdtempRgRZtinstall_site_pyR�R+RRR�tdownloadtinstall_itemR
R?R@RAtparse_requirement_argRtfetch_distributionRNRsR�Rt
precedenceR2tprocess_distributiontlocationR�(R�R�tdepsttmpdirR#RR((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR5Ls:	



	
	
cCs�|p|j}|p*tjj|�|k}|p@|jd�}|p||jdk	o|tjjt|��t|j�k}|r�|r�x4|j|j	D]}|j
|kr�Pq�q�Wt}ntj
dtjj|��|r!|j|||�}xY|D]}|j|||�qWn5|j|j|��g}|j||d|d�|dk	r�x!|D]}||kri|SqiWndS(Ns.eggs
Processing %siR(RsR?R@RtendswithR�RgR%R�tproject_nameR)R
RR�Rtinstall_eggsR(tcheck_conflictstegg_distribution(R�R�R#R+R*tinstall_neededRtdists((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR$us.
	

cCsUt|}xDtD]<}d|}t||�dkrt||||�qqWdS(s=Sets the install directories by applying the install schemes.tinstall_N(RRR�RgR�(R�R�tschemeRtattrname((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR��s



c
Gs4|j|�|jj|�|jj|�|j|�||j|j<tj|j	|||��|j
d�r�|jr�|jj|j
d��n|r�|jr�dS|dk	r�|j|jkr�tjd|�dS|dks�||kr0|j�}|p|}t|j|j|j�}ntjd|�y(tg�j|g|j|j�}Wngtk
r�tj�d}td|j��n4tk
r�tj�d}td|j��nX|js�|jr x9|D].}|j|jkr�|j|j��q�q�Wntjd|�dS(Nsdependency_links.txtsSkipping dependencies for %ssProcessing dependencies for %sis'Could not find required distribution %ss7Installed distribution %s conflicts with requirement %ss'Finished processing dependencies for %s( t
update_pthR�taddR�RR�RRR�tinstallation_reportthas_metadataR�R�tget_metadata_linesRsRgR�tas_requirementR+R-tspecstextrasR/tresolveR5R0R�RRRpR1R�(R�trequirementRR*R�tdistreqtdistrosR[((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR(�sL


	


cCsA|jdk	r|jS|jd�r*tS|jd�s=tStS(Nsnot-zip-safeszip-safe(RhRgR9R
R(R�R((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytshould_unzip�scCstjj|j|j�}tjj|�rMtjd|j|j|�|Stjj|�rh|}n�tjj	|�|kr�tj
|�ntj|�}t|�dkr�tjj||d�}tjj|�r�|}q�nt
|�tj||�|S(Ns<%r already exists in %s; build directory %s will not be keptii(R?R@R�RoRRARR�R�RR�tlistdirR�R'tshutiltmove(R�R�t
dist_filenamet
setup_basetdsttcontents((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt
maybe_move�s$	
cCs4|js0x$t|�D]}|j|�qWndS(N(Rltget_script_argstwrite_script(R�RRp((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR�s	cs�t|j��}t||�}�fd�}|rwd�|rW�jdd��nt|�|��t�}n|j|t|�d�dS(s/Generate a legacy script wrapper and install itcs4td��}|jd�}|jdd�}|S(sm
            There are a couple of template scripts in the package. This
            function loads one of them and prepares it for use.

            These templates use triple-quotes to escape variable
            substitutions so the scripts get the 2to3 treatment when build
            on Python 3. The templates cannot use triple-quotes naturally.
            R�sutf-8s"""R�(R&tdecodetreplace(R�t	raw_bytesttemplate_strtclean_template(t
template_name(sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytget_templates	sscript template.pys.pys	 (dev).pyRVN(tstrR;tis_python_scriptRNtget_script_headertlocalsRLRG(R�RRtscript_texttdev_pathR�t	is_scriptRS((RRsC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR�s	ttc	Cs�|jg|D]}tjj|j|�^q
�tjd||j�tjj|j|�}|j|�t�}|j	s�t
|�t|d|�}|j|�|j
�t|d|�ndS(s1Write an executable file to the scripts directorysInstalling %s script to %sR�i�N(R�R?R@R�RkRR�Rt
current_umaskR�R'R�RR�tchmod(	R�RRItmodeR�RQttargettmaskRT((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRLs,
		


cCs�|j�jd�r(|j||�gS|j�jd�rP|j||�gS|}tjj|�r�|jd�r�t|||j�n'tjj	|�r�tjj
|�}n|j|�r�|jr�|dk	r�|j|||�}ntjj|d�}tjj|�s�ttjj|dd��}|s[tdtjj
|���nt|�dkr�tdtjj
|���n|d	}n|jr�tj|j||��gS|j||�SdS(
Ns.eggs.exes.pyssetup.pyR�s"Couldn't find a setup script in %sisMultiple setup scripts in %si(RR,tinstall_eggtinstall_exeR?R@tisfileRtunpack_progressR�RbRdRoRgRJR�RARRR�RZRR�treport_editabletbuild_and_install(R�R�RFR+RGtsetup_scripttsetups((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR.*s4"
	cCs[tjj|�r3t|tjj|d��}nttj|��}tj	|d|�S(NsEGG-INFOtmetadata(
R?R@R�R-R�R.t	zipimporttzipimporterR,t
from_filename(R�tegg_pathRi((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR0Ss!cCs�tjj|jtjj|��}tjj|�}|jsLt|�n|j|�}|j	|�t
||�s�tjj|�r�tjj|�r�t
j|d|j�n2tjj|�r�|jtj|fd|�nt|�tjj|�r8|j|�r%tjd}}q�tjd}}na|j|�rg|j|�|jd}}n2|j|�r�tjd}}ntjd}}|j|||f|dtjj|�tjj|�f�n|j|�|j|�S(NR�s	Removing tMovingtCopyingt
Extractings	 %s to %s(R?R@R�RjRRbR�R'R0R/R4R�R�Rtremove_treeRAR�R�tuncache_zipdirRdRDREtcopytreeRBtmkpathtunpack_and_compiletcopy2RR(R�RmR+tdestinationRRTRM((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRaZs6$	

% 

)
cCs�t|�}|dkr+td|��ntdd|jdd�d|jdd�dt��}tjj||j	�d�}|_
|d}tjj|d	�}tjj|d
�}t|�t||�|_
|j||�tjj|�s}t|d�}	|	jd�xU|jd�D]D\}
}|
d
kr(|	jd|
jdd�j�|f�q(q(W|	j�ntjj|d�}|jgt|�D]}
tjj||
d�^q��tj||d|jd|j�|j||�S(Ns(%s is not a valid distutils Windows .exeR-RiR�R_tplatforms.eggs.tmpsEGG-INFOsPKG-INFOR�sMetadata-Version: 1.0
ttarget_versions%s: %s
t_t-RiR�R�(R7RgRR,R�RR?R@R�tegg_nameR)R'R-t	_providert
exe_to_eggRAR�RtitemsRNttitleR�R�RKRtmake_zipfileR�R�Ra(R�RFR+tcfgRRmtegg_tmpRtpkg_infRTtktvRkRp((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRb|s6	&


0
3cs�t|��g�g�i������fd�}t|�|�g}x��D]�}|j�jd�rV|jd�}|d}tj|d�d|d<tjj	�|�}�j
|�|j
|�tj||�qVqVW|j��tj
tjj	�d�tj�|��x�d
D]�}	t�|	r*tjj	�d|	d	�}
tjj|
�s�t|
d
�}|jdj	t�|	�d�|j�q�q*q*WdS(s;Extract a bdist_wininst to the directories an egg would usecsL|j�}x�D]\}}|j|�r||t|�}|jd�}tjj�|�}|j�}|jd�s�|jd�r�tj	|d�|d<d�tjj
|d�d<�j|�nI|jd�r|dkrd�tjj
|d�d<�j|�n|SqW|jd	�sHtj
d
|�ndS(Nt/s.pyds.dlli����iis.pysSCRIPTS/s.pthsWARNING: can't process %s(RRdR�R�R?R@R�R,Rtstrip_moduletsplitextR�RR�Rg(tsrcRHRFtoldtnewtpartstdl(R�tnative_libstprefixest
to_compilet	top_level(sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytprocess�s$s.pydR�i����s.pysEGG-INFOR�R�s.txtR�s
N(s	top_levelsnative_libs(R9RRR,R�RR�R?R@R�R�t
write_stubtbyte_compiletwrite_safety_flagtanalyze_eggRWRAR�RR�(R�RFR�R�tstubstresR�tresourcetpyfileR�ttxtRT((R�R�R�R�R�sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR~�s4






!cCs�|Sddlm}m}ddlm}g}tj|jd��}idd6dd6}x$|�D]\}}	}
d||<qfWxt|jg|j	�D]�\}}x�|D]�}
t
jj|
�\}}||kr�|sHy|||g�\}}
}Wnt
k
rq�qX|r)|j�n|
|kr|j|
�qq�||kr�|dkr�|jt
jj||
��q�q�q�Wq�W|r�|j||�n|S(	s9Verify that there are no conflicting "old-style" packagesi����(tfind_moduletget_suffixes(Rs
top_level.txtis.pycs.pyoRe(timpR�R�Rtdicttfromkeyst
_get_metadatatexpand_pathsRjR�R?R@R�tImportErrorR�R�R�tfound_conflicts(R�RR�R�RR�tnamestextstextR^ttypR@RR�RRTtdescr((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR/�s4&


*cCs�|jr#tjd�|j|�Sddj|�}|jrS|d|j7}n
|d7}|d7}tjj	|�tjj
�|js�td��ndS(Ns*Attempting to delete conflicting packages:s�-------------------------------------------------------------------------
CONFLICT WARNING:

The following modules or packages have the same names as modules or
packages being installed, and will be *before* the installed packages in
Python's search path.  You MUST remove all of the relevant files and
directories before you will be able to use the package(s) you are
installing:

   %s

s
   s�(Note: you can run EasyInstall on '%s' with the
--delete-conflicting option to attempt deletion of the above files
and/or directories.)
sLNote: you can attempt this installation again with EasyInstall, and use
either the --delete-conflicting (-D) option or the
--ignore-conflicts-at-my-risk option, to either delete the above files
and directories, or to ignore the conflicts, respectively.  Note that if
you ignore the conflicts, the installed package(s) may not work.
sJ-------------------------------------------------------------------------
s%Installation aborted due to conflicts(R�RR�R�R�R�R-R�tstderrRtflushR(R�RR�R((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR��s	

	
	t	Installedc	Cszd}|jrN|jrN|d7}|jtttj�krN|d7}qNn|j}|j}|j	}d}|t
�S(s9Helpful installation message for display to package userss
%(what)s %(eggloc)s%(extras)ss�

Because this distribution was installed --multi-version, before you can
import modules from this package in an application, you will need to
'import pkg_resources' and then use a 'require()' call similar to one of
these examples, in order to select the desired version:

    pkg_resources.require("%(name)s")  # latest installed version
    pkg_resources.require("%(name)s==%(version)s")  # this exact version
    pkg_resources.require("%(name)s>=%(version)s")  # this version or higher
s�

Note also that the installation directory must be on sys.path at runtime for
this to work.  (e.g. by being the application's script directory, by being on
PYTHONPATH, or by being added to sys.path by your code.)
R�(RtRyRjR�R%R�R@R)R-R_RW(	R�treqRtwhatRtegglocR�R_R=((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR8"s

			cCs&tjj|�}tj}dt�S(Ns"
Extracted editable version of %(spec)s to %(dirname)s

If it uses setuptools in its setup script, you can activate it in
"development" mode by going to that directory and running::

    %(python)s setup.py develop

See the setuptools documentation for the "develop" command for more info.
(R?R@RR�RRW(R�R�RgRtpython((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRe>s		cCs$tjjdt�tjjdt�t|�}|jdkrid|jd}|jdd|�n"|jdkr�|jdd�n|jr�|jdd	�nt	j
d
|t|�ddj|��yt
||�Wn;tk
rtj�d}td|jdf��nXdS(
Nsdistutils.command.bdist_eggsdistutils.command.egg_infoiR�iiR{s-qs-ns
Running %s %st sSetup script exited with %s(R�tmodulest
setdefaultRRtlistR�R�R�RR�R�R�Rt
SystemExitRRRp(R�RgRGRpR�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRKs"	$
c	Csddg}tjdddtjj|��}z�|jtjj|��|j|�|j|||�t|g�}g}x?|D]7}x.||D]"}|j|j	|j
|��q�Wq�W|r�|jr�tj
d|�n|SWdt|�tj|j�XdS(NRs
--dist-dirRxs
egg-dist-tmp-tdirs+No eggs found in %s (setup script problem?)(R R!R?R@Rt_set_fetcher_optionsR�RR*RaR)R�RR�R�R�R�(	R�RgRGRptdist_dirtall_eggsteggsRR((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRf`s$	

$	

c	Cs�|jjd�j�}d}i}xF|j�D]8\}}||krOq1n|d||jdd	�<q1Wtd|�}tjj|d
�}t	j
||�dS(
s
        When easy_install is about to run bdist_egg on a source dist, that
        source dist might have 'setup_requires' directives, requiring
        additional fetching. Ensure the fetcher options given to easy_install
        are available to that command as well.
        R5RnR�RmRqRviRzR{s	setup.cfgN(s
find_linkss	site_dirss	index_urlsoptimizes	site_dirssallow_hosts(R�R�tcopyRRNR�R?R@R�Rtedit_config(	R�Rtei_optstfetch_directivest
fetch_optionsRR�tsettingstcfg_filename((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR�xs	cCs�|jdkrdSx~|j|jD]l}|jsE|j|jkr$tjd|�|jj|�|j|jkr�|jj|j�q�q$q$W|js|j|jj	kr�tjd|�qtjd|�|jj
|�|j|jkr|jj|j�qn|js�|jj
�|jdkr�tjj|jd�}tjj|�rotj|�nt|d�}|j|jj|j�d�|j�q�ndS(Ns&Removing %s from easy-install.pth files4%s is already the active version in easy-install.pths"Adding %s to easy-install.pth fileR�ssetuptools.pthtwts
(R�RgRRtR)RR�tremoveR�tpathsR7R�R�tsaveR?R@R�RjR�R�R�Rt
make_relativeR�(R�RRPR�RT((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR6�s4	
	
 cCstjd||�|S(NsUnpacking %s to %s(Rtdebug(R�R�RH((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRd�scs�g�g����fd�}t|||��j���js�x<�D]1}tj|�tjdBd@}t||�qNWndS(Ncs�|jd�r/|jd�r/�j|�n.|jd�sM|jd�r]�j|�n�j||��jr}|p�dS(Ns.pys	EGG-INFO/s.dlls.so(R,RdR�RdR�Rg(R�RH(R�tto_chmodR�(sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytpf�simi�(RR�R�R?tstattST_MODER](R�RmRwR�RTR^((R�R�R�sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRu�s
	
cCs�tr|jd�dSddlm}zetj|jd�||ddddd|j�|jr�||d|jddd|j�nWdtj|j�XdS(	Ns%byte-compiling is disabled, skipping.i����(R�iRqitforceR�(	RR�tdistutils.utilR�RR�R�R�Rq(R�R�R�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR��s
	cCs d|jtjjdd�fS(Ns�bad install directory or PYTHONPATH

You are attempting to install a package to a directory that is not
on PYTHONPATH and which Python does not read ".pth" files from.  The
installation directory you specified (via --install-dir, --prefix, or
the distutils default setting) was:

    %s

and your PYTHONPATH environment variable currently contains:

    %r

Here are some of your options for correcting the problem:

* You can choose a different installation directory, i.e., one that is
  on PYTHONPATH or supports .pth files

* You can add the installation directory to the PYTHONPATH environment
  variable.  (It must then also be on PYTHONPATH whenever you run
  Python and want to use the package(s) you are installing.)

* You can set up the installation directory to support ".pth" files by
  using one of the approaches described here:

  https://pythonhosted.org/setuptools/easy_install.html#custom-installation-locations

Please make the appropriate changes for your system and try again.R�R�(RjR?R�R�(R�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR��scCs?|jr
dStjj|jd�}tdd�}d}tjj|�r�tjd|j�t	|d�}|j
�}tjd
kr�|j
�}n|j�|jd	�s�td
|��q�n||kr2tjd|�|jst|�t	|d�}|j|�|j�n|j|g�nt|_dS(s8Make sure there's a site.py in the target dir, if neededNssite.pyR�s
site-patch.pyR�sChecking existing site.py in %strbis
def __boot():s;%s is not a setuptools-generated site.py; please remove it.sCreating %stwb(i(R�R?R@R�RjR&RARR�R�treadR�tversion_infoRMR�RdRR�R�R'RR�R
(R�tsitepytsourcetcurrentRT((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR"s2	
	


cCs�|js
dSttjjd��}xct|j�D]R\}}|j|�r5tjj|�r5|j	d|�tj
|d�q5q5WdS(sCreate directories under ~.Nt~sos.makedirs('%s', 0700)i�(R`RR?R@R�RR�RdR�tdebug_printR(R�thomeR�R@((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR�6s	"R�Rjs/$base/lib/python$py_version_short/site-packagesRks	$base/bins$base/Lib/site-packagess
$base/ScriptscGs |jd�j}|jr�|j�}|j|d<|jjtj|j�}xH|j	�D]7\}}t
||d�dkr\t|||�q\q\Wnddl
m}xo|D]g}t
||�}|dk	r�|||�}tjdkrtjj|�}nt|||�q�q�WdS(NR�Ri����(RR�(tget_finalized_commandR�RxR�RR�R?R�tDEFAULT_SCHEMERR�RgR�R�RR@R�(R�R�R�R4R�R�R((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR�Rs 	

N(sprefix=Nsinstallation prefix(szip-okRLsinstall package as a zipfile(s
multi-versionRMs%make apps have to require() a version(supgradeROs1force upgrade (searches PyPI for latest versions)(sinstall-dir=RPsinstall package to DIR(sscript-dir=RFsinstall scripts to DIR(sexclude-scriptsRQsDon't install scripts(salways-copyRRs'Copy all needed packages to install dir(s
index-url=RSs base URL of Python Package Index(sfind-links=RTs(additional URL(s) to search for packages(sdelete-conflictingRUs no longer needed; don't use this(signore-conflicts-at-my-riskNs no longer needed; don't use this(sbuild-directory=RVs/download/extract/build in DIR; keep the results(s	optimize=RWslalso compile with optimization: -O1 for "python -O", -O2 for "python -OO", and -O0 to disable [default: -O0](srecord=Ns3filename in which to record list of installed files(salways-unzipRXs*don't install as a zipfile, no matter what(s
site-dirs=RYs)list of directories where .pth files work(seditableR[s+Install specified packages in editable form(sno-depsR\sdon't install dependencies(sallow-hosts=R]s$pattern(s) that hostnames must match(slocal-snapshots-okR^s(allow building eggs from local checkouts(sversionNs"print version information and exit(s
no-find-linksNs9Don't load find-links defined in packages being installed((At__name__t
__module__t__doc__tdescriptionR
tcommand_consumes_argumentsRgtuser_optionstboolean_optionsRaR�ReRftnegative_optRR�R�R�R�R�R�R�R�R�R�R�R�R�RRRRRR5R$R�R(RBRJRRRLR.R0RaRbR~R/R�R8ReRRfR�R6RdRuR�R�R"R�R�RR�R�(((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR5ks�		
	5	
	�								*	)	,				)&	/					)		"	)	1	#	)	
				$				)	'		cCsgtjjdd�jtj�D]}|r"|^q"}tjg}tjtjkrk|jtj�nx,|D]$}|rrtj	dkr�|jtj
j|dd��n|tjdkr|j
tj
j|dd	tjd
 d�tj
j|dd�g�n%|j
|tj
j|dd�g�tj	dkr�d
|kr�tjjd�}|r�|jtj
j|ddtjd
 d��q�q�q�qrqrWx6t�t�fD]"}||kr�|j|�q�q�Wtr�|jtj�nttt|��}|S(NR�R�tos2emxtriscostLibs
site-packagesR�tlibR�issite-pythontdarwinsPython.frameworktHOMEtLibrarytPython(sos2emxsriscos(R?R�R�R�R�R�RxR�R�RxR@R�tseptextendR_RR	RaReRfR�R�R%(R�tsitedirsR�RxR�tsite_lib((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR�osD+
"
ccs^i}xQ|D]I}t|�}||kr1q
nd||<tjj|�sSq
ntj|�}||fVx�|D]�}|jd�s�qtn|dkr�qtnttjj||��}tt	|��}|j
�xw|D]o}|jd�s�t|j��}||krNd||<tjj|�s4q�n|tj|�fVqNq�q�WqtWq
WdS(sBYield sys.path directories that might contain "old-style" packagesis.pthseasy-install.pthssetuptools.pthtimportN(seasy-install.pthssetuptools.pth(
R%R?R@R�RCR,R�R�R�R$R�Rdtrstrip(tinputstseenRRR�RTtlinestline((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR��s4





cCs�t|d�}z�tj|�}|dkr1dS|d|d|d}|dkr[dS|j|d�ddlm}m}ddl}|j	d	|j
d��\}}}	|dkr�dS|j|d|�|jidd
6dd6�}
yx|j
|�}tj
dkr'tdg�}ntd�}|j|d�d}
|
jd�}
|
j||
��Wn|jk
r�dSX|
jd�s�|
jd�r�dS|
SWd|j�XdS(snExtract configuration data from a bdist_wininst .exe

    Returns a ConfigParser.RawConfigParser, or None
    R�i	iiii����(tStringIOtConfigParserNs<iiiizV4i{V4R�R_RyiiiRHRitSetup(izV4i{V4(ii(R�tzipfilet_EndRecDataRgtseektsetuptools.compatR�R�R;tunpackR�tRawConfigParserR�R�tbytestchrR�RMtreadfptErrorthas_sectionR�(RFRTtendrect	prependedR�R�R;ttagtcfglentbmlenR�tpartt	null_bytetconfig((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR7�s<$ c
Cs�dddddg}tj|�}zwxp|j�D]b}|j}|jd�}t|�d	kr�|d
dkr�|djd
�r�|jddj|d
 �df�Pq�nt|�d
ks4|jd�r�q4n|jd�r�q4n|dj	�dkr4|j
|�}tjdkr1|j
�}nxbt|�D]Q}|j�jdd�}|jd�s>|jd|d|fdf�q>q>Wq4q4WWd|j�Xg|D]\}}	|j�|	f^q�}|j�|j�|S(s4Get exe->egg path translations for a given .exe filesPURELIB/R�sPLATLIB/pywin32_system32sPLATLIB/sSCRIPTS/sEGG-INFO/scripts/sDATA/lib/site-packagesR�iisPKG-INFOis	.egg-infois	EGG-INFO/s.pths
-nspkg.pthtPURELIBtPLATLIBs\R�s%s/%s/N(sPURELIB/R�(sPLATLIB/pywin32_system32R�(sPLATLIB/R�(sSCRIPTS/sEGG-INFO/scripts/(sDATA/lib/site-packagesR�(RR(i(R�tZipFiletinfolistR�R�R�R,R�R�tupperR�R�R�RMR$R�RNRdR�R�Rtsorttreverse(
texe_filenameR�RLR�R�R�RItpthRQty((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR9�s<		"#"3+

cCs<ytj|�SWn$tk
r7td|f��nXdS(Ns1Not a URL, existing file, or requirement spec: %r(R+tparseR�R(R�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR% s

cBsMeZdZeZdd�Zd�Zd�Zd�Zd�Z	d�Z
RS(s)A .pth file with Distribution paths in itcCs�||_ttt|��|_ttjj|j��|_|j	�t
j|gdd�x6t
|j�D]%}tt|jt|t���qoWdS(N(R�R�R�R%R�R?R@Rtbasedirt_loadR*t__init__RgR$R�R7R)R
(R�R�R�R@((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR-s	
cCs�g|_t}tj|j�}tjj|j�r3t	|jd�}x�|D]�}|j
d�rpt}qOn|j�}|jj
|�|j�sO|j�j
d�r�qOnttjj|j|��}|jd<tjj|�s�||kr|jj�t|_qOnd||<qOW|j�n|jrO|rOt|_nx.|jr|jdj�r|jj�qRWdS(NtrtR�t#i����i(R�RR�R�R�R?R@RcR�R�RdR
R�R�R�R%R�RRAtpoptdirtyR�(R�t
saw_importR�RTR�R@((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR5s2	
"&
	
 cCs�|js
dSdjt|j|j��}|r�tjd|j�d|}tj	j
|j�rvtj|j�nt|jd�}|j
|�|j�n;tj	j|j�r�tjd|j�tj|j�nt|_dS(s$Write changed .pth file back to diskNs
s	Saving %ss�import sys; sys.__plen = len(sys.path)
%s
import sys; new=sys.path[sys.__plen:]; del sys.path[sys.__plen:]; p=getattr(sys,'__egginsert',0); sys.path[p:p]=new; sys.__egginsert = p+len(new)
R�sDeleting empty %s(RR�R�R�R�RR�R�R?R@R�R�R�RR�RAR(R�tdataRT((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR�Ts 	

cCsl|j|jkrX|j|jks9|jtj�krX|jj|j�t|_ntj	||�dS(s"Add `dist` to the distribution mapN(
R)R�R�R?tgetcwdR�R
RR*R7(R�R((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR7pscCsIx2|j|jkr4|jj|j�t|_qWtj||�dS(s'Remove `dist` from the distribution mapN(R)R�R�R
RR*(R�R((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR�zs
cCs�tjjt|��\}}t|j�}|g}tjdkrKdpQtj}xut|�|kr�||jkr�|jtj	�|j
�|j|�Stjj|�\}}|j|�qWW|SdS(NR�(R?R@R�R%R�RtaltsepR�R�tcurdirRR�(R�R@tnpathtlasttbaselenR�R�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR��s	

((R�R�R�RRRRR�R7R�R�(((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR6(s			
	cCs)ddlm}t|jt�s=tj|jj��}n|dj�d}|j	|�}d}|r�|j
d�p~d}|r�d|}q�n|r�d}nt|�}d	t�}t
|�s	|r|j�jd
�rd|j�d}qq	d}nt||�}d	t�}|S(s;Create a #! line, getting options (if any) from script_texti����(t
first_line_res
iR�iR�s
python.exes#!%(executable)s%(options)s
R{s -x(tdistutils.command.build_scriptsR%R�tpatternRTtretcompileRMt
splitlinestmatchtgrouptnt_quote_argRWRJR�Rdtfix_jython_executable(RXRtwininstR%tfirstR+toptionsthdr((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRV�s,	
	
cCsz|tjkr8tjdkr8t|tj�||�Stj�\}}}t||d|dd||ff�dS(NR�iis %s %s(	R?R�R�R]R�tS_IWRITER�RR#(tfunctargtexctettevRz((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt
auto_chmod�s

cCs1ddlm}t||�t|tj�dS(s?Ensure that the importer caches dont have stale info for `path`i����(t_zip_directory_cacheN(RjR:t_uncacheR�tpath_importer_cache(R@tzdc((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRr�s
cCsT||kr||=n:t|�}x+|D]#}t|�|kr)||=dSq)WdS(N(R%(R@tcachetp((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR;�s

s<string>cCs7yt||d�Wnttfk
r.tSXtSdS(s%Is this string a valid Python script?texecN(R)tSyntaxErrort	TypeErrorRR
(ttextR�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt	is_python�s
cCsNy)t|�}|jd�}|j�Wnttfk
rC|SX|dkS(sCDetermine if the specified executable is a .sh (contains a #! line)is#!(R�R�R�R�R�(Rtfptmagic((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytis_sh�scCsg}t}d}d|kp'd|k}|r@|jd�nx�|D]z}|dkrf|d7}qG|dkr�|jd|dd�d}qG|r�|jd|�d}n|j|�qGW|r�|jd|�n|r|jd|�|jd�nd	j|�S(
s@Quote a command line argument according to Windows parsing rulesiR�s	t"s\iis\"R�(RR�R�(R5tresultt	needquotetnbtc((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR-�s,

		cCsb|jd�s|jd�r"tSt||�r5tS|jd�r^d|j�dj�kStS(sMIs this text, as a whole, a Python script? (as opposed to shell/bat/etc.
    s.pys.pyws#!R�i(R,R
RDRdR*RR(RXR�((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRUs(R]cGsdS(N((Rp((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt_chmodscCs_tjd||�yt||�Wn4tjk
rZtj�d}tjd|�nXdS(Nschanging mode of %s to %oischmod failed: %s(RR�RMR?terrorR�R(R@R^R[((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR]scCsntjjd�rjt|�rjddl}|jjjd�dkrI|S|r_tj	d�qjd|Sn|S(Ntjavai����sos.nametLinuxs�WARNING: Unable to adapt shebang line for Jython, the following script is NOT executable
         see http://bugs.jython.org/issue1112 for more information.s/usr/bin/env %s(
R�RxRdRGROtlangtSystemtgetPropertyRR�(RR1RO((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR.sccs�t|j��}td||�}x�dD]{}xr|j|�j�D][\}}dt�}tjdksu|r�|dkr�d}	d}
dg}tj	d	d
|�}n0d}	d}
d
ddg}tj	dd|�}t
jj|dd!j
d��stjdkr|}
n|}
||
|
|dg|D]}||^q6fV|dt|	�dfVt�s�|d}|t|�dfVq�qG|||fVqGWq+WdS(sEYield write_script() argument tuples for a distribution's entrypointsR�tconsole_scriptstgui_scriptss�# EASY-INSTALL-ENTRY-SCRIPT: %(spec)r,%(group)r,%(name)r
__requires__ = %(spec)r
import sys
from pkg_resources import load_entry_point

if __name__ == '__main__':
    sys.exit(
        load_entry_point(%(spec)r, %(group)r, %(name)r)()
    )
twin32tguis-script.pyws.pyws(?i)python.exespythonw.exetclis
-script.pys.pys.pycs.pyos(?i)pythonw.exes
python.exeii����RHR[s.exeRVs
.exe.manifestN(RTRU(RTR;RVt
get_entry_mapRRWR�RxR(tsubR?R@RAR�tget_win_launcherR=tload_launcher_manifest(RRR/R�theaderR,R�tepRXt
launcher_typeR�R�t
new_headerR2RQtm_name((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRK0s4
"

	1	0	
cCstd|}tj�j�dkr7|jdd�}nt�rU|jdd�}n|jdd�}td|�S(s�
    Load the Windows launcher (executable) suitable for launching a script.

    `type` should be either 'cli' or 'gui'

    Returns the executable as a byte string.
    s%s.exetarmt.s-arm.s-64.s-32.R�(RxtmachineRRNR=R&(ttypetlauncher_fn((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR[ds
	cCsHtjtd�}tjddkr0|t�S|jd�t�SdS(Nslauncher manifest.xmliisutf-8(t
pkg_resourcesR&R�R�R�tvarsRM(R�tmanifest((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR\uscCst|rd�}n|dkr*d�}ng}ytj|�}Wn-tjk
rr|tj|tj��nXx�|D]�}tjj||�}ytj|�j	}Wntjk
r�d}nXt
j|�r�t|||�qzytj
|�Wqztjk
r*|tj
|tj��qzXqzWytj|�Wn-tjk
ro|tj|tj��nXdS(s�Recursively delete a directory tree.

    This code is taken from the Python 2.4 version of 'shutil', because
    the 2.3 version doesn't really work right.
    cWsdS(N((Rp((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pytonerror�scWs�dS(N((Rp((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyRj�siN(RgR?RCRNR�RR@R�tlstattst_modeR�tS_ISDIRR�R�trmdir(R@t
ignore_errorsRjR�R�tfullnameR^((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR�|s2

!cCs tjd�}tj|�|S(Ni(R?tumask(ttmp((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR\�s
cCsMddl}tjj|jd�}|tjd<tjj|�t�dS(Ni����i(	R�R?R@Rt__path__R�targvR�R8(R�targv0((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt	bootstrap�s

cs�ddlm�ddlm�ddl�d��fd����fd��d�f��fd��Y��dkr�tjd	�n�����fd
��dS(Ni����(tsetup(R,sLusage: %(script)s [options] requirement_or_url ...
   or: %(script)s --help
cstjj|�}�t�S(N(R?R@RRh(Rtscript(tUSAGE(sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt	gen_usage�scs7�jj}z��j_|�SWd|�j_XdS(N(tcoreRz(RTt
old_gen_usage(R�Rz(sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt
with_ei_usage�s
tDistributionWithoutHelpCommandscs eZdZ��fd�ZRS(R�cs �����fd��dS(Ncs�j����S(N(t
_show_help((R,RptkwR�(sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt<lambda>�s((R�RpR�(R,R}(RpR�R�sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR�s(R�R�tcommon_usageR((R,R}(sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR~�sic	s6�ddddg�dtjdp)dd���S(Ntscript_argss-qR5s-vRit	distclass(R�Rt((R~RtR�Rw(sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR��s(R�Rwtsetuptools.distR,tdistutils.coreRgR�Rt(RtR�((	R,R~RyRtR�RzR�RwR}sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyR8�s(sR�R�R?RjRDR R�R(R�R�RxRRgR�RRtsetuptools.sandboxRR�RRt	sysconfigRRR	RR�tdistutils.sysconfigRR�RRRtdistutils.errorsRRRRtdistutils.command.installRRtsetuptools.commandRtsetuptools.archive_utilRtsetuptools.package_indexRRRRR�RRR R!R"R#R$R%R&R'R(R)R*R+R,R-R.R/R0R1R2R�tsys_executableR@RBRt__all__ReR_tENABLE_USER_SITERaR;R=R4R�RGRJR5R�R�R7R9R%R6RRVR9RrR;RDRGR-RUR]RMR.RKR[R\R�R\RvRgR8(((sC/usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyt<module>s�	

	
".d		
			�����		-	)	6	%	h			
				)	


		4		#		

Zerion Mini Shell 1.0