New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
net-p2p/retroshare: Version bump #21725
Conversation
Pull Request assignmentSubmitter: @G10h4ck net-p2p/retroshare: @G10h4ck, @gentoo/proxy-maint Linked bugsBugs linked: 798048, 798099, 785964, 779838 In order to force reassignment and/or bug reference scan, please append Docs: Code of Conduct ● Copyright policy (expl.) ● Devmanual ● GitHub PRs ● Proxy-maint guide |
Pull request CI reportReport generated at: 2021-07-20 12:29 UTC There are existing issues already. Please look into the report to make sure none of them affect the packages in question: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Be nice if the ebuild could receive some modernizing.
Small review for that if interested in a few suggestions (haven't really looked into building/runtime/bugs side of things).
net-p2p/retroshare/metadata.xml
Outdated
<flag name="autologin">Enables potentially insecure autologin capability via libsecret</flag> | ||
<flag name="cli">Enables terminal login support for retroshare-service</flag> | ||
<flag name="control-socket">Enables API via Unix socket support</flag> | ||
<flag name="gnome-keyring">Enables potentially insecure autologin capability via Gnome Keyring</flag> | ||
<flag name="jsonapi">Enables the new RetroShare JSON API</flag> | ||
<flag name="libupnp">Enables UPnP port forwarding via libupnp</flag> | ||
<flag name="miniupnp">Enables UPnP port forwarding via miniupnpc</flag> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If going to mention other packages, usually should use, e.g. <pkg>app-crypt/libsecret</pkg>
HOMEPAGE="https://retroshare.cc" | ||
SRC_URI="http://download.opensuse.org/repositories/network:/retroshare/Debian_Testing/retroshare-common_${PV}.orig.tar.gz -> ${P}.tar.gz" | ||
|
||
# pegmarkdown can also be used with MIT |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is this about? If something allows picking one of two license, you can use || ( license1 license2 )
libupnp? ( net-libs/libupnp ) | ||
miniupnp? ( net-libs/miniupnpc ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Both of these define a subslot, unsure how often it changes but usually enough reason to add :=
virtual/pkgconfig | ||
jsonapi? ( app-doc/doxygen )" | ||
|
||
S="${WORKDIR}"/RetroShare |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just style but be nice to move this right under SRC_URI with no blank line to match skel.ebuild ordering, and for S= usually S="${var}/full quoting"
is used (not that I'm saying should do that everywhere, just more of a convention thing in global scope except for EAPI variable).
# CRLF endings break patch... | ||
edos2unix retroshare-gui/src/gui/elastic/elnode.h |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's okay to leave like that not to complicate things with two patch versions, but just to say patch could've been converted to contain the right line terminators instead.
done | ||
} | ||
|
||
pkg_pretend() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Phases should be sorted in execution order, pretend is the first thing executed.
https://devmanual.gentoo.org/ebuild-writing/functions/index.html
Although see next comment.
pkg_pretend() { | ||
if ! use sqlcipher; then | ||
ewarn "You have disabled GXS database encryption, ${PN} will use SQLite" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Given this doesn't abort, there may not be much sense in having this in pretend.
If you wish, you could display this message only when flag is actually toggled. Can be done by checking in pkg_preinst what is currently set on the system, e.g.
if ! use sqlcipher && ! has_version "net-p2p/retroshare[-sqlcipher]"
not to nag every single time if it was disabled.
pkg_preinst() { | ||
local ver | ||
for ver in ${REPLACING_VERSIONS}; do | ||
if ver_test ${ver} -lt 0.5.9999; then | ||
ewarn "You are upgrading from Retroshare 0.5.* to ${PV}" | ||
ewarn "Version 0.6.* is backward-incompatible with 0.5 branch" | ||
ewarn "and clients with 0.6.* can not connect to clients that have 0.5.*" | ||
ewarn "It's recommended to drop all your configuration and either" | ||
ewarn "generate a new certificate or import existing from a backup" | ||
break | ||
fi | ||
if ver_test ${ver} -ge 0.6.0 && ver_test ${ver} -lt 0.6.4; then | ||
elog "Main executable has been renamed upstream from RetroShare06 to retroshare" | ||
break | ||
fi | ||
done | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Messages normally go in pkg_postinst rather than preinst but it's okay if you find it convenient (notably useful if need to use has_version checks, see sqlcipher comment).
Also, loop isn't wrong per-se but if this package is never going to be slotted then${REPLACING_VERSIONS}
will only ever be either an empty string or exactly 1 version. This allows to safely do something like:
if [[ ${REPLACING_VERSIONS} ]]; then
if ver_test ${REPLACING_VERSIONS} -lt ...; then
pkg_postinst() { | ||
xdg_icon_cache_update | ||
} | ||
|
||
pkg_postrm() { | ||
xdg_icon_cache_update | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe migrate from xdg-utils to xdg.eclass, just need to inherit it, remove this stuff, and ensure exported functions are called if overriding them (except xdg_src_prepare, that one is not important and export considered for removal in eapi-8).
https://devmanual.gentoo.org/eclass-reference/xdg.eclass/index.html
@@ -0,0 +1,143 @@ | |||
# Copyright 1999-2021 Gentoo Authors |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see updating the old ebuild too, is there a reason to? i.e. are you planning to stabilize -r3 over 0.6.6 or something? Or is there a problem with 0.6.6 that will make users want to keep using 0.6.5?
I don't use this, so I wouldn't know.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I plan to stabilize 0.6.6 but there might be problems with new version so I also wanted to do a minimal maintenance of 0.6.5 in case someone need to stick to that retroshare version
7ecd9de
to
ca7505c
Compare
Thanks for suggestions @ionenwks I have updated 0.6.6 ebuild according to them, can this be merged now? |
Pull request CI reportReport generated at: 2021-08-04 16:09 UTC There are existing issues already. Please look into the report to make sure none of them affect the packages in question: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for suggestions @ionenwks I have updated 0.6.6 ebuild according to them, can this be merged now?
Thanks, changes look good but still a few things.
Keeping 0.6.5-r3 is fine but I forgot to mention that it should be added in a separate commit. Version bumps are normally done in their own commit to allow easy reversal and could have a message for changes to specific to 0.6.5.
May also want to change Bug:
tags to Closes:
, if it's fixed it can be closed (unless you prefer to wait for stabilization to do that, up to you how to handle your bugs -- personally tend to close when fixed in ~arch unless it's affecting many users that may need to find the bug).
But more importantly, this time I tried to build and seem to get getting build issues with gcc11 for 0.6.6 with any USE combinations:
util/rsdir.cc:280:38: error: 'create_directories' is not a member of 'std::filesystem'
280 | if(!std::filesystem::create_directories(dest_dir))
Builds fine with append-cxxflags -std=c++14
(that's because gcc11 defaults to c++17), but that's more of a temporary workaround than a fix, preferable would be to patch rsdir.cc to #include <filesystem>
and send that upstream (if haven't yet, do check the clean patch howto).
Also, noticed a few other minor things.
fi | ||
} | ||
|
||
pkg_preinst() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No longer need to define the postinst/postrm with xdg.eclass, but it has a preinst and being overwritten here.
pkg_preinst() { | |
pkg_preinst() { | |
xdg_pkg_preinst | |
Or else it leads to:
* QA Notice: new icons were found installed but icon cache
* has not been updated:
* /usr/share/icons/hicolor/64x64/apps/retroshare.png
fi | ||
|
||
if [[ ${REPLACING_VERSIONS} ]]; then | ||
if ver_test ${REPLACING_VERSIONS} -lt 0.5.9999; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could make this -lt 0.6
Fixes a bunch of bugs fixed upstream in newer version and disabling components that are been obsoleted upstream in older versions Modernize 0.6.6 ebuild after ionenwks suggestions Bug: https://bugs.gentoo.org/785964 Bug: https://bugs.gentoo.org/779838 Bug: https://bugs.gentoo.org/798048 Bug: https://bugs.gentoo.org/798099 Package-Manager: Portage-3.0.20, Repoman-3.0.2 Signed-off-by: Gioacchino Mazzurco <gio@altermundi.net>
Fixes a bunch of bugs disabling components that are been obsoleted upstream in older versions Bug: https://bugs.gentoo.org/779838 Bug: https://bugs.gentoo.org/798048 Bug: https://bugs.gentoo.org/798099 Package-Manager: Portage-3.0.20, Repoman-3.0.2 Signed-off-by: Gioacchino Mazzurco <gio@altermundi.net>
ca7505c
to
87bd077
Compare
Pull request CI reportReport generated at: 2021-08-06 15:44 UTC There are existing issues already. Please look into the report to make sure none of them affect the packages in question: |
Thanks for the careful review @ionenwks all your remarks should be addressed ;) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the careful review @ionenwks all your remarks should be addressed ;)
Is it ok to merge this now?
Indeed, looks good. I see cleaned the edos2unix too, nice -- and hadn't realized you were the upstream, guess I didn't need to say anything about upstreaming patches :) Thanks for your work.
May also want to change
Bug:
tags toCloses:
, if it's fixed it can be closed (unless you prefer to wait for stabilization to do that, [...]
Haven't heard back of your preference on this point, assume it was overlooked considering there's no reason not to close the version bump one at least. I'll go ahead and switch to Closes:
myself where relevant so this doesn't have to wait longer.
Thanks! |
Fixes a bunch of bugs fixed upstream in newer version and disabling
components that are been obsoleted upstream in older versions
Bug: https://bugs.gentoo.org/785964
Bug: https://bugs.gentoo.org/779838
Bug: https://bugs.gentoo.org/798048
Bug: https://bugs.gentoo.org/798099
Package-Manager: Portage-3.0.20, Repoman-3.0.2
Signed-off-by: Gioacchino Mazzurco gio@altermundi.net