2009-10-15 08:07:12 +00:00
|
|
|
require 'formula'
|
2009-09-19 09:35:43 +00:00
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class GnuSmalltalk < Formula
|
2011-10-10 02:56:01 +00:00
|
|
|
homepage 'http://smalltalk.gnu.org/'
|
2013-05-21 23:36:28 +00:00
|
|
|
url 'http://ftpmirror.gnu.org/smalltalk/smalltalk-3.2.5.tar.xz'
|
|
|
|
mirror 'http://ftp.gnu.org/gnu/smalltalk/smalltalk-3.2.5.tar.xz'
|
|
|
|
sha1 '0eb5895b9b5bebe4f75308efbe34f8721fc2fd6b'
|
2009-09-19 09:35:43 +00:00
|
|
|
|
2013-05-26 19:19:39 +00:00
|
|
|
devel do
|
|
|
|
url 'ftp://alpha.gnu.org/gnu/smalltalk/smalltalk-3.2.90.tar.gz'
|
|
|
|
sha1 'dd8bba5702591f0d5e2676878e1b3ee48f0ff37f'
|
|
|
|
end
|
|
|
|
|
2011-10-10 02:56:01 +00:00
|
|
|
head 'https://github.com/bonzini/smalltalk.git'
|
2009-09-19 09:35:43 +00:00
|
|
|
|
2012-10-15 16:04:42 +00:00
|
|
|
option 'tests', 'Verify the build with make check (this may hang)'
|
|
|
|
option 'tcltk', 'Build the Tcl/Tk module that requires X11'
|
|
|
|
|
|
|
|
# Need newer versions on Snow Leopard
|
|
|
|
depends_on 'automake' => :build
|
|
|
|
depends_on 'libtool' => :build
|
2012-07-07 18:08:22 +00:00
|
|
|
|
2011-10-10 02:56:01 +00:00
|
|
|
depends_on 'pkg-config' => :build
|
2012-10-15 16:04:42 +00:00
|
|
|
depends_on 'xz' => :build
|
|
|
|
depends_on 'gawk' => :build
|
2012-11-11 03:12:26 +00:00
|
|
|
depends_on 'readline' => :build
|
2012-10-15 16:04:42 +00:00
|
|
|
depends_on 'libffi' => :recommended
|
|
|
|
depends_on 'libsigsegv' => :recommended
|
|
|
|
depends_on 'glew' => :optional
|
|
|
|
depends_on :x11 if build.include? 'tcltk'
|
2013-05-26 20:29:45 +00:00
|
|
|
depends_on 'gnutls'
|
2010-12-05 02:25:19 +00:00
|
|
|
|
2012-03-18 20:33:24 +00:00
|
|
|
fails_with :llvm do
|
|
|
|
build 2334
|
|
|
|
cause "Codegen problems with LLVM"
|
|
|
|
end
|
2010-05-03 17:40:24 +00:00
|
|
|
|
2011-10-10 02:56:01 +00:00
|
|
|
def install
|
2012-10-15 16:04:42 +00:00
|
|
|
ENV.m32 unless MacOS.prefer_64_bit?
|
|
|
|
|
|
|
|
args = %W[
|
|
|
|
--disable-debug
|
|
|
|
--disable-dependency-tracking
|
|
|
|
--prefix=#{prefix}
|
|
|
|
--disable-gtk
|
2012-11-11 03:12:26 +00:00
|
|
|
--with-readline=#{Formula.factory('readline').lib}
|
2012-10-15 16:04:42 +00:00
|
|
|
]
|
|
|
|
unless build.include? 'tcltk'
|
|
|
|
args << '--without-tcl' << '--without-tk' << '--without-x'
|
2011-10-10 02:56:01 +00:00
|
|
|
end
|
|
|
|
|
2013-02-04 17:34:12 +00:00
|
|
|
# disable generational gc in 32-bit and if libsigsegv is absent
|
|
|
|
if !MacOS.prefer_64_bit? or build.without? "libsigsegv"
|
|
|
|
args << "--disable-generational-gc"
|
|
|
|
end
|
2011-10-10 02:56:01 +00:00
|
|
|
|
2012-10-15 16:04:42 +00:00
|
|
|
system 'autoreconf', '-ivf'
|
2011-10-10 02:56:01 +00:00
|
|
|
system "./configure", *args
|
2009-12-03 07:07:11 +00:00
|
|
|
system "make"
|
2012-10-15 16:04:42 +00:00
|
|
|
system 'make', '-j1', 'check' if build.include? 'tests'
|
2009-09-19 09:35:43 +00:00
|
|
|
system "make install"
|
|
|
|
end
|
|
|
|
end
|