New comment by dkwo on void-packages repository https://github.com/void-linux/void-packages/pull/49935#issuecomment-2120983855 Comment: New river and waylock are now out, which makes this PR viable. However, the build style probably needs upgrading to use zig package manager, see e.g. https://codeberg.org/river/river/src/branch/master/PACKAGING.md This works for me on x86_64 with static zig 0.12, but it probably needs some refinement to be included in void's build style: ``` # Template file for 'river' pkgname=river -version=0.2.4 -revision=3 +version=0.3.2 +revision=1 archs="~i686* ~armv6l* ~armv7l*" build_style=zig-build -configure_args="$(vopt_if xwayland -Dxwayland) -Dpie" -hostmakedepends="pkg-config wayland-devel scdoc" -makedepends="wlroots0.16-devel libevdev-devel pixman-devel +hostmakedepends="pkg-config wayland-devel scdoc zig" +makedepends="wlroots0.17-devel libevdev-devel pixman-devel wayland-protocols libxkbcommon-devel wayland-devel" -depends="$(vopt_if xwayland xorg-server-xwayland)" +depends="xorg-server-xwayland" short_desc="Dynamic tiling Wayland compositor" maintainer="Orphaned " license="GPL-3.0-only" homepage="https://codeberg.org/river/river" distfiles="https://codeberg.org/river/river/releases/download/v${version}/river-${version}.tar.gz" -checksum=26c1c41a65ce3804069afad6988410515cf478d2b76303ebc699766d3d4dc69f +checksum=acb273487eb0cf9222c14e050c0faad692f426dba599b62e4c743ba43328ee9e +_deps="https://codeberg.org/ifreund/zig-pixman/archive/v0.1.0.tar.gz + https://codeberg.org/ifreund/zig-wayland/archive/v0.1.0.tar.gz + https://codeberg.org/ifreund/zig-wlroots/archive/v0.17.0.tar.gz + https://codeberg.org/ifreund/zig-xkbcommon/archive/v0.1.0.tar.gz" -build_options="xwayland" -build_options_default="xwayland" -desc_option_xwayland="Enable Xwayland support" +post_fetch() { + for _d in $_deps; do + zig fetch --global-cache-dir $XBPS_BUILDDIR/zig-input $_d + done +} + +do_build() { + DESTDIR="zig-out" zig build --system $XBPS_BUILDDIR/zig-input/p -Doptimize=ReleaseSafe -Dpie -Dxwayland --prefix /usr -Dcpu=baseline install +} + +do_check() { + zig build --system $XBPS_BUILDDIR/zig-input/p test +} ```