MCPcopy Create free account
hub / github.com/bitsandbytes-foundation/bitsandbytes / ExtBuildPy

Class ExtBuildPy

setup.py:20–34  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18
19
20class ExtBuildPy(build_py):
21 def run(self):
22 if os.environ.get("BNB_SKIP_CMAKE", "").lower() in ("1", "true", "yes"):
23 print("skipping CMake build")
24 else:
25 # build_cmake needs to be called prior to build_py, as the latter
26 # collects the files output into the package directory.
27 try:
28 self.run_command("build_cmake")
29 except DistutilsModuleError:
30 warn(
31 "scikit-build-core not installed, CMake will not be invoked automatically. "
32 "Please install scikit-build-core or run CMake manually to build extensions."
33 )
34 super().run()
35
36
37cmdclass = {"build_py": ExtBuildPy}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected