]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-117752: Autoconf: store all LLVM profile data in the build directory (#117790)
authorErlend E. Aasland <erlend@python.org>
Fri, 12 Apr 2024 05:23:39 +0000 (07:23 +0200)
committerGitHub <noreply@github.com>
Fri, 12 Apr 2024 05:23:39 +0000 (07:23 +0200)
This prevents spurious 'env changed' and llvm-profdata merge errors.

configure
configure.ac

index f9c181ac3805e170ccd477aa7ae0cc2e4d03ec6f..15a645ae84618aaffacfd69df848c5dda6efc3c6 100755 (executable)
--- a/configure
+++ b/configure
@@ -8828,7 +8828,7 @@ case "$CC_BASENAME" in
     PGO_PROF_GEN_FLAG="-fprofile-instr-generate"
     PGO_PROF_USE_FLAG="-fprofile-instr-use=code.profclangd"
     LLVM_PROF_MERGER="${LLVM_PROFDATA} merge -output=code.profclangd *.profclangr"
-    LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"code-%p.profclangr\""
+    LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"\$(shell pwd)/code-%p.profclangr\""
     if test $LLVM_PROF_FOUND = not-found
     then
       LLVM_PROF_ERR=yes
@@ -8844,7 +8844,7 @@ case "$CC_BASENAME" in
         PGO_PROF_GEN_FLAG="-fprofile-instr-generate"
         PGO_PROF_USE_FLAG="-fprofile-instr-use=code.profclangd"
         LLVM_PROF_MERGER="${LLVM_PROFDATA} merge -output=code.profclangd *.profclangr"
-        LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"code-%p.profclangr\""
+        LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"\$(shell pwd)/code-%p.profclangr\""
         if test "${LLVM_PROF_FOUND}" = "not-found"
         then
           LLVM_PROF_ERR=yes
index 47c084d92a30e8d84cd39a9c6fa2351acb572301..359ac2bd8393a947efb3b3120f252f79da311d2a 100644 (file)
@@ -2013,7 +2013,7 @@ case "$CC_BASENAME" in
     PGO_PROF_GEN_FLAG="-fprofile-instr-generate"
     PGO_PROF_USE_FLAG="-fprofile-instr-use=code.profclangd"
     LLVM_PROF_MERGER="${LLVM_PROFDATA} merge -output=code.profclangd *.profclangr"
-    LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"code-%p.profclangr\""
+    LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"\$(shell pwd)/code-%p.profclangr\""
     if test $LLVM_PROF_FOUND = not-found
     then
       LLVM_PROF_ERR=yes
@@ -2029,7 +2029,7 @@ case "$CC_BASENAME" in
         PGO_PROF_GEN_FLAG="-fprofile-instr-generate"
         PGO_PROF_USE_FLAG="-fprofile-instr-use=code.profclangd"
         LLVM_PROF_MERGER="${LLVM_PROFDATA} merge -output=code.profclangd *.profclangr"
-        LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"code-%p.profclangr\""
+        LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"\$(shell pwd)/code-%p.profclangr\""
         if test "${LLVM_PROF_FOUND}" = "not-found"
         then
           LLVM_PROF_ERR=yes