gnu-smalltalk: use opt_lib
This commit is contained in:
parent
de89153540
commit
38b870b320
1 changed files with 33 additions and 33 deletions
|
@ -1,35 +1,36 @@
|
|||
require 'formula'
|
||||
|
||||
class GnuSmalltalk < Formula
|
||||
desc "GNU Smalltalk interpreter and image"
|
||||
homepage 'http://smalltalk.gnu.org/'
|
||||
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'
|
||||
homepage "http://smalltalk.gnu.org/"
|
||||
url "http://ftpmirror.gnu.org/smalltalk/smalltalk-3.2.5.tar.xz"
|
||||
mirror "https://ftp.gnu.org/gnu/smalltalk/smalltalk-3.2.5.tar.xz"
|
||||
sha256 "819a15f7ba8a1b55f5f60b9c9a58badd6f6153b3f987b70e7b167e7755d65acc"
|
||||
revision 1
|
||||
|
||||
head "https://github.com/bonzini/smalltalk.git"
|
||||
|
||||
devel do
|
||||
url 'ftp://alpha.gnu.org/gnu/smalltalk/smalltalk-3.2.90.tar.gz'
|
||||
sha1 'dd8bba5702591f0d5e2676878e1b3ee48f0ff37f'
|
||||
url "ftp://alpha.gnu.org/gnu/smalltalk/smalltalk-3.2.90.tar.gz"
|
||||
mirror "https://www.mirrorservice.org/sites/alpha.gnu.org/gnu/smalltalk/smalltalk-3.2.90.tar.gz"
|
||||
sha256 "aa6cab17841f999c9217cdccd185a74e42fc6a7fc17139120dad8815bdff137c"
|
||||
end
|
||||
|
||||
head 'https://github.com/bonzini/smalltalk.git'
|
||||
option "with-tests", "Verify the build with make check (this may hang)"
|
||||
option "with-tcltk", "Build the Tcl/Tk module that requires X11"
|
||||
|
||||
option 'tests', 'Verify the build with make check (this may hang)'
|
||||
option 'tcltk', 'Build the Tcl/Tk module that requires X11'
|
||||
deprecated_option "tests" => "with-tests"
|
||||
deprecated_option "tcltk" => "with-tcltk"
|
||||
|
||||
depends_on 'autoconf' => :build
|
||||
depends_on 'automake' => :build
|
||||
depends_on 'libtool' => :build
|
||||
|
||||
depends_on 'pkg-config' => :build
|
||||
depends_on 'gawk' => :build
|
||||
depends_on 'readline' => :build
|
||||
depends_on 'libffi' => :recommended
|
||||
depends_on 'libsigsegv' => :recommended
|
||||
depends_on 'glew' => :optional
|
||||
depends_on :x11 if build.include? 'tcltk'
|
||||
depends_on 'gnutls'
|
||||
depends_on "autoconf" => :build
|
||||
depends_on "automake" => :build
|
||||
depends_on "libtool" => :run
|
||||
depends_on "pkg-config" => :build
|
||||
depends_on "gawk" => :build
|
||||
depends_on "readline"
|
||||
depends_on "gnutls"
|
||||
depends_on "libffi" => :recommended
|
||||
depends_on "libsigsegv" => :recommended
|
||||
depends_on "glew" => :optional
|
||||
depends_on :x11 if build.with? "tcltk"
|
||||
|
||||
fails_with :llvm do
|
||||
build 2334
|
||||
|
@ -44,30 +45,29 @@ class GnuSmalltalk < Formula
|
|||
--disable-dependency-tracking
|
||||
--prefix=#{prefix}
|
||||
--disable-gtk
|
||||
--with-readline=#{Formula['readline'].lib}
|
||||
--with-readline=#{Formula["readline"].opt_lib}
|
||||
]
|
||||
unless build.include? 'tcltk'
|
||||
args << '--without-tcl' << '--without-tk' << '--without-x'
|
||||
|
||||
if build.without? "tcltk"
|
||||
args << "--without-tcl" << "--without-tk" << "--without-x"
|
||||
end
|
||||
|
||||
# disable generational gc in 32-bit and if libsigsegv is absent
|
||||
if !MacOS.prefer_64_bit? or build.without? "libsigsegv"
|
||||
if !MacOS.prefer_64_bit? || build.without?("libsigsegv")
|
||||
args << "--disable-generational-gc"
|
||||
end
|
||||
|
||||
system 'autoreconf', '-ivf'
|
||||
system "autoreconf", "-ivf"
|
||||
system "./configure", *args
|
||||
system "make"
|
||||
system 'make', '-j1', 'check' if build.include? 'tests'
|
||||
system "make install"
|
||||
system "make", "-j1", "check" if build.with? "tests"
|
||||
system "make", "install"
|
||||
end
|
||||
|
||||
test do
|
||||
path = testpath/"test.gst"
|
||||
path.write "0 to: 9 do: [ :n | n display ]\n"
|
||||
|
||||
output = `#{bin}/gst #{path}`.strip
|
||||
assert_equal "0123456789", output
|
||||
assert_equal 0, $?.exitstatus
|
||||
assert_match /0123456789/, shell_output("#{bin}/gst #{path}")
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue