Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 77 lines (61 sloc) 2.452 kB
fdf6094 @tianyicui New formula: clisp
tianyicui authored
1 require 'formula'
2
0476235 @adamv Use ruby style for inheritance.
adamv authored
3 class Clisp < Formula
41b6985 @adamv clisp: update homepage
adamv authored
4 homepage 'http://www.clisp.org/'
d0dfc22 @jacknagel Use automatic mirror selection for GNU downloads
jacknagel authored
5 url 'http://ftpmirror.gnu.org/clisp/release/2.49/clisp-2.49.tar.bz2'
164c57f @jacknagel Add mirrors for GNU formulae
jacknagel authored
6 mirror 'http://ftp.gnu.org/gnu/clisp/release/2.49/clisp-2.49.tar.bz2'
41b6985 @adamv clisp: update homepage
adamv authored
7 sha1 '7e8d585ef8d0d6349ffe581d1ac08681e6e670d4'
fdf6094 @tianyicui New formula: clisp
tianyicui authored
8
9 depends_on 'libsigsegv'
10 depends_on 'readline'
11
12 skip_clean :all # otherwise abort trap
13
497b13a @jacknagel Use new fails_with DSL syntax
jacknagel authored
14 fails_with :llvm do
15 build 2334
16 cause "Configure fails on XCode 4/Snow Leopard."
17 end
32d8ed4 @jacknagel clisp: fix LLVM builds
jacknagel authored
18
19 def patches
ee2c3ab @camillol Remove spurious libiconv dependencies
camillol authored
20 { :p0 => "https://trac.macports.org/export/89054/trunk/dports/lang/clisp/files/patch-src_lispbibl_d.diff",
21 :p1 => DATA }
32d8ed4 @jacknagel clisp: fix LLVM builds
jacknagel authored
22 end
fdf6094 @tianyicui New formula: clisp
tianyicui authored
23
f4a925d @adamv Update fails_with_llvm in formulae
adamv authored
24 def install
25 ENV.j1 # This build isn't parallel safe.
ee35378 @nesv clisp: turn off optimization
nesv authored
26 ENV.remove_from_cflags /-O./
8e00ca8 @adamv clisp: does not compile with llvm
adamv authored
27
fdf6094 @tianyicui New formula: clisp
tianyicui authored
28 # Clisp requires to select word size explicitly this way,
29 # set it in CFLAGS won't work.
46c553a @adamv Replace snow_leopard_64? in brews.
adamv authored
30 ENV['CC'] = "#{ENV.cc} -m#{MacOS.prefer_64_bit? ? 64 : 32}"
fdf6094 @tianyicui New formula: clisp
tianyicui authored
31
32 system "./configure", "--prefix=#{prefix}",
33 "--with-readline=yes"
34
35 cd "src" do
36 # Multiple -O options will be in the generated Makefile,
37 # make Homebrew's the last such option so it's effective.
38 inreplace "Makefile" do |s|
b41ba21 @mxcl Fixes #14571; clisp superenv issue
mxcl authored
39 s.change_make_var! 'CFLAGS', "#{s.get_make_var('CFLAGS')} #{ENV['CFLAGS']}"
fdf6094 @tianyicui New formula: clisp
tianyicui authored
40 end
41
42 # The ulimit must be set, otherwise `make` will fail and tell you to do so
43 system "ulimit -s 16384 && make"
44
6b8d25f @jacknagel Clean up MacOS version method usage
jacknagel authored
45 if MacOS.version >= :lion
f31ba22 @adamv clisp: disable self-check on Lion
adamv authored
46 opoo "`make check` fails on Lion, so we are skipping it."
47 puts "But it probably means there will be other issues too."
48 puts "Please take them upstream to the clisp project itself."
49 else
50 # Considering the complexity of this package, a self-check is highly recommended.
51 system "make check"
52 end
53
fdf6094 @tianyicui New formula: clisp
tianyicui authored
54 system "make install"
55 end
56 end
57
58 def test
8022bf4 @jacknagel Fix more quoting issues
jacknagel authored
59 system "#{bin}/clisp", "--version"
fdf6094 @tianyicui New formula: clisp
tianyicui authored
60 end
61 end
ee2c3ab @camillol Remove spurious libiconv dependencies
camillol authored
62
63 __END__
64 diff --git a/src/stream.d b/src/stream.d
65 index 5345ed6..cf14e29 100644
66 --- a/src/stream.d
67 +++ b/src/stream.d
68 @@ -3994,7 +3994,7 @@ global object iconv_range (object encoding, uintL start, uintL end, uintL maxint
69 nonreturning_function(extern, error_unencodable, (object encoding, chart ch));
70
71 /* Avoid annoying warning caused by a wrongly standardized iconv() prototype. */
72 -#ifdef GNU_LIBICONV
73 +#if defined(GNU_LIBICONV) && !defined(__APPLE_CC__)
74 #undef iconv
75 #define iconv(cd,inbuf,inbytesleft,outbuf,outbytesleft) \
76 libiconv(cd,(ICONV_CONST char **)(inbuf),inbytesleft,outbuf,outbytesleft)
Something went wrong with that request. Please try again.