/snap/core20/2769/usr/lib/python3/dist-packages/setuptools
NameSizeModeActions
command/-0755rm
extern/-0755rm
_vendor/-0755rm
__pycache__/-0755rm
archive_util.py66260644editdlrm
build_meta.py99600644editdlrm
cli-32.exe655360644editdlrm
cli-64.exe747520644editdlrm
cli.exe655360644editdlrm
config.py205750644editdlrm
depends.py55170644editdlrm
dep_util.py9490644editdlrm
dist.py498720644editdlrm
errors.py5240644editdlrm
extension.py17290644editdlrm
glob.py50840644editdlrm
gui-32.exe655360644editdlrm
gui-64.exe752640644editdlrm
gui.exe655360644editdlrm
installer.py53360644editdlrm
launch.py7870644editdlrm
lib2to3_ex.py20130644editdlrm
monkey.py52640644editdlrm
msvc.py468070644editdlrm
namespaces.py32230644editdlrm
package_index.py423940644editdlrm
py27compat.py15040644editdlrm
py31compat.py8380644editdlrm
py33compat.py13300644editdlrm
py34compat.py2450644editdlrm
sandbox.py142840644editdlrm
script (dev).tmpl2180644editdlrm
script.tmpl1380644editdlrm
site-patch.py23460644editdlrm
ssl_support.py85430644editdlrm
unicode_utils.py9960644editdlrm
version.py1440644editdlrm
wheel.py84680644editdlrm
windows_support.py7140644editdlrm
_deprecation_warning.py2180644editdlrm
_imp.py23880644editdlrm
__init__.py72730644editdlrm
Edit: /snap/core20/2769/usr/lib/python3/dist-packages/setuptools/extension.py (1729B)
import re import functools import distutils.core import distutils.errors import distutils.extension from setuptools.extern.six.moves import map from .monkey import get_unpatched def _have_cython(): """ Return True if Cython can be imported. """ cython_impl = 'Cython.Distutils.build_ext' try: # from (cython_impl) import build_ext __import__(cython_impl, fromlist=['build_ext']).build_ext return True except Exception: pass return False # for compatibility have_pyrex = _have_cython _Extension = get_unpatched(distutils.core.Extension) class Extension(_Extension): """Extension that uses '.c' files in place of '.pyx' files""" def __init__(self, name, sources, *args, **kw): # The *args is needed for compatibility as calls may use positional # arguments. py_limited_api may be set only via keyword. self.py_limited_api = kw.pop("py_limited_api", False) _Extension.__init__(self, name, sources, *args, **kw) def _convert_pyx_sources_to_lang(self): """ 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. """ if _have_cython(): # the build has Cython, so allow it to compile the .pyx files return lang = self.language or '' target_ext = '.cpp' if lang.lower() == 'c++' else '.c' sub = functools.partial(re.sub, '.pyx$', target_ext) self.sources = list(map(sub, self.sources)) class Library(Extension): """Just like a regular Extension, but built as a library instead"""