symengine: revision bump (llvm 15.0.0)
Also, apply a patch to make sure we link with the `libLLVM` shared library instead of the static libraries. Trying to use the static libraries causes build failures because Apple's `ld` cannot read the LTOed object files. An alternative workaround is to do something like ENV.append_to_cflags "-fuse-ld=lld" if OS.mac? in the formula. Closes #106925. Signed-off-by: Daniel Nachun <9205048+danielnachun@users.noreply.github.com> Signed-off-by: BrewTestBot <1589480+BrewTestBot@users.noreply.github.com>master
parent
42421fc8a3
commit
3968f84edf
|
@ -4,7 +4,7 @@ class Symengine < Formula
|
|||
url "https://github.com/symengine/symengine/releases/download/v0.9.0/symengine-0.9.0.tar.gz"
|
||||
sha256 "dcf174ac708ed2acea46691f6e78b9eb946d8a2ba62f75e87cf3bf4f0d651724"
|
||||
license "MIT"
|
||||
revision 1
|
||||
revision 2
|
||||
|
||||
bottle do
|
||||
sha256 cellar: :any, arm64_monterey: "2f14a527a90815157ddd3a7050bce697084640bebadd38424d32f9303a94cffd"
|
||||
|
@ -16,6 +16,7 @@ class Symengine < Formula
|
|||
end
|
||||
|
||||
depends_on "cmake" => :build
|
||||
depends_on "cereal"
|
||||
depends_on "flint"
|
||||
depends_on "gmp"
|
||||
depends_on "libmpc"
|
||||
|
@ -24,6 +25,15 @@ class Symengine < Formula
|
|||
|
||||
fails_with gcc: "5"
|
||||
|
||||
# Avoid static linkage with LLVM. The static libraries contain
|
||||
# LTOed objects which causes errors with Apple's `ld`.
|
||||
# An alternative workaround is to use `lld` with `-fuse-ld=lld`.
|
||||
# TODO(carlocab): Upstream a version of this patch.
|
||||
patch do
|
||||
url "https://gitweb.gentoo.org/repo/gentoo.git/plain/sci-libs/symengine/files/symengine-0.8.1-fix_llvm.patch?id=83ab9587be9f89e667506b861208d613a2f016e5"
|
||||
sha256 "c654ea7c4ee44c689433e87f71c7ae78e6c04968e7dfe89be5e4ba4c8c53713b"
|
||||
end
|
||||
|
||||
def install
|
||||
system "cmake", "-S", ".", "-B", "build",
|
||||
"-DBUILD_SHARED_LIBS=ON",
|
||||
|
@ -35,6 +45,7 @@ class Symengine < Formula
|
|||
"-DWITH_COTIRE=OFF",
|
||||
"-DLLVM_DIR=#{Formula["llvm"].opt_lib}/cmake/llvm",
|
||||
"-DWITH_SYMENGINE_THREAD_SAFE=ON",
|
||||
"-DWITH_SYSTEM_CEREAL=ON",
|
||||
*std_cmake_args
|
||||
|
||||
system "cmake", "--build", "build"
|
||||
|
|
Loading…
Reference in New Issue