aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorCharlie Sharpsteen2011-11-21 11:26:05 -0800
committerCharlie Sharpsteen2011-11-21 11:26:05 -0800
commit9407a0cbcb71d9d859f8f76838de1be0a97668f3 (patch)
treeb71cba552e3d73da07a81894554a714ec7d2f720 /Library
parentf94d0ae50f9e92cb2d3f533fb4244c393415aeda (diff)
downloadhomebrew-9407a0cbcb71d9d859f8f76838de1be0a97668f3.tar.bz2
formula_installer.rb: Hotfix for head installs
For now, don't strip `--HEAD` from `ARGV` prior to forking for install. Currently this doesn't work because the formula object the installer is acting on has its `prefix` set while under the influence of `--HEAD`. So, the installer bails out when it sees that nothing is installed to `f.prefix`. This is a hotfix for issue #8668 to allow formulae to keep building. A proper fix should ensure that formula installers are operating on objects with appropriately set `prefix` values.
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/formula_installer.rb8
1 files changed, 6 insertions, 2 deletions
diff --git a/Library/Homebrew/formula_installer.rb b/Library/Homebrew/formula_installer.rb
index 1a4250486..4590bf96c 100644
--- a/Library/Homebrew/formula_installer.rb
+++ b/Library/Homebrew/formula_installer.rb
@@ -253,7 +253,7 @@ class FormulaInstaller
# list.
#
# FIXME:
- # `ARGV.formulae` probably should be throwing exceptions, it should be
+ # `ARGV.formulae` probably shouldn't be throwing exceptions, it should be
# the caller's responsibility to check `ARGV.formulae.empty?`.
return false if ARGV.named.empty?
ARGV.formulae.include? f
@@ -261,10 +261,14 @@ class FormulaInstaller
args = ARGV.clone
+ # FIXME: Also need to remove `--HEAD`, however there is a problem in that
+ # the properties of formula objects, such as `prefix`, are influenced by
+ # `--HEAD` and get set when the object is created.
+ #
+ # See issue #8668
%w[
--debug -d
--fresh
- --HEAD
--interactive -i
--verbose -v
].each {|flag| args.delete flag} unless explicitly_requested?