novelrt / NovelRT

A cross-platform 2D game engine accompanied by a strong toolset for visual novels.
MIT License
183 stars 43 forks source link

Add fix for Wayland support in GLFW. #525

Closed RubyNova closed 1 year ago

RubyNova commented 1 year ago

Please check if the PR fulfills these requirements

What kind of change does this PR introduce? (Bug fix, feature, docs update, ...) This change enables support for the Wayland windowing system inside our build of GLFW.

Is there an open issue that this resolves? If so, please link it here. No issue to track for this bug.

What is the current behavior? (You can also link to an open issue here) GLFW will compile for X11 only, causing wayland-only systems to fail.

What is the new behavior (if this is a feature change)? Wayland-only systems should be able to use the GLFW windowing backend correctly.

Does this PR introduce a breaking change? (What changes might users need to make in their application due to this PR?) No.

Other information: Documentation that directed this change can be found here: https://www.glfw.org/docs/latest/compile.html#compile_options_wayland

RubyNova commented 1 year ago

Nevermind. Ignore. Just read that you need the X11 interface for better NVIDIA support anyway.

FiniteReality commented 1 year ago

We should probably keep this option on anyway, as most applications will gracefully fall back to X11 if Wayland is not present. It's unlikely that a NVIDIA user would be using Wayland at the current time anyway.

capnkenny commented 1 year ago

That would leave this blocked, as GLFW has a bug (fixed in main but not released yet) that actually prevents X11 & Wayland support from compiling together (as we accidentally discovered today 😅)

FiniteReality commented 1 year ago

Oh, that's unfortunate. In that case, yeah, we should open a blocked issue for Wayland support.