10000 [3.12] gh-117752: Autoconf: fix PGO builds for 'make -C build' incant… · python/cpython@a39e01d · GitHub
[go: up one dir, main page]

Skip to content

Commit a39e01d

Browse files
[3.12] gh-117752: Autoconf: fix PGO builds for 'make -C build' incantations (GH-117803) (#117805)
(cherry picked from commit 1ddbeae) Co-authored-by: Erlend E. Aasland <erlend@python.org>
1 parent 3f2f0cf commit a39e01d

File tree

2 files changed

+16
-8
lines changed

2 files changed

+16
-8
lines changed

configure

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

configure.ac

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1987,8 +1987,12 @@ case $CC in
19871987
*clang*)
19881988
# Any changes made here should be reflected in the GCC+Darwin case below
19891989
PGO_PROF_GEN_FLAG="-fprofile-instr-generate"
1990-
PGO_PROF_USE_FLAG="-fprofile-instr-use=code.profclangd"
1991-
LLVM_PROF_MERGER="${LLVM_PROFDATA} merge -output=code.profclangd *.profclangr"
1990+
PGO_PROF_USE_FLAG="-fprofile-instr-use=\"\$(shell pwd)/code.profclangd\""
1991+
LLVM_PROF_MERGER=m4_normalize("
1992+
${LLVM_PROFDATA} merge
1993+
-output=\"\$(shell pwd)/code.profclangd\"
1994+
\"\$(shell pwd)\"/*.profclangr
1995+
")
19921996
LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"\$(shell pwd)/code-%p.profclangr\""
19931997
if test $LLVM_PROF_FOUND = not-found
19941998
then
@@ -2003,8 +2007,12 @@ case $CC in
20032007
case $ac_sys_system in
20042008
Darwin*)
20052009
PGO_PROF_GEN_FLAG="-fprofile-instr-generate"
2006-
PGO_PROF_USE_FLAG="-fprofile-instr-use=code.profclangd"
2007-
LLVM_PROF_MERGER="${LLVM_PROFDATA} merge -output=code.profclangd *.profclangr"
2010+
PGO_PROF_USE_FLAG="-fprofile-instr-use=\"\$(shell pwd)/code.profclangd\""
2011+
LLVM_PROF_MERGER=m4_normalize("
2012+
${LLVM_PROFDATA} merge
2013+
-output=\"\$(shell pwd)/code.profclangd\"
2014+
\"\$(shell pwd)\"/*.profclangr
2015+
")
20082016
LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"\$(shell pwd)/code-%p.profclangr\""
20092017
if test "${LLVM_PROF_FOUND}" = "not-found"
20102018
then

0 commit comments

Comments
 (0)
0