/[gentoo-x86]/net-libs/nativebiginteger/nativebiginteger-0.8.7.ebuild
Gentoo

Contents of /net-libs/nativebiginteger/nativebiginteger-0.8.7.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations) (download)
Mon Jan 2 15:57:17 2012 UTC (2 years, 8 months ago) by sera
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +3 -3 lines
Drop ia64 support #345433

(Portage version: 2.1.10.43/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/net-libs/nativebiginteger/nativebiginteger-0.8.7.ebuild,v 1.2 2011/08/03 17:49:53 tommy Exp $
4
5 EAPI=4
6
7 inherit eutils toolchain-funcs multilib java-pkg-2
8
9 DESCRIPTION="jbigi JNI library for net.i2p.util.NativeBigInteger java-class from I2P"
10 HOMEPAGE="http://www.i2p2.de"
11 SRC_URI="http://mirror.i2p2.de/i2psource_${PV}.tar.bz2"
12
13 LICENSE="|| ( public-domain BSD MIT )"
14 SLOT="0"
15 KEYWORDS="~amd64 ~x86"
16
17 IUSE="test"
18
19 DEPEND="${RDEPEND}
20 >=virtual/jdk-1.5"
21 RDEPEND="dev-libs/gmp"
22
23 S=${WORKDIR}/i2p-${PV}/core/
24
25 src_prepare() {
26 epatch "${FILESDIR}/${P}"-build-system.patch \
27 "${FILESDIR}/${P}"-jcpuid-build-system.patch \
28 "${FILESDIR}/${P}"-debug-all.patch \
29 "${FILESDIR}/${P}"-non-android-warnings.patch \
30 "${FILESDIR}/${P}"-asmfix.patch
31 }
32
33 src_compile() {
34 tc-export CC
35
36 cd c/jbigi/jbigi/src || die
37 ../../build_jbigi.sh dynamic || die
38
39 if use test ; then
40 einfo "Building tests ..."
41 cd "${S}"java/src || die
42 ejavac net/i2p/util/NativeBigInteger.java || die
43 eend $?
44 fi
45 if ( use amd64 || use x86 ) ; then
46 cd "${S}"c/jcpuid
47 ./build.sh || die
48 fi
49 }
50
51 src_test() {
52 cd java/src || die
53 java -Djava.library.path="${S}"/c/jbigi/jbigi/src net/i2p/util/NativeBigInteger || die
54 }
55
56 src_install() {
57 local os arch
58
59 dolib c/jbigi/jbigi/src/libjbigi.so
60 ( use amd64 || use x86 ) && dolib c/jcpuid/lib/freenet/support/CPUInformation/libjcpuid-x86-linux.so
61
62 ## The following is needed for compatibility with earlier versions of NativeBigInteger ##
63
64 # arch list found by "none" + grep 'JBIGI_OPTIMIZATION_.*=' core/java/src/net/i2p/util/NativeBigInteger.java
65 for arch in none arm k6 k62 k63 athlon x86_64 x86_64_32 pentium pentiummmx pentium2 pentium3 pentium4 ppc ; do
66 dosym libjbigi.so /usr/$(get_libdir)/libjbigi-linux-$arch.so
67 done
68 }

  ViewVC Help
Powered by ViewVC 1.1.20