MCPcopy Index your code
hub / github.com/RustPython/RustPython / get_makefile_filename

Function get_makefile_filename

Lib/sysconfig/__init__.py:326–344  ·  view source on GitHub ↗

Return the path of the Makefile.

()

Source from the content-addressed store, hash-verified

324
325
326def get_makefile_filename():
327 """Return the path of the Makefile."""
328
329 # GH-127429: When cross-compiling, use the Makefile from the target, instead of the host Python.
330 if cross_base := os.environ.get('_PYTHON_PROJECT_BASE'):
331 return os.path.join(cross_base, 'Makefile')
332
333 if _PYTHON_BUILD:
334 return os.path.join(_PROJECT_BASE, "Makefile")
335
336 if hasattr(sys, 'abiflags'):
337 config_dir_name = f'config-{_PY_VERSION_SHORT}{sys.abiflags}'
338 else:
339 config_dir_name = 'config'
340
341 if hasattr(sys.implementation, '_multiarch'):
342 config_dir_name += f'-{sys.implementation._multiarch}'
343
344 return os.path.join(get_path('stdlib'), config_dir_name, 'Makefile')
345
346
347def _import_from_directory(path, name):

Callers 2

_generate_posix_varsFunction · 0.90
_init_config_varsFunction · 0.85

Calls 4

hasattrFunction · 0.85
get_pathFunction · 0.85
getMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected