gh-93939: Build C extensions without setup.py (GH-94474)

Combines GH-93940, GH-94452, and GH-94433
This commit is contained in:
Christian Heimes 2022-07-14 09:51:49 +02:00 committed by GitHub
parent b03a9e8c8a
commit 81dca70d70
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
14 changed files with 89 additions and 1506 deletions

View file

@ -358,7 +358,7 @@ class AbstractBuilder(object):
env["LD_RUN_PATH"] = self.lib_dir
log.info("Rebuilding Python modules")
cmd = [sys.executable, os.path.join(PYTHONROOT, "setup.py"), "build"]
cmd = ["make", "sharedmods", "checksharedmods"]
self._subprocess_call(cmd, env=env)
self.check_imports()
@ -472,7 +472,7 @@ def main():
start = datetime.now()
if args.steps in {'modules', 'tests'}:
for name in ['setup.py', 'Modules/_ssl.c']:
for name in ['Makefile.pre.in', 'Modules/_ssl.c']:
if not os.path.isfile(os.path.join(PYTHONROOT, name)):
parser.error(
"Must be executed from CPython build dir"