From 887e700c916f264660967004aed8a4a1f36120ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Romildo?= Date: Sat, 18 Apr 2026 16:32:20 -0300 Subject: [PATCH] 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. --- pkgs/by-name/sf/sfwbar/package.nix | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/pkgs/by-name/sf/sfwbar/package.nix b/pkgs/by-name/sf/sfwbar/package.nix index aeeff1bdccf9..e4c511ce9424 100644 --- a/pkgs/by-name/sf/sfwbar/package.nix +++ b/pkgs/by-name/sf/sfwbar/package.nix @@ -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";