/[gentoo-x86]/dev-libs/gmp/gmp-4.3.1.ebuild
Gentoo

Contents of /dev-libs/gmp/gmp-4.3.1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.11 - (show annotations) (download)
Sun Jul 4 21:06:47 2010 UTC (4 years, 3 months ago) by vapier
Branch: MAIN
CVS Tags: HEAD
Changes since 1.10: +1 -1 lines
FILE REMOVED
old

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-libs/gmp/gmp-4.3.1.ebuild,v 1.10 2009/12/15 11:14:29 vapier Exp $
4
5 inherit flag-o-matic eutils libtool flag-o-matic
6
7 DESCRIPTION="Library for arithmetic on arbitrary precision integers, rational numbers, and floating-point numbers"
8 HOMEPAGE="http://gmplib.org/"
9 SRC_URI="mirror://gnu/${PN}/${P}.tar.bz2"
10 # doc? ( http://www.nada.kth.se/~tege/${PN}-man-${PV}.pdf )"
11
12 LICENSE="LGPL-3"
13 SLOT="0"
14 KEYWORDS="alpha amd64 arm hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~sparc-fbsd ~x86-fbsd"
15 IUSE="nocxx" #doc
16
17 src_unpack() {
18 unpack ${A}
19 cd "${S}"
20 [[ -d ${FILESDIR}/${PV} ]] && EPATCH_SUFFIX="diff" EPATCH_FORCE="yes" epatch "${FILESDIR}"/${PV}
21 epatch "${FILESDIR}"/${PN}-4.1.4-noexecstack.patch
22 epatch "${FILESDIR}"/${PN}-4.3.0-ABI-multilib.patch
23 epatch "${FILESDIR}"/${PN}-4.2.1-s390.diff
24 epatch "${FILESDIR}"/${PN}-4.3.1-fix-broken-ansi-check.patch #296964
25
26 sed -i -e 's:ABI = @ABI@:GMPABI = @GMPABI@:' \
27 Makefile.in */Makefile.in */*/Makefile.in
28
29 # note: we cannot run autotools here as gcc depends on this package
30 elibtoolize
31 }
32
33 src_compile() {
34 # GMP believes hppa2.0 is 64bit
35 local is_hppa_2_0
36 if [[ ${CHOST} == hppa2.0-* ]] ; then
37 is_hppa_2_0=1
38 export CHOST=${CHOST/2.0/1.1}
39 fi
40
41 # ABI mappings (needs all architectures supported)
42 case ${ABI} in
43 32|x86) export GMPABI=32;;
44 64|amd64|n64) export GMPABI=64;;
45 o32|n32) export GMPABI=${ABI};;
46 esac
47
48 tc-export CC
49 econf \
50 --localstatedir=/var/state/gmp \
51 --disable-mpfr \
52 --disable-mpbsd \
53 $(use_enable !nocxx cxx) \
54 || die "configure failed"
55
56 # Fix the ABI for hppa2.0
57 if [[ -n ${is_hppa_2_0} ]] ; then
58 sed -i \
59 -e 's:pa32/hppa1_1:pa32/hppa2_0:' \
60 "${S}"/config.h || die
61 export CHOST=${CHOST/1.1/2.0}
62 fi
63
64 emake || die "emake failed"
65 }
66
67 src_install() {
68 emake DESTDIR="${D}" install || die "make install failed"
69
70 dodoc AUTHORS ChangeLog NEWS README
71 dodoc doc/configuration doc/isa_abi_headache
72 dohtml -r doc
73
74 #use doc && cp "${DISTDIR}"/gmp-man-${PV}.pdf "${D}"/usr/share/doc/${PF}/
75 }

  ViewVC Help
Powered by ViewVC 1.1.20