homebrew-core/Formula/cloog.rb
Xiyue Deng 5e1ae81c5f New formula: isl
* Make cloog build using external isl.
  - Needed by newer GCC for which the bundled isl in cloog 0.17.0 is
    too old.
* Improve cloog test case indentation.

Closes Homebrew/homebrew#15862.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-12-04 21:30:59 -06:00

44 lines
801 B
Ruby

require 'formula'
class Cloog < Formula
homepage 'http://www.cloog.org/'
url 'http://www.bastoul.net/cloog/pages/download/count.php3?url=./cloog-0.17.0.tar.gz'
sha1 'decc2221b1f1bd9238288d043835cb018af15d5a'
depends_on 'pkg-config' => :build
depends_on 'gmp'
depends_on 'isl'
def install
args = [
"--disable-dependency-tracking",
"--prefix=#{prefix}",
"--with-isl-prefix=#{Formula.factory('isl').opt_prefix}"
]
system "./configure", *args
system "make install"
end
def test
cloog_source = <<-EOS.undent
c
0 2
0
1
1
0 2
0 0 0
0
0
EOS
pipe = IO.popen("cloog /dev/stdin", "w+")
pipe.write(cloog_source)
pipe.read =~ /Generated\ from \/dev\/stdin\ by\ CLooG/
end
end