summary refs log tree commit diff
path: root/gnu/packages/gnome.scm
diff options
context:
space:
mode:
authorTimothy Sample <samplet@ngyro.com>2019-02-13 14:22:14 -0500
committerLudovic Courtès <ludo@gnu.org>2019-02-17 00:04:56 +0100
commite57c2adb2a7ed94610f4c35e8710bc1346199de6 (patch)
tree18dfef403e8b580c53693cc9b25998800997bde8 /gnu/packages/gnome.scm
parent7af417502ce2e1712c8fbb3f5169147f820f7871 (diff)
downloadguix-e57c2adb2a7ed94610f4c35e8710bc1346199de6.tar.gz
services: gdm: Remove etc service.
* gnu/packages/gnome.scm (gdm)[arguments]: Update pre-configure phase to
make GDM get the configuration file path from an environment variable.
* gnu/services/xorg.scm (gdm-etc-service): Remove function.
(gdm-configuration-file): New function.
(gdm-shepherd-service): Set GDM_CUSTOM_CONF before invoking GDM.
(gdm-service-type)[extensions]: Remove etc-service-type extension.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Diffstat (limited to 'gnu/packages/gnome.scm')
-rw-r--r--gnu/packages/gnome.scm9
1 files changed, 7 insertions, 2 deletions
diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm
index 2f99755933..21c61473c5 100644
--- a/gnu/packages/gnome.scm
+++ b/gnu/packages/gnome.scm
@@ -32,7 +32,7 @@
 ;;; Copyright © 2018 Jovany Leandro G.C <bit4bit@riseup.net>
 ;;; Copyright © 2018 Vasile Dumitrascu <va511e@yahoo.com>
 ;;; Copyright © 2018 Björn Höfling <bjoern.hoefling@bjoernhoefling.de>
-;;; Copyright © 2018 Timothy Sample <samplet@ngyro.com>
+;;; Copyright © 2018, 2019 Timothy Sample <samplet@ngyro.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -5462,6 +5462,9 @@ libxml2.")
                 ;; processes.
                 "gdm_session_set_environment_variable (self, \"GDM_X_SERVER\",\n"
                 "    g_getenv (\"GDM_X_SERVER\"));\n"
+                ;; Propagate the GDM_CUSTOM_CONF environment variable.
+                "gdm_session_set_environment_variable (self, \"GDM_CUSTOM_CONF\",\n"
+                "    g_getenv (\"GDM_CUSTOM_CONF\"));\n"
                 ;; FIXME: Really glib should be declaring XDG_CONFIG_DIRS as a
                 ;; variable, but it doesn't do that right now.  Anyway
                 ;; /run/current-system/profile/share/gnome-session/sessions/gnome.desktop
@@ -5481,7 +5484,9 @@ libxml2.")
             ;; Look for custom GDM conf in /run/current-system.
             (substitute* '("common/gdm-settings-desktop-backend.c")
               (("GDM_CUSTOM_CONF")
-               "\"/run/current-system/etc/gdm/custom.conf\""))
+               (string-append "(g_getenv(\"GDM_CUSTOM_CONF\") != NULL"
+                              " ? g_getenv(\"GDM_CUSTOM_CONF\")"
+                              " : GDM_CUSTOM_CONF)")))
             ;; Use service-supplied path to X.
             (substitute* '("daemon/gdm-server.c")
               (("\\(X_SERVER X_SERVER_ARG_FORMAT")