aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/ngspice.rb
blob: f5cd363a33d70d6a1de7028e17554d8623d16a1b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
require 'formula'

class Ngspice < Formula
  homepage 'http://ngspice.sourceforge.net/'
  url 'http://downloads.sourceforge.net/project/ngspice/ng-spice-rework/24/ngspice-24.tar.gz'
  md5 'e9ed7092da3e3005aebd892996b2bd5f'

  def options
    [["--without-xspice", "Build without x-spice extensions"]]
  end

  def install
    args = ["--disable-debug",
            "--disable-dependency-tracking",
            "--prefix=#{prefix}",
            "--with-editline=yes",
            "--enable-x"]
    args << "--enable-xspice" unless ARGV.include? "--without-xspice"

    system "./configure", *args
    system "make install"
  end

  def caveats;
    "Note: ngspice is an X11 application."
 end
end