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

commit6ea37671692ec64b0d743012b1730bb27bcbbd7c
parent50cd40203c
authorIsaac Freund <[email protected]>
date2024-01-01 22:48
build: require at least wlroots 0.17.1

There are enough bugs fixed in 0.17.1 which are relevant to river that I
think it's worthwhile to refuse to compile against 0.17.1.

 .builds/alpine.yml    | 2 +-
 .builds/archlinux.yml | 2 +-
 .builds/freebsd.yml   | 2 +-
 README.md             | 2 +-
 river/main.zig        | 6 ++++++
 5 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/.builds/alpine.yml b/.builds/alpine.yml
index a33be10..3ab38c4 100644
--- a/.builds/alpine.yml
+++ b/.builds/alpine.yml
@@ -34,7 +34,7 @@ tasks:
       cd ..
 
       cd wlroots
-      git checkout 0.17.0
+      git checkout 0.17.1
       meson setup build --auto-features=enabled -Drenderers=gles2 -Dexamples=false \
             -Dwerror=false -Db_ndebug=false -Dxcb-errors=disabled --prefix /usr
       sudo ninja -C build/ install
diff --git a/.builds/archlinux.yml b/.builds/archlinux.yml
index f4dc688..7b89bd5 100644
--- a/.builds/archlinux.yml
+++ b/.builds/archlinux.yml
@@ -32,7 +32,7 @@ tasks:
       cd ..
 
       cd wlroots
-      git checkout 0.17.0
+      git checkout 0.17.1
       meson setup build --auto-features=enabled -Drenderers=gles2 -Dexamples=false \
             -Dwerror=false -Db_ndebug=false --prefix /usr
       sudo ninja -C build/ install
diff --git a/.builds/freebsd.yml b/.builds/freebsd.yml
index 367f5c0..e1b3e81 100644
--- a/.builds/freebsd.yml
+++ b/.builds/freebsd.yml
@@ -36,7 +36,7 @@ tasks:
       cd ..
 
       cd wlroots
-      git checkout 0.17.0
+      git checkout 0.17.1
       meson setup build --auto-features=enabled -Drenderers=gles2 -Dexamples=false \
             -Dwerror=false -Db_ndebug=false --prefix /usr
       sudo ninja -C build/ install
diff --git a/README.md b/README.md
index e36f8ad..81c6bd7 100644
--- a/README.md
+++ b/README.md
@@ -38,7 +38,7 @@ distribution.
 - [zig](https://ziglang.org/download/) 0.11
 - wayland
 - wayland-protocols
-- [wlroots](https://gitlab.freedesktop.org/wlroots/wlroots) 0.17
+- [wlroots](https://gitlab.freedesktop.org/wlroots/wlroots) 0.17.1
 - xkbcommon
 - libevdev
 - pixman
diff --git a/river/main.zig b/river/main.zig
index 54e5e77..81b558c 100644
--- a/river/main.zig
+++ b/river/main.zig
@@ -29,6 +29,12 @@ const util = @import("util.zig");
 
 const Server = @import("Server.zig");
 
+comptime {
+    if (wlr.version.major != 0 or wlr.version.minor != 17 or wlr.version.micro < 1) {
+        @compileError("river requires at least wlroots version 0.17.1 due to bugs in wlroots 0.17.0");
+    }
+}
+
 const usage: []const u8 =
     \\usage: river [options]
     \\