Skip to content
Snippets Groups Projects
Commit b87bf885 authored by Jack Nagel's avatar Jack Nagel
Browse files

FormulaInstaller: fix "optional build-time dep" edge case

An "optional build-time dep" is unlikely, but possible, and I happen to
notice this wasn't handled correctly while digging around in the deps
code over the last few days.
parent 0b4316fb
No related branches found
No related tags found
No related merge requests found
......@@ -151,17 +151,13 @@ class FormulaInstaller
def necessary_deps
ARGV.filter_for_dependencies do
f.recursive_dependencies do |dependent, dep|
if dep.optional? || dep.recommended?
Dependency.prune unless dependent.build.with?(dep.name)
elsif dep.build?
Dependency.prune if install_bottle?(dependent)
end
if f.build.universal?
dep.universal! unless dep.build?
end
dep.universal! if f.build.universal? && !dep.build?
if dep.satisfied?
if (dep.optional? || dep.recommended?) && dependent.build.without?(dep.name)
Dependency.prune
elsif dep.build? && install_bottle?(dependent)
Dependency.prune
elsif dep.satisfied?
Dependency.prune
elsif dep.installed?
raise UnsatisfiedDependencyError.new(f, dep)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment