2012-02-15 19:04:45 +00:00
|
|
|
class Bup < Formula
|
2014-07-21 02:22:28 +00:00
|
|
|
homepage "https://github.com/bup/bup"
|
2014-12-03 22:44:40 +00:00
|
|
|
head "https://github.com/bup/bup.git"
|
2014-12-16 12:29:32 +00:00
|
|
|
|
2015-03-09 04:59:14 +00:00
|
|
|
stable do
|
|
|
|
url "https://github.com/bup/bup/archive/0.26.tar.gz"
|
|
|
|
sha256 "8c25551fa723cfe5dcaaa671c5f0964d8caff22b068923df007a13169d8f015c"
|
2012-02-15 19:04:45 +00:00
|
|
|
|
2015-03-09 04:59:14 +00:00
|
|
|
# Fix compilation on 10.10
|
|
|
|
patch do
|
|
|
|
url "https://github.com/bup/bup/commit/75d089e7cdb7a7eb4d69c352f56dad5ad3aa1f97.diff"
|
|
|
|
sha256 "9a4615e91b7b2f43e5447e30aa4096f1b0bf65dc2081e7c08d852830ee217716"
|
|
|
|
end
|
2014-10-12 19:31:28 +00:00
|
|
|
end
|
|
|
|
|
2015-03-09 04:59:14 +00:00
|
|
|
option "with-tests", "Run unit tests after compilation"
|
|
|
|
option "with-pandoc", "Build and install the manpages"
|
|
|
|
|
|
|
|
deprecated_option "run-tests" => "with-tests"
|
|
|
|
|
|
|
|
depends_on "pandoc" => [:optional, :build]
|
|
|
|
|
2012-02-15 19:04:45 +00:00
|
|
|
def install
|
2014-01-04 13:02:46 +00:00
|
|
|
system "make"
|
2015-03-09 04:59:14 +00:00
|
|
|
system "make", "test" if build.with? "tests"
|
2013-11-17 20:19:59 +00:00
|
|
|
system "make", "install", "DESTDIR=#{prefix}", "PREFIX="
|
2012-02-15 19:04:45 +00:00
|
|
|
end
|
2015-03-09 04:59:14 +00:00
|
|
|
|
|
|
|
test do
|
|
|
|
system bin/"bup", "init"
|
|
|
|
assert File.exist?("#{testpath}/.bup")
|
|
|
|
end
|
2012-02-15 19:04:45 +00:00
|
|
|
end
|