Previous Thread
Next Thread
Print Thread
Page 2 of 2 1 2
mizapf #123361 03/23/24 09:52 PM
Joined: May 2007
Posts: 584
Likes: 9
M
mizapf Offline OP
Senior Member
OP Offline
Senior Member
M
Joined: May 2007
Posts: 584
Likes: 9
For openSUSE it is /usr/include/wayland/.

mizapf #123374 03/26/24 09:45 AM
Joined: Mar 2004
Posts: 698
Likes: 2
Senior Member
Offline
Senior Member
Joined: Mar 2004
Posts: 698
Likes: 2
Does the following patch help building with USE_WAYLAND=1?
Code
diff --git a/scripts/src/osd/sdl_cfg.lua b/scripts/src/osd/sdl_cfg.lua
index 17132ad814a..75f294a78b6 100644
--- a/scripts/src/osd/sdl_cfg.lua
+++ b/scripts/src/osd/sdl_cfg.lua
@@ -54,6 +54,11 @@ if _OPTIONS["USE_WAYLAND"]=="1" then
        defines {
                "SDLMAME_USE_WAYLAND",
        }
+       if _OPTIONS["targetos"]=="linux" then
+               buildoptions {
+                       backtick(pkgconfigcmd() .. " --cflags wayland-egl"),
+               }
+       end
 end
 
 if _OPTIONS["NO_USE_XINPUT"]=="1" then

mizapf #123387 03/30/24 05:36 AM
Joined: Mar 2004
Posts: 698
Likes: 2
Senior Member
Offline
Senior Member
Joined: Mar 2004
Posts: 698
Likes: 2

mizapf #123388 03/30/24 09:44 PM
Joined: May 2007
Posts: 584
Likes: 9
M
mizapf Offline OP
Senior Member
OP Offline
Senior Member
M
Joined: May 2007
Posts: 584
Likes: 9
Thanks, I'll test it during the next few days and report.

mizapf #123395 04/01/24 02:47 PM
Joined: May 2007
Posts: 584
Likes: 9
M
mizapf Offline OP
Senior Member
OP Offline
Senior Member
M
Joined: May 2007
Posts: 584
Likes: 9
Sorry, does not work yet:

../../../../../3rdparty/bgfx/src/renderer_vk.cpp:21:17: fatal error: wayland-egl-backend.h: No such file or directory
21 | # include <wayland-egl-backend.h>
| ^~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [bgfx.make:573: ../../../../linux_gcc/obj/x64/Release/3rdparty/bgfx/src/renderer_vk.o] Error 1
make[2]: *** Waiting for unfinished jobs....


I see the -I/usr/include/wayland entries in these files:

build/projects/sdl/mame/gmake-linux/mame.make
build/projects/sdl/mame/gmake-linux/ocore_sdl.make
build/projects/sdl/mame/gmake-linux/osd_sdl.make
build/projects/sdl/mame/gmake-linux/qtdbg_sdl.make

but not in

build/projects/sdl/mame/gmake-linux/bgfx.make

I guess that's where it's missing.

mizapf #123396 04/01/24 03:31 PM
Joined: Feb 2004
Posts: 2,597
Likes: 300
Very Senior Member
Offline
Very Senior Member
Joined: Feb 2004
Posts: 2,597
Likes: 300
Raise it upstream, we can cherry-pick a fix.

mizapf #123397 04/01/24 08:25 PM
Joined: Mar 2004
Posts: 698
Likes: 2
Senior Member
Offline
Senior Member
Joined: Mar 2004
Posts: 698
Likes: 2
@mizapf, please give this a shot:
Code
diff --git a/scripts/src/3rdparty.lua b/scripts/src/3rdparty.lua
index 64a8e3b7ab6..fc3ef8a6daa 100755
--- a/scripts/src/3rdparty.lua
+++ b/scripts/src/3rdparty.lua
@@ -1558,6 +1558,9 @@ end
                        defines {
                                "WL_EGL_PLATFORM=1",
                        }
+                       buildoptions {
+                               backtick(pkgconfigcmd() .. " --cflags wayland-egl-backend"),
+                       }
                end
        end
 
@Vas, bgfx upstream seems not to use pkg-config at all.

mizapf #123401 04/04/24 03:46 PM
Joined: May 2007
Posts: 584
Likes: 9
M
mizapf Offline OP
Senior Member
OP Offline
Senior Member
M
Joined: May 2007
Posts: 584
Likes: 9
Looks good, the build was successful. Thanks!

For video=bgfx I have to explicitly set videodriver=wayland. Auto does not work here.

As I said, I'm not really a fan of Wayland (yet). Too many applications that don't work as expected, most notably, keepassxc which loses its hotkey feature. (Not MAME-related, but if anyone knows how to fix that, any hint would be great.)

mizapf #123402 04/04/24 05:09 PM
Joined: Mar 2004
Posts: 698
Likes: 2
Senior Member
Offline
Senior Member
Joined: Mar 2004
Posts: 698
Likes: 2
Happy to hear compilation is fixed.

Regarding "auto", you get your distro's default, mame does not change anything here. You can use -verbose to see what the default you get is. Upstream SDL defaults to X11 afaik, Fedora has overridden this to wayland. I do not know whether openSUSE follows upstream SDL or have changed the default too.

Regarding hotkey - if you are referring to auto-type, vanilla keepass has the kpuinput plugin: https://keepass.info/help/kb/autotype_wayland.html

Last edited by belegdol; 04/04/24 05:10 PM.
1 member likes this: sairuk
Page 2 of 2 1 2

Link Copied to Clipboard
Who's Online Now
3 members (AJR, Golden Child, MrBogi), 283 guests, and 0 robots.
Key: Admin, Global Mod, Mod
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Forum Statistics
Forums9
Topics9,320
Posts121,922
Members5,074
Most Online1,283
Dec 21st, 2022
Our Sponsor
These forums are sponsored by Superior Solitaire, an ad-free card game collection for macOS and iOS. Download it today!

Superior Solitaire
Forum hosted by www.retrogamesformac.com