minecraft-wayland icon indicating copy to clipboard operation
minecraft-wayland copied to clipboard

Libdecoration patch status

Open vchernin opened this issue 3 years ago • 15 comments

I've been getting these patches to run in the Minecraft Flatpak, which seems to work reasonably well, Minecraft is actually able to run in Wayland natively within Flatpak. The 4 patches in this repo all work.

I'm wondering if the AUR package can build with libdecoration against GLFW 3.3.4? For me git am usually says things like this:

can't find file to patch at input line 123
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|
|From 3c90e95971b79c43553beb11d1221a65b25fb846 Mon Sep 17 00:00:00 2001
|From: Christian Rauch <[email protected]>
|Date: Mon, 11 May 2020 23:06:32 +0100
|Subject: [PATCH 5/9] CI: change to 'focal'
|
|---
| .travis.yml | 8 ++++----
| 1 file changed, 4 insertions(+), 4 deletions(-)
|
|diff --git a/.travis.yml b/.travis.yml
|index ff67562928..9f51abbe73 100644
|--- a/.travis.yml
|+++ b/.travis.yml
--------------------------

It might just be a matter of getting some dependency into the Flatpak, I mostly wanted to sanity check before reporting this behaviour to https://github.com/glfw/glfw/pull/1693.

Thank you for your work gathering these patches and documenting some steps! I am hopeful that adding it to the Flatpak will help resolve any issues, so GLFW can get mainlined Minecraft Wayland support.

Update: it seems if I remove parts 5/9 and 6/9 from the .patch git am is happy... but it still doesn't compile.

The patch depends on libdecoration itself, which of course makes sense, but it unfortunately doesn't seem to have alot of distro provided packages yet. Maybe there's one in the AUR.

Another update: I seem to be able to build with the libdecoration patch alone, need to test if it actually works.

vchernin avatar Jun 29 '21 20:06 vchernin

You should be able to edit the patch(es) and remove any changes to .travis.yml. That is the only file GitHub claims has any conflicts.

I'll try looking into it, but I don't have a GNOME setup to test things on, so things might break.

Admicos avatar Jun 30 '21 10:06 Admicos

Removing commits 3c90e95971b79c43553beb11d1221a65b25fb846 and be7da8186bbf8ae4de5535dbfc41b06855fd6240 from the PR seem to be enough for the travis.yml issue. Now I'll see what I can do about patch 32327c565ced3cf422778ce27fe5953e00e2e65c failing to apply...

Admicos avatar Jun 30 '21 10:06 Admicos

That patch "applied" fine after I performed the edits manually. Seems like CMakeLists.txt had a few lines since then. Haven't tried building, though. The next patch seems to fail too, but it's a bit longer so I don't want to manually go through and apply that one by hand.

Admicos avatar Jun 30 '21 10:06 Admicos

Did a patch -p1 and manually appllied the one bad chunk. The last commit is even longer and has more complicated changes, so this might take a while (and I am not exactly a big C dev)

Admicos avatar Jun 30 '21 10:06 Admicos

OH WAIT - these patches (except the .travis.yml ones ofc) all apply successfully to the master branch (as opposed to the latest release which was our current target) without any changes. I guess we could change the PKGBUILD to use a snapshot from the git history or something and apply the patches on top.

Admicos avatar Jun 30 '21 10:06 Admicos

I know you're not using this under Arch, but in any case, a testing version of the PKGBUILD is available at https://github.com/Admicos/minecraft-wayland/tree/libdecoration

Admicos avatar Jun 30 '21 10:06 Admicos

7b0c97b works! The Minecraft Flatpak now runs with libdecoration on native Wayland!

To clarify, main 0002-Don-t-crash-on-calls-to-focus-or-icon.patch & 0004-Do-not-crash-on-window-position-set.patch were not really needed in the latest git snapshot, and they were superseeded by 0003-wayland-don-t-crash-app-on-api-calls-to-window-focus.patch?

vchernin avatar Jun 30 '21 17:06 vchernin

I also found libdecoration appears to cause the entire minecraft window to be a bit blurry on my HIDPI monitor, does the AUR package experience this is as well?

There is a general blur to their entire window when libdecor is there. Compare them using this diff, click "Swipe" at the bottom. The image on the right is with the libdecor patch, the one on the left is without. You might need to zoom in if it's not obvious.

vchernin avatar Jun 30 '21 18:06 vchernin

On June 30, 2021 8:52:12 PM GMT+03:00, Vincent Chernin @.***> wrote:

7b0c97b works! The Minecraft Flatpak now runs with libdecoration on native Wayland!

To clarify, main 0002-Don-t-crash-on-calls-to-focus-or-icon.patch & 0004-Do-not-crash-on-window-position-set.patch were not really needed in the latest git snapshot, and they were superseeded by 0003-wayland-don-t-crash-app-on-api-calls-to-window-focus.patch?

AFAIK Patch 0004 partially fixed an issue with Forge before we found a proper fix. It shouldn't be required anymore.

Admicos avatar Jun 30 '21 19:06 Admicos

I also found libdecoration appears to cause the entire minecraft window to be a bit blurry on my HIDPI monitor, does the AUR package experience this is as well?

I don't have a HiDPI monitor so I cannot test that, sorry.

Admicos avatar Jun 30 '21 20:06 Admicos

It might still be an issue even without HIDPI.

Regardless I plan to test these patches out a bit and hopefully narrow down where the bugs are and report them. The more Wayland the better!

vchernin avatar Jun 30 '21 20:06 vchernin

It might still be an issue even without HIDPI.

Regardless I plan to test these patches out a bit and hopefully narrow down where the bugs are and report them. The more Wayland the better!

I have the blur it's one of the biggest issues for me >:( my laptop screen is 3200x1800 that's why, it's pretty HI-DPI

yavko avatar Nov 07 '21 09:11 yavko

It seems to pr fixed in this PR but idk: https://gitlab.gnome.org/jadahl/libdecor/-/merge_requests/30

yavko avatar Nov 07 '21 09:11 yavko

I think that PR doesn't necessarily cover this HiDPI bug we seem to see here.

Support is there and it works, but it doesn't fully work which is the problem.

vchernin avatar Nov 07 '21 09:11 vchernin

I think that PR doesn't necessarily cover this HiDPI bug we seem to see here.

Support is there and it works, but it doesn't fully work which is the problem.

I'll make an issue on the libdecor repo then

yavko avatar Nov 07 '21 09:11 yavko