From 67ab6a84a3f00db15fc9e50f4a3d5c71b3189a46 Mon Sep 17 00:00:00 2001 From: Kevin Modzelewski Date: Tue, 26 Jul 2022 12:04:38 -0400 Subject: [PATCH 1/2] Makefile: have "install" depend on pgo Previously, `make install` would ignore pgo. This isn't an issue if one runs `make && make install`, since `make` will build with pgo (if requested) and then `make install` won't rebuild anything. But if one simply does `./configure --enable-optimizations && make install`, the build system would build a non-pgo build and then install that. This commit changes the Makefile so that `install` depends on `all`, which includes pgo when requested. --- Makefile.pre.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile.pre.in b/Makefile.pre.in index 98df01963ca5ad..df0f06a69254ca 100644 --- a/Makefile.pre.in +++ b/Makefile.pre.in @@ -1760,7 +1760,7 @@ $(DESTSHARED): # Install the interpreter with $(VERSION) affixed # This goes into $(exec_prefix) -altbininstall: $(BUILDPYTHON) @FRAMEWORKPYTHONW@ +altbininstall: all @FRAMEWORKPYTHONW@ @for i in $(BINDIR) $(LIBDIR); \ do \ if test ! -d $(DESTDIR)$$i; then \ From f134ab43b64194a31023b382ae1898e1152d5761 Mon Sep 17 00:00:00 2001 From: Itamar Oren Date: Tue, 17 Nov 2026 12:12:16 -0800 Subject: [PATCH 2/2] Add NEWS entry for gh-162170 --- .../next/Build/2026-11-17-20-12-03.gh-issue-162170.0SpcRZ.rst | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 Misc/NEWS.d/next/Build/2026-11-17-20-12-03.gh-issue-162170.0SpcRZ.rst diff --git a/Misc/NEWS.d/next/Build/2026-11-17-20-12-03.gh-issue-162170.0SpcRZ.rst b/Misc/NEWS.d/next/Build/2026-11-17-20-12-03.gh-issue-162170.0SpcRZ.rst new file mode 100644 index 00000000000000..caa4b13ce30339 --- /dev/null +++ b/Misc/NEWS.d/next/Build/2026-11-17-20-12-03.gh-issue-162170.0SpcRZ.rst @@ -0,0 +1,3 @@ +``make install`` now depends on the ``all`` target, so running it directly +after ``./configure --enable-optimizations`` installs the PGO-optimized +interpreter rather than an unoptimized build.