aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/llvm.rb
diff options
context:
space:
mode:
authorJack Nagel2014-12-30 13:57:30 -0500
committerJack Nagel2014-12-30 16:13:01 -0500
commit3099fa4d2c4f0718f6dc6802cfdc4b1daec38124 (patch)
tree870843560d02580d2ea87eda067d6bb14df86e61 /Library/Formula/llvm.rb
parent62865eaac13d8cd015390a052bcc4bf21026998d (diff)
downloadhomebrew-3099fa4d2c4f0718f6dc6802cfdc4b1daec38124.tar.bz2
llvm: use absolute dylib IDs
Fixes #32566.
Diffstat (limited to 'Library/Formula/llvm.rb')
-rw-r--r--Library/Formula/llvm.rb25
1 files changed, 23 insertions, 2 deletions
diff --git a/Library/Formula/llvm.rb b/Library/Formula/llvm.rb
index 804415456..ab67f73a2 100644
--- a/Library/Formula/llvm.rb
+++ b/Library/Formula/llvm.rb
@@ -1,5 +1,3 @@
-require 'formula'
-
class Llvm < Formula
homepage 'http://llvm.org/'
@@ -37,6 +35,9 @@ class Llvm < Formula
end
end
+ # Use absolute paths for shared library IDs
+ patch :DATA
+
option :universal
option 'with-clang', 'Build Clang support library'
option 'with-lld', 'Build LLD linker'
@@ -114,3 +115,23 @@ class Llvm < Formula
EOS
end
end
+
+__END__
+diff --git a/Makefile.rules b/Makefile.rules
+index ebebc0a..b0bb378 100644
+--- a/Makefile.rules
++++ b/Makefile.rules
+@@ -599,7 +599,12 @@ ifneq ($(HOST_OS), $(filter $(HOST_OS), Cygwin MingW))
+ ifneq ($(HOST_OS),Darwin)
+ LD.Flags += $(RPATH) -Wl,'$$ORIGIN'
+ else
+- LD.Flags += -Wl,-install_name -Wl,"@rpath/lib$(LIBRARYNAME)$(SHLIBEXT)"
++ LD.Flags += -Wl,-install_name
++ ifdef LOADABLE_MODULE
++ LD.Flags += -Wl,"$(PROJ_libdir)/$(LIBRARYNAME)$(SHLIBEXT)"
++ else
++ LD.Flags += -Wl,"$(PROJ_libdir)/$(SharedPrefix)$(LIBRARYNAME)$(SHLIBEXT)"
++ endif
+ endif
+ endif
+ endif