sfwbar: fix SVG icon rendering via wrapGAppsHook3

Add `wrapGAppsHook3` to `nativeBuildInputs` to ensure `sfwbar` can
successfully locate the `gdk-pixbuf` loaders required to render SVG symbolic
icons in default GTK widgets (such as the battery, bluez, and volume
modules).

The inclusion of this hook automatically generates a unified `loaders.cache`
and wraps the resulting binary with the correct `GDK_PIXBUF_MODULE_FILE`
environment variable. Furthermore, it automatically handles the population
of `XDG_DATA_DIRS`, rendering the previous manual `wrapProgram` execution in
`postFixup` redundant.
This commit is contained in:
José Romildo
2026-04-18 16:32:20 -03:00
parent eb059e762d
commit 887e700c91
+2 -5
View File
@@ -16,6 +16,7 @@
makeWrapper,
docutils,
wayland-scanner,
wrapGAppsHook3,
}:
stdenv.mkDerivation (finalAttrs: {
@@ -47,13 +48,9 @@ stdenv.mkDerivation (finalAttrs: {
pkg-config
makeWrapper
wayland-scanner
wrapGAppsHook3
];
postFixup = ''
wrapProgram $out/bin/sfwbar \
--suffix XDG_DATA_DIRS : $out/share
'';
meta = {
homepage = "https://github.com/LBCrion/sfwbar";
description = "Flexible taskbar application for wayland compositors, designed with a stacking layout in mind";