diff options
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Homebrew/formula.rb | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Library/Homebrew/formula.rb b/Library/Homebrew/formula.rb index fa4841dd7..9801e0c47 100644 --- a/Library/Homebrew/formula.rb +++ b/Library/Homebrew/formula.rb @@ -831,12 +831,16 @@ private def finalize_dsl # Synthesize options for optional dependencies dependencies.deps.select(&:optional?).each do |dep| - option "with-#{dep.name}", "Build with #{dep.name} support" + unless build.has_option? "with-#{dep.name}" + option "with-#{dep.name}", "Build with #{dep.name} support" + end end # Synthesize options for recommended dependencies dependencies.deps.select(&:recommended?).each do |dep| - option "without-#{dep.name}", "Build without #{dep.name} support" + unless build.has_option? "without-#{dep.name}" + option "without-#{dep.name}", "Build without #{dep.name} support" + end end end end |
