Browse Source

Merge branch 'master' into core-updates

Conflicts:
	guix/packages.scm
gn-latest-20200428
Ludovic Courtès 8 years ago
parent
commit
edae5b3d50
  1. 24
      README
  2. 61
      build-aux/list-packages.scm
  3. 46
      doc/guix.texi
  4. 5
      gnu-system.am
  5. 50
      gnu/packages/apl.scm
  6. 4
      gnu/packages/autogen.scm
  7. 9
      gnu/packages/base.scm
  8. 4
      gnu/packages/bison.scm
  9. 4
      gnu/packages/cflow.scm
  10. 49
      gnu/packages/complexity.scm
  11. 4
      gnu/packages/freeipmi.scm
  12. 4
      gnu/packages/gnunet.scm
  13. 97
      gnu/packages/gnuzilla.scm
  14. 48
      gnu/packages/gvpe.scm
  15. 37
      gnu/packages/kde.scm
  16. 4
      gnu/packages/lightning.scm
  17. 4
      gnu/packages/linux.scm
  18. 47
      gnu/packages/parallel.scm
  19. 72
      gnu/packages/qt.scm
  20. 47
      gnu/packages/sdl.scm
  21. 6
      gnu/packages/version-control.scm
  22. 2
      gnu/system/vm.scm
  23. 3
      guix/build-system/python.scm
  24. 118
      guix/derivations.scm
  25. 40
      guix/packages.scm
  26. 181
      guix/scripts/build.scm
  27. 32
      guix/scripts/substitute-binary.scm
  28. 32
      guix/store.scm
  29. 31
      guix/ui.scm
  30. 24
      guix/utils.scm
  31. 1
      po/LINGUAS
  32. 1304
      po/sr.po
  33. 52
      tests/derivations.scm
  34. 19
      tests/guix-build.sh
  35. 17
      tests/packages.scm
  36. 36
      tests/store.scm
  37. 8
      tests/utils.scm

24
README

@ -50,26 +50,16 @@ You can re-build and re-install Guix using a system that already runs Guix.
To do so:
- Install the dependencies (see 'Requirements' above) and build tools using
Guix. You should have the following packages installed in your user
profile:
- autoconf
- automake
- bzip2
- gcc
- gettext
- glibc
- guile
- ld-wrapper
- libgcrypt
- pkg-config
- sqlite
Guix:
guix package --install={autoconf,automake,bzip2,gcc,binutils,ld-wrapper,glibc,gettext,guile,libgcrypt,pkg-config,sqlite}
- set the environment variables that Guix recommends you to set during the
package installation process:
ACLOCAL, CPATH, LIBRARY_PATH, PATH, PKG_CONFIG_PATH
In addition, set
GUIX_LD_WRAPPER_ALLOW_IMPURITIES=yes
ACLOCAL_PATH, CPATH, LIBRARY_PATH, PKG_CONFIG_PATH
- set the PATH environment variable to refer to the profile:
PATH=$HOME/.guix-profile/bin:$PATH
- re-run the configure script passing it the option
`--with-libgcrypt-prefix=$HOME/.guix-profile/'

61
build-aux/list-packages.scm

@ -71,12 +71,14 @@ of packages still to be processed in REMAINING. Also Introduces a call to the
JavaScript prep_pkg_descs function as part of the output of PACKAGE, every
time the length of DESCRIPTION-IDS, increasing, is 15 or when REMAINING,
decreasing, is 1."
(define (location-url loc)
(string-append "http://git.savannah.gnu.org/cgit/guix.git/tree/"
(location-file loc) "#n"
(number->string (location-line loc))))
(define (source-url package)
(let ((loc (package-location package)))
(and loc
(string-append "http://git.savannah.gnu.org/cgit/guix.git/tree/"
(location-file loc) "#n"
(number->string (location-line loc))))))
(and loc (location-url loc))))
(define (license package)
(define ->sxml
@ -103,26 +105,37 @@ decreasing, is 1."
"http://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/patches/"
(basename patch)))
(match (and (origin? (package-source package))
(origin-patches (package-source package)))
((patches ..1)
`(div "patches: "
,(let loop ((patches patches)
(number 1)
(links '()))
(match patches
(()
(list-join (reverse links) ", "))
((patch rest ...)
(loop rest
(+ 1 number)
(cons `(a (@ (href ,(patch-url patch))
(title ,(string-append
"Link to "
(basename patch))))
,(number->string number))
links)))))))
(_ #f)))
(define (snippet-link snippet)
(let ((loc (package-field-location package 'source)))
`(a (@ (href ,(location-url loc))
(title "Link to patch snippet"))
"snippet")))
(and (origin? (package-source package))
(let ((patches (origin-patches (package-source package)))
(snippet (origin-snippet (package-source package))))
(and (or (pair? patches) snippet)
`(div "patches: "
,(let loop ((patches patches)
(number 1)
(links '()))
(match patches
(()
(let* ((additional (and snippet
(snippet-link snippet)))
(links (if additional
(cons additional links)
links)))
(list-join (reverse links) ", ")))
((patch rest ...)
(loop rest
(+ 1 number)
(cons `(a (@ (href ,(patch-url patch))
(title ,(string-append
"Link to "
(basename patch))))
,(number->string number))
links))))))))))
(define (status package)
(define (url system)

46
doc/guix.texi

@ -95,7 +95,7 @@ always produces the same result when passed a given set of inputs. It
cannot alter the system's environment in
any way; for instance, it cannot create, modify, or delete files outside
of its build and installation directories. This is achieved by running
build processes in isolated environments (or @dfn{chroots}), where only their
build processes in isolated environments (or @dfn{containers}), where only their
explicit inputs are visible.
@cindex store
@ -224,6 +224,7 @@ The @code{guix-daemon} program may then be run as @code{root} with:
# guix-daemon --build-users-group=guix-builder
@end example
@cindex chroot
@noindent
This way, the daemon starts build processes in a chroot, under one of
the @code{guix-builder} users. On GNU/Linux, by default, the chroot
@ -271,6 +272,10 @@ is normally run as @code{root} like this:
@noindent
For details on how to set it up, @ref{Setting Up the Daemon}.
@cindex chroot
@cindex container, build environment
@cindex build environment
@cindex reproducible builds
By default, @command{guix-daemon} launches build processes under
different UIDs, taken from the build group specified with
@code{--build-users-group}. In addition, each build process is run in a
@ -278,7 +283,10 @@ chroot environment that only contains the subset of the store that the
build process depends on, as specified by its derivation
(@pxref{Programming Interface, derivation}), plus a set of specific
system directories. By default, the latter contains @file{/dev} and
@file{/dev/pts}.
@file{/dev/pts}. Furthermore, on GNU/Linux, the build environment is a
@dfn{container}: in addition to having its own file system tree, it has
a separate mount name space, its own PID name space, network name space,
etc. This helps achieve reproducible builds (@pxref{Features}).
The following command-line options are supported:
@ -447,13 +455,18 @@ profiles, and remove those that are provably no longer referenced
generations of their profile so that the packages they refer to can be
collected.
@cindex reproducibility
@cindex reproducible builds
Finally, Guix takes a @dfn{purely functional} approach to package
management, as described in the introduction (@pxref{Introduction}).
Each @file{/nix/store} package directory name contains a hash of all the
inputs that were used to build that package---compiler, libraries, build
scripts, etc. This direct correspondence allows users to make sure a
given package installation matches the current state of their
distribution, and helps maximize @dfn{reproducibility}.
distribution. It also helps maximize @dfn{build reproducibility}:
thanks to the isolated build environments that are used, a given build
is likely to yield bit-identical files when performed on different
machines (@pxref{Invoking guix-daemon, container}).
@cindex substitute
This foundation allows Guix to support @dfn{transparent binary/source
@ -1470,12 +1483,16 @@ The @var{options} may be zero or more of the following:
@item --expression=@var{expr}
@itemx -e @var{expr}
Build the package @var{expr} evaluates to.
Build the package or derivation @var{expr} evaluates to.
For example, @var{expr} may be @code{(@@ (gnu packages guile)
guile-1.8)}, which unambiguously designates this specific variant of
version 1.8 of Guile.
Alternately, @var{expr} may refer to a zero-argument monadic procedure
(@pxref{The Store Monad}). The procedure must return a derivation as a
monadic value, which is then passed through @code{run-with-store}.
@item --source
@itemx -S
Build the packages' source derivations, rather than the packages
@ -1546,6 +1563,22 @@ Use the given verbosity level. @var{level} must be an integer between 0
and 5; higher means more verbose output. Setting a level of 4 or more
may be helpful when debugging setup issues with the build daemon.
@item --log-file
Return the build log file names for the given
@var{package-or-derivation}s, or raise an error if build logs are
missing.
This works regardless of how packages or derivations are specified. For
instance, the following invocations are equivalent:
@example
guix build --log-file `guix build -d guile`
guix build --log-file `guix build guile`
guix build --log-file guile
guix build --log-file -e '(@@ (gnu packages guile) guile-2.0)'
@end example
@end table
Behind the scenes, @command{guix build} is essentially an interface to
@ -1708,8 +1741,9 @@ Guix comes with a distribution of free software@footnote{The term
users of that software}.} that form the basis of the GNU system. This
includes core GNU packages such as GNU libc, GCC, and Binutils, as well
as many GNU and non-GNU applications. The complete list of available
packages can be seen by running @command{guix package} (@pxref{Invoking
guix package}):
packages can be browsed
@url{http://www.gnu.org/software/guix/package-list.html,on-line} or by
running @command{guix package} (@pxref{Invoking guix package}):
@example
guix package --list-available

5
gnu-system.am

@ -26,6 +26,7 @@ GNU_SYSTEM_MODULES = \
gnu/packages/acct.scm \
gnu/packages/acl.scm \
gnu/packages/algebra.scm \
gnu/packages/apl.scm \
gnu/packages/apr.scm \
gnu/packages/aspell.scm \
gnu/packages/attr.scm \
@ -43,6 +44,7 @@ GNU_SYSTEM_MODULES = \
gnu/packages/check.scm \
gnu/packages/cmake.scm \
gnu/packages/compression.scm \
gnu/packages/complexity.scm \
gnu/packages/cpio.scm \
gnu/packages/cppi.scm \
gnu/packages/cross-base.scm \
@ -77,6 +79,7 @@ GNU_SYSTEM_MODULES = \
gnu/packages/gnunet.scm \
gnu/packages/gnupg.scm \
gnu/packages/gnutls.scm \
gnu/packages/gnuzilla.scm \
gnu/packages/gperf.scm \
gnu/packages/gprolog.scm \
gnu/packages/graphviz.scm \
@ -88,6 +91,7 @@ GNU_SYSTEM_MODULES = \
gnu/packages/gtk.scm \
gnu/packages/guile.scm \
gnu/packages/gv.scm \
gnu/packages/gvpe.scm \
gnu/packages/help2man.scm \
gnu/packages/hugs.scm \
gnu/packages/icu4c.scm \
@ -139,6 +143,7 @@ GNU_SYSTEM_MODULES = \
gnu/packages/openldap.scm \
gnu/packages/openssl.scm \
gnu/packages/package-management.scm \
gnu/packages/parallel.scm \
gnu/packages/parted.scm \
gnu/packages/patchelf.scm \
gnu/packages/pcre.scm \

50
gnu/packages/apl.scm

@ -0,0 +1,50 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
;;;
;;; This file is part of GNU Guix.
;;;
;;; GNU Guix is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
;;; the Free Software Foundation; either version 3 of the License, or (at
;;; your option) any later version.
;;;
;;; GNU Guix is distributed in the hope that it will be useful, but
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;;; GNU General Public License for more details.
;;;
;;; You should have received a copy of the GNU General Public License
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
(define-module (gnu packages apl)
#:use-module (guix licenses)
#:use-module (guix packages)
#:use-module (guix download)
#:use-module (guix build-system gnu)
#:use-module ((gnu packages gettext)
#:renamer (symbol-prefix-proc 'guix:))
#:use-module (gnu packages maths)
#:use-module (gnu packages readline))
(define-public apl
(package
(name "apl")
(version "1.1")
(source
(origin
(method url-fetch)
(uri (string-append "mirror://gnu/apl/apl-" version ".tar.gz"))
(sha256
(base32
"1myinxa0m3y4fanpxflfakfk3m1s8641wdlbwbs0vg5yp10xm0m3"))))
(build-system gnu-build-system)
(home-page "http://www.gnu.org/software/apl/")
(inputs
`(("gettext" ,guix:gettext)
("lapack" ,lapack)
("readline" ,readline)))
(synopsis "APL interpreter")
(description
"GNU APL is a free interpreter for the programming language APL. It is
an implementation of the ISO standard 13751.")
(license gpl3+)))

4
gnu/packages/autogen.scm

@ -28,7 +28,7 @@
(define-public autogen
(package
(name "autogen")
(version "5.18.1")
(version "5.18.2")
(source
(origin
(method url-fetch)
@ -37,7 +37,7 @@
version ".tar.gz"))
(sha256
(base32
"0k0gkr5inr9wb3ws30q6bbiqg3qm3ryvl9cznym2xis4lm216d53"))))
"0s2021bwpq6h199cbbranz96hhm5s7v66lc68h8v198vqbg049yc"))))
(build-system gnu-build-system)
(inputs `(("which" ,which)
("guile" ,guile-2.0)))

9
gnu/packages/base.scm

@ -49,19 +49,14 @@
(define-public hello
(package
(name "hello")
(version "2.8")
(version "2.9")
(source (origin
(method url-fetch)
(uri (string-append "mirror://gnu/hello/hello-" version
".tar.gz"))
(sha256
(base32 "0wqd8sjmxfskrflaxywc7gqw7sfawrfvdxd9skxawzfgyy0pzdz6"))))
(base32 "19qy37gkasc4csb1d3bdiz9snn8mir2p3aj0jgzmfv0r2hi7mfzc"))))
(build-system gnu-build-system)
(arguments '(#:configure-flags
`("--disable-dependency-tracking"
,(string-append "--with-gawk=" ; for illustration purposes
(assoc-ref %build-inputs "gawk")))))
(inputs `(("gawk" ,gawk)))
(synopsis "Hello, GNU world: An example GNU package")
(description
"GNU Hello prints the message \"Hello, world!\" and then exits. It

4
gnu/packages/bison.scm

@ -30,7 +30,7 @@
(define bison
(package
(name "bison")
(version "3.0")
(version "3.0.1")
(source
(origin
(method url-fetch)
@ -38,7 +38,7 @@
version ".tar.xz"))
(sha256
(base32
"1j14fqgi9wzqgsy4fhkcdrv4hv6rrvhvn84axs520w9b022mbb79"))))
"1jx2ymvhl6h2jq6sf0lrk7ggfc2v1ri49yib8ppir0vdnh1znkll"))))
(build-system gnu-build-system)
(native-inputs `(("perl" ,perl)))
(inputs `(("flex" ,flex)))

4
gnu/packages/cflow.scm

@ -35,6 +35,10 @@
(base32
"1jkbq97ajcf834z68hbn3xfhiz921zhn39gklml1racf0kb3jzh3"))))
(build-system gnu-build-system)
;; Needed to have cflow-mode.el installed.
(native-inputs `(("emacs" ,emacs)))
(home-page "http://www.gnu.org/software/cflow/")
(synopsis "Create a graph of control flow within a program")
(description

49
gnu/packages/complexity.scm

@ -0,0 +1,49 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2013 Ludovic Courtès <ludo@gnu.org>
;;;
;;; This file is part of GNU Guix.
;;;
;;; GNU Guix is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
;;; the Free Software Foundation; either version 3 of the License, or (at
;;; your option) any later version.
;;;
;;; GNU Guix is distributed in the hope that it will be useful, but
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;;; GNU General Public License for more details.
;;;
;;; You should have received a copy of the GNU General Public License
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
(define-module (gnu packages complexity)
#:use-module (guix packages)
#:use-module (guix download)
#:use-module (guix licenses)
#:use-module (guix build-system gnu)
#:use-module (gnu packages texinfo)
#:use-module (gnu packages autogen))
(define-public complexity
(package
(name "complexity")
(version "1.1")
(source (origin
(method url-fetch)
(uri (string-append "mirror://gnu/complexity/complexity-"
version ".tar.gz"))
(sha256
(base32
"1aad7n35ymxbj5dlpvm64dcd71b6i7hbmps0g7nkf47vj53l6y2j"))))
(build-system gnu-build-system)
(native-inputs
`(("texinfo" ,texinfo)
("autogen" ,autogen)))
(home-page "http://www.gnu.org/software/complexity/")
(synopsis "Analyze complexity of C functions")
(description
"GNU complexity provides tools for finding procedures that are
convoluted, overly long or otherwise difficult to understand. This
may help in learning or reviewing unfamiliar code or perhaps
highlighting your own code that seemed comprehensible when you wrote it.")
(license gpl3+)))

4
gnu/packages/freeipmi.scm

@ -27,14 +27,14 @@
(define-public freeipmi
(package
(name "freeipmi")
(version "1.3.2")
(version "1.3.3")
(source (origin
(method url-fetch)
(uri (string-append "mirror://gnu/freeipmi/freeipmi-"
version ".tar.gz"))
(sha256
(base32
"1gz2r3zp8ag4cd5cflh4fy8mpvwcx1wdr37mkqkph3m5lx2w48qb"))))
"0pmgr66k4cx0gdwzfby6643m15bb4q2yx2g5r2jr3qidrfyxhi3j"))))
(build-system gnu-build-system)
(inputs
`(("readline" ,readline) ("libgcrypt" ,libgcrypt)))

4
gnu/packages/gnunet.scm

@ -38,14 +38,14 @@
(define-public libextractor
(package
(name "libextractor")
(version "1.1")
(version "1.2")
(source (origin
(method url-fetch)
(uri (string-append "mirror://gnu/libextractor/libextractor-"
version ".tar.gz"))
(sha256
(base32
"1zvj64ig456c9ya3r8ib48ms42cnli9y7ig5p04xqm16z7vw5dyb"))))
"1n7z6s5ils6xmf6b0z1xda41maxj94c1n6wlyyxmacs5lrkh2a96"))))
(build-system gnu-build-system)
;; WARNING: Checks require /dev/shm to be in the build chroot, especially
;; not to be a symbolic link to /run/shm.

97
gnu/packages/gnuzilla.scm

@ -0,0 +1,97 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2013 Andreas Enge <andreas@enge.fr>
;;;
;;; This file is part of GNU Guix.
;;;
;;; GNU Guix is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
;;; the Free Software Foundation; either version 3 of the License, or (at
;;; your option) any later version.
;;;
;;; GNU Guix is distributed in the hope that it will be useful, but
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;;; GNU General Public License for more details.
;;;
;;; You should have received a copy of the GNU General Public License
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
(define-module (gnu packages gnuzilla)
#:use-module (gnu packages)
#:use-module ((guix licenses)
#:renamer (symbol-prefix-proc 'license:))
#:use-module (guix packages)
#:use-module (guix download)
#:use-module (guix build-system gnu)
#:use-module (gnu packages glib)
#:use-module (gnu packages gstreamer)
#:use-module (gnu packages gtk)
#:use-module (gnu packages linux)
#:use-module (gnu packages perl)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages python)
#:use-module (gnu packages xorg)
#:use-module (gnu packages yasm)
#:use-module (gnu packages zip))
(define-public icecat
(package
(name "icecat")
(version "24.0")
(source
(origin
(method url-fetch)
(uri (string-append "mirror://gnu/gnuzilla/"
(substring version 0 (string-index version #\.))
"/icecat-" version ".tar.gz"))
(sha256
(base32
"1vxzjwmhad6yxx4sk9zvapjgv5salcv10id061q0991ii3dycy9a"))))
(build-system gnu-build-system)
(inputs
`(("alsa-lib" ,alsa-lib)
("dbus" ,dbus)
("dbus-glib" ,dbus-glib)
("glib" ,glib)
("gstreamer" ,gstreamer-0.10)
("gst-plugins-base" ,gst-plugins-base-0.10)
("gtk+" ,gtk+-2)
("libxt" ,libxt)
("mesa" ,mesa)
("perl" ,perl)
("pkg-config" ,pkg-config)
("python" ,python-2) ; Python 3 not supported
("python2-pysqlite" ,python2-pysqlite)
("unzip" ,unzip)
("yasm" ,yasm)
("zip" ,zip)))
(arguments
`(#:tests? #f ; no check target
#:phases
(alist-cons-before
'patch-source-shebangs 'sanitise
(lambda _
;; delete dangling symlinks
(delete-file "browser/base/content/.#aboutDialog.xul")
(delete-file "browser/base/content/abouthome/.#aboutHome.xhtml")
(delete-file "browser/branding/unofficial/content/.#aboutHome.xhtml")
(delete-file "toolkit/crashreporter/google-breakpad/autotools/compile"))
(alist-replace
'configure
;; configure does not work followed by both "SHELL=..." and
;; "CONFIG_SHELL=..."; set environment variables instead
(lambda* (#:key outputs configure-flags #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(setenv "SHELL" (which "bash"))
(setenv "CONFIG_SHELL" (which "bash"))
(zero? (system* "./configure"
(string-append "--prefix=" out)
"--disable-webrtc")))) ; webrtc creates an error
%standard-phases))))
(home-page "http://www.gnu.org/software/gnuzilla/")
(synopsis "Entirely free browser derived from Mozilla Firefox")
(description
"IceCat is the GNU version of the Firefox browser. It is entirely free
software, which does not recommend non-free plugins and addons. It also
features extra privacy-protecting features built in.")
(license license:mpl2.0))) ; and others, see toolkit/content/license.html

48
gnu/packages/gvpe.scm

@ -0,0 +1,48 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2013 Ludovic Courtès <ludo@gnu.org>
;;;
;;; This file is part of GNU Guix.
;;;
;;; GNU Guix is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
;;; the Free Software Foundation; either version 3 of the License, or (at
;;; your option) any later version.
;;;
;;; GNU Guix is distributed in the hope that it will be useful, but
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;;; GNU General Public License for more details.
;;;
;;; You should have received a copy of the GNU General Public License
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
(define-module (gnu packages gvpe)
#:use-module (guix packages)
#:use-module (guix download)
#:use-module ((guix licenses) #:select (gpl3+))
#:use-module (guix build-system gnu)
#:use-module (gnu packages openssl)
#:use-module ((gnu packages compression) #:select (zlib)))
(define-public gvpe
(package
(name "gvpe")
(version "2.25")
(source (origin
(method url-fetch)
(uri (string-append "mirror://gnu/gvpe/gvpe-"
version ".tar.gz"))
(sha256
(base32
"1gsipcysvsk80gvyn9jnk9g0xg4ng9yd5zp066jnmpgs52d2vhvk"))))
(build-system gnu-build-system)
(home-page "http://software.schmorp.de/pkg/gvpe.html")
(inputs `(("openssl" ,openssl)
("zlib" ,zlib)))
(synopsis "Secure VPN among multiple nodes over an untrusted network")
(description
"The GNU Virtual Private Ethernet creates a virtual network
with multiple nodes using a variety of transport protocols. It works
by creating encrypted host-to-host tunnels between multiple
endpoints.")
(license gpl3+)))

37
gnu/packages/kde.scm

@ -17,11 +17,15 @@
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
(define-module (gnu packages kde)
#:use-module ((guix licenses) #:select (bsd-2))
#:use-module ((guix licenses) #:select (bsd-2 lgpl2.1+))
#:use-module (guix packages)
#:use-module (guix download)
#:use-module (guix build-system cmake)
#:use-module (gnu packages qt))
#:use-module (gnu packages glib)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages pulseaudio)
#:use-module (gnu packages qt)
#:use-module (gnu packages xorg))
(define-public automoc4
(package
@ -44,3 +48,32 @@
(synopsis "build tool for KDE")
(description "KDE desktop environment")
(license bsd-2)))
(define-public phonon
(package
(name "phonon")
(version "4.7.0")
(source (origin
(method url-fetch)
(uri (string-append "http://download.kde.org/stable/" name
"/" version "/"
name "-" version ".tar.xz"))
(sha256
(base32
"1sxrnwm16dxy32xmrqf26762wmbqing1zx8i4vlvzgzvd9xy39ac"))))
(build-system cmake-build-system)
;; FIXME: Add interpreter ruby once available.
;; Add optional input libqtzeitgeist.
(inputs
`(("automoc4" ,automoc4)
("glib" ,glib)
("libx11" ,libx11)
("pkg-config" ,pkg-config)
("pulseaudio" ,pulseaudio)
("qt" ,qt-4)))
(arguments
`(#:tests? #f)) ; no test target
(home-page "http://phonon.kde.org/")
(synopsis "Qt 4 multimedia API")
(description "KDE desktop environment")
(license lgpl2.1+)))

4
gnu/packages/lightning.scm

@ -25,14 +25,14 @@
(define-public lightning
(package
(name "lightning")
(version "2.0.1")
(version "2.0.2")
(source (origin
(method url-fetch)
(uri (string-append "mirror://gnu/lightning/lightning-"
version ".tar.gz"))
(sha256
(base32
"1cc19rpgrqvpkzb19ffsxw3k254m46npbkx8cbgv3dbxjf9sf4v5"))))
"100ya7dx12403gimif7p2q7ahd8vxqrxpxqzqr1zqci825nb0b43"))))
(build-system gnu-build-system)
(synopsis "Library for generating assembly code at runtime")
(description

4
gnu/packages/linux.scm

@ -145,7 +145,7 @@
(license gpl2+)))
(define-public linux-libre
(let* ((version "3.11")
(let* ((version "3.12")
(build-phase
'(lambda* (#:key system #:allow-other-keys #:rest args)
(let ((arch (car (string-split system #\-))))
@ -191,7 +191,7 @@
(uri (linux-libre-urls version))
(sha256
(base32
"1vlk04xkvyy1kc9zz556md173rn1qzlnvhz7c9sljv4bpk3mdspl"))))
"0drjxm9h2k9bik2mhrqqqi6cm5rn2db647wf0zvb58xldj0zmhb6"))))
(build-system gnu-build-system)
(native-inputs `(("perl" ,perl)
("bc" ,bc)

47
gnu/packages/parallel.scm

@ -0,0 +1,47 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2013 Eric Bavier <bavier@member.fsf.org>
;;;
;;; This file is part of GNU Guix.
;;;
;;; GNU Guix is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
;;; the Free Software Foundation; either version 3 of the License, or (at
;;; your option) any later version.
;;;
;;; GNU Guix is distributed in the hope that it will be useful, but
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;;; GNU General Public License for more details.
;;;
;;; You should have received a copy of the GNU General Public License
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
(define-module (gnu packages parallel)
#:use-module (guix packages)
#:use-module (guix licenses)
#:use-module (guix download)
#:use-module (guix build-system gnu)
#:use-module (gnu packages)
#:use-module (gnu packages perl))
(define-public parallel
(package
(name "parallel")
(version "20131022")
(source
(origin
(method url-fetch)
(uri (string-append "mirror://gnu/parallel/parallel-"
version ".tar.bz2"))
(sha256
(base32
"1ydn8aj72wfjdvldzjwah9cvqay8vzr3dbspa5l0g2y10dx0qa4k"))))
(build-system gnu-build-system)
(inputs `(("perl" ,perl)))
(home-page "http://www.gnu.org/software/parallel/")
(synopsis "Build and execute command lines in parallel")
(description
"GNU Parallel is a tool for executing shell jobs in parallel using one
or more computers. Jobs can consist of single commands or of scripts
and they are executed on lists of files, hosts, users or other items.")
(license gpl3+)))

72
gnu/packages/qt.scm

@ -118,22 +118,28 @@ X11 (yet).")
(("/bin/pwd") (which "pwd")))
;; do not pass "--enable-fast-install", which makes the
;; configure process fail
(zero? (system* "./configure"
"-verbose"
"-prefix" out
"-opensource"
"-confirm-license"
;; drop all special machine instructions
"-no-sse2"
"-no-sse3"
"-no-ssse3"
"-no-sse4.1"
"-no-sse4.2"
"-no-avx"
"-no-avx2"
"-no-neon"
"-no-mips_dsp"
"-no-mips_dspr2"))))
(zero? (system*
"./configure"
"-verbose"
"-prefix" out
"-opensource"
"-confirm-license"
;; drop special machine instructions not supported
;; on all instances of the target
,@(if (string-prefix? "x86_64"
(or (%current-target-system)
(%current-system)))
'()
'("-no-sse2"))
"-no-sse3"
"-no-ssse3"
"-no-sse4.1"
"-no-sse4.2"
"-no-avx"
"-no-avx2"
"-no-neon"
"-no-mips_dsp"
"-no-mips_dspr2"))))
%standard-phases)))
(home-page "http://qt-project.org/")
(synopsis "Cross-platform GUI library")
@ -165,20 +171,26 @@ developers using C++ or QML, a CSS & JavaScript like language.")
(("/bin/pwd") (which "pwd")))
;; do not pass "--enable-fast-install", which makes the
;; configure process fail
(zero? (system* "./configure"
"-verbose"
"-prefix" out
"-opensource"
"-confirm-license"
;; drop all special machine instructions
"-no-mmx"
(zero? (system*
"./configure"
"-verbose"
"-prefix" out
"-opensource"
"-confirm-license"
;; drop special machine instructions not supported
;; on all instances of the target
,@(if (string-prefix? "x86_64"
(or (%current-target-system)
(%current-system)))
'()
'("-no-mmx"
"-no-3dnow"
"-no-sse"
"-no-sse2"
"-no-sse3"
"-no-ssse3"
"-no-sse4.1"
"-no-sse4.2"
"-no-avx"
"-no-neon"))))
"-no-sse2"))
"-no-sse3"
"-no-ssse3"
"-no-sse4.1"
"-no-sse4.2"
"-no-avx"
"-no-neon"))))
%standard-phases)))))

47
gnu/packages/sdl.scm

@ -23,8 +23,53 @@
#:use-module (guix download)
#:use-module (guix build-system gnu)
#:use-module (gnu packages linux)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages pulseaudio)
#:use-module (gnu packages xorg)
#:export (libmikmod))
#:export (sdl
sdl2
libmikmod))
(define sdl
(package
(name "sdl")
(version "1.2.15")
(source (origin
(method url-fetch)
(uri
(string-append "http://libsdl.org/release/SDL-"
version ".tar.gz"))
(sha256
(base32
"005d993xcac8236fpvd1iawkz4wqjybkpn8dbwaliqz5jfkidlyn"))))
(build-system gnu-build-system)
(arguments '(#:tests? #f)) ; no check target
(inputs `(("libx11" ,libx11)
("libxrandr" ,libxrandr)
("mesa" ,mesa)
("alsa-lib" ,alsa-lib)
("pkg-config" ,pkg-config)
("pulseaudio" ,pulseaudio)))
(synopsis "Cross platform game development library")
(description "Simple DirectMedia Layer is a cross-platform development
library designed to provide low level access to audio, keyboard, mouse,
joystick, and graphics hardware.")
(home-page "http://libsdl.org/")
(license lgpl2.1)))
(define sdl2
(package (inherit sdl)
(name "sdl2")
(version "2.0.0")
(source (origin
(method url-fetch)
(uri
(string-append "http://libsdl.org/release/SDL2-"
version ".tar.gz"))
(sha256
(base32
"0y3in99brki7vc2mb4c0w39v70mf4h341mblhh8nmq4h7lawhskg"))))
(license bsd-3)))
(define libmikmod
(package

6
gnu/packages/version-control.scm

@ -29,6 +29,7 @@
#:use-module (gnu packages gettext)
#:use-module (gnu packages apr)
#:use-module (gnu packages curl)
#:use-module (gnu packages ed)
#:use-module (gnu packages nano)
#:use-module (gnu packages openssl)
#:use-module (gnu packages perl)
@ -262,15 +263,16 @@ projects, from individuals to large-scale enterprise operations.")
(define-public rcs
(package
(name "rcs")
(version "5.9.0")
(version "5.9.1")
(source (origin
(method url-fetch)
(uri (string-append "mirror://gnu/rcs/rcs-"
version ".tar.xz"))
(sha256
(base32
"0w26vsx732dcmb5qfhlkkzvrk1sx6d74qibrn914n14j0ci90jcq"))))
"1376amzaj7x6ar3xi1dldc0hgfa3n7412c46wqk2h2f2lf67jsk0"))))
(build-system gnu-build-system)
(native-inputs `(("ed" ,ed)))
(home-page "http://www.gnu.org/software/rcs/")
(synopsis "Per-file local revision control system")
(description

2
gnu/system/vm.scm

@ -134,7 +134,7 @@ made available under the /xchg CIFS share."
(setenv "PATH" cu)
,(if make-disk-image?
`(zero? (system* img "create" "image.qcow2"
`(zero? (system* img "create" "-f" "qcow2" "image.qcow2"
,(number->string disk-image-size)))
'(begin))

3
guix/build-system/python.scm

@ -96,6 +96,7 @@ prepended to the name."
#:key
(python (default-python))
(tests? #t)
(test-target "test")
(configure-flags ''())
(phases '(@ (guix build python-build-system)
%standard-phases))
@ -124,7 +125,7 @@ provides a 'setup.py' file as its build system."
source)
#:configure-flags ,configure-flags
#:system ,system
#:test-target "test"
#:test-target ,test-target
#:tests? ,tests?
#:phases ,phases
#:outputs %outputs

118
guix/derivations.scm

@ -25,6 +25,7 @@
#:use-module (rnrs bytevectors)
#:use-module (ice-9 match)
#:use-module (ice-9 rdelim)
#:use-module (ice-9 vlist)
#:use-module (guix store)
#:use-module (guix utils)
#:use-module (guix hash)
@ -63,6 +64,7 @@
derivation-path->output-path
derivation-path->output-paths
derivation
map-derivation
%guile-for-build
imported-modules
@ -539,15 +541,6 @@ advance, such as a file download.
When REFERENCES-GRAPHS is true, it must be a list of file name/store path
pairs. In that case, the reference graph of each store path is exported in
the build environment in the corresponding file, in a simple text format."
(define direct-store-path?
(let ((len (+ 1 (string-length (%store-prefix)))))
(lambda (p)
;; Return #t if P is a store path, and not a sub-directory of a
;; store path. This predicate is needed because files *under* a
;; store path are not valid inputs.
(and (store-path? p)
(not (string-index (substring p len) #\/))))))
(define (add-output-paths drv)
;; Return DRV with an actual store path for each of its output and the
;; corresponding environment variable.
@ -655,6 +648,113 @@ the build environment in the corresponding file, in a simple text format."
inputs))))
(set-file-name drv file))))
(define* (map-derivation store drv mapping
#:key (system (%current-system)))
"Given MAPPING, a list of pairs of derivations, return a derivation based on
DRV where all the 'car's of MAPPING have been replaced by its 'cdr's,
recursively."
(define (substitute str initial replacements)
(fold (lambda (path replacement result)
(string-replace-substring result path
replacement))
str
initial replacements))
(define (substitute-file file initial replacements)
(define contents
(with-fluids ((%default-port-encoding #f))
(call-with-input-file file get-string-all)))
(let ((updated (substitute contents initial replacements)))
(if (string=? updated contents)
file
;; XXX: permissions aren't preserved.
(add-text-to-store store (store-path-package-name file)
updated))))
(define input->output-paths
(match-lambda
(((? derivation? drv))
(list (derivation->output-path drv)))
(((? derivation? drv) sub-drvs ...)
(map (cut derivation->output-path drv <>)
sub-drvs))
((file)
(list file))))
(let ((mapping (fold (lambda (pair result)
(match pair
(((? derivation? orig) . replacement)
(vhash-cons (derivation-file-name orig)
replacement result))
((file . replacement)
(vhash-cons file replacement result))))
vlist-null
mapping)))
(define rewritten-input
;; Rewrite the given input according to MAPPING, and return an input
;; in the format used in 'derivation' calls.
(memoize
(lambda (input loop)
(match input
(($ <derivation-input> path (sub-drvs ...))
(match (vhash-assoc path mapping)
((_ . (? derivation? replacement))
(cons replacement sub-drvs))
((_ . replacement)
(list replacement))
(#f
(let* ((drv (loop (call-with-input-file path read-derivation))))
(cons drv sub-drvs)))))))))
(let loop ((drv drv))
(let* ((inputs (map (cut rewritten-input <> loop)
(derivation-inputs drv)))
(initial (append-map derivation-input-output-paths
(derivation-inputs drv)))
(replacements (append-map input->output-paths inputs))
;; Sources typically refer to the output directories of the
;; original inputs, INITIAL. Rewrite them by substituting
;; REPLACEMENTS.
(sources (map (lambda (source)
(match (vhash-assoc source mapping)
((_ . replacement)
replacement)
(#f
(substitute-file source
initial replacements))))
(derivation-sources drv)))
;; Now augment the lists of initials and replacements.
(initial (append (derivation-sources drv) initial))
(replacements (append sources replacements))
(name (store-path-package-name
(string-drop-right (derivation-file-name drv)
4))))
(derivation store name
(substitute (derivation-builder drv)
initial replacements)
(map (cut substitute <> initial replacements)
(derivation-builder-arguments drv))
#:system system
#:env-vars (map (match-lambda
((var . value)
`(,var
. ,(substitute value initial
replacements))))
(derivation-builder-environment-vars drv))
#:inputs (append (map list sources) inputs)
#:outputs (map car (derivation-outputs drv))
#:hash (match (derivation-outputs drv)
((($ <derivation-output> _ algo hash))
hash)
(_ #f))
#:hash-algo (match (derivation-outputs drv)
((($ <derivation-output> _ algo hash))
algo)
(_ #f)))))))
;;;
;;; Store compatibility layer.

40
guix/packages.scm

@ -224,24 +224,26 @@ corresponds to the arguments expected by `set-path-environment-variable'."
(($ <location> file line column)
(catch 'system
(lambda ()
(call-with-input-file (search-path %load-path file)
(lambda (port)
(goto port line column)
(match (read port)
(('package inits ...)
(let ((field (assoc field inits)))
(match field
((_ value)
;; Put the `or' here, and not in the first argument of
;; `and=>', to work around a compiler bug in 2.0.5.
(or (and=> (source-properties value)
source-properties->location)
(and=> (source-properties field)
source-properties->location)))
(_
#f))))
(_
#f)))))
;; In general we want to keep relative file names for modules.
(with-fluids ((%file-port-name-canonicalization 'relative))
(call-with-input-file (search-path %load-path file)
(lambda (port)
(goto port line column)
(match (read port)
(('package inits ...)
(let ((field (assoc field inits)))
(match field
((_ value)
;; Put the `or' here, and not in the first argument of
;; `and=>', to work around a compiler bug in 2.0.5.
(or (and=> (source-properties value)
source-properties->location)
(and=> (source-properties field)
source-properties->location)))
(_
#f))))
(_
#f))))))
(lambda _
#f)))
(_ #f)))
@ -419,7 +421,7 @@ IMPORTED-MODULES specify modules to use/import for use by SNIPPET."
#:modules modules
#:imported-modules modules
#:guile-for-build guile)))
((and (? string?) (? store-path?) file)
((and (? string?) (? direct-store-path?) file)
file)
((? string? file)
(add-to-store store (basename file) #t "sha256" file))))

181
guix/scripts/build.scm

@ -23,6 +23,7 @@
#:use-module (guix derivations)
#:use-module (guix packages)
#:use-module (guix utils)
#:use-module (guix monads)
#:use-module (ice-9 format)
#:use-module (ice-9 match)
#:use-module (ice-9 vlist)
@ -38,19 +39,23 @@
(define %store
(make-parameter #f))
(define (derivations-from-package-expressions str package-derivation
system source?)
(define (derivation-from-expression str package-derivation
system source?)
"Read/eval STR and return the corresponding derivation path for SYSTEM.
When SOURCE? is true, return the derivations of the package sources;
otherwise, use PACKAGE-DERIVATION to compute the derivation of a package."
(let ((p (read/eval-package-expression str)))
(if source?
(let ((source (package-source p)))
(if source
(package-source-derivation (%store) source)
(leave (_ "package `~a' has no source~%")
(package-name p))))
(package-derivation (%store) p system))))
When SOURCE? is true and STR evaluates to a package, return the derivation of
the package source; otherwise, use PACKAGE-DERIVATION to compute the
derivation of a package."
(match (read/eval str)
((? package? p)
(if source?
(let ((source (package-source p)))
(if source
(package-source-derivation (%store) source)
(leave (_ "package `~a' has no source~%")
(package-name p))))
(package-derivation (%store) p system)))
((? procedure? proc)
(run-with-store (%store) (proc) #:system system))))
;;;
@ -68,7 +73,7 @@ otherwise, use PACKAGE-DERIVATION to compute the derivation of a package."
(display (_ "Usage: guix build [OPTION]... PACKAGE-OR-DERIVATION...
Build the given PACKAGE-OR-DERIVATION and return their output paths.\n"))
(display (_ "
-e, --expression=EXPR build the package EXPR evaluates to"))
-e, --expression=EXPR build the package or derivation EXPR evaluates to"))
(display (_ "
-S, --source build the packages' source derivations"))
(display (_ "
@ -95,6 +100,8 @@ Build the given PACKAGE-OR-DERIVATION and return their output paths.\n"))
as a garbage collector root"))
(display (_ "
--verbosity=LEVEL use the given verbosity LEVEL"))
(display (_ "
--log-file return the log file names for the given derivations"))
(newline)
(display (_ "
-h, --help display this help and exit"))
@ -161,7 +168,10 @@ Build the given PACKAGE-OR-DERIVATION and return their output paths.\n"))
(lambda (opt name arg result)
(let ((level (string->number arg)))
(alist-cons 'verbosity level
(alist-delete 'verbosity result)))))))
(alist-delete 'verbosity result)))))
(option '("log-file") #f #f
(lambda (opt name arg result)
(alist-cons 'log-file? #t result)))))
;;;
@ -235,68 +245,89 @@ Build the given PACKAGE-OR-DERIVATION and return their output paths.\n"))
(leave (_ "~A: unknown package~%") name))))))
(with-error-handling
(let ((opts (parse-options)))
(define package->derivation
(match (assoc-ref opts 'target)
(#f package-derivation)
(triplet
(cut package-cross-derivation <> <> triplet <>))))
;; Ask for absolute file names so that .drv file names passed from the
;; user to 'read-derivation' are absolute when it returns.
(with-fluids ((%file-port-name-canonicalization 'absolute))
(let ((opts (parse-options)))
(define package->derivation
(match (assoc-ref opts 'target)
(#f package-derivation)
(triplet
(cut package-cross-derivation <> <> triplet <>))))
(parameterize ((%store (open-connection)))
(let* ((src? (assoc-ref opts 'source?))
(sys (assoc-ref opts 'system))
(drv (filter-map (match-lambda
(('expression . str)
(derivations-from-package-expressions
str package->derivation sys src?))
(('argument . (? derivation-path? drv))
(call-with-input-file drv read-derivation))
(('argument . (? string? x))
(let ((p (find-package x)))
(if src?
(let ((s (package-source p)))
(package-source-derivation
(%store) s))
(package->derivation (%store) p sys))))
(_ #f))
opts))
(roots (filter-map (match-lambda
(('gc-root . root) root)
(_ #f))
opts)))
(parameterize ((%store (open-connection)))
(let* ((src? (assoc-ref opts 'source?))
(sys (assoc-ref opts 'system))
(drv (filter-map (match-lambda
(('expression . str)
(derivation-from-expression
str package->derivation sys src?))
(('argument . (? derivation-path? drv))
(call-with-input-file drv read-derivation))
(('argument . (? store-path?))
;; Nothing to do; maybe for --log-file.
#f)
(('argument . (? string? x))
(let ((p (find-package x)))
(if src?
(let ((s (package-source p)))
(package-source-derivation
(%store) s))
(package->derivation (%store) p sys))))
(_ #f))
opts))
(roots (filter-map (match-lambda
(('gc-root . root) root)
(_ #f))
opts)))
(show-what-to-build (%store) drv
#:use-substitutes? (assoc-ref opts 'substitutes?)
#:dry-run? (assoc-ref opts 'dry-run?))
(unless (assoc-ref opts 'log-file?)
(show-what-to-build (%store) drv
#:use-substitutes? (assoc-ref opts 'substitutes?)
#:dry-run? (assoc-ref opts 'dry-run?)))
;; TODO: Add more options.
(set-build-options (%store)
#:keep-failed? (assoc-ref opts 'keep-failed?)
#:build-cores (or (assoc-ref opts 'cores) 0)
#:fallback? (assoc-ref opts 'fallback?)
#:use-substitutes? (assoc-ref opts 'substitutes?)
#:max-silent-time (assoc-ref opts 'max-silent-time)
#:verbosity (assoc-ref opts 'verbosity))
;; TODO: Add more options.
(set-build-options (%store)
#:keep-failed? (assoc-ref opts 'keep-failed?)
#:build-cores (or (assoc-ref opts 'cores) 0)
#:fallback? (assoc-ref opts 'fallback?)
#:use-substitutes? (assoc-ref opts 'substitutes?)
#:max-silent-time (assoc-ref opts 'max-silent-time)
#:verbosity (assoc-ref opts 'verbosity))
(if (assoc-ref opts 'derivations-only?)
(begin
(format #t "~{~a~%~}" (map derivation-file-name drv))
(for-each (cut register-root <> <>)
(map (compose list derivation-file-name) drv)
roots))
(or (assoc-ref opts 'dry-run?)
(and (build-derivations (%store) drv)
(for-each (lambda (d)
(format #t "~{~a~%~}"
(map (match-lambda
((out-name . out)
(derivation->output-path
d out-name)))
(derivation-outputs d))))
drv)
(for-each (cut register-root <> <>)
(map (lambda (drv)
(map cdr
(derivation->output-paths drv)))
drv)
roots)))))))))
(cond ((assoc-ref opts 'log-file?)
(for-each (lambda (file)
(let ((log (log-file (%store) file)))
(if log
(format #t "~a~%" log)
(leave (_ "no build log for '~a'~%")
file))))
(delete-duplicates
(append (map derivation-file-name drv)
(filter-map (match-lambda
(('argument
. (? store-path? file))
file)
(_ #f))
opts)))))
((assoc-ref opts 'derivations-only?)
(format #t "~{~a~%~}" (map derivation-file-name drv))
(for-each (cut register-root <> <>)
(map (compose list derivation-file-name) drv)
roots))
((not (assoc-ref opts 'dry-run?))
(and (build-derivations (%store) drv)
(for-each (lambda (d)
(format #t "~{~a~%~}"
(map (match-lambda
((out-name . out)
(derivation->output-path
d out-name)))
(derivation-outputs d))))
drv)
(for-each (cut register-root <> <>)
(map (lambda (drv)
(map cdr
(derivation->output-paths drv)))
drv)
roots))))))))))

32
guix/scripts/substitute-binary.scm

@ -123,7 +123,8 @@ again."
(lambda ()
body ...)
(lambda args
;; The SIGALRM triggers EINTR, because of the bug at
;; Before Guile v2.0.9-39-gfe51c7b, the SIGALRM triggers EINTR
;; because of the bug at
;; <http://lists.gnu.org/archive/html/guile-devel/2013-06/msg00050.html>.
;; When that happens, try again. Note: SA_RESTART cannot be
;; used because of <http://bugs.gnu.org/14640>.
@ -162,10 +163,17 @@ provide."
(warning (_ "while fetching ~a: server is unresponsive~%")
(uri->string uri))
(warning (_ "try `--no-substitutes' if the problem persists~%"))
(when port
(close-port port)))
;; Before Guile v2.0.9-39-gfe51c7b, EINTR was reported to the user,
;; and thus PORT had to be closed and re-opened. This is not the
;; case afterward.
(unless (or (guile-version>? "2.0.9")
(version>? (version) "2.0.9.39"))
(when port
(close-port port))))
(begin
(set! port (open-socket-for-uri uri #:buffered? buffered?))
(when (or (not port) (port-closed? port))
(set! port (open-socket-for-uri uri #:buffered? buffered?)))