Skip to content

Commit b4732c0

Browse files
authored
Merge pull request #203402 from Homebrew/llvm@[email protected]
llvm@14, llvm@15: test with py3.12
2 parents a893292 + b7f90dc commit b4732c0

File tree

2 files changed

+16
-16
lines changed

2 files changed

+16
-16
lines changed

Formula/l/[email protected]

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,9 @@ class LlvmAT14 < Formula
3232
depends_on "cmake" => :build
3333
# sanitizer_mac.cpp:621:15: error: constexpr function never produces a constant expression [-Winvalid-constexpr]
3434
# constexpr u16 GetOSMajorKernelOffset() {
35-
depends_on maximum_macos: [:sonoma, :build]
36-
depends_on "[email protected]" => :build
35+
depends_on maximum_macos: [:ventura, :build]
36+
depends_on "[email protected]" => [:build, :test]
3737

38-
uses_from_macos "python" => :test
3938
uses_from_macos "libedit"
4039
uses_from_macos "libffi", since: :catalina
4140
uses_from_macos "ncurses"
@@ -53,9 +52,11 @@ class LlvmAT14 < Formula
5352
# Backport of https://reviews.llvm.org/D130060
5453
patch :DATA
5554

56-
def install
57-
python3 = "python3.12"
55+
def python3
56+
"python3.12"
57+
end
5858

59+
def install
5960
# The clang bindings need a little help finding our libclang.
6061
inreplace "clang/bindings/python/clang/cindex.py",
6162
/^(\s*library_path\s*=\s*)None$/,
@@ -461,10 +462,8 @@ def caveats
461462
shell_output("#{bin}/clang-format -style=google clangformattest.c")
462463

463464
# This will fail if the clang bindings cannot find `libclang`.
464-
# We explicitly call `"python3"` instead of the method to be able to do
465-
# `uses_from_macos "python" => :test`.
466-
with_env(PYTHONPATH: prefix/Language::Python.site_packages("python3")) do
467-
system "python3", "-c", <<~PYTHON
465+
with_env(PYTHONPATH: prefix/Language::Python.site_packages(python3)) do
466+
system python3, "-c", <<~PYTHON
468467
from clang import cindex
469468
cindex.Config().get_cindex_library()
470469
PYTHON

Formula/l/[email protected]

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,10 @@ class LlvmAT15 < Formula
3232
depends_on "cmake" => :build
3333
# sanitizer_mac.cpp:630:15: error: constexpr function never produces a constant expression [-Winvalid-constexpr]
3434
# constexpr u16 GetOSMajorKernelOffset() {
35-
depends_on maximum_macos: [:sonoma, :build]
36-
depends_on "[email protected]" => :build
35+
depends_on maximum_macos: [:ventura, :build]
36+
depends_on "[email protected]" => [:build, :test]
3737
depends_on "zstd"
3838

39-
uses_from_macos "python" => :test
4039
uses_from_macos "libedit"
4140
uses_from_macos "libffi", since: :catalina
4241
uses_from_macos "ncurses"
@@ -48,9 +47,11 @@ class LlvmAT15 < Formula
4847
depends_on "elfutils" # openmp requires <gelf.h>
4948
end
5049

51-
def install
52-
python3 = "python3.12"
50+
def python3
51+
"python3.12"
52+
end
5353

54+
def install
5455
# The clang bindings need a little help finding our libclang.
5556
inreplace "clang/bindings/python/clang/cindex.py",
5657
/^(\s*library_path\s*=\s*)None$/,
@@ -448,8 +449,8 @@ def caveats
448449
shell_output("#{bin}/clang-format -style=google clangformattest.c")
449450

450451
# This will fail if the clang bindings cannot find `libclang`.
451-
with_env(PYTHONPATH: prefix/Language::Python.site_packages("python3")) do
452-
system "python3", "-c", <<~PYTHON
452+
with_env(PYTHONPATH: prefix/Language::Python.site_packages(python3)) do
453+
system python3, "-c", <<~PYTHON
453454
from clang import cindex
454455
cindex.Config().get_cindex_library()
455456
PYTHON

0 commit comments

Comments
 (0)