aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula
diff options
context:
space:
mode:
authorJack Nagel2013-11-29 10:35:24 -0600
committerJack Nagel2013-11-29 10:36:54 -0600
commit2d7dbba911e514cd939e5b13188ad527267324c1 (patch)
tree2bb2fb1adf3b3e197e6cf71746dbe81aec6f8a54 /Library/Formula
parentd817acc611c2342b7d651df923343b17ba0d678a (diff)
downloadhomebrew-2d7dbba911e514cd939e5b13188ad527267324c1.tar.bz2
lsyncd: don't try to define incomplete resources
Fixes #24699.
Diffstat (limited to 'Library/Formula')
-rw-r--r--Library/Formula/lsyncd.rb48
1 files changed, 18 insertions, 30 deletions
diff --git a/Library/Formula/lsyncd.rb b/Library/Formula/lsyncd.rb
index 0ed6df12a..be566cd5f 100644
--- a/Library/Formula/lsyncd.rb
+++ b/Library/Formula/lsyncd.rb
@@ -15,36 +15,24 @@ class Lsyncd < Formula
# This is an artificial requirement, the resource below is incomplete
depends_on :macos => :lion
- resource 'xnu' do
- # Note: Do not use MacOS::version -- the version number is not
- # enough, we need the patch number as well.
- osx_version = `sw_vers -productVersion`.strip
- case osx_version
- when "10.7.5"
- url 'http://www.opensource.apple.com/tarballs/xnu/xnu-1699.32.7.tar.gz'
- sha1 'da3df48952b40ad3b8612c7f639b8bf0f92fb414'
- when "10.8"
- url 'http://www.opensource.apple.com/tarballs/xnu/xnu-2050.7.9.tar.gz'
- sha1 '9aaf1e0b0a148ff303577161fecaf3ea6188aa1b'
- when "10.8.1"
- url 'http://www.opensource.apple.com/tarballs/xnu/xnu-2050.9.2.tar.gz'
- sha1 '2bd58959afc5ac8f2c9fa3d693882acc96b25321'
- when "10.8.2"
- url 'http://www.opensource.apple.com/tarballs/xnu/xnu-2050.18.24.tar.gz'
- sha1 '3a2a0b3629cb215b17aca3bb365b8b10b8b408fe'
- when "10.8.3"
- url 'http://www.opensource.apple.com/tarballs/xnu/xnu-2050.22.13.tar.gz'
- sha1 'a002806d1e64505c6a98c10af26186454818a9ff'
- when "10.8.4"
- url 'http://www.opensource.apple.com/tarballs/xnu/xnu-2050.24.15.tar.gz'
- sha1 'a080f28b7385b0cc63f9ba5a07d922d53ea0a4a3'
- when "10.8.5"
- url 'http://www.opensource.apple.com/tarballs/xnu/xnu-2050.48.11.tar.gz'
- sha1 '1f6860148f8231a53a6b393aa1af589cdedfc70c'
- when "10.9"
- url "http://www.opensource.apple.com/tarballs/xnu/xnu-2422.1.72.tar.gz"
- sha1 "c7bdc40396df3c51ece934c0e3b4a19b063ea34c"
- end
+ osx_version = `sw_vers -productVersion`.strip
+ xnu_headers = {
+ "10.7.5" => ['xnu-1699.32.7.tar.gz', 'da3df48952b40ad3b8612c7f639b8bf0f92fb414'],
+ "10.8" => ['xnu-2050.7.9.tar.gz', '9aaf1e0b0a148ff303577161fecaf3ea6188aa1b'],
+ "10.8.1" => ['xnu-2050.9.2.tar.gz', '2bd58959afc5ac8f2c9fa3d693882acc96b25321'],
+ "10.8.2" => ['xnu-2050.18.24.tar.gz', '3a2a0b3629cb215b17aca3bb365b8b10b8b408fe'],
+ "10.8.3" => ['xnu-2050.22.13.tar.gz', 'a002806d1e64505c6a98c10af26186454818a9ff'],
+ "10.8.4" => ['xnu-2050.24.15.tar.gz', 'a080f28b7385b0cc63f9ba5a07d922d53ea0a4a3'],
+ "10.8.5" => ['xnu-2050.48.11.tar.gz', '1f6860148f8231a53a6b393aa1af589cdedfc70c'],
+ "10.9" => ['xnu-2422.1.72.tar.gz', 'c7bdc40396df3c51ece934c0e3b4a19b063ea34c'],
+ }
+
+ if xnu_headers.key? osx_version
+ tarball, checksum = xnu_headers.fetch(osx_version)
+ resource 'xnu' do
+ url "http://www.opensource.apple.com/tarballs/xnu/#{tarball}"
+ sha1 checksum
+ end
end
def install