Skip to content

Commit

Permalink
update to 17.0.6.2
Browse files Browse the repository at this point in the history
  • Loading branch information
mulle-nat committed Nov 20, 2024
1 parent aa0f137 commit 8d3d1d0
Showing 1 changed file with 20 additions and 12 deletions.
32 changes: 20 additions & 12 deletions mulle-clang-project.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ class MulleClangProject < Formula
desc "Objective-C compiler for the mulle-objc runtime"
homepage "https://github.com/mulle-cc/mulle-clang-project"
license "BSD-3-Clause"
version "14.0.6.2"
version "17.0.6.2"
# revision 1
head "https://github.com/mulle-cc/mulle-clang-project.git", branch: "mulle/14.0.6"
head "https://github.com/mulle-cc/mulle-clang-project.git", branch: "mulle/17.0.6"

#
# MEMO:
Expand All @@ -15,11 +15,11 @@ class MulleClangProject < Formula
# 3. Run shasum over it `shasum -a 256 -b 13.0.0.i1.tar.gz`
# 4. Remove bottle urls
#
url "https://github.com/mulle-cc/mulle-clang-project/archive/refs/tags/14.0.6.2.tar.gz"
sha256 "299ebbdeafa4f5699f35b87b921f7222097d64f6b56d5e417633bf0419726833"
url "https://github.com/mulle-cc/mulle-clang-project/archive/refs/tags/17.0.6.2.tar.gz"
sha256 "78e50da1e1254575df3e2c34b3ba2e46b2e3b82b2acaea10784b2d9695e7d520"

def vendor
"mulle-clang 14.0.6.2 (runtime-load-version: 17)"
"mulle-clang 17.0.6.2 (runtime-load-version: 18)"
end

#
Expand All @@ -42,10 +42,9 @@ def vendor
# "#{root_url}/#{name}-#{version}.#{tag}.bottle.#{revision}.tar.gz"
# root_url "https://www.mulle-kybernetik.com/bottles"

root_url "https://github.com/mulle-cc/mulle-clang-project/releases/download/14.0.6.2"
root_url "https://github.com/mulle-cc/mulle-clang-project/releases/download/17.0.6.2"

sha256 cellar: :any, monterey: "d9fe5d0177b19e74885bddf4ea4c9fcffd453a937ebeeee2116196e6b905cc54"
sha256 cellar: :any, big_sur: "c9f575ca3854f4b2cbeb6bf780a74f881356dbd02149f6af81a34f4f231f4907"
sha256 cellar: :any, sonoma: "a00b8b54c20a6131844b52fe2e577344b6f46a2b2eebe89cd82b16ad1f08937c"
end

#
Expand All @@ -69,25 +68,34 @@ def vendor
def install
mkdir "build" do
args = std_cmake_args
args << '-DLLVM_ENABLE_PROJECTS=libcxxabi;libcxx;clang'
args << '-DLLVM_BUILD_LLVM_DYLIB=ON'
args << "-DLLVM_ENABLE_PROJECTS='clang'" # ";compiler-rt'" don't build for now on sonoma
args << "-DLLVM_ENABLE_RUNTIMES='libcxxabi;libcxx'"
args << '-DLLVM_LINK_LLVM_DYLIB=ON'
args << '-DLLVM_PARALLEL_LINK_JOBS=4'
args << '-DCMAKE_BUILD_TYPE=Release'
args << '-DCLANG_VENDOR=mulle'
args << '-DCLANG_VENDOR=mulle'
args << "-DLLVM_TARGETS_TO_BUILD='X86;ARM;AArch64'"
# apparently not longer working
# args << "-DCMAKE_SHARED_LINKER_FLAGS='-Wl,--reduce-memory-overheads'"
# args << "-DCMAKE_EXE_LINKER_FLAGS='-Wl,--reduce-memory-overheads'"
args << '-DCMAKE_INSTALL_MESSAGE=LAZY'
args << "-DCMAKE_INSTALL_PREFIX='#{prefix}/root'"
args << '../llvm'

system "cmake", "-G", "Ninja", *args
system "ninja", "install"
end
bin.install_symlink "#{prefix}/root/bin/clang" => "mulle-clang"
bin.install_symlink "#{prefix}/root/bin/nm" => "mulle-nm"
bin.install_symlink "#{prefix}/root/bin/scan-build" => "mulle-scan-build"
end

def caveats
str = <<~EOS
To use mulle-clang inside homebrew formulae, you need a shim.
See:
https://github.com/mulle-objc/mulle-clang-homebrew
https://github.com/mulle-kybernetik/mulle-clang-homebrew
EOS
str
end
Expand Down

0 comments on commit 8d3d1d0

Please sign in to comment.