Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 906882 - net-libs/nativebiginteger: should be last rited after integration into net-vpn/i2p and merge of PR #30643
Summary: net-libs/nativebiginteger: should be last rited after integration into net-vp...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: tharvik
URL:
Whiteboard:
Keywords: PullRequest
Depends on:
Blocks:
 
Reported: 2023-05-21 06:29 UTC by Volkmar W. Pogatzki
Modified: 2023-09-15 08:04 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
dependency tree (dependencies_freenet-build01497,2.48 KB, text/plain)
2023-05-23 09:49 UTC, Volkmar W. Pogatzki
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Volkmar W. Pogatzki 2023-05-21 06:29:34 UTC
net-p2p/freenet/freenet-0.7.5_p1497 needs Java classes related to nativebiginteger and CPUInformation:

Presently only the native libraries are present in net-libs/nativebiginteger.
It should also include following classes from net-vpn/i2p:
core/java/src/freenet/support/CPUInformation/*
core/java/src/net/i2p/util/NativeBigInteger.java
Comment 1 tharvik 2023-05-21 23:32:24 UTC
I don't thinks that really doable without pulling much of i2p. NativeBigInteger is using net.i2p.I2PAppContext (a kind of global configuration object) at a bunch of places, which needs pretty much everything else in core. That might be a bit big.

One way to workaround it would be to split i2p into its subparts, such as i2p-core, i2psnark, i2p-addressbook, ... I don't know how well these can be split, but it seems to be supported for at least one app. In this case, freenet would depend on the new net-vpn/i2p-core, thus reducing the number of pulled deps.

Another workaround would be to have freenet handling their own version of NativeBigInteger and CPUInfo* as they are already bundling the built libs (but not related java files) in their contrib repo.

Anyway, with any of theses fixes, I don't see the point of keeping net-libs/nativebiginteger around.
Comment 2 Volkmar W. Pogatzki 2023-05-22 08:05:00 UTC
(In reply to tharvik from comment #1)
> [...]
> Another workaround would be to have freenet handling their own version of
> NativeBigInteger and CPUInfo* as they are already bundling the built libs
> (but not related java files) in their contrib repo.

You might have seen that https://github.com/gentoo/gentoo/pull/30643 already switches away from net-libs/nativebiginteger in favor of freenet-ext-29 which has all necessary java files.

> 
> Anyway, with any of theses fixes, I don't see the point of keeping
> net-libs/nativebiginteger around.

The only reason to keep might be some few duplicate java classes like NativeBigInteger.class and also duplicate native code once in net-vpn/i2p and once in dev-java/freenet-ext.
Comment 3 tharvik 2023-05-23 09:39:14 UTC
> > Another workaround would be to have freenet handling their own version of
> > NativeBigInteger and CPUInfo* as they are already bundling the built libs
> > (but not related java files) in their contrib repo.
> 
> You might have seen that https://github.com/gentoo/gentoo/pull/30643 already
> switches away from net-libs/nativebiginteger in favor of freenet-ext-29
> which has all necessary java files.

Indeed, it should work for freenet with contrib:v29. But contrib:v50 or its main branch doesn't have the java files anymore, they only appear on their "legacy" repo nowadays. I don't even understand with which NativeBigInteger latest freenet is built now: from I2P (but no info in readme/gradle) or via contrib:v29 (but v50 has been out for the last 8 years)?
And what do we do when contrib:v50 is required?

> > Anyway, with any of theses fixes, I don't see the point of keeping
> > net-libs/nativebiginteger around.
> 
> The only reason to keep might be some few duplicate java classes like
> NativeBigInteger.class and also duplicate native code once in net-vpn/i2p
> and once in dev-java/freenet-ext.

Both version differed quite a while back. I2P's added support for many new CPUs, new GMP version, their own handling of tmpfile, caching and logging, bunch of fixes and speedups, ... That would be nice if freenet could use thoses improvements but I can't really do it by crippling i2p's implementation, via a patch removing i2p specifics for eg.
Comment 4 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-05-23 09:39:46 UTC
Right, they're essentially codebases with a shared heritage but not the same versions at all.
Comment 5 Volkmar W. Pogatzki 2023-05-23 09:49:17 UTC
Created attachment 862259 [details]
dependency tree

(In reply to tharvik from comment #3)
> [...]
> Indeed, it should work for freenet with contrib:v29. But contrib:v50 or its
> main branch doesn't have the java files anymore, they only appear on their
> "legacy" repo nowadays. I don't even understand with which NativeBigInteger
> latest freenet is built now: from I2P (but no info in readme/gradle) or via
> contrib:v29 

I am adding the dependency tree I got from running
gradle dependencies | sed -n '/Classpath/,/^$/p'
Comment 6 tharvik 2023-05-23 11:17:05 UTC
(In reply to Volkmar W. Pogatzki from comment #5)
> (In reply to tharvik from comment #3)
> > I don't even understand with which NativeBigInteger
> > latest freenet is built now: from I2P (but no info in readme/gradle) or via
> > contrib:v29 
> 
> I am adding the dependency tree I got from running
> gradle dependencies | sed -n '/Classpath/,/^$/p'

Thansk, that makes it clearer :) still got no idea why tag v50 was even created, probably only upstream knows.

(In reply to Sam James from comment #4)
> Right, they're essentially codebases with a shared heritage but not the same
> versions at all.

Absorbing it in =net-vpn/i2p-2.2.1
Comment 7 Larry the Git Cow gentoo-dev 2023-06-14 04:17:03 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=dd1ef40c9adf86cec9376946000accd5dcada4b0

commit dd1ef40c9adf86cec9376946000accd5dcada4b0
Author:     Valérian Rousset <tharvik@users.noreply.github.com>
AuthorDate: 2023-06-03 16:42:05 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-06-14 04:16:35 +0000

    net-vpn/i2p: add 2.2.1
    
    Closes: https://bugs.gentoo.org/906820
    Bug: https://bugs.gentoo.org/906882
    Signed-off-by: Valérian Rousset <tharvik@users.noreply.github.com>
    Closes: https://github.com/gentoo/gentoo/pull/31291
    Signed-off-by: Sam James <sam@gentoo.org>

 net-vpn/i2p/Manifest                              |   1 +
 net-vpn/i2p/files/2.2.1-fix-junit-classpath.patch | 122 ++++++++++
 net-vpn/i2p/i2p-2.2.1.ebuild                      | 266 ++++++++++++++++++++++
 3 files changed, 389 insertions(+)
Comment 8 Larry the Git Cow gentoo-dev 2023-07-18 17:23:30 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9ce679d4e9e2d0934814a61cc6bbeaf10da2a02b

commit 9ce679d4e9e2d0934814a61cc6bbeaf10da2a02b
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2023-07-18 17:22:57 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2023-07-18 17:23:05 +0000

    net-vpn/i2p: drop 1.7.0-r1
    
    Bug: https://bugs.gentoo.org/906882
    Signed-off-by: Sam James <sam@gentoo.org>

 net-vpn/i2p/Manifest                |   1 -
 net-vpn/i2p/files/1.7.0-i2p.init    |  17 -----
 net-vpn/i2p/files/1.7.0-i2p.service |  10 ---
 net-vpn/i2p/i2p-1.7.0-r1.ebuild     | 139 ------------------------------------
 net-vpn/i2p/metadata.xml            |   3 -
 5 files changed, 170 deletions(-)
Comment 9 Larry the Git Cow gentoo-dev 2023-08-06 05:48:03 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=52f4a0471bd6c78f186729bd52d98c43c71d0bc7

commit 52f4a0471bd6c78f186729bd52d98c43c71d0bc7
Author:     Volkmar W. Pogatzki <gentoo@pogatzki.net>
AuthorDate: 2023-07-21 06:19:29 +0000
Commit:     Miroslav Šulc <fordfrog@gentoo.org>
CommitDate: 2023-08-06 05:47:50 +0000

    profiles: Last rite net-libs/nativebiginteger
    
    Bug: https://bugs.gentoo.org/906882
    Signed-off-by: Volkmar W. Pogatzki <gentoo@pogatzki.net>
    Closes: https://github.com/gentoo/gentoo/pull/31989
    Signed-off-by: Miroslav Šulc <fordfrog@gentoo.org>

 profiles/package.mask | 5 +++++
 1 file changed, 5 insertions(+)
Comment 10 Larry the Git Cow gentoo-dev 2023-09-15 08:04:53 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=83cdebeffe1c3b2af2bc8dd85d85a1abf921b7ba

commit 83cdebeffe1c3b2af2bc8dd85d85a1abf921b7ba
Author:     David Seifert <soap@gentoo.org>
AuthorDate: 2023-09-15 08:04:41 +0000
Commit:     David Seifert <soap@gentoo.org>
CommitDate: 2023-09-15 08:04:41 +0000

    net-libs/nativebiginteger: treeclean
    
    Closes: https://bugs.gentoo.org/906882
    Signed-off-by: David Seifert <soap@gentoo.org>

 net-libs/nativebiginteger/Manifest                 |  2 -
 net-libs/nativebiginteger/metadata.xml             | 15 -----
 .../nativebiginteger/nativebiginteger-1.6.1.ebuild | 67 --------------------
 .../nativebiginteger/nativebiginteger-2.1.0.ebuild | 71 ----------------------
 profiles/package.mask                              |  5 --
 5 files changed, 160 deletions(-)