]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.14] GH-146475: Block Apple Clang for building JIT stencils (#149188) (#149339)
authorSavannah Ostrowski <savannah@python.org>
Mon, 4 May 2026 00:30:24 +0000 (17:30 -0700)
committerGitHub <noreply@github.com>
Mon, 4 May 2026 00:30:24 +0000 (00:30 +0000)
GH-146475: Block Apple Clang for building JIT stencils (#149188)

(cherry picked from commit c0e064003954142b4ba820dfe149f893227c4f11)

Misc/NEWS.d/next/Build/2026-04-30-08-43-47.gh-issue-146475.1cL4hX.rst [new file with mode: 0644]
Tools/jit/_llvm.py

diff --git a/Misc/NEWS.d/next/Build/2026-04-30-08-43-47.gh-issue-146475.1cL4hX.rst b/Misc/NEWS.d/next/Build/2026-04-30-08-43-47.gh-issue-146475.1cL4hX.rst
new file mode 100644 (file)
index 0000000..225c659
--- /dev/null
@@ -0,0 +1,2 @@
+Block Apple Clang from being used to build the JIT as it ships without
+required LLVM tools.
index f09a8404871b24b92f836324cc35a6bc10bc5408..79b6b7ec53005ef23712974fa3b22ee0d7950928 100644 (file)
@@ -11,7 +11,9 @@ import typing
 import _targets
 
 _LLVM_VERSION = 19
-_LLVM_VERSION_PATTERN = re.compile(rf"version\s+{_LLVM_VERSION}\.\d+\.\d+\S*\s+")
+_LLVM_VERSION_PATTERN = re.compile(
+    rf"(?<!Apple )(LLVM|clang) version\s+{_LLVM_VERSION}\.\d+\.\d+\S*\s+"
+)
 _EXTERNALS_LLVM_TAG = "llvm-19.1.7.0"
 
 _P = typing.ParamSpec("_P")