Bug 33241 - Emacs build does not work correctly on Wayland GNOME.
Summary: Emacs build does not work correctly on Wayland GNOME.
Status: NEW
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: 9
Hardware: x86_64 Linux
Priority: Normal minor
Target Milestone: ---
Assignee: Nicolas Salguero
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-05-26 00:58 CEST by Omar Purata Funes
Modified: 2024-07-08 16:00 CEST (History)
0 users

See Also:
Source RPM: emacs-28.2-10.1.mga9.src.rpm
CVE:
Status comment:


Attachments

Description Omar Purata Funes 2024-05-26 00:58:49 CEST
Description of problem:

Hello Mageia developers. Thanks for taking the time to read this bug. Currently, the shipped GNOME version in Mageia 9 is 44, and it uses wayland by default. This makes the provided Emacs package behave strangely inside a wayland session, mainly due to graphical bugs such as black corners/borders when snapping the GTK window.

I know the v9 errata proposes switching back to Xorg. However, I think that may be overkill for this package.


Version-Release number of selected component (if applicable): 28.2


How reproducible: Probably easy

Steps to Reproduce:
1. Install emacs via dnf
2. Open a new emacs (gtk) window and snap it to either side of the screen.
3. Notice the errors in the borders of the window.

I tested this with both stock adwaita and third party themes, and the issue still persists. I managed to compile emacs for myself using podman and the --with-pgtk configuration flag, which seems to enhance support for wayland. However, I did not know how to “repackage” the Mageia version in a suitable .rpm format.

I also marked this as minor since, “technically” all I had to do was steal the configuration used in mageia emacs and add the --with-pgtk flag to configure.
Comment 1 Lewis Smith 2024-05-26 20:23:36 CEST
Thank you for the report. Agreed, it is not serious.

Assigning this to ns80, the main maintainer of emacs.
If you (Nicolas) can put a version of emacs in Core/Updates_Testing compiled as the user suggests, so that *he* can try it from there, that would be easiest for him.
Otherwise, explain whether & how he can convert his compiled emacs into a package so that he can install it locally to try. I suspect that might be complicated.

Assignee: bugsquad => nicolas.salguero

Comment 2 Omar Purata Funes 2024-05-27 07:46:36 CEST
I'm willing to help with testing if my assistance is needed. The mageia podman image has proven to be very useful for these tasks.

I made some research and tried with both fedpkg-minimal and rpmbuild to no avail. I'll keep you updated if I find anything else in the meantime.

Thanks for taking this into account!
Comment 3 Nicolas Salguero 2024-05-27 10:23:08 CEST
Hi,

For Mageia 9, emacs cannot be built with --with-pgtk flag because:
1) It means emacs could not be used with x11 any more but only with wayland.
2) That flag is in emacs >= 29 and Mageia 9 ships version 28.2.

For Cauldron, I will try to build emacs twice when I have some time.

Best regards,

Nico.
Comment 4 Nicolas Salguero 2024-05-31 15:43:14 CEST
Hi,

For Cauldron, could you test if replacing emacs-29.3-3.mga10 by emacs-pgtk-29.3-3.mga10 solves the issue, please?

Best regards,

Nico.
Comment 5 Omar Purata Funes 2024-06-01 22:46:35 CEST
Sorry for the late response. I had to test the package to give proper answers. Redirecting display output from podman to wayland was a complete odyssey. 

I tried both:

- emacs-pgtk-29.3-3.mga10.x86_64 inside Mageia Cauldron container image
- emacs-pgtk-29.3-3.mga10.x86_64 inside Mageia Cauldron qemu

I tried backporting it using Mageia 9 libraries but I think this is not possibile due to incomatibilities with: libc (version), libjansson-devel (couldn't find that in dnf) and emacs-common.

Thanks a lot for attending this.
Comment 6 Nicolas Salguero 2024-07-08 16:00:00 CEST
Hi,

I built emacs 29.4 for Mageia 9. Can you test it, please?

Best regards,

Nico.

Note You need to log in before you can comment on or make changes to this bug.