Gentoo Archives: gentoo-commits

From: "Andrey Grozin (grozin)" <grozin@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in sci-mathematics/maxima: ChangeLog maxima-5.16.3.ebuild maxima-5.16.2.ebuild
Date: Tue, 26 Aug 2008 05:44:10
Message-Id: E1KXrLb-0001IF-7L@stork.gentoo.org
1 grozin 08/08/26 05:44:07
2
3 Modified: ChangeLog
4 Added: maxima-5.16.3.ebuild
5 Removed: maxima-5.16.2.ebuild
6 Log:
7 Version bump
8 (Portage version: 2.2_rc8/cvs/Linux 2.6.25-tuxonice-r1 i686)
9
10 Revision Changes Path
11 1.58 sci-mathematics/maxima/ChangeLog
12
13 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-mathematics/maxima/ChangeLog?rev=1.58&view=markup
14 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-mathematics/maxima/ChangeLog?rev=1.58&content-type=text/plain
15 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-mathematics/maxima/ChangeLog?r1=1.57&r2=1.58
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/sci-mathematics/maxima/ChangeLog,v
20 retrieving revision 1.57
21 retrieving revision 1.58
22 diff -u -r1.57 -r1.58
23 --- ChangeLog 19 Aug 2008 05:19:19 -0000 1.57
24 +++ ChangeLog 26 Aug 2008 05:44:06 -0000 1.58
25 @@ -1,6 +1,12 @@
26 # ChangeLog for sci-mathematics/maxima
27 # Copyright 2002-2008 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/sci-mathematics/maxima/ChangeLog,v 1.57 2008/08/19 05:19:19 grozin Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/sci-mathematics/maxima/ChangeLog,v 1.58 2008/08/26 05:44:06 grozin Exp $
30 +
31 +*maxima-5.16.3 (26 Aug 2008)
32 +
33 + 26 Aug 2008; Andrey Grozin <grozin@g.o> -maxima-5.16.2.ebuild,
34 + +maxima-5.16.3.ebuild:
35 + Version bump
36
37 *maxima-5.16.2 (19 Aug 2008)
38
39
40
41
42 1.1 sci-mathematics/maxima/maxima-5.16.3.ebuild
43
44 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-mathematics/maxima/maxima-5.16.3.ebuild?rev=1.1&view=markup
45 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-mathematics/maxima/maxima-5.16.3.ebuild?rev=1.1&content-type=text/plain
46
47 Index: maxima-5.16.3.ebuild
48 ===================================================================
49 # Copyright 1999-2008 Gentoo Foundation
50 # Distributed under the terms of the GNU General Public License v2
51 # $Header: /var/cvsroot/gentoo-x86/sci-mathematics/maxima/maxima-5.16.3.ebuild,v 1.1 2008/08/26 05:44:06 grozin Exp $
52 inherit eutils elisp-common
53
54 DESCRIPTION="Free computer algebra environment based on Macsyma"
55 HOMEPAGE="http://maxima.sourceforge.net/"
56 SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
57
58 LICENSE="GPL-2 AECA"
59 SLOT="0"
60 KEYWORDS="~amd64 ~sparc ~x86"
61
62 # Supported lisps with readline
63 SUPP_RL="gcl clisp"
64 # Supported lisps without readline
65 SUPP_NORL="cmucl sbcl"
66 SUPP_LISPS="${SUPP_RL} ${SUPP_NORL}"
67 # Default lisp if none selected
68 DEF_LISP="sbcl"
69
70 IUSE="latex emacs tk nls unicode xemacs X ${SUPP_LISPS} ${IUSE}"
71
72 # Languages
73 LANGS="es pt pt_BR"
74 for lang in ${LANGS}; do
75 IUSE="${IUSE} linguas_${lang}"
76 done
77
78 # >=maxima-5.15.0 includes imaxima; it depends on dev-tex/mh
79 RDEPEND="!app-emacs/imaxima
80 X? ( x11-misc/xdg-utils
81 sci-visualization/gnuplot
82 tk? ( dev-lang/tk ) )
83 latex? ( || ( dev-texlive/texlive-latexrecommended
84 >=app-text/tetex-3
85 app-text/ptex ) )
86 emacs? ( virtual/emacs
87 latex? ( app-emacs/auctex dev-tex/mh ) )
88 xemacs? ( virtual/xemacs
89 latex? ( app-emacs/auctex
90 || ( dev-tex/mh dev-texlive/texlive-mathextra ) ) )"
91
92 # create lisp dependencies
93 for LISP in ${SUPP_LISPS}; do
94 RDEPEND="${RDEPEND} ${LISP}? ( dev-lisp/${LISP} )"
95 DEF_DEP="${DEF_DEP} !${LISP}? ( "
96 done
97 DEF_DEP="${DEF_DEP} dev-lisp/${DEF_LISP}"
98 for LISP in ${SUPP_NORL}; do
99 RDEPEND="${RDEPEND} ${LISP}? ( app-misc/rlwrap )"
100 [[ ${LISP} = ${DEF_LISP} ]] && \
101 DEF_DEP="${DEF_DEP} app-misc/rlwrap"
102 done
103 for LISP in ${SUPP_LISPS}; do
104 DEF_DEP="${DEF_DEP} )"
105 done
106
107 RDEPEND="${RDEPEND}
108 ${DEF_DEP}"
109
110 DEPEND="${RDEPEND}
111 sys-apps/texinfo"
112
113 pkg_setup() {
114 LISPS=""
115
116 for LISP in ${SUPP_LISPS}; do
117 use ${LISP} && LISPS="${LISPS} ${LISP}"
118 done
119
120 if [ -z "${LISPS}" ]; then
121 ewarn "No lisp specified in USE flags, choosing ${DEF_LISP} as default"
122 LISPS="${DEF_LISP}"
123 fi
124
125 RL=""
126
127 for LISP in ${SUPP_NORL}; do
128 use ${LISP} && RL="yes"
129 done
130
131 if use gcl; then
132 if ! built_with_use dev-lisp/gcl ansi; then
133 eerror "gcl must be emerged with the USE flag ansi"
134 die "This package needs gcl with USE=ansi"
135 fi
136 # gcl in the main tree is broken (bug #205803)
137 ewarn "Please use gcl from http://repo.or.cz/w/gentoo-lisp-overlay.git"
138 fi
139
140 # Calculating MAXIMA_TEXMFDIR
141 if use latex; then
142 local TEXMFPATH="$(kpsewhich -var-value=TEXMFSITE)"
143 local TEXMFCONFIGFILE="$(kpsewhich texmf.cnf)"
144
145 if [ -z "${TEXMFPATH}" ]; then
146 eerror "You haven't defined the TEXMFSITE variable in your TeX config."
147 eerror "Please do so in the file ${TEXMFCONFIGFILE:-/var/lib/texmf/web2c/texmf.cnf}"
148 die "Define TEXMFSITE in TeX configuration!"
149 else
150 # go through the colon separated list of directories
151 # (maybe only one) provided in the variable
152 # TEXMFPATH (generated from TEXMFSITE from TeX's config)
153 # and choose only the first entry.
154 # All entries are separated by colons, even when defined
155 # with semi-colons, kpsewhich changes
156 # the output to a generic format, so IFS has to be redefined.
157 local IFS="${IFS}:"
158
159 for strippedpath in ${TEXMFPATH}; do
160 if [ -d ${strippedpath} ]; then
161 MAXIMA_TEXMFDIR="${strippedpath}"
162 break
163 fi
164 done
165
166 # verify if an existing path was chosen to prevent from
167 # installing into the wrong directory
168 if [ -z ${MAXIMA_TEXMFDIR} ]; then
169 eerror "TEXMFSITE does not contain any existing directory."
170 eerror "Please define an existing directory in your TeX config file"
171 eerror "${TEXMFCONFIGFILE:-/var/lib/texmf/web2c/texmf.cnf} or create at least one of the there specified directories"
172 die "TEXMFSITE variable did not contain an existing directory"
173 fi
174 fi
175 fi
176
177 if use X && ! built_with_use sci-visualization/gnuplot gd wxwindows; then
178 elog "To benefit full plotting capability of maxima,"
179 elog "enable the gd USE flag for sci-visualization/gnuplot"
180 elog "And if you are planning to use wxmaxima, you want to"
181 elog "also add the wxwindows flag to gnuplot."
182 epause 5
183 fi
184 }
185
186 src_unpack() {
187 unpack ${A}
188 cd "${S}"
189 # use xdg-open to view ps, pdf
190 epatch "${FILESDIR}"/${PN}-xdg-utils.patch
191 epatch "${FILESDIR}"/${PN}-no-init-files.patch
192 # remove rmaxima if neither cmucl nor sbcl
193 if [ -z "${RL}" ]; then
194 sed -e '/^@WIN32_FALSE@bin_SCRIPTS/s/rmaxima//' \
195 -i "${S}"/src/Makefile.in \
196 || die "sed for rmaxima failed"
197 fi
198 }
199
200 src_compile() {
201 local myconf=""
202 for LISP in ${LISPS}; do
203 myconf="${myconf} --enable-${LISP}"
204 done
205
206 # remove xmaxima if no tk
207 if use tk; then
208 myconf="${myconf} --with-wish=wish"
209 else
210 myconf="${myconf} --with-wish=none"
211 sed -i \
212 -e '/^SUBDIRS/s/xmaxima//' \
213 interfaces/Makefile.in || die "sed for tk failed"
214 fi
215
216 # enable existing translated doc
217 if use nls; then
218 for lang in ${LANGS}; do
219 if use "linguas_${lang}"; then
220 myconf="${myconf} --enable-lang-${lang}"
221 use unicode && myconf="${myconf} --enable-lang-${lang}-utf8"
222 fi
223 done
224 fi
225
226 econf ${myconf} || die "econf failed"
227 emake || die "emake failed"
228 }
229
230 src_install() {
231 einstall emacsdir="${D}${SITELISP}/${PN}" || die "einstall failed"
232
233 use tk && make_desktop_entry xmaxima xmaxima \
234 /usr/share/${PN}/${PV}/xmaxima/maxima-new.png \
235 "Science;Math;Education"
236
237 if use latex; then
238 insinto "${MAXIMA_TEXMFDIR}"/tex/latex/emaxima
239 doins interfaces/emacs/emaxima/emaxima.sty
240 fi
241
242 # do not use dodoc because interfaces can't read compressed files
243 # read COPYING before attempt to remove it from dodoc
244 insinto /usr/share/${PN}/${PV}/doc
245 doins AUTHORS COPYING README README.lisps || die
246 dodir /usr/share/doc
247 dosym ../${PN}/${PV}/doc /usr/share/doc/${PF} || die
248
249 if use emacs; then
250 elisp-site-file-install "${FILESDIR}"/50maxima-gentoo.el
251 # imaxima docs
252 cd interfaces/emacs/imaxima
253 insinto /usr/share/${PN}/${PV}/doc/imaxima
254 doins ChangeLog NEWS README || die "installing imaxima docs failed"
255 insinto /usr/share/${PN}/${PV}/doc/imaxima/imath-example
256 doins imath-example/*.txt || die "installing imaxima docs failed"
257 fi
258 }
259
260 pkg_preinst() {
261 # some lisps do not read compress info files (bug #176411)
262 for infofile in "${D}"/usr/share/info/*.bz2 ; do
263 bunzip2 "${infofile}"
264 done
265 for infofile in "${D}"/usr/share/info/*.gz ; do
266 gunzip "${infofile}"
267 done
268 }
269
270 pkg_postinst() {
271 use emacs && elisp-site-regen
272 use latex && mktexlsr
273 }
274
275 pkg_postrm() {
276 use emacs && elisp-site-regen
277 }