2013-10-28 07:03:12 +00:00
|
|
|
require 'formula'
|
|
|
|
|
|
|
|
class Capnp < Formula
|
|
|
|
homepage 'http://kentonv.github.io/capnproto/'
|
2014-01-14 07:11:04 +00:00
|
|
|
url 'http://capnproto.org/capnproto-c++-0.4.0.tar.gz'
|
|
|
|
sha1 '1d356a0229a9c6b3665930a4b166b91cba03825b'
|
2013-10-28 07:03:12 +00:00
|
|
|
|
2014-02-17 19:49:42 +00:00
|
|
|
# TODO add fails_with statements for FSF GCC
|
2013-10-28 07:03:12 +00:00
|
|
|
fails_with :gcc do
|
|
|
|
cause "Cap'n Proto requires C++11 support"
|
|
|
|
end
|
|
|
|
|
2014-02-17 19:49:42 +00:00
|
|
|
fails_with :gcc_4_0 do
|
2013-10-28 07:03:12 +00:00
|
|
|
cause "Cap'n Proto requires C++11 support"
|
|
|
|
end
|
|
|
|
|
|
|
|
fails_with :clang do
|
|
|
|
build 425
|
|
|
|
cause "Clang 3.2 or newer is required to build Cap'n Proto"
|
|
|
|
end
|
|
|
|
|
|
|
|
fails_with :llvm do
|
|
|
|
cause "Cap'n Proto requires C++11 support"
|
|
|
|
end
|
|
|
|
|
|
|
|
def install
|
|
|
|
system "./configure", "--disable-debug",
|
|
|
|
"--disable-dependency-tracking",
|
|
|
|
"--disable-silent-rules",
|
|
|
|
"--prefix=#{prefix}"
|
|
|
|
system "make", "check"
|
|
|
|
system "make", "install"
|
|
|
|
end
|
|
|
|
|
|
|
|
test do
|
|
|
|
system "#{bin}/capnp", "--version"
|
|
|
|
end
|
|
|
|
end
|