aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorMisty De Meo2013-10-24 20:29:14 -0700
committerMisty De Meo2013-10-26 21:54:30 -0700
commit0e6df1c3bf1c5f5d23bcfa5c668d26cf48dffd20 (patch)
tree2ea84afc00a0787824dfc88e83ec994828905d1e /Library
parent2775a4b12cce406c85b97b70ed424852bf3bc783 (diff)
downloadbrew-0e6df1c3bf1c5f5d23bcfa5c668d26cf48dffd20.tar.bz2
detect_cxx_stdlibs: use mach_o_files
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/keg_fix_install_names.rb6
1 files changed, 1 insertions, 5 deletions
diff --git a/Library/Homebrew/keg_fix_install_names.rb b/Library/Homebrew/keg_fix_install_names.rb
index 694daaba8..9210e70e3 100644
--- a/Library/Homebrew/keg_fix_install_names.rb
+++ b/Library/Homebrew/keg_fix_install_names.rb
@@ -47,13 +47,9 @@ class Keg
# Note that this doesn't attempt to distinguish between libstdc++ versions,
# for instance between Apple libstdc++ and GNU libstdc++
def detect_cxx_stdlibs
- return [] unless lib.exist?
-
results = Set.new
- lib.find do |file|
- next if file.symlink? || file.directory?
- next unless file.dylib?
+ mach_o_files.each do |file|
dylibs = file.dynamically_linked_libraries
results << :libcxx unless dylibs.grep(/libc\+\+.+\.dylib/).empty?
results << :libstdcxx unless dylibs.grep(/libstdc\+\+.+\.dylib/).empty?