xfce.ristretto: enable JXL and WebP support

This commit is contained in:
Bobby Rong 2024-09-08 16:20:13 +08:00
parent 5075ab87dd
commit e2210d169c
No known key found for this signature in database

View File

@ -2,9 +2,13 @@
, mkXfceDerivation
, gtk3
, glib
, gnome
, libexif
, libjxl
, librsvg
, libxfce4ui
, libxfce4util
, webp-pixbuf-loader
, xfconf
}:
@ -27,6 +31,18 @@ mkXfceDerivation {
env.NIX_CFLAGS_COMPILE = "-I${glib.dev}/include/gio-unix-2.0";
postInstall = ''
# Pull in JXL and WebP support for ristretto.
# In postInstall to run before gappsWrapperArgsHook.
export GDK_PIXBUF_MODULE_FILE="${gnome._gdkPixbufCacheBuilder_DO_NOT_USE {
extraLoaders = [
libjxl
librsvg
webp-pixbuf-loader
];
}}"
'';
meta = with lib; {
description = "Fast and lightweight picture-viewer for the Xfce desktop environment";
mainProgram = "ristretto";