2011-03-10 05:11:03 +00:00
|
|
|
class Cabextract < Formula
|
2015-05-19 00:00:59 +00:00
|
|
|
desc "Extract files from Microsoft cabinet files"
|
2014-11-28 21:37:18 +00:00
|
|
|
homepage "http://www.cabextract.org.uk/"
|
2015-04-24 11:04:19 +00:00
|
|
|
url "http://www.cabextract.org.uk/cabextract-1.6.tar.gz"
|
|
|
|
sha256 "cee661b56555350d26943c5e127fc75dd290b7f75689d5ebc1f04957c4af55fb"
|
2009-11-30 01:29:40 +00:00
|
|
|
|
2014-11-28 22:15:00 +00:00
|
|
|
bottle do
|
|
|
|
cellar :any
|
2015-04-24 11:12:15 +00:00
|
|
|
sha256 "e86f3dda55d8cbba0602abacbf67d09a1b733d4fe6db761938f8a3416f1cf5a8" => :yosemite
|
|
|
|
sha256 "f71f87d6bbb877207ad984d8ad4bd68c7f50ae0305178583c968847cb57f6179" => :mavericks
|
|
|
|
sha256 "464d4ede11b2be5ecf25244193e901d9d08c1d0daf254204703e054405e41603" => :mountain_lion
|
2014-11-28 22:15:00 +00:00
|
|
|
end
|
|
|
|
|
2009-11-30 01:29:40 +00:00
|
|
|
def install
|
2012-01-26 06:00:57 +00:00
|
|
|
system "./configure", "--disable-dependency-tracking",
|
2015-02-05 22:30:47 +00:00
|
|
|
"--disable-silent-rules",
|
2014-11-28 21:37:18 +00:00
|
|
|
"--prefix=#{prefix}"
|
|
|
|
system "make", "install"
|
2009-11-30 01:29:40 +00:00
|
|
|
end
|
2015-01-18 18:49:29 +00:00
|
|
|
|
|
|
|
test do
|
|
|
|
# probably the smallest valid .cab file
|
|
|
|
cab = <<-EOS.gsub(/\s+/, "")
|
|
|
|
4d5343460000000046000000000000002c000000000000000301010001000000d20400003
|
|
|
|
e00000001000000000000000000000000003246899d200061000000000000000000
|
|
|
|
EOS
|
|
|
|
(testpath/"test.cab").binwrite [cab].pack("H*")
|
|
|
|
|
|
|
|
system "#{bin}/cabextract", "test.cab"
|
|
|
|
assert File.exist? "a"
|
|
|
|
end
|
2009-11-30 01:29:40 +00:00
|
|
|
end
|