diff options
| author | Jack Nagel | 2013-11-04 12:00:06 -0600 | 
|---|---|---|
| committer | Jack Nagel | 2013-11-04 12:10:26 -0600 | 
| commit | 6c3ee52d14e54f5cb23438c3ec4a1b57a1e60e80 (patch) | |
| tree | aad3ec6b99130bd4d7ba2b56ae39cc8b1901883e /Library/Homebrew | |
| parent | c556b3dc09b130ab431e55e2752a8a3a479040d7 (diff) | |
| download | brew-6c3ee52d14e54f5cb23438c3ec4a1b57a1e60e80.tar.bz2 | |
Remove special cases in build-time dep audit
Closes Homebrew/homebrew#23931.
Diffstat (limited to 'Library/Homebrew')
| -rw-r--r-- | Library/Homebrew/cmd/audit.rb | 6 | ||||
| -rw-r--r-- | Library/Homebrew/dependency_collector.rb | 13 | 
2 files changed, 8 insertions, 11 deletions
| diff --git a/Library/Homebrew/cmd/audit.rb b/Library/Homebrew/cmd/audit.rb index f05fe8b07..10b37e57a 100644 --- a/Library/Homebrew/cmd/audit.rb +++ b/Library/Homebrew/cmd/audit.rb @@ -151,11 +151,7 @@ class FormulaAuditor        case dep.name        when *BUILD_TIME_DEPS -        next if dep.build? -        next if dep.name == 'autoconf' && f.name =~ /automake/ -        next if dep.name == 'libtool' && %w{imagemagick libgphoto2 libp11 libextractor}.any? { |n| f.name == n } -        next if dep.name =~ /autoconf|pkg-config/ && f.name == 'ruby-build' - +        next if dep.build? or dep.run?          problem %{#{dep} dependency should be "depends_on '#{dep}' => :build"}        when "git", "ruby", "emacs", "mercurial"          problem <<-EOS.undent diff --git a/Library/Homebrew/dependency_collector.rb b/Library/Homebrew/dependency_collector.rb index 43e701078..8ede0c144 100644 --- a/Library/Homebrew/dependency_collector.rb +++ b/Library/Homebrew/dependency_collector.rb @@ -132,14 +132,15 @@ class DependencyCollector    end    def autotools_dep(spec, tags) -    unless MacOS::Xcode.provides_autotools? -      case spec -      when :libltdl then spec = :libtool -      else tags << :build -      end +    return if MacOS::Xcode.provides_autotools? -      Dependency.new(spec.to_s, tags) +    if spec == :libltdl +      spec = :libtool +      tags << :run      end + +    tags << :build unless tags.include? :run +    Dependency.new(spec.to_s, tags)    end    def ant_dep(spec, tags) | 
