homebrew-core/Formula/ngspice.rb
Victor Martinez 8dc451e3e2 Fixed several broken sourceforge.net download locations
Closes Homebrew/homebrew#20645.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2013-06-30 12:17:57 -07:00

29 lines
773 B
Ruby

require 'formula'
class Ngspice < Formula
homepage 'http://ngspice.sourceforge.net/'
url 'http://downloads.sourceforge.net/project/ngspice/ng-spice-rework/25/ngspice-25.tar.gz'
sha1 '745c3c32385b7d5c808836e393fe7699f8568860'
option "with-x", "Build with X support"
option "without-xspice", "Build without x-spice extensions"
depends_on :x11 if MacOS::X11.installed? or build.include? "with-x"
def install
args = %W[
--disable-dependency-tracking
--prefix=#{prefix}
--with-editline=yes
]
args << "--enable-x" if build.include? "with-x"
args << "--enable-xspice" unless build.include? "without-xspice"
system "./configure", *args
system "make install"
end
def test
system "#{bin}/ngspice", "-v"
end
end