summary refs log tree commit diff
path: root/gnu
diff options
context:
space:
mode:
authorTobias Geerinckx-Rice <me@tobias.gr>2021-07-18 14:14:27 +0200
committerTobias Geerinckx-Rice <me@tobias.gr>2021-07-18 20:28:17 +0200
commit7f2b9306eea163391dda6e4cf395a0e2be1be984 (patch)
tree58d2f9a173c75fcc52be3abe2dd87ea1ecf63432 /gnu
parent8b1bde7bb3936a64244824500ffe60f123704437 (diff)
downloadguix-7f2b9306eea163391dda6e4cf395a0e2be1be984.tar.gz
gnu: mg: Fix reference to native diffutils.
* gnu/packages/text-editors.scm (mg)[inputs]: Add diffutils.
[arguments]: Refer to it in the 'correct-location-of-diff phase.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/text-editors.scm11
1 files changed, 7 insertions, 4 deletions
diff --git a/gnu/packages/text-editors.scm b/gnu/packages/text-editors.scm
index 11332fab0b..2f42d831c0 100644
--- a/gnu/packages/text-editors.scm
+++ b/gnu/packages/text-editors.scm
@@ -47,6 +47,7 @@
   #:use-module (gnu packages aspell)
   #:use-module (gnu packages assembly)
   #:use-module (gnu packages autotools)
+  #:use-module (gnu packages base)
   #:use-module (gnu packages boost)
   #:use-module (gnu packages code)
   #:use-module (gnu packages crates-io)
@@ -524,7 +525,8 @@ Wordstar-, EMACS-, Pico, Nedit or vi-like key bindings.  e3 can be used on
     (native-inputs
      `(("pkg-config" ,pkg-config)))
     (inputs
-     `(("libbsd" ,libbsd)
+     `(("diffutils" ,diffutils)
+       ("libbsd" ,libbsd)
        ("ncurses" ,ncurses)))
     (arguments
      ;; No test suite available.
@@ -533,11 +535,12 @@ Wordstar-, EMACS-, Pico, Nedit or vi-like key bindings.  e3 can be used on
                           (string-append "CC=" ,(cc-for-target)))
        #:phases (modify-phases %standard-phases
                   (delete 'configure)   ; no configure script
-                  (add-before 'build 'correct-location-of-difftool
-                    (lambda _
+                  (add-before 'build 'correct-location-of-diff
+                    (lambda* (#:key inputs #:allow-other-keys)
                       (substitute* "buffer.c"
                         (("/usr/bin/diff")
-                         (which "diff")))))
+                         (string-append (assoc-ref inputs "diffutils")
+                                        "/bin/diff")))))
                   (add-before 'build 'pkg-config-for-cross-compiling-target
                     (lambda _
                       (substitute* "GNUmakefile"