2013-03-27 19:12:57 +00:00
|
|
|
class Libtar < Formula
|
2015-05-19 00:00:59 +00:00
|
|
|
desc "C library for manipulating POSIX tar files"
|
2015-06-15 19:50:33 +00:00
|
|
|
homepage "http://repo.or.cz/w/libtar.git"
|
|
|
|
url "http://repo.or.cz/libtar.git",
|
|
|
|
:tag => "v1.2.20",
|
|
|
|
:revision => "0907a9034eaf2a57e8e4a9439f793f3f05d446cd"
|
2014-03-14 07:19:01 +00:00
|
|
|
|
2014-03-20 19:05:10 +00:00
|
|
|
bottle do
|
|
|
|
cellar :any
|
2015-06-15 21:14:24 +00:00
|
|
|
revision 2
|
2015-09-24 05:04:49 +00:00
|
|
|
sha256 "018f1c9897f52b783878db67db39a5933a4863a3f9dedc2af9b6bf13f2161957" => :el_capitan
|
2015-06-15 21:14:24 +00:00
|
|
|
sha256 "d8d138fb4c1cf8c33aaaf8633cd748e9a423e84f1df886ae1842d4816b1f34a0" => :yosemite
|
|
|
|
sha256 "b8eb40cc1715243eb0ff85eddd2a5f5546e19ca7278ce30b08bd8e1bd3f0682f" => :mavericks
|
|
|
|
sha256 "7e79320f86f0fc61f80a041e48aafacc9148403b124dd0543b78c84bdf1b3384" => :mountain_lion
|
2014-03-20 19:05:10 +00:00
|
|
|
end
|
|
|
|
|
2015-06-15 19:50:33 +00:00
|
|
|
depends_on "autoconf" => :build
|
|
|
|
depends_on "automake" => :build
|
|
|
|
depends_on "libtool" => :build
|
2013-03-27 19:12:57 +00:00
|
|
|
|
|
|
|
def install
|
2014-03-14 07:19:01 +00:00
|
|
|
system "autoreconf", "--force", "--install"
|
2013-03-27 19:12:57 +00:00
|
|
|
system "./configure", "--disable-debug",
|
|
|
|
"--disable-dependency-tracking",
|
|
|
|
"--prefix=#{prefix}",
|
|
|
|
"--mandir=#{man}"
|
2014-03-14 07:19:01 +00:00
|
|
|
system "make", "install"
|
2013-03-27 19:12:57 +00:00
|
|
|
end
|
2015-06-15 19:50:33 +00:00
|
|
|
|
|
|
|
test do
|
|
|
|
(testpath/"homebrew.txt").write "This is a simple example"
|
|
|
|
system "tar", "-cvf", "test.tar", "homebrew.txt"
|
|
|
|
rm "homebrew.txt"
|
|
|
|
assert !File.exist?("homebrew.txt")
|
|
|
|
assert File.exist?("test.tar")
|
|
|
|
|
|
|
|
system bin/"libtar", "-x", "test.tar"
|
|
|
|
assert File.exist?("homebrew.txt")
|
|
|
|
end
|
2013-03-27 19:12:57 +00:00
|
|
|
end
|