/[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.1 - (show annotations) (download)
Sat May 23 23:23:36 2009 UTC (5 years, 4 months ago) by vapier
Branch: MAIN
Version bump #270810 by Arseny Solokha.
(Portage version: 2.2_rc33/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-libs/gmp/gmp-4.3.0.ebuild,v 1.1 2009/04/27 06:46:22 vapier Exp $
4
5 inherit flag-o-matic eutils libtool
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 ~sparc-fbsd ~x86 ~x86-fbsd"
15 IUSE="nocxx" #doc
16
17 RDEPEND=""
18 DEPEND=""
19
20 src_unpack () {
21 unpack ${A}
22 cd "${S}"
23 [[ -d ${FILESDIR}/${PV} ]] && EPATCH_SUFFIX="diff" EPATCH_FORCE="yes" epatch "${FILESDIR}"/${PV}
24 epatch "${FILESDIR}"/${PN}-4.1.4-noexecstack.patch
25 epatch "${FILESDIR}"/${PN}-4.3.0-ABI-multilib.patch
26 epatch "${FILESDIR}"/${PN}-4.2.1-s390.diff
27
28 sed -i -e 's:ABI = @ABI@:GMPABI = @GMPABI@:' \
29 Makefile.in */Makefile.in */*/Makefile.in
30
31 # note: we cannot run autotools here as gcc depends on this package
32 elibtoolize
33 }
34
35 src_compile() {
36 # GMP believes hppa2.0 is 64bit
37 local is_hppa_2_0
38 if [[ ${CHOST} == hppa2.0-* ]] ; then
39 is_hppa_2_0=1
40 export CHOST=${CHOST/2.0/1.1}
41 fi
42
43 # ABI mappings (needs all architectures supported)
44 case ${ABI} in
45 32|x86) export GMPABI=32;;
46 64|amd64|n64) export GMPABI=64;;
47 o32|n32) export GMPABI=${ABI};;
48 esac
49
50 econf \
51 --localstatedir=/var/state/gmp \
52 --disable-mpfr \
53 --disable-mpbsd \
54 $(use_enable !nocxx cxx) \
55 || die "configure failed"
56
57 # Fix the ABI for hppa2.0
58 if [[ -n ${is_hppa_2_0} ]] ; then
59 sed -i \
60 -e 's:pa32/hppa1_1:pa32/hppa2_0:' \
61 "${S}"/config.h || die
62 export CHOST=${CHOST/1.1/2.0}
63 fi
64
65 emake || die "emake failed"
66 }
67
68 src_install() {
69 emake DESTDIR="${D}" install || die "make install failed"
70
71 dodoc AUTHORS ChangeLog NEWS README
72 dodoc doc/configuration doc/isa_abi_headache
73 dohtml -r doc
74
75 #use doc && cp "${DISTDIR}"/gmp-man-${PV}.pdf "${D}"/usr/share/doc/${PF}/
76 }

  ViewVC Help
Powered by ViewVC 1.1.20