From 2cc94ee095134be7eeed5528a2e175f589371e86 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=80=9A=E6=B4=B2?= Date: Sat, 27 Jul 2024 19:53:25 +0800 Subject: [PATCH] DisplayServer (Linux): fix build with no wayland support --- src/detection/displayserver/linux/wayland/wayland.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/detection/displayserver/linux/wayland/wayland.c b/src/detection/displayserver/linux/wayland/wayland.c index 603d373af..3fc59362a 100644 --- a/src/detection/displayserver/linux/wayland/wayland.c +++ b/src/detection/displayserver/linux/wayland/wayland.c @@ -133,7 +133,6 @@ uint32_t ffWaylandHandleRotation(WaylandDisplay* display) } return rotation; } -#endif const char* ffdsConnectWayland(FFDisplayServerResult* result) { @@ -261,3 +260,12 @@ const char* ffdsConnectWayland(FFDisplayServerResult* result) ffStrbufSetStatic(&result->wmProtocolName, FF_WM_PROTOCOL_WAYLAND); return NULL; } + +#else + +const char* ffdsConnectWayland(FF_MAYBE_UNUSED FFDisplayServerResult* result) +{ + return "Fastfetch was compiled without Wayland support"; +} + +#endif