1 |
commit: fd6e992a45c0835bca83f25237c2b928f743d57b |
2 |
Author: tharvik <tharvik <AT> users <DOT> noreply <DOT> github <DOT> com> |
3 |
AuthorDate: Sun Aug 26 14:18:14 2018 +0000 |
4 |
Commit: Patrice Clement <monsieurp <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Sep 7 08:23:50 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fd6e992a |
7 |
|
8 |
net-libs/nativebiginteger: bump to 0.9.36. |
9 |
|
10 |
Closes: https://github.com/gentoo/gentoo/pull/9702 |
11 |
|
12 |
net-libs/nativebiginteger/Manifest | 1 + |
13 |
.../files/nativebiginteger-0.9.36-asmfix.patch | 31 ++++++++++ |
14 |
.../nativebiginteger-0.9.36.ebuild | 67 ++++++++++++++++++++++ |
15 |
3 files changed, 99 insertions(+) |
16 |
|
17 |
diff --git a/net-libs/nativebiginteger/Manifest b/net-libs/nativebiginteger/Manifest |
18 |
index 8bd47c53649..18eaf831a7c 100644 |
19 |
--- a/net-libs/nativebiginteger/Manifest |
20 |
+++ b/net-libs/nativebiginteger/Manifest |
21 |
@@ -1 +1,2 @@ |
22 |
DIST i2psource_0.8.7.tar.bz2 18473515 BLAKE2B 9f79cd2e69f26ba0fadc24b6cad0ff43301c65fd640313688687895de908c6a0c6fd9d1be6c82a6d7478cd4ecf633ce3b8fd4d200cce644512a7b4fa275a0927 SHA512 32b4eb4bf8bc7d6bb692b3ecd6b0a34c4d3d7c94b0d09a4ff330151979ccdaca9a6c88fef9b7e7965a1bba8ef54dbb710d89e0bb19265ee177ce547ff50ca969 |
23 |
+DIST i2psource_0.9.36.tar.bz2 29856168 BLAKE2B 0f10101b874bf6fc8415f10b08282947962a6fb8c3eaefde67d3f250d65a159551c24038625aa6712e88b368ccae38d136314025ac19fcb9dd9145251283b357 SHA512 e9023cae1c7dbdd92c9c4823497dfa8497cee3683de1232deddbdc548ba08edefe218bd81e00e952d8a95037c32de8359daaf43c2d5f25c75aba65554d2d47b4 |
24 |
|
25 |
diff --git a/net-libs/nativebiginteger/files/nativebiginteger-0.9.36-asmfix.patch b/net-libs/nativebiginteger/files/nativebiginteger-0.9.36-asmfix.patch |
26 |
new file mode 100644 |
27 |
index 00000000000..cdb8c7f64cb |
28 |
--- /dev/null |
29 |
+++ b/net-libs/nativebiginteger/files/nativebiginteger-0.9.36-asmfix.patch |
30 |
@@ -0,0 +1,31 @@ |
31 |
+--- c/jcpuid/src/jcpuid.c 2008-10-06 09:44:53.000000000 -0400 |
32 |
++++ c/jcpuid/src/jcpuid.c.new2 2010-12-27 09:41:53.000000000 -0500 |
33 |
+@@ -19,6 +19,7 @@ |
34 |
+ mov d, edx |
35 |
+ } |
36 |
+ #else |
37 |
++ #ifdef _LP64 |
38 |
+ //Use GCC assembler notation |
39 |
+ asm |
40 |
+ ( |
41 |
+@@ -29,6 +30,20 @@ |
42 |
+ "=d"(d) |
43 |
+ :"a"(iFunction) |
44 |
+ ); |
45 |
++ #elif defined(__i386__) |
46 |
++ asm |
47 |
++ ( |
48 |
++ "pushl %%ebx\n\t" |
49 |
++ "cpuid\n\t" |
50 |
++ "movl %%ebx, %%edi\n\t" |
51 |
++ "popl %%ebx" |
52 |
++ : "=a" (a), |
53 |
++ "=D" (b), |
54 |
++ "=c" (c), |
55 |
++ "=d" (d) |
56 |
++ :"a"(iFunction) |
57 |
++ ); |
58 |
++ #endif |
59 |
+ #endif |
60 |
+ return (*env)->NewObject(env, clsResult,constructor,a,b,c,d); |
61 |
+ } |
62 |
|
63 |
diff --git a/net-libs/nativebiginteger/nativebiginteger-0.9.36.ebuild b/net-libs/nativebiginteger/nativebiginteger-0.9.36.ebuild |
64 |
new file mode 100644 |
65 |
index 00000000000..d327fc13809 |
66 |
--- /dev/null |
67 |
+++ b/net-libs/nativebiginteger/nativebiginteger-0.9.36.ebuild |
68 |
@@ -0,0 +1,67 @@ |
69 |
+# Copyright 1999-2018 Gentoo Foundation |
70 |
+# Distributed under the terms of the GNU General Public License v2 |
71 |
+ |
72 |
+EAPI=6 |
73 |
+ |
74 |
+inherit eutils toolchain-funcs multilib java-pkg-opt-2 |
75 |
+ |
76 |
+DESCRIPTION="jbigi JNI library for net.i2p.util.NativeBigInteger java-class from I2P" |
77 |
+HOMEPAGE="http://www.i2p2.de" |
78 |
+SRC_URI="http://mirror.i2p2.de/i2psource_${PV}.tar.bz2" |
79 |
+ |
80 |
+LICENSE="|| ( public-domain BSD MIT )" |
81 |
+SLOT="0" |
82 |
+KEYWORDS="~amd64 ~x86" |
83 |
+ |
84 |
+IUSE="test" |
85 |
+ |
86 |
+RDEPEND="dev-libs/gmp" |
87 |
+DEPEND=" |
88 |
+ ${RDEPEND} |
89 |
+ test? ( >=virtual/jdk-1.7 ) |
90 |
+" |
91 |
+ |
92 |
+S=${WORKDIR}/i2p-${PV}/core |
93 |
+ |
94 |
+PATCHES=( |
95 |
+ "${FILESDIR}/${P}"-asmfix.patch |
96 |
+) |
97 |
+ |
98 |
+src_compile() { |
99 |
+ tc-export CC |
100 |
+ |
101 |
+ cd c/jbigi/jbigi/src && |
102 |
+ ../../build_jbigi.sh dynamic || |
103 |
+ die 'unable to build jbigi' |
104 |
+ |
105 |
+ if use test |
106 |
+ then |
107 |
+ cd "${S}/java/src" && |
108 |
+ ejavac -encoding UTF-8 net/i2p/util/NativeBigInteger.java || |
109 |
+ die 'unable to build tests' |
110 |
+ fi |
111 |
+ |
112 |
+ if ( use amd64 || use x86 ) |
113 |
+ then |
114 |
+ cd "${S}/c/jcpuid" && |
115 |
+ ./build.sh || |
116 |
+ die 'unable to build jcpuid' |
117 |
+ fi |
118 |
+} |
119 |
+ |
120 |
+src_test() { |
121 |
+ cd java/src && |
122 |
+ java -Djava.library.path="${S}/c/jbigi/jbigi/src" net/i2p/util/NativeBigInteger || |
123 |
+ die 'unable to pass tests' |
124 |
+} |
125 |
+ |
126 |
+src_install() { |
127 |
+ dolib c/jbigi/jbigi/src/libjbigi.so |
128 |
+ |
129 |
+ if ( use amd64 || use x86 ) |
130 |
+ then |
131 |
+ newlib.so \ |
132 |
+ "c/jcpuid/lib/freenet/support/CPUInformation/libjcpuid-$(tc-arch)-linux.so" \ |
133 |
+ libjcpuid.so |
134 |
+ fi |
135 |
+} |