AUR AI Reviewer

Review Results

Version #2833 of wlroots-git · commit 41a4f7d6e0e1 · status Reviewed

Risk 0/5 · Safe .gitignore
Result #5109

Comment

The change only updates .gitignore to stop ignoring the package install script so it can be tracked in the repo. This does not affect build logic, source integrity, runtime behavior, or packaging contents by itself. No security-relevant code is introduced in this diff hunk.

@@ -2,3 +2,4 @@
 !/PKGBUILD
 !/.SRCINFO
 !/.gitignore
+!/wlroots-git.install
Risk 0/5 · Safe PKGBUILD
Result #5110

Comment

The change is a routine packaging update for a VCS package: it refreshes pkgver, adjusts dependencies to match upstream wlroots, adds a check() phase, and switches to a standard meson build/install flow. I do not see any suspicious network fetches, shell execution, privilege escalation, or install-script behavior in the diff. The new install file is referenced but not shown here; based on the PKGBUILD alone there is no evidence of malicious behavior. The only notable change is the new provides/conflicts naming, which appears intended to track the wlroots soname/package name and is not inherently risky.

@@ -1,79 +1,76 @@
 # Maintainer: Adrian Perez de Castro <aperez@igalia.com>
 # Maintainer: GreyXor <greyxor@protonmail.com>
-# Maintainer: Antonin Décimo <antonin dot decimo at gmail dot com>
+# Contributor: Antonin Décimo <antonin dot decimo at gmail dot com>
 pkgname=wlroots-git
-pkgver=0.21.0.r7488.62c86fb9
+pkgver=0.21.0.r7943.f9d2520
 pkgrel=1
 pkgdesc='Modular Wayland compositor library (git development version)'
 arch=(x86_64)
 url=https://gitlab.freedesktop.org/wlroots/wlroots
 license=(MIT)
-options=(debug)
 depends=(
 	glibc
+	lcms2
+	libdisplay-info
 	libdrm
+	libglvnd
 	libinput
 	libliftoff
 	libxcb
-	libglvnd
-	lcms2
 	libxkbcommon
-	systemd-libs
+	mesa
 	opengl-driver
 	pixman
+	seatd
+	systemd-libs
+	vulkan-icd-loader
 	wayland
+	wayland-protocols
 	xcb-util-errors
 	xcb-util-renderutil
 	xcb-util-wm
-	seatd
-	glslang
-	vulkan-icd-loader
-	libdisplay-info)
+)
 makedepends=(
 	git
+	glslang
+	hwdata
 	meson
 	vulkan-headers
-	wayland-protocols
-	xorgproto
 	xorg-xwayland
 )
 optdepends=(
+	'vulkan-validation-layers: debug the Vulkan renderer'
 	'xorg-xwayland: enable X11 support'
 )
-provides=("lib${pkgname%-git}-${pkgver%.*.*.*}.so")
+provides=(
+	"wlroots${pkgver%.*.*.*}=${pkgver}"
+	"libwlroots-${pkgver%.*.*.*}.so"
+)
+conflicts=("wlroots${pkgver%.*.*.*}")
+install="${pkgname}.install"
 source=("${pkgname}::git+${url}.git")
 b2sums=('SKIP')
-_builddir="build"
-_builddir_pkgver="build-pkgver"
-
-_meson_setup() {
-	arch-meson \
-		--buildtype=debug \
-		-Dwerror=false \
-		-Dexamples=false \
-		"${pkgname}" "$1"
-}
-
-prepare() {
-	_meson_setup "${_builddir_pkgver}"
-}
 
 pkgver() {
-	(
-		set -o pipefail
-		meson introspect --projectinfo "${_builddir_pkgver}" |
-		awk 'match($0, /"version":\s*"([[:digit:]]+\.[[:digit:]]+\.[[:digit:]]+)-(dev|rc[[:digit:]]+)"/, ret) {printf "%s",ret[1]}'
-	)
 	cd "${pkgname}"
-	printf ".r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+	local ver
+	ver=$(meson introspect --projectinfo meson.build 2>/dev/null |
+		python -c 'import json, sys; print(json.load(sys.stdin)["version"].split("-")[0])') || return
+	printf '%s.r%s.%s' "${ver}" "$(git rev-list --count HEAD)" "$(git rev-parse --short=7 HEAD)"
 }
 
 build() {
-	_meson_setup "${_builddir}"
-	meson compile -C "${_builddir}"
+	arch-meson "${pkgname}" build \
+		-D examples=false \
+		-D werror=false
+	meson compile -C build
+}
+
+check() {
+	meson test -C build --print-errorlogs
 }
 
 package() {
-	meson install -C "${_builddir}" --destdir="${pkgdir}"
-	install -Dm644 "${pkgname}/"LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+	meson install -C build --destdir "${pkgdir}"
+	install -Dm644 "${pkgname}/LICENSE" -t "${pkgdir}/usr/share/licenses/${pkgname}/"
 }
Risk 0/5 · Safe wlroots-git.install
Result #5111

Comment

This .install change only adds a post-upgrade notice that compares old/new package versions and prints a rebuild warning when the wlroots SONAME major.minor changes. It does not execute external commands, modify system state, access the network, or alter package contents. The logic is straightforward and limited to user-facing messaging, so I see no security concern in this diff.

@@ -0,0 +1,14 @@
+post_upgrade() {
+	# pkgver is MAJOR.MINOR.PATCH.rCOUNT.HASH and the library is named
+	# libwlroots-MAJOR.MINOR.so, so a MAJOR.MINOR change replaces the library.
+	local new=${1%-*} old=${2%-*}
+	new=${new%.*.*.*}
+	old=${old%.*.*.*}
+	if [ "${new}" != "${old}" ]; then
+		cat <<EOF
+==> libwlroots-${old}.so has been replaced by libwlroots-${new}.so.
+    Rebuild sway-git and any other package built against wlroots-git,
+    otherwise they will fail to start.
+EOF
+	fi
+}