homebrew-core/Formula/isl.rb

58 lines
1.8 KiB
Ruby
Raw Normal View History

class Isl < Formula
desc "Integer Set Library for the polyhedral model"
2015-01-08 07:13:34 +00:00
homepage "http://freecode.com/projects/isl"
# Note: Always use tarball instead of git tag for stable version.
#
# Currently isl detects its version using source code directory name
# and update isl_version() function accordingly. All other names will
# result in isl_version() function returning "UNKNOWN" and hence break
# package detection.
2015-02-18 08:48:45 +00:00
url "http://isl.gforge.inria.fr/isl-0.14.1.tar.xz"
sha256 "8882c9e36549fc757efa267706a9af733bb8d7fe3905cbfde43e17a89eea4675"
2013-09-24 23:32:59 +00:00
bottle do
2013-12-05 07:02:39 +00:00
cellar :any
2015-05-19 17:29:30 +00:00
revision 3
sha256 "8f2930559c015c477a094e67f2f70aff8ef0fb37296432e95921569fa9080db9" => :yosemite
sha256 "835d04dc9d6be86f7480b31824522ece83895ec0ed78314caf900c4bfd5611fa" => :mavericks
sha256 "19f797f8031bd373bb13a61ceefd9d74ee74cca0af1790617020f8a951ae8ce2" => :mountain_lion
2013-09-24 23:32:59 +00:00
end
2013-09-20 15:15:56 +00:00
head do
2015-01-08 07:13:34 +00:00
url "http://repo.or.cz/r/isl.git"
2014-05-23 21:17:35 +00:00
depends_on "autoconf" => :build
depends_on "automake" => :build
depends_on "libtool" => :build
end
2015-01-08 07:13:34 +00:00
depends_on "gmp"
2013-09-20 15:15:56 +00:00
def install
system "./autogen.sh" if build.head?
system "./configure", "--disable-dependency-tracking",
"--disable-silent-rules",
"--prefix=#{prefix}",
"--with-gmp=system",
2014-02-25 06:59:23 +00:00
"--with-gmp-prefix=#{Formula["gmp"].opt_prefix}"
system "make"
system "make", "install"
(share/"gdb/auto-load").install Dir["#{lib}/*-gdb.py"]
end
test do
(testpath/"test.c").write <<-EOS.undent
#include <isl/ctx.h>
int main()
{
isl_ctx* ctx = isl_ctx_alloc();
isl_ctx_free(ctx);
return 0;
}
EOS
system ENV.cc, "test.c", "-lisl", "-o", "test"
system "./test"
end
end