summary refs log tree commit diff
path: root/gnu/packages
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2015-11-21 17:47:00 +0100
committerRicardo Wurmus <rekado@elephly.net>2015-11-29 20:33:35 +0100
commit25a21c7ff68a2e045ae8c5b8a464359e77781b5f (patch)
treea2d48b07dd5cd4d81a155f7b9e5b83fe3b7c6219 /gnu/packages
parentcb7bd0cff5e8ea1c01ba835a4ebba6c9abae7e16 (diff)
downloadguix-25a21c7ff68a2e045ae8c5b8a464359e77781b5f.tar.gz
gnu: xfce-session: Enable shutdown/reboot menu entries.
* gnu/packages/xfce.scm (xfce-session)[inputs]: Add upower and polkit.
[source]: Replace paths to "shutdown" with "halt" and "restart".
Diffstat (limited to 'gnu/packages')
-rw-r--r--gnu/packages/xfce.scm14
1 files changed, 13 insertions, 1 deletions
diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm
index a4987c1b2e..e213fb6067 100644
--- a/gnu/packages/xfce.scm
+++ b/gnu/packages/xfce.scm
@@ -35,6 +35,7 @@
   #:use-module (gnu packages image)
   #:use-module (gnu packages gnome)
   #:use-module (gnu packages pdf)
+  #:use-module (gnu packages polkit)
   #:use-module (gnu packages gstreamer)
   #:use-module (gnu packages linux)
   #:use-module (gnu packages photo)
@@ -426,7 +427,16 @@ your system in categories, so you can quickly find and launch them.")
                 "01kvbd09c06j20n155hracsgrq06rlmfgdywffjsvlwpn19m9j38"))
               (patches
                ;; See: https://bugzilla.xfce.org/show_bug.cgi?id=12282
-               (list (search-patch "xfce4-session-fix-xflock4.patch")))))
+               (list (search-patch "xfce4-session-fix-xflock4.patch")))
+              (modules '((guix build utils)))
+              (snippet
+               '(begin
+                  (substitute* "xfsm-shutdown-helper/main.c"
+                    (("/sbin/shutdown -h now")  "halt")
+                    (("/sbin/shutdown -r now")  "restart")
+                    (("/usr/sbin/pm-suspend")   "pm-suspend")
+                    (("/usr/sbin/pm-hibernate") "pm-hibernate"))
+                  #t))))
     (build-system gnu-build-system)
     (arguments
      '(#:configure-flags
@@ -436,6 +446,8 @@ your system in categories, so you can quickly find and launch them.")
        ("intltool" ,intltool)))
     (inputs
      `(("iceauth" ,iceauth)
+       ("upower" ,upower)
+       ("polkit" ,polkit)
        ("libsm" ,libsm)
        ("libwnck" ,libwnck-1)
        ("libxfce4ui" ,libxfce4ui)))