aboutsummaryrefslogtreecommitdiff
path: root/distro
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2012-10-17 17:52:12 +0200
committerLudovic Courtès <ludo@gnu.org>2012-10-17 23:25:25 +0200
commit9735a7b6eaccf248d91e1f3c17446b2fac41ec9a (patch)
tree966131d051d31220e6ceb3f544ad23c14a447ddc /distro
parenteb1db76e34e19bd539955a1019e38c5d8b5d02e7 (diff)
downloadguix-9735a7b6eaccf248d91e1f3c17446b2fac41ec9a.tar
guix-9735a7b6eaccf248d91e1f3c17446b2fac41ec9a.tar.gz
distro: Add package that builds a tarball of the bootstrap Guile.
* distro/packages/base.scm (%guile-static-stripped): New variable.
Diffstat (limited to 'distro')
-rw-r--r--distro/packages/base.scm28
1 files changed, 28 insertions, 0 deletions
diff --git a/distro/packages/base.scm b/distro/packages/base.scm
index ad3c4882a2..8ffdbf635d 100644
--- a/distro/packages/base.scm
+++ b/distro/packages/base.scm
@@ -2101,4 +2101,32 @@ store.")
#t))))
(inputs `(("guile" ,%guile-static)))))
+(define %guile-bootstrap-tarball
+ ;; A tarball with the statically-linked, relocatable Guile.
+ (package (inherit %guile-static)
+ (name "guile-bootstrap-tarball")
+ (build-system trivial-build-system)
+ (inputs `(("tar" ,tar)
+ ("xz" ,xz)
+ ("guile" ,%guile-static-stripped)))
+ (arguments
+ (lambda (system)
+ `(#:modules ((guix build utils))
+ #:builder
+ (begin
+ (use-modules (guix build utils))
+ (let ((out (assoc-ref %outputs "out"))
+ (guile (assoc-ref %build-inputs "guile"))
+ (tar (assoc-ref %build-inputs "tar"))
+ (xz (assoc-ref %build-inputs "xz")))
+ (mkdir out)
+ (set-path-environment-variable "PATH" '("bin") (list tar xz))
+ (with-directory-excursion guile
+ (zero? (system* "tar" "cJvf"
+ (string-append out "/guile-bootstrap-"
+ ,(package-version %guile-static)
+ "-" ,system
+ ".tar.xz")
+ "."))))))))))
+
;;; base.scm ends here