diff options
| author | Adam Vandenberg | 2012-07-12 07:08:23 -0700 |
|---|---|---|
| committer | Jack Nagel | 2012-08-17 15:35:54 -0500 |
| commit | 4a948c413248dcb13fe25902c55755b66d07d833 (patch) | |
| tree | 610a45de54594f9f6f2a17d06992f6ddff57e4cc /Library/Homebrew | |
| parent | ac51c0ffbb4ab4d46b28eccd19810357548e2dd3 (diff) | |
| download | brew-4a948c413248dcb13fe25902c55755b66d07d833.tar.bz2 | |
Add special :xcode dependency
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library/Homebrew')
| -rw-r--r-- | Library/Homebrew/dependencies.rb | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/Library/Homebrew/dependencies.rb b/Library/Homebrew/dependencies.rb index 44584242a..43d77f531 100644 --- a/Library/Homebrew/dependencies.rb +++ b/Library/Homebrew/dependencies.rb @@ -70,6 +70,8 @@ private end when :x11 X11Dependency.new(tag) + when :xcode + XCodeDependency.new else raise "Unsupported special dependency #{spec}" end @@ -322,3 +324,16 @@ class ConflictRequirement < Requirement not ARGV.force? end end + +class XCodeDependency < Requirement + def fatal?; true; end + + def satisfied? + MacOS::Xcode.installed? + end + + def message; <<-EOS.undent + XCode is required to compile this software. + EOS + end +end |
