diff options
| author | James Harris | 2010-08-02 11:28:21 -0500 |
|---|---|---|
| committer | Adam Vandenberg | 2010-08-02 12:49:20 -0700 |
| commit | 74bcfa464d1b2e6d8ce44cdab1b04ec3ed2912c6 (patch) | |
| tree | a39d50067827bfc67185ee72e2fd16d1158eee9b /Library | |
| parent | 2bf506e3d90254f81a669a0216f33b2f09589028 (diff) | |
| download | homebrew-74bcfa464d1b2e6d8ce44cdab1b04ec3ed2912c6.tar.bz2 | |
archs_for_command now follows symlinks.
Tell file(1) to follow symlinks using the -L option.
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Homebrew/utils.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Library/Homebrew/utils.rb b/Library/Homebrew/utils.rb index 8b3d6fb79..a34e108de 100644 --- a/Library/Homebrew/utils.rb +++ b/Library/Homebrew/utils.rb @@ -177,7 +177,7 @@ def archs_for_command cmd cmd = `/usr/bin/which #{cmd}` unless Pathname.new(cmd).absolute? cmd.gsub! ' ', '\\ ' # Escape spaces in the filename. - archs = IO.popen("/usr/bin/file #{cmd}").readlines.inject([]) do |archs, line| + archs = IO.popen("/usr/bin/file -L #{cmd}").readlines.inject([]) do |archs, line| case line when /Mach-O (executable|dynamically linked shared library) ppc/ archs << :ppc7400 |
