/[gentoo-x86]/dev-lisp/clisp/clisp-2.47.ebuild
Gentoo

Contents of /dev-lisp/clisp/clisp-2.47.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations) (download)
Wed Jul 29 11:32:46 2009 UTC (10 years, 2 months ago) by hkbst
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +1 -1 lines
FILE REMOVED
remove old versions
(Portage version: 2.1.6.13/cvs/Linux x86_64)

1 # Copyright 1999-2009 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/dev-lisp/clisp/clisp-2.47.ebuild,v 1.2 2009/01/05 21:44:03 maekke Exp $
4
5 inherit flag-o-matic eutils toolchain-funcs multilib
6
7 DESCRIPTION="A portable, bytecode-compiled implementation of Common Lisp"
8 HOMEPAGE="http://clisp.sourceforge.net/"
9 SRC_URI="mirror://sourceforge/clisp/${P}.tar.bz2"
10 LICENSE="GPL-2"
11
12 # EAPI="1"
13 SLOT="2"
14 KEYWORDS="~alpha amd64 ~ia64 ~ppc -sparc x86"
15 IUSE="hyperspec X new-clx fastcgi gdbm gtk pari pcre postgres readline svm zlib"
16
17 RDEPEND="virtual/libiconv
18 >=dev-libs/libsigsegv-2.4
19 >=dev-libs/ffcall-1.10
20 fastcgi? ( dev-libs/fcgi )
21 gdbm? ( sys-libs/gdbm )
22 gtk? ( >=x11-libs/gtk+-2.10 >=gnome-base/libglade-2.6 )
23 pari? ( >=sci-mathematics/pari-2.3.0 )
24 postgres? ( >=virtual/postgresql-server-8.0 )
25 readline? ( sys-libs/readline )
26 pcre? ( dev-libs/libpcre )
27 svm? ( sci-libs/libsvm )
28 zlib? ( sys-libs/zlib )
29 X? ( new-clx? ( x11-libs/libXpm ) )
30 hyperspec? ( dev-lisp/hyperspec )"
31 # berkdb? ( sys-libs/db:4.5 )
32
33 DEPEND="${RDEPEND} X? ( new-clx? ( x11-misc/imake x11-proto/xextproto ) )"
34
35 PDEPEND="dev-lisp/gentoo-init"
36
37 PROVIDE="virtual/commonlisp"
38
39 enable_modules() {
40 [[ $# = 0 ]] && die "${FUNCNAME[0]} must receive at least one argument"
41 for m in "$@" ; do
42 einfo "enabling module $m"
43 myconf="${myconf} --with-module=${m}"
44 done
45 }
46
47 BUILDDIR="builddir"
48
49 # modules not enabled:
50 # * berkdb: must figure out a way to make the configure script pick up the
51 # currect version of the library and headers
52 # * dirkey: fails to compile, requiring windows.h, possibly wrong #ifdefs
53 # * matlab, netica: not in portage
54 # * oracle: can't install oracle-instantclient
55
56 src_unpack() {
57 unpack ${A}
58 cd "${S}"
59
60 # More than -O1 breaks alpha/ia64
61 use alpha || use ia64 && sed -i -e 's/-O2//g' src/makemake.in
62 }
63
64 src_compile() {
65 # built-in features
66 local myconf="--with-ffcall --with-dynamic-modules"
67 use readline || myconf="${myconf} --with-noreadline"
68
69 # We need this to build on alpha/ia64
70 if use alpha || use ia64; then
71 replace-flags -O? -O1
72 append-flags '-D NO_MULTIMAP_SHM -D NO_MULTIMAP_FILE -D NO_SINGLEMAP -D NO_TRIVIALMAP'
73 fi
74 # default modules
75 enable_modules wildcard rawsock
76 # optional modules
77 use elibc_glibc && enable_modules bindings/glibc
78 if use X; then
79 if use new-clx; then
80 enable_modules clx/new-clx
81 else
82 enable_modules clx/mit-clx
83 fi
84 fi
85 if use postgres; then
86 enable_modules postgresql
87 CPPFLAGS="-I $(pg_config --includedir)"
88 fi
89 # if use berkdb; then
90 # enable_modules berkley-db
91 # CPPFLAGS="${CPPFLAGS} -I /usr/include/db4.5"
92 # fi
93 use fastcgi && enable_modules fastcgi
94 use gdbm && enable_modules gdbm
95 use gtk && enable_modules gtk2
96 use pari && enable_modules pari
97 use pcre && enable_modules pcre
98 use svm && enable_modules libsvm
99 use zlib && enable_modules zlib
100
101 if use hyperspec; then
102 CLHSROOT="file:///usr/share/doc/hyperspec/HyperSpec/"
103 else
104 CLHSROOT="http://www.lispworks.com/reference/HyperSpec/"
105 fi
106
107 # configure chokes on --infodir option
108 ./configure --prefix=/usr --libdir=/usr/$(get_libdir) \
109 ${myconf} --hyperspec=${CLHSROOT} ${BUILDDIR} || die "./configure failed"
110 cd ${BUILDDIR}
111 sed -i 's,"vi","nano",g' config.lisp
112 IMPNOTES="file://${ROOT%/}/usr/share/doc/${PN}-${PVR}/html/impnotes.html"
113 sed -i "s,http://clisp.cons.org/impnotes/,${IMPNOTES},g" config.lisp
114 # parallel build fails
115 emake -j1 || die "emake failed"
116 }
117
118 src_install() {
119 pushd ${BUILDDIR}
120 make DESTDIR="${D}" prefix=/usr install-bin || die
121 doman clisp.1
122 dodoc SUMMARY README* NEWS MAGIC.add ANNOUNCE clisp.dvi clisp.html
123 chmod a+x "${D}"/usr/$(get_libdir)/clisp-${PV/_*/}/clisp-link
124 # stripping them removes common symbols (defined but unitialised variables)
125 # which are then needed to build modules...
126 export STRIP_MASK="*/usr/$(get_libdir)/clisp-${PV}/*/*"
127 popd
128 dohtml doc/impnotes.{css,html} ${BUILDDIR}/clisp.html doc/clisp.png
129 dodoc ${BUILDDIR}/clisp.ps doc/{editors,CLOS-guide,LISP-tutorial}.txt
130 }

  ViewVC Help
Powered by ViewVC 1.1.20