guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

16/57: bootstrap: diffutils-mesboot: Use Gash instead of coretutils&co.


From: guix-commits
Subject: 16/57: bootstrap: diffutils-mesboot: Use Gash instead of coretutils&co.
Date: Mon, 16 Dec 2019 13:20:08 -0500 (EST)

janneke pushed a commit to branch wip-bootstrap
in repository guix.

commit e6eef86306b9ea69f80e2c30d64a892a619bc995
Author: Jan Nieuwenhuizen <address@hidden>
Date:   Sun Sep 22 00:56:46 2019 +0200

    bootstrap: diffutils-mesboot: Use Gash instead of coretutils&co.
    
    * gnu/packages/commencement.scm (diffutils-mesboot): Use Gash instead of
    coretutils&co.
---
 gnu/packages/commencement.scm | 39 ++++++++++++++++++++++-----------------
 1 file changed, 22 insertions(+), 17 deletions(-)

diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm
index e75713e..b0f8da1 100644
--- a/gnu/packages/commencement.scm
+++ b/gnu/packages/commencement.scm
@@ -1057,6 +1057,7 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\"
                 #t)))))))))
 
 (define diffutils-mesboot
+  ;; The initial diffutils.
   (package
     (inherit diffutils)
     (name "diffutils-mesboot")
@@ -1071,12 +1072,7 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\"
     (supported-systems '("i686-linux" "x86_64-linux"))
     (inputs '())
     (propagated-inputs '())
-    (native-inputs `(("mes" ,mes-boot)
-                     ("tcc" ,tcc-boot)
-
-                     ("bash" ,%bootstrap-coreutils&co)
-                     ("coreutils" ,%bootstrap-coreutils&co)
-                     ("make" ,make-mesboot0)))
+    (native-inputs (%boot-tcc0-inputs))
     (arguments
      `(#:implicit-inputs? #f
        #:guile ,%bootstrap-guile
@@ -1085,20 +1081,29 @@ $MES -e '(mescc)' module/mescc.scm -- \"$@\"
        #:strip-binaries? #f   ; no strip yet
        #:phases
        (modify-phases %standard-phases
-         ;; diffutils-2.7 needs more traditional configure
-         (replace 'configure
-           (lambda* (#:key outputs #:allow-other-keys)
-             (let ((out (assoc-ref outputs "out"))
-                   (bash (assoc-ref %build-inputs "bash")))
-               (setenv "CONFIG_SHELL" (string-append bash "/bin/sh"))
-               (setenv "CC" "tcc")
-               (setenv "LD" "tcc")
-               (invoke "./configure" (string-append "--prefix=" out)))))
          (add-before 'configure 'remove-diff3-sdiff
            (lambda* (#:key outputs #:allow-other-keys)
              (substitute* "Makefile.in"
-               (("PROGRAMS = .*" all) "PROGRAMS = cmp diff"))
-             #t)))))))
+               (("PROGRAMS = .*" all) "PROGRAMS = cmp diff"))))
+         (replace 'configure           ; needs classic invocation of configure
+           (lambda* (#:key configure-flags #:allow-other-keys)
+             (let* ((out (assoc-ref %outputs "out"))
+                    (bash (assoc-ref %build-inputs "bash"))
+                    (shell (string-append bash "/bin/bash")))
+               (setenv "CONFIG_SHELL" shell)
+               (setenv "CC" "tcc")
+               (setenv "LD" "tcc")
+               (format (current-error-port)
+                       "running ./configure ~a\n" (string-join 
configure-flags))
+               (apply invoke (cons "./configure" configure-flags)))))
+         (replace 'install
+           (lambda _
+             (let* ((out (assoc-ref %outputs "out"))
+                    (bin (string-append out "/bin")))
+               (mkdir-p bin)
+               (install-file "cmp" bin)
+               (install-file "diff" bin)
+               #t))))))))
 
 (define binutils-mesboot0
   (package



reply via email to

[Prev in Thread] Current Thread [Next in Thread]