git.lucas.co / cce-compositor
Wayland compositor (wlroots)
git clone https://git.lucas.co/cce-compositor.git

commit3cf279b0281e2574029ecee0f695916bbeba8348
parentd29381a19a
authorKirill Primak <[email protected]>
date2026-04-18 18:42
river: add Xwayland support info to version

 river/main.zig | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/river/main.zig b/river/main.zig
index 7a10208..6aa89be 100644
--- a/river/main.zig
+++ b/river/main.zig
@@ -29,6 +29,11 @@ const usage: []const u8 =
     \\
 ;
 
+const full_version = std.fmt.comptimePrint("{s} {c}xwayland", .{
+    build_options.version,
+    if (build_options.xwayland) '+' else '-',
+});
+
 pub var server: Server = undefined;
 
 pub fn main() anyerror!void {
@@ -57,7 +62,7 @@ pub fn main() anyerror!void {
     }
 
     if (result.flags.version) {
-        try stdout.writeAll(build_options.version ++ "\n");
+        try stdout.writeAll(full_version ++ "\n");
         try stdout.flush();
         posix.exit(0);
     }
@@ -112,7 +117,7 @@ pub fn main() anyerror!void {
 
     try detectClassic(startup_command);
 
-    log.info("river version {s}, initializing server", .{build_options.version});
+    log.info("initializing river version {s}", .{full_version});
 
     river_init_wlroots_log(switch (runtime_log_level) {
         .debug => .debug,