U
ë˜Re” ã @ sp d dl Z d dlZd dlZd dlZd dlZddlmZ dd„ ZeZ eej
jƒZG dd„ deƒZG dd „ d eƒZ
dS )
é Né )Ú
get_unpatchedc C s4 d} zt | dgd�j W dS tk
r. Y nX dS )z0
Return True if Cython can be imported.
zCython.Distutils.build_extÚ build_ext)ÚfromlistTF)Ú
__import__r Ú Exception)Zcython_impl© r úŠ/builddir/build/BUILDROOT/alt-python38-setuptools-58.3.0-2.el8.x86_64/opt/alt/python38/lib/python3.8/site-packages/setuptools/extension.pyÚ_have_cython
s r
c @ s e Zd ZdZdd„ Zdd„ ZdS )Ú Extensionz7Extension that uses '.c' files in place of '.pyx' filesc O s( | dd¡| _tj| ||f|ž|Ž d S )NÚpy_limited_apiF)Úpopr Ú
_ExtensionÚ__init__)ÚselfÚnameÚsourcesÚargsÚkwr r r r ! s zExtension.__init__c C sN t ƒ r
dS | jpd}| ¡ dkr$dnd}t tjd|¡}tt|| j ƒƒ| _ dS )zÜ
Replace sources with .pyx extensions to sources with the target
language extension. This mechanism allows language authors to supply
pre-converted sources but to prefer the .pyx sources.
NÚ zc++z.cppz.cz.pyx$)
r
ÚlanguageÚlowerÚ functoolsÚpartialÚreÚsubÚlistÚmapr )r ÚlangZ
target_extr r r r Ú_convert_pyx_sources_to_lang' s
z&Extension._convert_pyx_sources_to_langN)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r r r r r r r s r c @ s e Zd ZdZdS )ÚLibraryz=Just like a regular Extension, but built as a library insteadN)r r! r" r# r r r r r$ 6 s r$ )r r Údistutils.coreÚ distutilsÚdistutils.errorsÚdistutils.extensionÚmonkeyr r
Z
have_pyrexÚcorer r r$ r r r r Ú