Lua 5.2 is very different from 5.1. See discussion at $link.
Created attachment 304375 [details] Proposed patch to block too-new versions of Lua Added proposed patch to the builds to block newer versions of Lua.
Created attachment 304377 [details, diff] correctly annotated version of patch
You should add yourself to the maintainers and commit it yourself!
Done & done.
How is this anykind of patch? lua is _NOT_ slotted
Comment on attachment 304377 [details, diff] correctly annotated version of patch bogus
What version isn't compatible and how is it incompatible?
The details of how/why are at $link, as mentioned. As for versions: Lua >=5.2 is sufficiently different from <5.2 that Prosody up to and including 0.8.2 (latest release according to http://prosody.im/ ) will not work with it. Above mentioned link also has the main dev saying that migrating to being 5.2-compatible is desirable and planned -- but no release has been made since then.
It has been 5 years, current prosody version is 0.9.12 Is this really still dependent on lua-5.1 ? What about others like luasec and lua-zlib (also currently depending on lua:0 in portage)?
Prosody-0.10 will support lua-5.2, although it won't be as well-tested as with 5.1 https://prosody.im/issues/issue/299#comment-6 I suggest migrating to lua-5.2 ince prosody-0.10 is released although this is not recommended by the prosody devs. But getting rid of this lua-5.2 blocker should be quite important.
Good news: prosody-0.10.0 is finally released and includes initial support for lua-5.2! http://blog.prosody.im/prosody-0-10-0-released/ Although the developers still recommend lua-5.1 for stable servers, it might be worth a thought to create at least a use flag for running prosody with lua-5.2 if other packages require lua-5.2. That way we can get rid of the lua blocker while still running prosody as stable as possible with 5.1 if no other packages require a lua-5.2 Is this actually possible with portage?
I'd prefer to just remove the blocker and allow lua 5.2 (from what i gathered the 5.1 recommendation in the changelog is just "in case"... ) Maybe adding a local use flag lua51 for now and just could be just dropped later
So for Prosody >=0.11 upstream recommends Lua 5.2: "The recommended Lua version for 0.11 is Lua 5.2, while Lua 5.1 is still supported for the platforms that need it. However the 0.11.x series is the last series that will still support Lua 5.1 (and by extension, LuaJIT)." (from https://prosody.im/doc/release/0.11.0#lua-5.2) Thus arguably, this bug can be closed. Note that it is not the last blocker for the 5.2 unmasking bug. I will try and do some testing of Prosody with 5.2 sometime soon and the report back here.
As of right now, net-im/prosody-0.11.5 builds fine against lua-5.2. Regarding 5.3, the ebuild as it stands now pulls in dev-lua/LuaBitOp - which is not and will likely never be (https://www.freelists.org/post/luajit/Port-bitop-to-53,1) compatible with Lua versions newer than 5.2. Fortunately, Prosody can use the module "bit32" instead - which is built into Lua-5.2+ and is available in Gentoo for 5.1 as dev-lua/lua-bit32.
Note that I haven't been running Prosody in over a year, and as such the package is maintainer-needed (or -wanted, if you prefer). I asked on -dev if someone wanted to take over, but nobody stepped up.
(In reply to Tobias Klausmann from comment #15) > Note that I haven't been running Prosody in over a year, and as such the > package is maintainer-needed (or -wanted, if you prefer). > > I asked on -dev if someone wanted to take over, but nobody stepped up. Haven't seen that, so added myself now as maintainer, since I am running it still. I've revbumped to far to newest version and overhauled the ebuild. (In reply to Marek Szuba from comment #14) > As of right now, net-im/prosody-0.11.5 builds fine against lua-5.2. > > Regarding 5.3, the ebuild as it stands now pulls in dev-lua/LuaBitOp - which > is not and will likely never be > (https://www.freelists.org/post/luajit/Port-bitop-to-53,1) compatible with > Lua versions newer than 5.2. Fortunately, Prosody can use the module "bit32" > instead - which is built into Lua-5.2+ and is available in Gentoo for 5.1 as > dev-lua/lua-bit32. @Marek: Currently Lua 5.2 is masked. What are the plans to unmask? I am not really deep into lua, to let's see what we can do here. So you suggest to drop dev-lua/LuaBitOp and use dev-lua/lua-bit32 only on lua5.1 versions? I guess, that needs your new eclass for slotting lua, which you recently commited?
Using dev-lua/lua-bit32 instead of won't launch prosody, as it will fail with: Prosody was unable to find lua-bitops There is a check inside /usr/lib64/prosody/util/dependencies.lua: > local bit = _G.bit32 or softreq"bit"; > > if not bit then > missingdep("lua-bitops", { > ["Debian/Ubuntu"] = "sudo apt-get install lua-bitop"; > ["luarocks"] = "luarocks install luabitop"; > ["Source"] = "http://bitop.luajit.org/"; > }, "WebSocket support will not be available"); > end If I do change that to match bit32 from dev-lua/lua-bit32, this seems to make the error (correctly?) go away. I am a little bit worried, that "_G.bit32" seems to be always false on both packages? OLD: local bit = _G.bit32 or softreq"bit"; NEW: local bit = _G.bit32 or softreq"bit32"; After those changes, my prosody server seems to run fine. I don't see any error in my log files regarding bit(32) stuff.
Ah, I guess the check is complete. Looking into /usr/lib64/prosody/net/websocket/frames.lua, there is a difference check: > local bit = assert(softreq"bit" or softreq"bit32", > "No bit module found. See https://prosody.im/doc/depends#bitop"); I guess, the main check needs to be adjusted.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=21185d1a53f9597691eff67f05f7ac4fa0a3c769 commit 21185d1a53f9597691eff67f05f7ac4fa0a3c769 Author: Conrad Kostecki <conikost@gentoo.org> AuthorDate: 2020-10-10 15:53:20 +0000 Commit: Conrad Kostecki <conikost@gentoo.org> CommitDate: 2020-10-10 15:57:23 +0000 net-im/prosody: switch to bit32, update init scripts Since dev-lua/LuaBitOp is not supported on >=lua-5.2, switching to dev-lua/lua-bit32 as an alternative, since it's supported by upstream. Also updated the init scripts, since starting with prosodyctl is not recomended and current init scripts warns about not using it. Closes: https://bugs.gentoo.org/407079 Package-Manager: Portage-3.0.8, Repoman-3.0.1 Signed-off-by: Conrad Kostecki <conikost@gentoo.org> net-im/prosody/files/prosody-0.11.7-bit32.patch | 20 +++++ net-im/prosody/files/prosody-0.11.7-gentoo.patch | 29 +++++++ net-im/prosody/files/prosody.initd-r4 | 43 +++++++++++ net-im/prosody/files/prosody.service-r1 | 13 ++++ net-im/prosody/files/prosody.tmpfilesd-r1 | 1 + net-im/prosody/prosody-0.11.7-r1.ebuild | 96 ++++++++++++++++++++++++ 6 files changed, 202 insertions(+)