diff --git a/Library/Homebrew/formula_installer.rb b/Library/Homebrew/formula_installer.rb index caf4a7475f..0ac94a40ca 100644 --- a/Library/Homebrew/formula_installer.rb +++ b/Library/Homebrew/formula_installer.rb @@ -56,6 +56,10 @@ class FormulaInstaller @pour_failed = false end + def skip_deps_check? + ignore_deps? + end + # When no build tools are available and build flags are passed through ARGV, # it's necessary to interrupt the user before any sort of installation # can proceed. Only invoked when the user has no developer tools. @@ -97,7 +101,7 @@ class FormulaInstaller end def prelude - verify_deps_exist unless ignore_deps? + verify_deps_exist unless skip_deps_check? lock check_install_sanity end @@ -120,7 +124,7 @@ class FormulaInstaller def check_install_sanity raise FormulaInstallationAlreadyAttemptedError, formula if @@attempted.include?(formula) - unless ignore_deps? + unless skip_deps_check? unlinked_deps = formula.recursive_dependencies.map(&:to_formula).select do |dep| dep.installed? && !dep.keg_only? && !dep.linked_keg.directory? end @@ -159,7 +163,7 @@ class FormulaInstaller raise BuildToolsError.new([formula]) end - unless ignore_deps? + unless skip_deps_check? deps = compute_dependencies check_dependencies_bottled(deps) if pour_bottle? && !MacOS.has_apple_developer_tools? install_dependencies(deps) @@ -364,15 +368,8 @@ class FormulaInstaller end class DependencyInstaller < FormulaInstaller - def initialize(*) - super - @ignore_deps = true - end - - def sanitized_ARGV_options - args = super - args.delete "--ignore-dependencies" - args + def skip_deps_check? + true end end