summary refs log tree commit diff
path: root/nixos/modules/services/x11/display-managers
diff options
context:
space:
mode:
authorJan Tojnar <jtojnar@gmail.com>2022-05-05 23:46:24 +0200
committerJan Tojnar <jtojnar@gmail.com>2022-05-17 00:19:18 +0200
commitff691ed9ba21528c1b4e034f36a04027e4522c58 (patch)
treef79428e3b4c6ef5b58f05033c8be89eaa9e645c5 /nixos/modules/services/x11/display-managers
parent4f7d4241c2beb76820e4b4eae8a51d3a157d1df9 (diff)
downloadnixpkgs-ff691ed9ba21528c1b4e034f36a04027e4522c58.tar
nixpkgs-ff691ed9ba21528c1b4e034f36a04027e4522c58.tar.gz
nixpkgs-ff691ed9ba21528c1b4e034f36a04027e4522c58.tar.bz2
nixpkgs-ff691ed9ba21528c1b4e034f36a04027e4522c58.tar.lz
nixpkgs-ff691ed9ba21528c1b4e034f36a04027e4522c58.tar.xz
nixpkgs-ff691ed9ba21528c1b4e034f36a04027e4522c58.tar.zst
nixpkgs-ff691ed9ba21528c1b4e034f36a04027e4522c58.zip
nixos/gdm: Fix missing icons
Recent `wrapGAppsHook` change stops `adwaita-icon-theme` from being added to `XDG_DATA_DIRS`:
https://github.com/NixOS/nixpkgs/commit/b1e73fa2e086f1033a33d93524ae2a1781d12b95
Since `display-manager.service` does not have `/run/current-system/sw/share` in `XDG_DATA_DIRS`, it does not pick up the globally installed icon theme either, preventing icons from showing.

Let’s make Adwaita available to fix that for now.

Fixes: https://github.com/NixOS/nixpkgs/issues/171692
Diffstat (limited to 'nixos/modules/services/x11/display-managers')
-rw-r--r--nixos/modules/services/x11/display-managers/gdm.nix9
1 files changed, 7 insertions, 2 deletions
diff --git a/nixos/modules/services/x11/display-managers/gdm.nix b/nixos/modules/services/x11/display-managers/gdm.nix
index 4941d13c810..45e3d84afa4 100644
--- a/nixos/modules/services/x11/display-managers/gdm.nix
+++ b/nixos/modules/services/x11/display-managers/gdm.nix
@@ -140,8 +140,13 @@ in
         environment = {
           GDM_X_SERVER_EXTRA_ARGS = toString
             (filter (arg: arg != "-terminate") cfg.xserverArgs);
-          # GDM is needed for gnome-login.session
-          XDG_DATA_DIRS = "${gdm}/share:${cfg.sessionData.desktops}/share:${pkgs.gnome.gnome-control-center}/share";
+          XDG_DATA_DIRS = lib.makeSearchPath "share" [
+            gdm # for gnome-login.session
+            cfg.sessionData.desktops
+            pkgs.gnome.gnome-control-center # for accessibility icon
+            pkgs.gnome.adwaita-icon-theme
+            pkgs.hicolor-icon-theme # empty icon theme as a base
+          ];
         } // optionalAttrs (xSessionWrapper != null) {
           # Make GDM use this wrapper before running the session, which runs the
           # configured setupCommands. This relies on a patched GDM which supports