Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 869857 - games-action/polymc needs dependency on x11-apps/xrandr to launch minecraft
Summary: games-action/polymc needs dependency on x11-apps/xrandr to launch minecraft
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Thiago
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-09-12 12:56 UTC by ev
Modified: 2023-04-10 19:43 UTC (History)
3 users (show)

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


Attachments
log of minecraft failing to launch due to missing xrandr (minecraft.log,14.67 KB, text/x-log)
2022-09-12 12:56 UTC, ev
Details

Note You need to log in before you can comment on or make changes to this bug.
Description ev 2022-09-12 12:56:43 UTC
Created attachment 804847 [details]
log of minecraft failing to launch due to missing xrandr

I've installed games-action/polymc on my minimal sway/wayland desktop and couldn't launch the game.

lwjgl library used by minecraft seems to check available displays using xrandr.
I didn't have x11-apps/xrandr and couldn't launch the game. 

Thread about similar issues on arch forum.
https://bbs.archlinux.org/viewtopic.php?id=221345

Could you please add x11-apps/xrandr as a dependency for this package?

PS. games-action/multimc-bin probably also needs this dependency.
Comment 1 Liu Yujie 2022-09-12 13:03:24 UTC
this is not related to wayland I think
old Minecraft (<= 1.12.2) support needs x11-libs/libXrandr

https://github.com/PolyMC/PolyMC/issues/227
Comment 2 ev 2022-09-12 15:44:02 UTC
It's not directly related to wayland. I've just encountered it on a machine which didn't have x11-apps/xrandr installed. Most normal desktop enviroments probably would have had it installed.  

It requires x11-apps/xrandr.
I've tested with x11-libs/libXrandr installed and it didn't work.
Comment 3 Nowa Ammerlaan gentoo-dev 2022-09-12 18:44:58 UTC
It's already listed as being optionally required for minecraft<=1.12 in the post install phase. I don't think we should add it to the runtime dependencies because it is only required for the older versions of minecraft. 

There are also some other dependencies specific to certain versions of minecraft (e.g certain versions of java). I think we shouldn't add them all to the polymc ebuild because we would be pulling in too many dependencies that aren't strictly necessary for everyone.
Comment 4 Liu Yujie 2022-09-12 19:18:45 UTC
Running minecraft on wayland takes effort.

Old versions (<1.13) currently do not have a workaround for doing this, and you are try to launch version 1.12.2 with forge according to the log you uploaded.

You may want to have a look at https://github.com/Admicos/minecraft-wayland
Comment 5 ev 2022-09-14 14:01:16 UTC
(In reply to Andrew Ammerlaan from comment #3)
> It's already listed as being optionally required for minecraft<=1.12 in the
> post install phase. I don't think we should add it to the runtime
> dependencies because it is only required for the older versions of
> minecraft. 
> 
> There are also some other dependencies specific to certain versions of
> minecraft (e.g certain versions of java). I think we shouldn't add them all
> to the polymc ebuild because we would be pulling in too many dependencies
> that aren't strictly necessary for everyone.

Ok, could you correct post install phase to also mention x11-apps/xrandr?
In my tests having x11-libs/libXrandr doesn't seem to help. Old Minecraft requires x11-apps/xrandr.
People in that github issue also talk about xrandr, not libXrandr. 


(In reply to Liu Yujie from comment #4)
> Running minecraft on wayland takes effort.

I haven't had any issues since I've figured out it needs x11-apps/xrandr. Minecraft on xwayland works ok.

Forge probably doesn't matter. Creating fresh vanilla instance doesn't change the results.
Comment 6 Larry the Git Cow gentoo-dev 2022-09-14 14:16:47 UTC
The bug has been closed via the following commit(s):

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

commit ece8c3c5db656af60a3415fcd375d0500f22a213
Author:     Andrew Ammerlaan <andrewammerlaan@gentoo.org>
AuthorDate: 2022-09-14 14:15:57 +0000
Commit:     Andrew Ammerlaan <andrewammerlaan@gentoo.org>
CommitDate: 2022-09-14 14:16:39 +0000

    games-action/polymc: we need the full xrandr, not just the lib
    
    Closes: https://bugs.gentoo.org/869857
    Signed-off-by: Andrew Ammerlaan <andrewammerlaan@gentoo.org>

 games-action/polymc/polymc-1.4.1-r2.ebuild | 2 +-
 games-action/polymc/polymc-1.4.2-r1.ebuild | 2 +-
 games-action/polymc/polymc-9999.ebuild     | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)