Fix install_name massaging for keg-only brews
Fixes Homebrew/homebrew#6065. My pre-emptive fix that avoided calling Pathname.ensure_writable because I was not convinced it worked broke this function due to incorrect logic. The lesson is, don’t write pre-emptive fixes. Wait until you've seen the bug first. All code has bugs in, so write less. I'm an idiot sometimes.
This commit is contained in:
parent
02b09e311f
commit
870f36769e
@ -2,9 +2,6 @@ class Keg
|
||||
def fix_install_names
|
||||
dylibs.each do |dylib|
|
||||
bad_install_names_for dylib do |id, bad_names|
|
||||
# avoid the chmod change if unecessary—I'm not convinced it reverses right
|
||||
next if bad_names.empty? and id.to_s == dylib.to_s
|
||||
|
||||
dylib.ensure_writable do
|
||||
system "install_name_tool", "-id", id, dylib
|
||||
bad_names.each do |bad_name|
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user