Created attachment 224844 [details]
This patch is [1/4] from series of patches. The patches are posted in the order poudriere builds qt5-gui and its dependencies.
This is needed for qt5-gui to build and run in a pure Wayland environment. Tested with:
OPTIONS_UNSET+= CONSOLEKIT OPENGL PULSEAUDIO VDPAU X11 XCB XLIB
Note that Qt 5 has a weird build system that picks up if libX11 is installed or not. Turning off X11 like adding no-xcb and stuff to QT_CONFIG does not work. I currently don't have the time to dig deeper into Qt build system, I already have PipeWire to do. This depends on bug 254584, because xkeyboard-config gets installed into poudriere jail, without that patch libX11 gets installed.
Tested both pure Wayland and X11 with KeepassXC and this series of patches. Note that KeePassXC includes Xlib in one place, I locally patched it for pure Wayland.
This should build a Qt application in a pure Wayland environment that depends on qt5-gui and does not include X11 dependencies.
I know that there are other Qt 5 ports as well, though one can't start making X11 optional without the qt5-gui port first.
PORTREVISION is bumped to catch regressions if any.