summary refs log tree commit diff
path: root/gnu/packages/enlightenment.scm
diff options
context:
space:
mode:
authorEfraim Flashner <efraim@flashner.co.il>2017-06-19 09:48:06 +0300
committerEfraim Flashner <efraim@flashner.co.il>2017-06-19 09:50:45 +0300
commit7e60206dff66339b540fb3a0e1e6d2b4eec4994f (patch)
tree438c27fa92cfc12021b8696fe2d3b7a84c6313a6 /gnu/packages/enlightenment.scm
parent00f037ca44497d5be6da531c8d8440e97a949cd8 (diff)
downloadguix-7e60206dff66339b540fb3a0e1e6d2b4eec4994f.tar.gz
gnu: enlightenment: Patch more hardcoded paths.
* gnu/packages/enlightenment.scm (enlightenment)[arguments]: Patch
hardcoded paths to mount, umount, eject, halt, reboot.
[native-inputs]: Add util-linux.
Diffstat (limited to 'gnu/packages/enlightenment.scm')
-rw-r--r--gnu/packages/enlightenment.scm17
1 files changed, 13 insertions, 4 deletions
diff --git a/gnu/packages/enlightenment.scm b/gnu/packages/enlightenment.scm
index a56dac4db3..50da8c8d2f 100644
--- a/gnu/packages/enlightenment.scm
+++ b/gnu/packages/enlightenment.scm
@@ -230,19 +230,28 @@ Libraries with some extra bells and whistles.")
      `(#:configure-flags '("--enable-mount-eeze")
        #:phases
        (modify-phases %standard-phases
-         (add-before 'configure 'fix-keyboard
-           (lambda _
-             (let ((xkeyboard (assoc-ref %build-inputs "xkeyboard-config")))
+         (add-before 'configure 'set-system-actions
+           (lambda* (#:key inputs #:allow-other-keys)
+             (let ((xkeyboard (assoc-ref inputs "xkeyboard-config"))
+                   (utils     (assoc-ref inputs "util-linux")))
                ;; We need to patch the path to 'base.lst' to be able
                ;; to switch the keyboard layout in E.
                (substitute* "src/modules/xkbswitch/e_mod_parse.c"
                  (("/usr/share/X11/xkb/rules/xorg.lst")
                   (string-append xkeyboard
                                  "/share/X11/xkb/rules/base.lst")))
+               (substitute* "configure"
+                 (("/bin/mount") (string-append utils "/bin/mount"))
+                 (("/bin/umount") (string-append utils "/bin/umount"))
+                 (("/usr/bin/eject") (string-append utils "/bin/eject"))
+                 ; TODO: Replace suspend and hibernate also.
+                 (("/sbin/shutdown -h now") "/run/current-system/profile/sbin/halt")
+                 (("/sbin/shutdown -r now") "/run/current-system/profile/sbin/reboot"))
                #t))))))
     (native-inputs
      `(("gettext" ,gettext-minimal)
-       ("pkg-config" ,pkg-config)))
+       ("pkg-config" ,pkg-config)
+       ("util-linux" ,util-linux)))
     (inputs
      `(("alsa-lib" ,alsa-lib)
        ("dbus" ,dbus)