aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/cmd
diff options
context:
space:
mode:
authorMike McQuaid2013-09-10 21:56:39 +0100
committerMike McQuaid2013-09-10 21:56:39 +0100
commitba057f6b9a568ab2097d021c657996ffc28f2fa4 (patch)
treeb2fc828de4720285144379e4ec5ff6d807993829 /Library/Homebrew/cmd
parent63a268d4465f52144fef760eb7e7c6b725353598 (diff)
downloadhomebrew-ba057f6b9a568ab2097d021c657996ffc28f2fa4.tar.bz2
bottle: loosen prefix grep check.
/usr/local is in lots of things unrelated to Homebrew so be more specific and look for opt instead.
Diffstat (limited to 'Library/Homebrew/cmd')
-rw-r--r--Library/Homebrew/cmd/bottle.rb8
1 files changed, 7 insertions, 1 deletions
diff --git a/Library/Homebrew/cmd/bottle.rb b/Library/Homebrew/cmd/bottle.rb
index 379ba9e93..f758cc143 100644
--- a/Library/Homebrew/cmd/bottle.rb
+++ b/Library/Homebrew/cmd/bottle.rb
@@ -78,7 +78,13 @@ module Homebrew extend self
# references to the Cellar e.g. Qt's QMake annoyingly does this.
keg.relocate_install_names prefix, tmp_prefix, cellar, tmp_cellar
- relocatable = !keg_contains(HOMEBREW_PREFIX, keg)
+ if prefix == '/usr/local'
+ prefix_check = HOMEBREW_PREFIX/'opt'
+ else
+ prefix_check = HOMEBREW_PREFIX
+ end
+
+ relocatable = !keg_contains(prefix_check, keg)
relocatable = !keg_contains(HOMEBREW_CELLAR, keg) if relocatable
# And do the same thing in reverse to change the library references