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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.11 - (show annotations) (download)
Fri Feb 20 16:48:02 2015 UTC (4 years, 7 months ago) by grozin
Branch: MAIN
CVS Tags: HEAD
Changes since 1.10: +1 -1 lines
FILE REMOVED
Cleaning old (#540808)

(Portage version: 2.2.17/cvs/Linux i686, signed Manifest commit with key 0x3AFFCE974D34BD8C!)

1 # Copyright 1999-2014 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-r1.ebuild,v 1.10 2014/12/28 15:36:16 titanofold Exp $
4
5 EAPI=1
6 inherit flag-o-matic eutils toolchain-funcs multilib
7
8 DESCRIPTION="A portable, bytecode-compiled implementation of Common Lisp"
9 HOMEPAGE="http://clisp.sourceforge.net/"
10 SRC_URI="mirror://sourceforge/clisp/${P}.tar.bz2"
11 LICENSE="GPL-2"
12
13 # EAPI="1"
14 SLOT="2"
15 KEYWORDS="alpha amd64 ia64 ppc -sparc x86"
16 IUSE="hyperspec X new-clx dbus fastcgi gdbm gtk pari pcre postgres readline svm zlib"
17
18 RDEPEND="virtual/libiconv
19 >=dev-libs/libsigsegv-2.4
20 >=dev-libs/ffcall-1.10
21 dbus? ( sys-apps/dbus )
22 fastcgi? ( dev-libs/fcgi )
23 gdbm? ( sys-libs/gdbm )
24 gtk? ( >=x11-libs/gtk+-2.10:2 >=gnome-base/libglade-2.6:2.0 )
25 pari? ( >=sci-mathematics/pari-2.3.0 )
26 postgres? ( >=dev-db/postgresql-8.0 )
27 readline? ( >=sys-libs/readline-5.0 )
28 pcre? ( dev-libs/libpcre )
29 svm? ( sci-libs/libsvm )
30 zlib? ( sys-libs/zlib )
31 X? ( new-clx? ( x11-libs/libXpm ) )
32 hyperspec? ( dev-lisp/hyperspec )"
33 # berkdb? ( sys-libs/db:4.5 )
34
35 DEPEND="${RDEPEND} X? ( new-clx? ( x11-misc/imake x11-proto/xextproto ) )"
36
37 PDEPEND="dev-lisp/gentoo-init"
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 epatch "${FILESDIR}"/pari.patch #bug 246074
61
62 # More than -O1 breaks alpha/ia64
63 use alpha || use ia64 && sed -i -e 's/-O2//g' src/makemake.in
64 }
65
66 src_compile() {
67 # built-in features
68 local myconf="--with-ffcall --with-dynamic-modules"
69 use readline || myconf="${myconf} --with-noreadline"
70
71 # We need this to build on alpha/ia64
72 if use alpha || use ia64; then
73 replace-flags -O? -O1
74 append-flags '-D NO_MULTIMAP_SHM -D NO_MULTIMAP_FILE -D NO_SINGLEMAP -D NO_TRIVIALMAP'
75 fi
76 # default modules
77 enable_modules wildcard rawsock
78 # optional modules
79 use elibc_glibc && enable_modules bindings/glibc
80 if use X; then
81 if use new-clx; then
82 enable_modules clx/new-clx
83 else
84 enable_modules clx/mit-clx
85 fi
86 fi
87 if use postgres; then
88 enable_modules postgresql
89 CPPFLAGS="-I $(pg_config --includedir)"
90 fi
91 # if use berkdb; then
92 # enable_modules berkley-db
93 # CPPFLAGS="${CPPFLAGS} -I /usr/include/db4.5"
94 # fi
95 use dbus && enable_modules dbus
96 use fastcgi && enable_modules fastcgi
97 use gdbm && enable_modules gdbm
98 use gtk && enable_modules gtk2
99 use pari && enable_modules pari
100 use pcre && enable_modules pcre
101 use svm && enable_modules libsvm
102 use zlib && enable_modules zlib
103
104 if use hyperspec; then
105 CLHSROOT="file:///usr/share/doc/hyperspec/HyperSpec/"
106 else
107 CLHSROOT="http://www.lispworks.com/reference/HyperSpec/"
108 fi
109
110 # configure chokes on --infodir option
111 local configure="./configure --prefix=/usr --libdir=/usr/$(get_libdir) \
112 ${myconf} --hyperspec=${CLHSROOT} ${BUILDDIR}"
113 einfo "${configure}"
114 ${configure} || die "./configure failed"
115
116 cd ${BUILDDIR}
117 sed -i 's,"vi","nano",g' config.lisp
118 IMPNOTES="file://${ROOT%/}/usr/share/doc/${PN}-${PVR}/html/impnotes.html"
119 sed -i "s,http://clisp.cons.org/impnotes/,${IMPNOTES},g" config.lisp
120 # parallel build fails
121 emake -j1 || die "emake failed"
122 }
123
124 src_install() {
125 pushd ${BUILDDIR}
126 make DESTDIR="${D}" prefix=/usr install-bin || die
127 doman clisp.1
128 dodoc SUMMARY README* NEWS MAGIC.add ANNOUNCE clisp.dvi clisp.html
129 chmod a+x "${D}"/usr/$(get_libdir)/clisp-${PV/_*/}/clisp-link
130 # stripping them removes common symbols (defined but unitialised variables)
131 # which are then needed to build modules...
132 export STRIP_MASK="*/usr/$(get_libdir)/clisp-${PV}/*/*"
133 popd
134 dohtml doc/impnotes.{css,html} doc/regexp.html doc/clisp.png
135 dodoc doc/{editors,CLOS-guide,LISP-tutorial}.txt
136 }

  ViewVC Help
Powered by ViewVC 1.1.20