/[gentoo-x86]/sci-libs/libcore/libcore-2.1.1-r1.ebuild
Gentoo

Contents of /sci-libs/libcore/libcore-2.1.1-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Fri Aug 3 19:34:54 2012 UTC (7 years, 5 months ago) by bicatali
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +3 -3 lines
Keyword amd64-linux x86-linux

(Portage version: 2.2.01.20796-prefix/cvs/Linux x86_64)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sci-libs/libcore/libcore-2.1.1-r1.ebuild,v 1.1 2011/08/08 18:51:41 bicatali Exp $
4
5 EAPI=4
6 inherit eutils toolchain-funcs versionator
7
8 MYPN=core
9 DOCPV="$(get_version_component_range 1-2)"
10
11 DESCRIPTION="Robust numerical and geometric computation library"
12 HOMEPAGE="http://www.cs.nyu.edu/exact/core_pages/"
13 SRC_URI="http://cs.nyu.edu/exact/core/download/${MYPN}/${MYPN}-${PV}.tgz
14 doc? ( http://cs.nyu.edu/exact/core/download/${MYPN}/${MYPN}-${DOCPV}.doc.tgz )"
15
16 LICENSE="QPL-1.0"
17 SLOT="0"
18 KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
19 IUSE="doc static-libs"
20
21 RDEPEND=""
22 DEPEND="${RDEPEND}
23 dev-libs/mpfr
24 dev-libs/gmp
25 doc? ( app-doc/doxygen[latex] )"
26
27 S="${WORKDIR}/${MYPN}-${PV}"
28
29 src_prepare() {
30 epatch "${FILESDIR}"/${PV}-makefiles.patch
31 sed -i \
32 -e "s/-O2/${CXXFLAGS}/g" \
33 -e "s/-shared/-shared ${LDFLAGS}/g" \
34 Make.config || die
35 sed -i -e 's/-lgmp/-lgmp -lgmpxx/g' progs/Make.options || die
36 # missing input file in gaussian test and buggy test in tutorial
37 sed -i -e '/gaussian/d' -e '/tutorial/d' progs/Makefile || die
38 }
39
40 src_compile(){
41 emake VAR= LINKAGE=shared corelib corex USE_GMPXX=1
42 rm -f src/*.o ext/*.o
43 use static-libs && emake VAR="" corelib corex USE_GMPXX=1
44 if use doc; then
45 cd "${S}/doc"
46 export VARTEXFONTS="${T}/fonts"
47 emake -j1 all
48 emake -j1 -C doxy/latex pdf
49 fi
50 }
51
52 src_test() {
53 LD_LIBRARY_PATH="${S}/lib" emake \
54 VAR= GMP_PREFIX= MPFR_PREFIX= test
55 }
56
57 src_install(){
58 dolib.so lib/*.so*
59 for i in $(find "${ED}/usr/$(get_libdir)" -name "*so" | sed "s:${ED}::g"); do
60 dosym $i.2 $i
61 done
62 use static-libs && dolib.a lib/*.a
63
64 insinto /usr/include
65 doins inc/CORE.h
66 insinto /usr/include/CORE
67 doins inc/CORE/*.h
68
69 dodoc FAQs README
70 if use doc; then
71 dodoc doc/*.txt
72 dodoc doc/tutorial/tutorial.pdf doc/doxy/latex/*pdf
73 dohtml -r doc/doxy/html/*
74 fi
75 }

  ViewVC Help
Powered by ViewVC 1.1.20