[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
140/211: gnu: Add %diffutils-static, %diffutils-static-stripped, %diffut
From: |
Jan Nieuwenhuizen |
Subject: |
140/211: gnu: Add %diffutils-static, %diffutils-static-stripped, %diffutils-bootstrap-tarball. |
Date: |
Sat, 8 Sep 2018 11:09:44 -0400 (EDT) |
janneke pushed a commit to branch wip-bootstrap
in repository guix.
commit 8683d1740e8469d0bb2978522288f26e36d14f39
Author: Jan Nieuwenhuizen <address@hidden>
Date: Thu Aug 23 22:52:29 2018 +0200
gnu: Add %diffutils-static, %diffutils-static-stripped,
%diffutils-bootstrap-tarball.
* gnu/packages/make-bootstrap.scm (%diffutils-static,
%diffutils-static-stripped, %diffutils-bootstrap-tarball): New variable.
---
gnu/packages/make-bootstrap.scm | 52 +++++++++++++++++++++++++++++++++++++++++
1 file changed, 52 insertions(+)
diff --git a/gnu/packages/make-bootstrap.scm b/gnu/packages/make-bootstrap.scm
index efef713..a84cfb3 100644
--- a/gnu/packages/make-bootstrap.scm
+++ b/gnu/packages/make-bootstrap.scm
@@ -41,6 +41,7 @@
#:use-module (ice-9 match)
#:use-module (srfi srfi-1)
#:export (%bootstrap-binaries-tarball
+ %diffutils-bootstrap-tarball
%make-bootstrap-tarball
%binutils-bootstrap-tarball
%glibc-bootstrap-tarball
@@ -301,6 +302,53 @@ for `sh' in $PATH, and without nscd, and with static NSS
modules."
(license gpl3+)
(home-page #f)))
+(define %diffutils-static
+ ;; Statically-linked Diffutils.
+ (package
+ (inherit diffutils)
+ (name "diffutils-static")
+ (arguments
+ `(#:strip-flags '("--strip-all")
+ #:make-flags '("V=2")
+ #:phases (modify-phases %standard-phases
+ (add-before 'configure 'all-static
+ (lambda _
+ ;; The `-all-static' libtool flag can only be passed
+ ;; after `configure', since configure tests don't use
+ ;; libtool, and only for executables built with libtool.
+ (substitute* '("Makefile.in"
+ "src/Makefile.in")
+ (("^LDFLAGS =(.*)$" line)
+ (string-append line
+ "\nAM_LDFLAGS = -static\n"))))))))))
+
+(define %diffutils-static-stripped
+ ;; The subset of Diffutils that we need.
+ (package (inherit %diffutils-static)
+ (name (string-append (package-name %diffutils-static) "-stripped"))
+ (build-system trivial-build-system)
+ (outputs '("out"))
+ (arguments
+ `(#:modules ((guix build utils))
+ #:builder
+ (begin
+ (use-modules (guix build utils))
+
+ (setvbuf (current-output-port) _IOLBF)
+ (let* ((in (assoc-ref %build-inputs "diffutils"))
+ (out (assoc-ref %outputs "out"))
+ (bin (string-append out "/bin")))
+ (mkdir-p bin)
+ (for-each (lambda (file)
+ (let ((target (string-append bin "/" file)))
+ (format #t "copying `~a'...~%" file)
+ (copy-file (string-append in "/bin/" file)
+ target)
+ (remove-store-references target)))
+ '("cmp" "diff"))
+ #t))))
+ (inputs `(("diffutils" ,%diffutils-static)))))
+
(define %make-static
;; Statically-linked Make.
(package
@@ -702,6 +750,10 @@ for `sh' in $PATH, and without nscd, and with static NSS
modules."
;; A tarball with the statically-linked bootstrap binaries.
(tarball-package %static-binaries))
+(define %diffutils-bootstrap-tarball
+ ;; A tarball with the statically-linked Diffutils programs.
+ (tarball-package %diffutils-static-stripped))
+
(define %make-bootstrap-tarball
;; A tarball with the statically-linked Make programs.
(tarball-package %make-static-stripped))
- 169/211: bootstrap: Evaluate %bootstrap-inputs+toolchain at build time., (continued)
- 169/211: bootstrap: Evaluate %bootstrap-inputs+toolchain at build time., Jan Nieuwenhuizen, 2018/09/08
- 165/211: Revert "gnu: make-boot0: Set LOADLIBES for i686-linux.", Jan Nieuwenhuizen, 2018/09/08
- 120/211: gnu: mes-boot: Update to 0.16.1; revise dependencies., Jan Nieuwenhuizen, 2018/09/08
- 123/211: gnu: binutils-mesboot0: Revise dependencies., Jan Nieuwenhuizen, 2018/09/08
- 142/211: gnu: Add %linux-libre-headers-stripped, %linux-libre-headers-bootstrap-tarball., Jan Nieuwenhuizen, 2018/09/08
- 155/211: Revert "gnu: Add %diffutils-static, %diffutils-static-stripped, %diffutils-bootstrap-tarball.", Jan Nieuwenhuizen, 2018/09/08
- 130/211: gnu: %tinycc-seed: Update for mes 0.17., Jan Nieuwenhuizen, 2018/09/08
- 141/211: gnu: Add %bootstrap-diffutils., Jan Nieuwenhuizen, 2018/09/08
- 112/211: gnu: tcc-boot: Package with bootstrap-guile., Jan Nieuwenhuizen, 2018/09/08
- 159/211: gcc-mesboot: use package-full-name "-" :-), Jan Nieuwenhuizen, 2018/09/08
- 140/211: gnu: Add %diffutils-static, %diffutils-static-stripped, %diffutils-bootstrap-tarball.,
Jan Nieuwenhuizen <=
- 129/211: gnu: %mes-seed: Update for mes 0.17., Jan Nieuwenhuizen, 2018/09/08
- 110/211: Revert "REMOVEME: %fake-bootstrap => #t.", Jan Nieuwenhuizen, 2018/09/08
- 104/211: gnu: gcc-mesboot: Rename from gcc-boot., Jan Nieuwenhuizen, 2018/09/08
- 98/211: gnu: binutils-boot0: Inject AR, LD from bootstrap-binaries., Jan Nieuwenhuizen, 2018/09/08
- 94/211: gnu: tcc-boot0: Update for mes 0.16., Jan Nieuwenhuizen, 2018/09/08
- 93/211: gnu: Add tcc-boot 0.9.27., Jan Nieuwenhuizen, 2018/09/08
- 100/211: gnu: m4:mesboot: Rename from m4-boot., Jan Nieuwenhuizen, 2018/09/08
- 63/211: gnu: binutils-boot: Update to 2.10.1., Jan Nieuwenhuizen, 2018/09/08
- 88/211: gnu: mes-boot: Update to 0.16., Jan Nieuwenhuizen, 2018/09/08
- 75/211: Revert "gnu: gcc-boot: Update to 3.4.0.", Jan Nieuwenhuizen, 2018/09/08