summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Sachau <tommy@gentoo.org>2011-07-31 18:20:59 +0000
committerThomas Sachau <tommy@gentoo.org>2011-07-31 18:20:59 +0000
commit6faee0a315cbfc13413e9b020d74c56054109c97 (patch)
tree7b5b8d44a2a03b521c2136c58a55c45f3ee2f7dc /net-libs/nativebiginteger
parentVersion bump. (diff)
downloadhistorical-6faee0a315cbfc13413e9b020d74c56054109c97.tar.gz
historical-6faee0a315cbfc13413e9b020d74c56054109c97.tar.bz2
historical-6faee0a315cbfc13413e9b020d74c56054109c97.zip
Version bump, partly based on ebuilds by Dennis Schridde, fixes bug 376971
Package-Manager: portage-2.2.0_alpha47-r1/cvs/Linux x86_64
Diffstat (limited to 'net-libs/nativebiginteger')
-rw-r--r--net-libs/nativebiginteger/ChangeLog14
-rw-r--r--net-libs/nativebiginteger/Manifest21
-rw-r--r--net-libs/nativebiginteger/files/nativebiginteger-0.8.7-asmfix.patch31
-rw-r--r--net-libs/nativebiginteger/files/nativebiginteger-0.8.7-build-system.patch22
-rw-r--r--net-libs/nativebiginteger/files/nativebiginteger-0.8.7-debug-all.patch35
-rw-r--r--net-libs/nativebiginteger/files/nativebiginteger-0.8.7-jcpuid-build-system.patch23
-rw-r--r--net-libs/nativebiginteger/files/nativebiginteger-0.8.7-non-android-warnings.patch11
-rw-r--r--net-libs/nativebiginteger/nativebiginteger-0.8.7.ebuild75
8 files changed, 223 insertions, 9 deletions
diff --git a/net-libs/nativebiginteger/ChangeLog b/net-libs/nativebiginteger/ChangeLog
index 0f4a9487283e..a27079e4dcfb 100644
--- a/net-libs/nativebiginteger/ChangeLog
+++ b/net-libs/nativebiginteger/ChangeLog
@@ -1,6 +1,16 @@
# ChangeLog for net-libs/nativebiginteger
-# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-libs/nativebiginteger/ChangeLog,v 1.6 2010/12/28 12:34:30 tommy Exp $
+# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/net-libs/nativebiginteger/ChangeLog,v 1.7 2011/07/31 18:20:59 tommy Exp $
+
+*nativebiginteger-0.8.7 (31 Jul 2011)
+
+ 31 Jul 2011; Thomas Sachau (Tommy[D]) <tommy@gentoo.org>
+ +nativebiginteger-0.8.7.ebuild, +files/nativebiginteger-0.8.7-asmfix.patch,
+ +files/nativebiginteger-0.8.7-build-system.patch,
+ +files/nativebiginteger-0.8.7-debug-all.patch,
+ +files/nativebiginteger-0.8.7-jcpuid-build-system.patch,
+ +files/nativebiginteger-0.8.7-non-android-warnings.patch:
+ Version bump, partly based on ebuilds by Dennis Schridde, fixes bug 376971
*nativebiginteger-0.6.4-r3 (28 Dec 2010)
diff --git a/net-libs/nativebiginteger/Manifest b/net-libs/nativebiginteger/Manifest
index 3e3a771f8a72..d18e59df57f4 100644
--- a/net-libs/nativebiginteger/Manifest
+++ b/net-libs/nativebiginteger/Manifest
@@ -3,17 +3,24 @@ Hash: SHA1
AUX nativebiginteger-0.6.4-asmfix.patch 586 RMD160 bf9d3735089402903777cc119cf56da83839c6f1 SHA1 9574a780ee0d2998eff2aa25f7d7c6e6e78ba146 SHA256 2ad29016057f3ea18596bff1eb47bc1ef6b4cc129d1f3b55d134f2717b8e631a
AUX nativebiginteger-0.6.4-ldflags.patch 967 RMD160 4f7cb1d44df2d3db41e51b5249da65d898a8fada SHA1 c4b363e75c8d203f94172d0c65bb45d92dd04489 SHA256 9e30b7ef2a4c8e55ce9dcacdc4d19ed76e8249f4af540094543f3aae3e27838a
+AUX nativebiginteger-0.8.7-asmfix.patch 590 RMD160 13b56f091b24026c35eda0268878f16ccd444394 SHA1 7ef920903b4ae2f0e83068ddd0a82c951566fb44 SHA256 f21f798dfc4bf30e717b5a113d9564d9a1ce93d6460e9d77ea452c2869f3ece1
+AUX nativebiginteger-0.8.7-build-system.patch 907 RMD160 75900fbe2e6c5aa7d54acb2fda1a281da59d27f1 SHA1 064c970e40d5ff5c5c2c7b76799e33a87a2e9c1d SHA256 fb22532815cbef13e1e2639d9dd2f16018d9663370f22aee073b6fb0868f87d6
+AUX nativebiginteger-0.8.7-debug-all.patch 1215 RMD160 3e00b1b4018c4a64704697b439e1d123adb1fb80 SHA1 2810e5ff914f7afa0b07413ba28c862c8536848d SHA256 a8ffe1ae7497bda2d10c01f35845bc31689b727c36af39ea73edc8614cc26a18
+AUX nativebiginteger-0.8.7-jcpuid-build-system.patch 761 RMD160 e3aaa56f002831e0ccf204a4669c4c5e9e05067a SHA1 37c4214167b190719c1488fc740a871f0947b37c SHA256 62fe230a522df9371427ffa04805279bb1bf1802b6dece013b2d8762bbf7a31d
+AUX nativebiginteger-0.8.7-non-android-warnings.patch 533 RMD160 524ccea5c2fe69399046f59115e89e8db007303c SHA1 0e9953cbe299b7717c56ee9103a94802a2189521 SHA256 a23ed96c74fd35b45d3dd89c47a348cc5c992857a582e29506894677f4aa2922
+DIST i2psource_0.8.7.tar.bz2 18473515 RMD160 545e72fab13d6f6ca660b5b74d86648a9160a000 SHA1 61727b1b745d7cd882268300c7913dfd13b9f612 SHA256 31acef3fcd1a5839edc3b931f108944222c833d218bd427fe89a57b4acd92ece
DIST nativebiginteger-0.6.4.tar.bz2 10248 RMD160 a7ac7832371c74a1e9592a9abd1b6d5ef40a360a SHA1 37b433b3a7a2cf818a7ca3713548153f63da3817 SHA256 ef36fb57c1d885164f00b3e5d239c22349a530fa20df652efc5cb1f1ccea2c32
EBUILD nativebiginteger-0.6.4-r3.ebuild 867 RMD160 5c87ea56c8e81302121c057f5e72c65cc68eb8bb SHA1 f1df5a12ee59b2a3ccda03f3b27b6976f6275623 SHA256 30f2a7e27ede87d44acd82675f6b3c9469d227619f5c2c354910a684937ee18b
EBUILD nativebiginteger-0.6.4.ebuild 786 RMD160 a4034c175976d8c3ccd0c1f3b87fcf5dca06fa14 SHA1 7e479d833c9c045f72350c502c8e7ec6ebde269d SHA256 6739e7cc8119bcd19d0272b6a89cbc86df39aa3e105d685f08c81e665b71c2ed
-MISC ChangeLog 1443 RMD160 ca3a9a249f2df36fc271d9ae1d6268ad52e2c149 SHA1 4034687c8877378411249be4cf87e1d146bc0982 SHA256 38a5eca646b24bc73f1a0e30920c8827bdebb8a7a4779132084cc3e563a7c7bc
+EBUILD nativebiginteger-0.8.7.ebuild 2116 RMD160 144ace63c4c3b7ae13594d01d741b364f7db0592 SHA1 c182a250d93638794673cbbfcc62b074d3818ca1 SHA256 a9c35e979430e91fa67d10729384151ccc375daf3b63d54018f388b65d119271
+MISC ChangeLog 1917 RMD160 1a9ae7d8cdebf1611ec292feea557f13155dc256 SHA1 201f7bd647dec41d1663d91f98330dced3c97568 SHA256 6a93a660f452718f3dd657254610a4ccb652305b64dd13ba8971ddba107109b7
MISC metadata.xml 265 RMD160 8391b845c1dc290dbfc6d8391aed1e0537e14725 SHA1 98eb1209de8c64009ada779e9c4b57f0b8273c41 SHA256 02b8c461c4f564f9a88d09d6e5d6cb1018b06173aa6b0fb4f188664b00f057fa
-----BEGIN PGP SIGNATURE-----
-Version: GnuPG v2.0.16 (GNU/Linux)
+Version: GnuPG v2.0.17 (GNU/Linux)
-iJwEAQECAAYFAk0Z2jgACgkQG7kqcTWJkGfMnQQAxSMNJaKshZ4aO63qUNMxdB0J
-zEF1h6JQ27dk8cJI5j1OEEnpJOyQ4NngppXKpeuwLEYuqrEK5rmqBY8jfjw6OpYe
-chzfyopHzL+3qpi98CVazum1LfVuTdMbZe/6gxBsFPNyax3mZHfJo9TgBeViqLZ/
-9bsw33UcxTz3PiAAhR8=
-=AmoP
+iJwEAQECAAYFAk41nRcACgkQG7kqcTWJkGexVAP+POXCmXaWtRNMwH3ldY7eQkUS
+b7MOc6UafssFk15o/5kUrzTFFZmL5XLUKis4pNo+2JUW+MbTFcq9Pw71TA/1rD6E
+PSwyrPfn7Erlr7z4Hz39UitBG6Zkx2i6VWA/iZoaT+tc/7uVKnPSnVOxogzRxDOH
+o5ematyj6wRHtGmYyLc=
+=vj07
-----END PGP SIGNATURE-----
diff --git a/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-asmfix.patch b/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-asmfix.patch
new file mode 100644
index 000000000000..3443a91c288b
--- /dev/null
+++ b/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-asmfix.patch
@@ -0,0 +1,31 @@
+--- c/jcpuid/src/jcpuid.c 2008-10-06 09:44:53.000000000 -0400
++++ c/jcpuid/src/jcpuid.c.new2 2010-12-27 09:41:53.000000000 -0500
+@@ -19,6 +19,7 @@
+ mov d, edx
+ }
+ #else
++ #ifdef _LP64
+ //Use GCC assembler notation
+ asm
+ (
+@@ -29,6 +30,20 @@
+ "=d"(d)
+ :"a"(iFunction)
+ );
++ #elif defined(__i386__)
++ asm
++ (
++ "pushl %%ebx\n\t"
++ "cpuid\n\t"
++ "movl %%ebx, %%edi\n\t"
++ "popl %%ebx"
++ : "=a" (a),
++ "=D" (b),
++ "=c" (c),
++ "=d" (d)
++ :"a"(iFunction)
++ );
++ #endif
+ #endif
+ return (*env)->NewObject(env, clsResult,constructor,a,b,c,d);
+ }
diff --git a/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-build-system.patch b/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-build-system.patch
new file mode 100644
index 000000000000..ea298b5d0358
--- /dev/null
+++ b/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-build-system.patch
@@ -0,0 +1,22 @@
+--- i2p-0.8.7/core/c/jbigi/build_jbigi.sh.orig 2011-07-29 11:52:43.000000000 +0200
++++ i2p-0.8.7/core/c/jbigi/build_jbigi.sh 2011-07-29 11:53:43.000000000 +0200
+@@ -3,8 +3,8 @@
+ # When executed in Linux/FreeBSD: Produces an libjbigi.so
+ # Darwin produces libjbigi.jnilib, right?
+
+-CC="gcc"
++test -z "$CC" && CC="gcc"
+
+ case `uname -sr` in
+ MINGW*)
+ JAVA_HOME="c:/software/j2sdk1.4.2_05"
+@@ -57,5 +55,7 @@
+
+ echo "Compiling C code..."
+ rm -f jbigi.o $LIBFILE
+-$CC -c $COMPILEFLAGS $INCLUDES ../../jbigi/src/jbigi.c
+-$CC $LINKFLAGS $INCLUDES $INCLUDELIBS -o $LIBFILE jbigi.o $STATICLIBS
++echo $CC -c $COMPILEFLAGS $CFLAGS $CPPFLAGS $INCLUDES ../../jbigi/src/jbigi.c
++$CC -c $COMPILEFLAGS $CFLAGS $CPPFLAGS $INCLUDES ../../jbigi/src/jbigi.c
++echo $CC $LINKFLAGS $LDFLAGS $INCLUDES -o $LIBFILE jbigi.o $STATICLIBS $INCLUDELIBS
++$CC $LINKFLAGS $LDFLAGS $INCLUDES -o $LIBFILE jbigi.o $STATICLIBS $INCLUDELIBS
diff --git a/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-debug-all.patch b/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-debug-all.patch
new file mode 100644
index 000000000000..07dd05227582
--- /dev/null
+++ b/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-debug-all.patch
@@ -0,0 +1,35 @@
+--- core/java/src/net/i2p/util/NativeBigInteger.java.orig 2011-07-29 13:14:05.000000000 +0200
++++ core/java/src/net/i2p/util/NativeBigInteger.java 2011-07-29 13:15:16.000000000 +0200
+@@ -481,14 +481,12 @@
+
+ /** @since 0.8.7 */
+ private static void debug(String s) {
+- I2PAppContext.getGlobalContext().logManager().getLog(NativeBigInteger.class).debug(s);
++ System.err.println("DEBUG: " + s);
+ }
+
+
+ private static void info(String s) {
+- if(_doLog)
+- System.err.println("INFO: " + s);
+- I2PAppContext.getGlobalContext().logManager().getLog(NativeBigInteger.class).info(s);
++ System.err.println("INFO: " + s);
+ _loadStatus = s;
+ }
+
+@@ -496,12 +496,9 @@
+
+ /** @since 0.8.7 */
+ private static void warn(String s, Throwable t) {
+- if(_doLog) {
+- System.err.println("WARNING: " + s);
+- if (t != null)
+- t.printStackTrace();
+- }
+- I2PAppContext.getGlobalContext().logManager().getLog(NativeBigInteger.class).warn(s, t);
++ System.err.println("WARNING: " + s);
++ if (t != null)
++ t.printStackTrace();
+ if (t != null)
+ _loadStatus = s + ' ' + t;
+ else
diff --git a/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-jcpuid-build-system.patch b/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-jcpuid-build-system.patch
new file mode 100644
index 000000000000..a4020a012b98
--- /dev/null
+++ b/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-jcpuid-build-system.patch
@@ -0,0 +1,23 @@
+--- i2p-0.8.7/core/c/jcpuid/build.sh.orig 2011-07-29 18:38:44.554000219 +0200
++++ i2p-0.8.7/core/c/jcpuid/build.sh 2011-07-29 18:38:13.789000172 +0200
+@@ -24,8 +24,8 @@
+ mkdir lib/freenet/support
+ mkdir lib/freenet/support/CPUInformation
+
+-CC="gcc"
++test -z "$CC" && CC="gcc"
+
+ case `uname -sr` in
+ MINGW*)
+ JAVA_HOME="/c/software/j2sdk1.4.2_05"
+@@ -50,8 +52,8 @@
+
+ echo "Compiling C code..."
+ rm -f $LIBFILE
+-$CC $COMPILEFLAGS $LINKFLAGS $INCLUDES src/*.c -o $LIBFILE
+-strip $LIBFILE
++echo $CC $COMPILEFLAGS $CPPFLAGS $CFLAGS $LINKFLAGS $LDFLAGS $INCLUDES src/*.c -o $LIBFILE
++$CC $COMPILEFLAGS $CPPFLAGS $CFLAGS $LINKFLAGS $LDFLAGS $INCLUDES src/*.c -o $LIBFILE
+ echo Built $LIBFILE
+
+ #g++ -shared -static -static-libgcc -Iinclude -I$JAVA_HOME/include \
diff --git a/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-non-android-warnings.patch b/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-non-android-warnings.patch
new file mode 100644
index 000000000000..6240d25bcd9b
--- /dev/null
+++ b/net-libs/nativebiginteger/files/nativebiginteger-0.8.7-non-android-warnings.patch
@@ -0,0 +1,11 @@
+--- core/java/src/net/i2p/util/NativeBigInteger.java.orig 2011-07-29 13:22:39.000000000 +0200
++++ core/java/src/net/i2p/util/NativeBigInteger.java 2011-07-29 13:22:55.000000000 +0200
+@@ -526,7 +526,7 @@
+ System.loadLibrary(name);
+ return true;
+ } catch (UnsatisfiedLinkError ule) {
+- if (_isAndroid) {
++ if (!_isAndroid) {
+ // Unfortunately,
+ // this is not interesting on Android, it says "file not found"
+ // on link errors too.
diff --git a/net-libs/nativebiginteger/nativebiginteger-0.8.7.ebuild b/net-libs/nativebiginteger/nativebiginteger-0.8.7.ebuild
new file mode 100644
index 000000000000..4e05cf43f626
--- /dev/null
+++ b/net-libs/nativebiginteger/nativebiginteger-0.8.7.ebuild
@@ -0,0 +1,75 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-libs/nativebiginteger/nativebiginteger-0.8.7.ebuild,v 1.1 2011/07/31 18:20:59 tommy Exp $
+
+EAPI=4
+
+inherit eutils toolchain-funcs multilib java-pkg-2
+
+DESCRIPTION="jbigi JNI library for net.i2p.util.NativeBigInteger java-class from I2P"
+HOMEPAGE="http://www.i2p2.de"
+SRC_URI="http://mirror.i2p2.de/i2psource_${PV}.tar.bz2"
+
+LICENSE="|| ( public-domain BSD MIT )"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+IUSE="test"
+
+DEPEND="${RDEPEND}
+ >=virtual/jdk-1.5"
+RDEPEND="dev-libs/gmp"
+
+S=${WORKDIR}/i2p-${PV}/core/
+
+src_prepare() {
+ epatch "${FILESDIR}/${P}"-build-system.patch \
+ "${FILESDIR}/${P}"-jcpuid-build-system.patch \
+ "${FILESDIR}/${P}"-debug-all.patch \
+ "${FILESDIR}/${P}"-non-android-warnings.patch \
+ "${FILESDIR}/${P}"-asmfix.patch
+}
+
+src_compile() {
+ tc-export CC
+
+ cd c/jbigi/jbigi/src || die
+ ../../build_jbigi.sh dynamic || die
+
+ if use test ; then
+ einfo "Building tests ..."
+ cd "${S}"java/src || die
+ ejavac net/i2p/util/NativeBigInteger.java || die
+ eend $?
+ fi
+ if ( use amd64 || use x86 ) ; then
+ cd "${S}"c/jcpuid
+ ./build.sh || die
+ fi
+}
+
+src_test() {
+ cd java/src || die
+ java -Djava.library.path="${S}"/c/jbigi/jbigi/src net/i2p/util/NativeBigInteger || die
+}
+
+src_install() {
+ local os arch
+
+ dolib c/jbigi/jbigi/src/libjbigi.so || die
+ ( use amd64 || use x86 ) && dolib c/jcpuid/lib/freenet/support/CPUInformation/libjcpuid-x86-linux.so || die
+
+ ## The following is needed for compatibility with earlier versions of NativeBigInteger ##
+
+ # os list found by: grep 'jbigi-' core/java/src/net/i2p/util/NativeBigInteger.java
+ case ${CHOST} in
+ *-fbsd) os=freebsd ;;
+ *-darwin) os=osx ;;
+ *-mingw*|*-cygwin) os=windows ;;
+ *) os=linux ;;
+ esac
+ # arch list found by "none" + grep 'JBIGI_OPTIMIZATION_.*=' core/java/src/net/i2p/util/NativeBigInteger.java
+ for arch in none arm k6 k62 k63 athlon x86_64 x86_64_32 pentium pentiummmx pentium2 pentium3 pentium4 ppc ; do
+ dosym libjbigi.so /usr/$(get_libdir)/libjbigi-$os-$arch.so || die
+ done
+}