Your IP : 3.15.12.133


Current Path : /opt/alt/python33/lib64/python3.3/distutils/command/__pycache__/
Upload File :
Current File : //opt/alt/python33/lib64/python3.3/distutils/command/__pycache__/build_clib.cpython-33.pyc

�
��fVc@srdZddlZddlmZddlTddlmZddlmZdd�Z	Gd	d
�d
e�Z
dS(u�distutils.command.build_clib

Implements the Distutils 'build_clib' command, to build a C/C++ library
that is included in the module distribution and needed by an extension
module.iN(uCommand(u*(ucustomize_compiler(ulogcCsddlm}|�dS(Ni(ushow_compilers(udistutils.ccompilerushow_compilers(ushow_compilers((uA/opt/alt/python33/lib64/python3.3/distutils/command/build_clib.pyushow_compilerssushow_compilerscBs�|EeZdZdZd"d#d$d%d&gZddgZdd!defgZdd�Z	dd�Z
dd�Zdd�Zdd�Z
dd�Zdd �Zd!S('u
build_clibu/build C/C++ libraries used by Python extensionsubuild-clib=ubu%directory to build C/C++ libraries toubuild-temp=utu,directory to put temporary build by-productsudebugugu"compile with debugging informationuforceufu2forcibly build everything (ignore file timestamps)u	compiler=ucuspecify the compiler typeu
help-compilerulist available compilerscCsUd|_d|_d|_d|_d|_d|_d|_d|_d|_	dS(Ni(
uNoneu
build_clibu
build_tempu	librariesuinclude_dirsudefineuundefudebuguforceucompiler(uself((uA/opt/alt/python33/lib64/python3.3/distutils/command/build_clib.pyuinitialize_options4s								ubuild_clib.initialize_optionscCs�|jdddd	d
d�|jj|_|jrG|j|j�n|jdkrn|jjpeg|_nt|jt�r�|jjt	j
�|_ndS(Nubuildu
build_tempu
build_clibucompilerudebuguforce(u
build_tempu
build_clib(u
build_tempu
build_temp(ucompilerucompiler(udebugudebug(uforceuforce(uset_undefined_optionsudistributionu	librariesucheck_library_listuinclude_dirsuNoneu
isinstanceustrusplituosupathsep(uself((uA/opt/alt/python33/lib64/python3.3/distutils/command/build_clib.pyufinalize_optionsDs		ubuild_clib.finalize_optionscCs�|js
dSddlm}|d|jd|jd|j�|_t|j�|jdk	rv|jj	|j�n|j
dk	r�x-|j
D]\}}|jj||�q�Wn|jdk	r�x$|jD]}|jj
|�q�Wn|j|j�dS(Ni(unew_compilerucompilerudry_runuforce(u	librariesudistutils.ccompilerunew_compilerucompilerudry_runuforceucustomize_compileruinclude_dirsuNoneuset_include_dirsudefineudefine_macrouundefuundefine_macroubuild_libraries(uselfunew_compilerunameuvalueumacro((uA/opt/alt/python33/lib64/python3.3/distutils/command/build_clib.pyurun^s 		
ubuild_clib.runcCs�t|t�std��nx�|D]�}t|t�r\t|�dkr\td��n|\}}t|t�s�td��nd|ks�tjdkr�tj|kr�td|d��nt|t�s%td��q%q%Wd	S(
u`Ensure that the list of libraries is valid.

        `library` is presumably provided as a command option 'libraries'.
        This method checks that it is a list of 2-tuples, where the tuples
        are (library_name, build_info_dict).

        Raise DistutilsSetupError if the structure is invalid anywhere;
        just returns otherwise.
        u+'libraries' option must be a list of tuplesiu*each element of 'libraries' must a 2-tupleuNfirst element of each tuple in 'libraries' must be a string (the library name)u/u;bad library name '%s': may not contain directory separatorsiuMsecond element of each tuple in 'libraries' must be a dictionary (build info)N(	u
isinstanceulistuDistutilsSetupErrorutupleulenustruosusepudict(uselfu	librariesulibunameu
build_info((uA/opt/alt/python33/lib64/python3.3/distutils/command/build_clib.pyucheck_library_listvs"

"*ubuild_clib.check_library_listcCs>|js
dSg}x$|jD]\}}|j|�qW|S(N(u	librariesuNoneuappend(uselfu	lib_namesulib_nameu
build_info((uA/opt/alt/python33/lib64/python3.3/distutils/command/build_clib.pyuget_library_names�s	ubuild_clib.get_library_namescCs�|j|j�g}xh|jD]]\}}|jd�}|dks]t|ttf�rptd|��n|j|�q W|S(Nusourcesufin 'libraries' option (library '%s'), 'sources' must be present and must be a list of source filenames(	ucheck_library_listu	librariesugetuNoneu
isinstanceulistutupleuDistutilsSetupErroruextend(uselfu	filenamesulib_nameu
build_infousources((uA/opt/alt/python33/lib64/python3.3/distutils/command/build_clib.pyuget_source_files�s"
ubuild_clib.get_source_filescCs�x�|D]�\}}|jd�}|dksDt|ttf�rWtd|��nt|�}tjd|�|jd�}|jd�}|jj	|d|j
d|d|d|j�}|jj||d|j
d|j�qWdS(Nusourcesufin 'libraries' option (library '%s'), 'sources' must be present and must be a list of source filenamesubuilding '%s' libraryumacrosuinclude_dirsu
output_dirudebug(ugetuNoneu
isinstanceulistutupleuDistutilsSetupErroruloguinfoucompilerucompileu
build_tempudebugucreate_static_libu
build_clib(uselfu	librariesulib_nameu
build_infousourcesumacrosuinclude_dirsuobjects((uA/opt/alt/python33/lib64/python3.3/distutils/command/build_clib.pyubuild_libraries�s$"
		ubuild_clib.build_librariesN(ubuild-clib=ubu%directory to build C/C++ libraries to(ubuild-temp=utu,directory to put temporary build by-products(udebugugu"compile with debugging information(uforceufu2forcibly build everything (ignore file timestamps)(u	compiler=ucuspecify the compiler type(u__name__u
__module__u__qualname__udescriptionuuser_optionsuboolean_optionsuNoneushow_compilersuhelp_optionsuinitialize_optionsufinalize_optionsurunucheck_library_listuget_library_namesuget_source_filesubuild_libraries(u
__locals__((uA/opt/alt/python33/lib64/python3.3/distutils/command/build_clib.pyu
build_clibs*	$u
build_clib(u__doc__uosudistutils.coreuCommandudistutils.errorsudistutils.sysconfigucustomize_compileru	distutilsulogushow_compilersu
build_clib(((uA/opt/alt/python33/lib64/python3.3/distutils/command/build_clib.pyu<module>s


?>