diff options
Diffstat (limited to 'gnu/packages/bootstrap.scm')
-rw-r--r-- | gnu/packages/bootstrap.scm | 96 |
1 files changed, 85 insertions, 11 deletions
diff --git a/gnu/packages/bootstrap.scm b/gnu/packages/bootstrap.scm index 936d6c1a2a..82d2295695 100644 --- a/gnu/packages/bootstrap.scm +++ b/gnu/packages/bootstrap.scm @@ -2,6 +2,7 @@ ;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018 Ludovic Courtès <[email protected]> ;;; Copyright © 2014, 2015, 2018 Mark H Weaver <[email protected]> ;;; Copyright © 2017 Efraim Flashner <[email protected]> +;;; Copyright © 2018 Jan (janneke) Nieuwenhuizen <[email protected]> ;;; ;;; This file is part of GNU Guix. ;;; @@ -43,10 +44,15 @@ %bootstrap-guile %bootstrap-coreutils&co + %bootstrap-linux-libre-headers %bootstrap-binutils %bootstrap-gcc %bootstrap-glibc - %bootstrap-inputs)) + %bootstrap-inputs + %mescc-tools-seed + %mes-seed + %srfi-43 + %tinycc-seed)) ;;; Commentary: ;;; @@ -97,10 +103,10 @@ (define* (package-from-tarball name source program-to-test description #:key snippet) "Return a package that correspond to the extraction of SOURCE. -PROGRAM-TO-TEST is a program to run after extraction of SOURCE, to check -whether everything is alright. If SNIPPET is provided, it is evaluated after -extracting SOURCE. SNIPPET should raise an exception to signal an error; its -return value is ignored." +PROGRAM-TO-TEST is #f or a string: the program to run after extraction of +SOURCE to check whether everything is alright. If SNIPPET is provided, it is +evaluated after extracting SOURCE. SNIPPET should return true if successful, +or false to signal an error." (package (name name) (version "0") @@ -123,8 +129,9 @@ return value is ignored." (invoke tar "xvf" (string-append builddir "/binaries.tar")) ,@(if snippet (list snippet) '()) - (invoke (string-append "bin/" ,program-to-test) - "--version")))))) + (or (not ,program-to-test) + (invoke (string-append "bin/" ,program-to-test) + "--version"))))))) (inputs `(("tar" ,(search-bootstrap-binary "tar" (%current-system))) ("xz" ,(search-bootstrap-binary "xz" (%current-system))) @@ -391,6 +398,23 @@ $out/bin/guile --version~%" (("^exec grep") (string-append (getcwd) "/bin/grep")))) (chmod "bin" #o555)))) +(define-public %bootstrap-linux-libre-headers + (package-from-tarball + "linux-libre-headers-bootstrap" + (lambda (system) + (origin + (method url-fetch) + (uri (match system + ((or "i686-linux" + "x86_64-linux") + "http://lilypond.org/janneke/mes/linux-libre-headers-stripped-4.14.26-i686-linux.tar.xz") + (_ (error "linux-libre-headers-bootstrap: system not supported")))) + (sha256 + (base32 + "0nwspwydn089xbd28nnas762iwl6l9ymbcz170qvfi50ywgim1ma")))) + #f ; no program to test + "Bootstrap linux-libre-headers")) + (define %bootstrap-binutils (package-from-tarball "binutils-bootstrap" (lambda (system) @@ -586,12 +610,62 @@ exec ~a/bin/.gcc-wrapped -B~a/lib \ (home-page #f) (license gpl3+))) -(define %bootstrap-inputs +(define %mescc-tools-seed ; todo: add tarballs to alpha.gnu.org/pub/mes/bootstrap/ + (let ((commit "dc4e20e74924a5c80a2b7a77b4d7b927234fa71c")) + (origin + (method url-fetch) + (uri (string-append "https://gitlab.com/janneke/mescc-tools-seed" + "/-/archive/" commit + "/mescc-tools-seed-" commit ".tar.gz")) + (sha256 + (base32 + "1lj7df73vxanmffmiwkhcn83r7yd9n8568nkki06bqq5zg526nyz"))))) + +(define %mes-seed + (let ((commit "057fd36735b5605fe582d6b3625f793a62922206")) + (origin + (method url-fetch) + (uri (string-append "https://gitlab.com/janneke/mes-seed" + "/-/archive/" commit + "/mes-seed-" commit ".tar.gz")) + (sha256 + (base32 + "0vdb4kc05a1kdpmsi8dg425d5f33kp28sgl2fi3s320pc0v4dv13"))))) + +(define %tinycc-seed + (let ((commit "843d47ca682617f21333b50c67851797b8c3fd04")) + (origin + (method url-fetch) + (uri (string-append "https://gitlab.com/janneke/tinycc-seed" + "/-/archive/" commit + "/tinycc-seed-" commit ".tar.gz")) + (sha256 + (base32 + "0599wwv30js03l1rpmvzfclq3jadzvq04pi29j45nf6fyfg5hhqb"))))) + +(define %srfi-43 + (origin + (method url-fetch) + (uri "http://git.savannah.gnu.org/cgit/guile.git/plain/module/srfi/srfi-43.scm?h=stable-2.0") + (file-name "srfi-43.scm") + (sha256 + (base32 + "0rnkppwdkxbzkgp9s9ccmby9f7p3ijxjlmvj0pzqxwmrmpy7jwmb")))) + +(define (%bootstrap-inputs) ;; The initial, pre-built inputs. From now on, we can start building our ;; own packages. - `(("libc" ,%bootstrap-glibc) - ("gcc" ,%bootstrap-gcc) - ("binutils" ,%bootstrap-binutils) + `(,@(match (%current-system) + ((or "i686-linux" "x86_64-linux") + `(("linux-libre-headers" ,%bootstrap-linux-libre-headers) + ("mescc-tools-seed" ,%mescc-tools-seed) + ("mes-seed" ,%mes-seed) + ("srfi-43" ,%srfi-43 ) + ("tinycc-seed" ,%tinycc-seed))) + (_ + `(("libc" ,%bootstrap-glibc) + ("gcc" ,%bootstrap-gcc) + ("binutils" ,%bootstrap-binutils)))) ("coreutils&co" ,%bootstrap-coreutils&co) ;; In gnu-build-system.scm, we rely on the availability of Bash. |