Archived
1
0
Fork 0

Merge 'master' into core-updates

This commit is contained in:
Thomas Danckaert 2017-10-16 19:52:30 +02:00
commit 8cff2e7aed
No known key found for this signature in database
GPG key ID: 5C3B064C724A5726
69 changed files with 4811 additions and 1034 deletions

View file

@ -80,6 +80,7 @@ MODULES = \
guix/build-system/dub.scm \ guix/build-system/dub.scm \
guix/build-system/emacs.scm \ guix/build-system/emacs.scm \
guix/build-system/font.scm \ guix/build-system/font.scm \
guix/build-system/go.scm \
guix/build-system/meson.scm \ guix/build-system/meson.scm \
guix/build-system/minify.scm \ guix/build-system/minify.scm \
guix/build-system/asdf.scm \ guix/build-system/asdf.scm \
@ -111,6 +112,7 @@ MODULES = \
guix/build/meson-build-system.scm \ guix/build/meson-build-system.scm \
guix/build/minify-build-system.scm \ guix/build/minify-build-system.scm \
guix/build/font-build-system.scm \ guix/build/font-build-system.scm \
guix/build/go-build-system.scm \
guix/build/asdf-build-system.scm \ guix/build/asdf-build-system.scm \
guix/build/git.scm \ guix/build/git.scm \
guix/build/hg.scm \ guix/build/hg.scm \

View file

@ -2,6 +2,7 @@
# GNU Guix --- Functional package management for GNU # GNU Guix --- Functional package management for GNU
# Copyright © 2012, 2013, 2014, 2015, 2017 Ludovic Courtès <ludo@gnu.org> # Copyright © 2012, 2013, 2014, 2015, 2017 Ludovic Courtès <ludo@gnu.org>
# Copyright © 2017 Eric Bavier <bavier@cray.com>
# #
# This file is part of GNU Guix. # This file is part of GNU Guix.
# #
@ -50,13 +51,9 @@ NIX_LIBEXEC_DIR="@abs_top_builddir@/nix/scripts" # for 'guix-authenticate'
export NIX_ROOT_FINDER NIX_SUBSTITUTERS NIX_LIBEXEC_DIR export NIX_ROOT_FINDER NIX_SUBSTITUTERS NIX_LIBEXEC_DIR
NIX_BUILD_HOOK="$abs_top_builddir/nix/scripts/offload" NIX_BUILD_HOOK="$abs_top_builddir/nix/scripts/offload"
if [ -x "$NIX_BUILD_HOOK" ] @BUILD_DAEMON_OFFLOAD_TRUE@export NIX_BUILD_HOOK
then @BUILD_DAEMON_OFFLOAD_FALSE@# No offloading support.
export NIX_BUILD_HOOK @BUILD_DAEMON_OFFLOAD_FALSE@unset NIX_BUILD_HOOK
else
# No offloading support.
unset NIX_BUILD_HOOK
fi
# The 'guix-register' program. # The 'guix-register' program.
GUIX_REGISTER="$abs_top_builddir/guix-register" GUIX_REGISTER="$abs_top_builddir/guix-register"

View file

@ -3576,6 +3576,24 @@ debugging information''), which roughly means that code is compiled with
@code{-O2 -g}, as is the case for Autoconf-based packages by default. @code{-O2 -g}, as is the case for Autoconf-based packages by default.
@end defvr @end defvr
@defvr {Scheme Variable} go-build-system
This variable is exported by @code{(guix build-system go)}. It
implements a build procedure for Go packages using the standard
@url{https://golang.org/cmd/go/#hdr-Compile_packages_and_dependencies,
Go build mechanisms}.
The user is expected to provide a value for the key @code{#:import-path}
and, in some cases, @code{#:unpack-path}. The
@url{https://golang.org/doc/code.html#ImportPaths, import path}
corresponds to the filesystem path expected by the package's build
scripts and any referring packages, and provides a unique way to
refer to a Go package. It is typically based on a combination of the
package source code's remote URI and filesystem hierarchy structure. In
some cases, you will need to unpack the package's source code to a
different directory structure than the one indicated by the import path,
and @code{#:unpack-path} should be used in such cases.
@end defvr
@defvr {Scheme Variable} glib-or-gtk-build-system @defvr {Scheme Variable} glib-or-gtk-build-system
This variable is exported by @code{(guix build-system glib-or-gtk)}. It This variable is exported by @code{(guix build-system glib-or-gtk)}. It
is intended for use with packages making use of GLib or GTK+. is intended for use with packages making use of GLib or GTK+.
@ -8406,6 +8424,7 @@ management, power management, and more, would look like this:
@include os-config-desktop.texi @include os-config-desktop.texi
@end lisp @end lisp
@cindex UEFI
A graphical UEFI system with a choice of lightweight window managers A graphical UEFI system with a choice of lightweight window managers
instead of full-blown desktop environments would look like this: instead of full-blown desktop environments would look like this:
@ -8413,6 +8432,10 @@ instead of full-blown desktop environments would look like this:
@include os-config-lightweight-desktop.texi @include os-config-lightweight-desktop.texi
@end lisp @end lisp
This example refers to the @file{/boot/efi} partition by its UUID,
@code{1234-ABCD}. Replace this UUID with the right UUID on your system,
as returned by the @command{blkid} command.
@xref{Desktop Services}, for the exact list of services provided by @xref{Desktop Services}, for the exact list of services provided by
@var{%desktop-services}. @xref{X.509 Certificates}, for background @var{%desktop-services}. @xref{X.509 Certificates}, for background
information about the @code{nss-certs} package that is used here. information about the @code{nss-certs} package that is used here.
@ -9767,8 +9790,32 @@ Return a service that runs the Guix build daemon according to
@var{config}. @var{config}.
@end deffn @end deffn
@deffn {Scheme Procedure} udev-service [#:udev udev] @cindex udev-service
@cindex udev-rule
@deffn {Scheme Procedure} udev-service [#:udev @var{udev}] [#:rules @var{'()}]
Run @var{udev}, which populates the @file{/dev} directory dynamically. Run @var{udev}, which populates the @file{/dev} directory dynamically.
Additional udev rules can be provided as a list of files through the
@var{rules} variable. The procedure @var{udev-rule} simplifies the
creation of these rule files.
In the following example, a rule for a USB device is defined to be
stored in the file @file{90-usb-thing.rules}, and the default
@var{udev-service} is extended with it. The rule runs a script upon
detecting a USB device with a given product identifier.
@example
(define %example-udev-rule
(udev-rule "90-usb-thing.rules"
"ACTION==\"add\", SUBSYSTEM==\"usb\", ATTR@{product@}==\"Example\", RUN+=\"/path/to/script\""))
(operating-system
;; @dots{}
(services (modify-services %desktop-services
(udev-service-type config =>
(udev-configuration (inherit config)
(rules (append (udev-configuration-rules config)
(list %example-udev-rule))))))))
@end example
@end deffn @end deffn
@deffn {Scheme Procedure} urandom-seed-service @var{#f} @deffn {Scheme Procedure} urandom-seed-service @var{#f}

View file

@ -20,9 +20,11 @@
(define-module (gnu build file-systems) (define-module (gnu build file-systems)
#:use-module (gnu system uuid) #:use-module (gnu system uuid)
#:use-module (gnu system file-systems)
#:use-module (guix build utils) #:use-module (guix build utils)
#:use-module (guix build bournish) #:use-module (guix build bournish)
#:use-module (guix build syscalls) #:use-module ((guix build syscalls)
#:hide (file-system-type))
#:use-module (rnrs io ports) #:use-module (rnrs io ports)
#:use-module (rnrs bytevectors) #:use-module (rnrs bytevectors)
#:use-module (ice-9 match) #:use-module (ice-9 match)
@ -192,7 +194,7 @@ if DEVICE does not contain a btrfs file system."
Trailing spaces are trimmed." Trailing spaces are trimmed."
(string-trim-right (latin1->string (sub-bytevector sblock 71 11) (lambda (c) #f)) #\space)) (string-trim-right (latin1->string (sub-bytevector sblock 71 11) (lambda (c) #f)) #\space))
(define (check-fat32-file-system device) (define (check-fat-file-system device)
"Return the health of a fat file system on DEVICE." "Return the health of a fat file system on DEVICE."
(match (status:exit-val (match (status:exit-val
(system* "fsck.vfat" "-v" "-a" device)) (system* "fsck.vfat" "-v" "-a" device))
@ -200,6 +202,33 @@ Trailing spaces are trimmed."
(1 'errors-corrected) (1 'errors-corrected)
(_ 'fatal-error))) (_ 'fatal-error)))
;;;
;;; FAT16 file systems.
;;;
(define (fat16-superblock? sblock)
"Return #t when SBLOCK is a fat16 boot record."
(bytevector=? (sub-bytevector sblock 54 8)
(string->utf8 "FAT16 ")))
(define (read-fat16-superblock device)
"Return the raw contents of DEVICE's fat16 superblock as a bytevector, or
#f if DEVICE does not contain a fat16 file system."
(read-superblock device 0 62 fat16-superblock?))
(define (fat16-superblock-uuid sblock)
"Return the Volume ID of a fat superblock SBLOCK as a 4-byte bytevector."
(sub-bytevector sblock 39 4))
(define (fat16-superblock-volume-name sblock)
"Return the volume name of SBLOCK as a string of at most 11 characters, or
#f if SBLOCK has no volume name. The volume name is a latin1 string.
Trailing spaces are trimmed."
(string-trim-right (latin1->string (sub-bytevector sblock 43 11)
(lambda (c) #f))
#\space))
;;; ;;;
;;; ISO9660 file systems. ;;; ISO9660 file systems.
@ -384,7 +413,9 @@ partition field reader that returned a value."
(partition-field-reader read-btrfs-superblock (partition-field-reader read-btrfs-superblock
btrfs-superblock-volume-name) btrfs-superblock-volume-name)
(partition-field-reader read-fat32-superblock (partition-field-reader read-fat32-superblock
fat32-superblock-volume-name))) fat32-superblock-volume-name)
(partition-field-reader read-fat16-superblock
fat16-superblock-volume-name)))
(define %partition-uuid-readers (define %partition-uuid-readers
(list (partition-field-reader read-iso9660-superblock (list (partition-field-reader read-iso9660-superblock
@ -394,7 +425,9 @@ partition field reader that returned a value."
(partition-field-reader read-btrfs-superblock (partition-field-reader read-btrfs-superblock
btrfs-superblock-uuid) btrfs-superblock-uuid)
(partition-field-reader read-fat32-superblock (partition-field-reader read-fat32-superblock
fat32-superblock-uuid))) fat32-superblock-uuid)
(partition-field-reader read-fat16-superblock
fat16-superblock-uuid)))
(define read-partition-label (define read-partition-label
(cut read-partition-field <> %partition-label-readers)) (cut read-partition-field <> %partition-label-readers))
@ -448,8 +481,7 @@ the following:
\"/dev/sda1\"; \"/dev/sda1\";
'label', in which case SPEC is known to designate a partition label--e.g., 'label', in which case SPEC is known to designate a partition label--e.g.,
\"my-root-part\"; \"my-root-part\";
'uuid', in which case SPEC must be a UUID (a 16-byte bytevector) 'uuid', in which case SPEC must be a UUID designating a partition;
designating a partition;
'any', in which case SPEC can be anything. 'any', in which case SPEC can be anything.
" "
(define max-trials (define max-trials
@ -495,9 +527,11 @@ the following:
(resolve find-partition-by-label spec identity)) (resolve find-partition-by-label spec identity))
((uuid) ((uuid)
(resolve find-partition-by-uuid (resolve find-partition-by-uuid
(if (string? spec) (cond ((string? spec)
(string->uuid spec) (string->uuid spec))
spec) ((uuid? spec)
(uuid-bytevector spec))
(else spec))
uuid->string)) uuid->string))
(else (else
(error "unknown device title" title)))) (error "unknown device title" title))))
@ -508,7 +542,7 @@ the following:
(cond (cond
((string-prefix? "ext" type) check-ext2-file-system) ((string-prefix? "ext" type) check-ext2-file-system)
((string-prefix? "btrfs" type) check-btrfs-file-system) ((string-prefix? "btrfs" type) check-btrfs-file-system)
((string-suffix? "fat" type) check-fat32-file-system) ((string-suffix? "fat" type) check-fat-file-system)
(else #f))) (else #f)))
(if check-procedure (if check-procedure
@ -552,11 +586,8 @@ corresponds to the symbols listed in FLAGS."
(() (()
0)))) 0))))
(define* (mount-file-system spec #:key (root "/root")) (define* (mount-file-system fs #:key (root "/root"))
"Mount the file system described by SPEC under ROOT. SPEC must have the "Mount the file system described by FS, a <file-system> object, under ROOT.
form:
(DEVICE TITLE MOUNT-POINT TYPE (FLAGS ...) OPTIONS CHECK?)
DEVICE, MOUNT-POINT, and TYPE must be strings; OPTIONS can be a string or #f; DEVICE, MOUNT-POINT, and TYPE must be strings; OPTIONS can be a string or #f;
FLAGS must be a list of symbols. CHECK? is a Boolean indicating whether to FLAGS must be a list of symbols. CHECK? is a Boolean indicating whether to
@ -582,34 +613,36 @@ run a file system check."
(if options (if options
(string-append "," options) (string-append "," options)
""))))) "")))))
(match spec (let ((type (file-system-type fs))
((source title mount-point type (flags ...) options check?) (options (file-system-options fs))
(let ((source (canonicalize-device-spec source title)) (source (canonicalize-device-spec (file-system-device fs)
(mount-point (string-append root "/" mount-point)) (file-system-title fs)))
(flags (mount-flags->bit-mask flags))) (mount-point (string-append root "/"
(when check? (file-system-mount-point fs)))
(check-file-system source type)) (flags (mount-flags->bit-mask (file-system-flags fs))))
(when (file-system-check? fs)
(check-file-system source type))
;; Create the mount point. Most of the time this is a directory, but ;; Create the mount point. Most of the time this is a directory, but
;; in the case of a bind mount, a regular file or socket may be needed. ;; in the case of a bind mount, a regular file or socket may be needed.
(if (and (= MS_BIND (logand flags MS_BIND)) (if (and (= MS_BIND (logand flags MS_BIND))
(not (file-is-directory? source))) (not (file-is-directory? source)))
(unless (file-exists? mount-point) (unless (file-exists? mount-point)
(mkdir-p (dirname mount-point)) (mkdir-p (dirname mount-point))
(call-with-output-file mount-point (const #t))) (call-with-output-file mount-point (const #t)))
(mkdir-p mount-point)) (mkdir-p mount-point))
(cond (cond
((string-prefix? "nfs" type) ((string-prefix? "nfs" type)
(mount-nfs source mount-point type flags options)) (mount-nfs source mount-point type flags options))
(else (else
(mount source mount-point type flags options))) (mount source mount-point type flags options)))
;; For read-only bind mounts, an extra remount is needed, as per ;; For read-only bind mounts, an extra remount is needed, as per
;; <http://lwn.net/Articles/281157/>, which still applies to Linux 4.0. ;; <http://lwn.net/Articles/281157/>, which still applies to Linux 4.0.
(when (and (= MS_BIND (logand flags MS_BIND)) (when (and (= MS_BIND (logand flags MS_BIND))
(= MS_RDONLY (logand flags MS_RDONLY))) (= MS_RDONLY (logand flags MS_RDONLY)))
(let ((flags (logior MS_BIND MS_REMOUNT MS_RDONLY))) (let ((flags (logior MS_BIND MS_REMOUNT MS_RDONLY)))
(mount source mount-point type flags #f))))))) (mount source mount-point type flags #f)))))
;;; file-systems.scm ends here ;;; file-systems.scm ends here

View file

@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU ;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2013, 2014, 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com> ;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com>
;;; ;;;
;;; This file is part of GNU Guix. ;;; This file is part of GNU Guix.
@ -27,9 +27,11 @@
#:use-module (ice-9 match) #:use-module (ice-9 match)
#:use-module (ice-9 ftw) #:use-module (ice-9 ftw)
#:use-module (guix build utils) #:use-module (guix build utils)
#:use-module (guix build syscalls) #:use-module ((guix build syscalls)
#:hide (file-system-type))
#:use-module (gnu build linux-modules) #:use-module (gnu build linux-modules)
#:use-module (gnu build file-systems) #:use-module (gnu build file-systems)
#:use-module (gnu system file-systems)
#:export (mount-essential-file-systems #:export (mount-essential-file-systems
linux-command-line linux-command-line
find-long-option find-long-option
@ -349,19 +351,17 @@ supports kernel command-line options '--load', '--root', and '--repl'.
Mount the root file system, specified by the '--root' command-line argument, Mount the root file system, specified by the '--root' command-line argument,
if any. if any.
MOUNTS must be a list suitable for 'mount-file-system'. MOUNTS must be a list of <file-system> objects.
When VOLATILE-ROOT? is true, the root file system is writable but any changes When VOLATILE-ROOT? is true, the root file system is writable but any changes
to it are lost." to it are lost."
(define root-mount-point? (define (root-mount-point? fs)
(match-lambda (string=? (file-system-mount-point fs) "/"))
((device _ "/" _ ...) #t)
(_ #f)))
(define root-fs-type (define root-fs-type
(or (any (match-lambda (or (any (lambda (fs)
((device _ "/" type _ ...) type) (and (root-mount-point? fs)
(_ #f)) (file-system-type fs)))
mounts) mounts)
"ext4")) "ext4"))

View file

@ -152,8 +152,7 @@ for the process."
;; Mount user-specified file systems. ;; Mount user-specified file systems.
(for-each (lambda (file-system) (for-each (lambda (file-system)
(mount-file-system (file-system->spec file-system) (mount-file-system file-system #:root root))
#:root root))
mounts) mounts)
;; Jail the process inside the container's root file system. ;; Jail the process inside the container's root file system.

View file

@ -87,6 +87,7 @@ GNU_SYSTEM_MODULES = \
%D%/packages/check.scm \ %D%/packages/check.scm \
%D%/packages/chez.scm \ %D%/packages/chez.scm \
%D%/packages/ci.scm \ %D%/packages/ci.scm \
%D%/packages/cinnamon.scm \
%D%/packages/cmake.scm \ %D%/packages/cmake.scm \
%D%/packages/cobol.scm \ %D%/packages/cobol.scm \
%D%/packages/code.scm \ %D%/packages/code.scm \
@ -382,6 +383,7 @@ GNU_SYSTEM_MODULES = \
%D%/packages/suckless.scm \ %D%/packages/suckless.scm \
%D%/packages/swig.scm \ %D%/packages/swig.scm \
%D%/packages/sync.scm \ %D%/packages/sync.scm \
%D%/packages/syncthing.scm \
%D%/packages/synergy.scm \ %D%/packages/synergy.scm \
%D%/packages/syndication.scm \ %D%/packages/syndication.scm \
%D%/packages/task-management.scm \ %D%/packages/task-management.scm \
@ -1048,6 +1050,7 @@ dist_patch_DATA = \
%D%/packages/patches/ttf2eot-cstddef.patch \ %D%/packages/patches/ttf2eot-cstddef.patch \
%D%/packages/patches/ttfautohint-source-date-epoch.patch \ %D%/packages/patches/ttfautohint-source-date-epoch.patch \
%D%/packages/patches/tophat-build-with-later-seqan.patch \ %D%/packages/patches/tophat-build-with-later-seqan.patch \
%D%/packages/patches/totem-meson-easy-codec.patch \
%D%/packages/patches/tuxpaint-stamps-path.patch \ %D%/packages/patches/tuxpaint-stamps-path.patch \
%D%/packages/patches/unrtf-CVE-2016-10091.patch \ %D%/packages/patches/unrtf-CVE-2016-10091.patch \
%D%/packages/patches/unzip-CVE-2014-8139.patch \ %D%/packages/patches/unzip-CVE-2014-8139.patch \

View file

@ -961,21 +961,27 @@ follower.")
(define-public fluidsynth (define-public fluidsynth
(package (package
(name "fluidsynth") (name "fluidsynth")
(version "1.1.6") (version "1.1.8")
(source (origin (source (origin
(method url-fetch) (method git-fetch)
(uri (string-append (uri (git-reference
"mirror://sourceforge/fluidsynth/fluidsynth-" (url "https://github.com/FluidSynth/fluidsynth.git")
version "/fluidsynth-" version ".tar.gz")) (commit (string-append "v" version))))
(file-name (string-append name "-" version "-checkout"))
(sha256 (sha256
(base32 (base32
"070pwb7brdcn1mfvplkd56vjc7lbz4iznzkqvfsakvgbv68k71ah")))) "12q7hv0zvgylsdj1ipssv5zr7ap2y410dxsd63dz22y05fa2hwwd"))))
(build-system gnu-build-system) (build-system cmake-build-system)
(arguments (arguments
`(#:phases '(#:tests? #f ; no check phase
#:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-after 'unpack 'remove-broken-symlinks (add-after 'unpack 'fix-libdir
(lambda _ (delete-file-recursively "m4") #t))))) (lambda _
(substitute* "CMakeLists.txt"
(("LIB_SUFFIX \\$\\{_init_lib_suffix\\}")
"LIB_SUFFIX \"\""))
#t)))))
(inputs (inputs
`(("libsndfile" ,libsndfile) `(("libsndfile" ,libsndfile)
("alsa-lib" ,alsa-lib) ("alsa-lib" ,alsa-lib)
@ -993,7 +999,7 @@ follower.")
specifications. FluidSynth reads and handles MIDI events from the MIDI input specifications. FluidSynth reads and handles MIDI events from the MIDI input
device. It is the software analogue of a MIDI synthesizer. FluidSynth can device. It is the software analogue of a MIDI synthesizer. FluidSynth can
also play midifiles using a Soundfont.") also play midifiles using a Soundfont.")
(license license:gpl2+))) (license license:lgpl2.1+)))
(define-public faad2 (define-public faad2
(package (package

View file

@ -730,14 +730,14 @@ provide a coordinated and extensible framework to do computational biology.")
(define-public python-biopython (define-public python-biopython
(package (package
(name "python-biopython") (name "python-biopython")
(version "1.68") (version "1.70")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
;; use PyPi rather than biopython.org to ease updating ;; use PyPi rather than biopython.org to ease updating
(uri (pypi-uri "biopython" version)) (uri (pypi-uri "biopython" version))
(sha256 (sha256
(base32 (base32
"07qc7nz0k77y8hf8s18rscvibvm91zw0kkq7ylrhisf8vp8hkp6i")))) "0nz4n9d2y2dg849gn1z0vjlkwcpzzkzy3fij7x94a6ixy2c54z2a"))))
(build-system python-build-system) (build-system python-build-system)
(arguments (arguments
`(#:phases `(#:phases
@ -1774,15 +1774,14 @@ collections of DNA motifs.")
(define-public clustal-omega (define-public clustal-omega
(package (package
(name "clustal-omega") (name "clustal-omega")
(version "1.2.1") (version "1.2.4")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (string-append "http://www.clustal.org/omega/clustal-omega-"
"http://www.clustal.org/omega/clustal-omega-" version ".tar.gz"))
version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"02ibkx0m0iwz8nscg998bh41gg251y56cgh86bvyrii5m8kjgwqf")))) "1vm30mzncwdv881vrcwg11vzvrsmwy4wg80j5i0lcfk6dlld50w6"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(inputs (inputs
`(("argtable" ,argtable))) `(("argtable" ,argtable)))
@ -4890,6 +4889,43 @@ subsequent visualization, annotation and storage of results.")
;; LGPLv2.1+ ;; LGPLv2.1+
(license (list license:gpl2 license:lgpl2.1+)))) (license (list license:gpl2 license:lgpl2.1+))))
(define-public plink-ng
(package (inherit plink)
(name "plink-ng")
(version "1.90b4")
(source
(origin
(method url-fetch)
(uri (string-append "https://github.com/chrchang/plink-ng/archive/v"
version ".tar.gz"))
(file-name (string-append name "-" version ".tar.gz"))
(sha256
(base32 "09ixrds009aczjswxr2alcb774mksq5g0v78dgjjn1h4dky0kf9a"))))
(build-system gnu-build-system)
(arguments
'(#:tests? #f ;no "check" target
#:make-flags (list "BLASFLAGS=-llapack -lopenblas"
"CFLAGS=-Wall -O2 -DDYNAMIC_ZLIB=1"
"ZLIB=-lz"
"-f" "Makefile.std")
#:phases
(modify-phases %standard-phases
(add-after 'unpack 'chdir
(lambda _ (chdir "1.9") #t))
(delete 'configure) ; no "configure" script
(replace 'install
(lambda* (#:key outputs #:allow-other-keys)
(let ((bin (string-append (assoc-ref outputs "out")
"/bin/")))
(install-file "plink" bin)
#t))))))
(inputs
`(("zlib" ,zlib)
("lapack" ,lapack)
("openblas" ,openblas)))
(home-page "https://www.cog-genomics.org/plink/")
(license license:gpl3+)))
(define-public smithlab-cpp (define-public smithlab-cpp
(let ((revision "1") (let ((revision "1")
(commit "728a097bec88c6f4b8528b685932049e660eff2e")) (commit "728a097bec88c6f4b8528b685932049e660eff2e"))
@ -8070,7 +8106,7 @@ library implementing most of the pipeline's features.")
(define-public rcas-web (define-public rcas-web
(package (package
(name "rcas-web") (name "rcas-web")
(version "0.0.3") (version "0.0.4")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
@ -8079,7 +8115,7 @@ library implementing most of the pipeline's features.")
"/rcas-web-" version ".tar.gz")) "/rcas-web-" version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"0d3my0g8i7js59n184zzzjdki7hgmhpi4rhfvk7i6jsw01ba04qq")))) "1p16frfys41a8yaa4gkm457nzkqhqs2pc3lkac0ds457w9w5j1gm"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(arguments (arguments
`(#:phases `(#:phases
@ -9977,7 +10013,7 @@ browser.")
(revision "1")) (revision "1"))
(package (package
(name "f-seq") (name "f-seq")
(version (string-append "1.1-" revision "." commit)) (version (string-append "1.1-" revision "." (string-take commit 7)))
(source (origin (source (origin
(method git-fetch) (method git-fetch)
(uri (git-reference (uri (git-reference
@ -10086,3 +10122,51 @@ straight away. Its main features are:
and CHH context and CHH context
@end itemize\n") @end itemize\n")
(license license:gpl3+))) (license license:gpl3+)))
(define-public paml
(package
(name "paml")
(version "4.9e")
(source (origin
(method url-fetch)
(uri (string-append "http://abacus.gene.ucl.ac.uk/software/"
"paml" version ".tgz"))
(sha256
(base32
"13zf6h9fiqghwhch2h06x1zdr6s42plsnqahflp5g7myr3han3s6"))
(modules '((guix build utils)))
;; Remove Windows binaries
(snippet
'(begin
(for-each delete-file (find-files "." "\\.exe$"))
#t))))
(build-system gnu-build-system)
(arguments
`(#:tests? #f ; there are no tests
#:make-flags '("CC=gcc")
#:phases
(modify-phases %standard-phases
(replace 'configure
(lambda _
(substitute* "src/BFdriver.c"
(("/bin/bash") (which "bash")))
(chdir "src")
#t))
(replace 'install
(lambda* (#:key outputs #:allow-other-keys)
(let ((tools '("baseml" "basemlg" "codeml"
"pamp" "evolver" "yn00" "chi2"))
(bin (string-append (assoc-ref outputs "out") "/bin"))
(docdir (string-append (assoc-ref outputs "out")
"/share/doc/paml")))
(mkdir-p bin)
(for-each (lambda (file) (install-file file bin)) tools)
(copy-recursively "../doc" docdir)
#t))))))
(home-page "http://abacus.gene.ucl.ac.uk/software/paml.html")
(synopsis "Phylogentic analysis by maximum likelihood")
(description "PAML (for Phylogentic Analysis by Maximum Likelihood)
contains a few programs for model fitting and phylogenetic tree reconstruction
using nucleotide or amino-acid sequence data.")
;; GPLv3 only
(license license:gpl3)))

View file

@ -70,15 +70,15 @@ makes a few sacrifices to acquire fast full and incremental build times.")
(define-public meson (define-public meson
(package (package
(name "meson") (name "meson")
(version "0.42.1") (version "0.43.0")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "https://github.com/mesonbuild/meson/" (uri (string-append "https://github.com/mesonbuild/meson/"
"archive/" version ".tar.gz")) "releases/download/" version "/meson-"
(file-name (string-append name "-" version ".tar.gz")) version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"1494hdnd40g2v6pky34j0f2iwc6kwn51vck37qwz7nl2xr17b18q")))) "0h3k0m45004ay1hzz9r66fkl1kwizaigxahyrlabyw0d1slyq4y5"))))
(build-system python-build-system) (build-system python-build-system)
(inputs `(("ninja", ninja))) (inputs `(("ninja", ninja)))
(propagated-inputs `(("python" ,python))) (propagated-inputs `(("python" ,python)))

86
gnu/packages/cinnamon.scm Normal file
View file

@ -0,0 +1,86 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2017 ng0 <ng0@infotropique.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 cinnamon)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
#:use-module (guix download)
#:use-module (guix utils)
#:use-module (guix build-system gnu)
#:use-module (gnu packages)
#:use-module (gnu packages autotools)
#:use-module (gnu packages freedesktop)
#:use-module (gnu packages gettext)
#:use-module (gnu packages glib)
#:use-module (gnu packages gtk)
#:use-module (gnu packages gnome)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages pulseaudio)
#:use-module (gnu packages python)
#:use-module (gnu packages xorg))
(define-public cinnamon-desktop
(package
(name "cinnamon-desktop")
(version "3.4.2")
(source (origin
(method url-fetch)
(uri (string-append "https://github.com/linuxmint/cinnamon-desktop/"
"archive/" version ".tar.gz"))
(file-name (string-append name "-" version ".tar.gz"))
(sha256
(base32
"1jf24csrbfi9aiza1g70jpvsbjiqwphk0i5wilxq9kpjjsl99maq"))))
(build-system gnu-build-system)
(arguments
`(#:phases
(modify-phases %standard-phases
(add-after 'unpack 'autoconf
(lambda _
(mkdir-p "m4")
(zero?
(and (system* "glib-gettextize" "--force" "--copy")
(system* "intltoolize" "--force" "--copy" "--automake")
(system* "autoreconf" "--verbose" "--force" "--install"))))))))
;; TODO: package 'libgsystem'.
(inputs
`(("accountsservice" ,accountsservice)
("gtk+" ,gtk+)
("glib" ,glib)
("gobject-introspection" ,gobject-introspection)
("gnome-common" ,gnome-common)
("libxkbfile" ,libxkbfile)
("libxrandr" ,libxrandr)
("python-2" ,python-2)
("pulseaudio" ,pulseaudio)
("xkeyboard-config" ,xkeyboard-config)))
(native-inputs
`(("autoconf" ,autoconf)
("automake" ,automake)
("gettext" ,gettext-minimal)
("glib" ,glib "bin") ; glib-gettextize
("intltool" ,intltool)
("libtool" ,libtool)
("pkg-config" ,pkg-config)))
(home-page "https://github.com/linuxmint/cinnamon-desktop/")
(synopsis "Library for the Cinnamon Desktop")
(description
"The cinnamon-desktop package contains the libcinnamon-desktop library,
as well as some desktop-wide documents.")
(license (list license:gpl2+ license:lgpl2.0+
license:expat)))) ;display-name.c , edid-parse.c

View file

@ -4,7 +4,7 @@
;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name> ;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name>
;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox> ;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox>
;;; Copyright © 2016 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2016 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is> ;;; Copyright © 2016, 2017 ng0 <ng0@infotropique.org>
;;; Copyright © 2016, 2017 Eric Bavier <bavier@member.fsf.org> ;;; Copyright © 2016, 2017 Eric Bavier <bavier@member.fsf.org>
;;; ;;;
;;; This file is part of GNU Guix. ;;; This file is part of GNU Guix.
@ -35,10 +35,12 @@
#:use-module (gnu packages image) #:use-module (gnu packages image)
#:use-module (gnu packages pkg-config) #:use-module (gnu packages pkg-config)
#:use-module (gnu packages libbsd) #:use-module (gnu packages libbsd)
#:use-module (gnu packages libffi)
#:use-module (gnu packages linux) #:use-module (gnu packages linux)
#:use-module (gnu packages nettle) #:use-module (gnu packages nettle)
#:use-module (gnu packages password-utils) #:use-module (gnu packages password-utils)
#:use-module (gnu packages perl) #:use-module (gnu packages perl)
#:use-module (gnu packages python)
#:use-module (gnu packages readline) #:use-module (gnu packages readline)
#:use-module (gnu packages search) #:use-module (gnu packages search)
#:use-module (gnu packages serialization) #:use-module (gnu packages serialization)
@ -594,3 +596,39 @@ or millenia for an attacker to try them all.
data on your platform, so the seed itself will be as random as possible. data on your platform, so the seed itself will be as random as possible.
@end enumerate\n") @end enumerate\n")
(license license:artistic2.0))) (license license:artistic2.0)))
(define-public python-pynacl
(package
(name "python-pynacl")
(version "1.1.2")
(source
(origin
(method url-fetch)
(uri (pypi-uri "PyNaCl" version))
(modules '((guix build utils)))
;; Remove bundled libsodium
(snippet '(delete-file-recursively "src/libsodium"))
(sha256
(base32
"135gz0020fqx8fbr9izpwyq49aww202nkqacq0cw61xz99sjpx9j"))))
(build-system python-build-system)
(arguments
`(#:phases
(modify-phases %standard-phases
(add-before 'build 'use-system-sodium
(lambda _
(setenv "SODIUM_INSTALL" "system")
#t)))))
(native-inputs
`(("python-pytest" ,python-pytest)))
(propagated-inputs
`(("python-cffi" ,python-cffi)
("python-six" ,python-six)
("libsodium" ,libsodium)))
(home-page "https://github.com/pyca/pynacl/")
(synopsis "Python bindings to libsodium")
(description
"PyNaCl is a Python binding to libsodium, which is a fork of the
Networking and Cryptography library. These libraries have a stated goal
of improving usability, security and speed.")
(license license:asl2.0)))

View file

@ -61,7 +61,7 @@
(source(origin (source(origin
(method url-fetch) (method url-fetch)
(uri (uri
(string-append "http://openprinting.org/download/cups-filters/" (string-append "https://openprinting.org/download/cups-filters/"
"cups-filters-" version ".tar.xz")) "cups-filters-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
@ -226,13 +226,13 @@ filters for the PDF-centric printing workflow introduced by OpenPrinting.")
(home-page "https://www.cups.org") (home-page "https://www.cups.org")
(synopsis "The Common Unix Printing System") (synopsis "The Common Unix Printing System")
(description (description
"CUPS is a printing system that uses the Internet Printing "CUPS is a printing system that uses the Internet Printing Protocol
Protocol (IPP). It provides System V and BSD command-line interfaces, as well (@dfn{IPP}). It provides System V and BSD command-line interfaces, as well
as a Web interface and a C programming interface to manage printers and print as a Web interface and a C programming interface to manage printers and print
jobs. It supports printing to both local (parallel, serial, USB) and jobs. It supports printing to both local (parallel, serial, USB) and
networked printers, and printers can be shared from one computer to another. networked printers, and printers can be shared from one computer to another.
Internally, CUPS uses PostScript Printer Description (PPD) files to describe Internally, CUPS uses PostScript Printer Description (@dfn{PPD}) files to
printer capabilities and features and a wide variety of generic and describe printer capabilities and features, and a wide variety of generic and
device-specific programs to convert and print many types of files.") device-specific programs to convert and print many types of files.")
(license license:gpl2))) (license license:gpl2)))

View file

@ -646,6 +646,19 @@ TIMESTAMP. It also supports storage of binary large objects, including
pictures, sounds, or video.") pictures, sounds, or video.")
(license (license:x11-style "file://COPYRIGHT")))) (license (license:x11-style "file://COPYRIGHT"))))
(define-public postgresql-9.6
(package
(inherit postgresql)
(name "postgresql")
(version "9.6.5")
(source (origin
(method url-fetch)
(uri (string-append "https://ftp.postgresql.org/pub/source/v"
version "/postgresql-" version ".tar.bz2"))
(sha256
(base32
"0k3ls2x182jz6djjiqj9kycddabdl2gk1y1ajq1vipnxwfki5nh6"))))))
(define-public qdbm (define-public qdbm
(package (package
(name "qdbm") (name "qdbm")

View file

@ -319,14 +319,14 @@ and can dramatically shorten the lifespan of the drive if left unchecked.")
(define-public gparted (define-public gparted
(package (package
(name "gparted") (name "gparted")
(version "0.28.1") (version "0.30.0")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
(uri (string-append "mirror://sourceforge/gparted/gparted/gparted-" (uri (string-append "mirror://sourceforge/gparted/gparted/gparted-"
version "/gparted-" version ".tar.gz")) version "/gparted-" version ".tar.gz"))
(sha256 (sha256
(base32 "0cyk8lpimm6wani8khw0szwqkgw5wpq2mfnfxkbgfm2774a1z2bn")))) (base32 "0jngbsbvg8k8vbpsphqbk8br2cbmxhabbm2c5bmxm2q5zvpr64fk"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(arguments (arguments
`(#:tests? #f ; Tests require a network connection. `(#:tests? #f ; Tests require a network connection.

View file

@ -361,7 +361,7 @@ when typing parentheses directly or commenting out code line by line.")
(define-public git-modes (define-public git-modes
(package (package
(name "git-modes") (name "git-modes")
(version "1.2.4") (version "1.2.6")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (string-append
@ -370,7 +370,7 @@ when typing parentheses directly or commenting out code line by line.")
(file-name (string-append name "-" version ".tar.gz")) (file-name (string-append name "-" version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"0xxrmf0jnyljxvllc22qa0v8lgi4k1ldnayjm5hf68m25jsr378l")))) "18z04wn5ird9l0h6n6x97v0kyzdj73832bj9qakm3fjjl7vcn0pw"))))
(build-system emacs-build-system) (build-system emacs-build-system)
(home-page "https://github.com/magit/git-modes") (home-page "https://github.com/magit/git-modes")
(synopsis "Emacs major modes for Git configuration files") (synopsis "Emacs major modes for Git configuration files")
@ -382,7 +382,7 @@ configuration files, such as .gitattributes, .gitignore, and .git/config.")
(define-public emacs-with-editor (define-public emacs-with-editor
(package (package
(name "emacs-with-editor") (name "emacs-with-editor")
(version "2.5.10") (version "2.7.0")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (string-append
@ -391,7 +391,7 @@ configuration files, such as .gitattributes, .gitignore, and .git/config.")
(file-name (string-append name "-" version ".tar.gz")) (file-name (string-append name "-" version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"0lsxa1hghybkzvqhqvvym3hxbyp9vjcnnpb9j800z0vyhbnlka67")))) "0kah7pv211zx9fsb5g4hd51bqcq2bxd1chdykd488ihvfz1l5y14"))))
(build-system emacs-build-system) (build-system emacs-build-system)
(propagated-inputs (propagated-inputs
`(("emacs-dash" ,emacs-dash))) `(("emacs-dash" ,emacs-dash)))
@ -407,7 +407,7 @@ on stdout instead of using a socket as the Emacsclient does.")
(define-public magit (define-public magit
(package (package
(name "magit") (name "magit")
(version "2.10.3") (version "2.11.0")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (string-append
@ -415,7 +415,7 @@ on stdout instead of using a socket as the Emacsclient does.")
version "/" name "-" version ".tar.gz")) version "/" name "-" version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"03ln65ss420gc3h4pi56dayd1p163xfxrxrd9fkb9xnkl8mjglqk")))) "11xly5bma9jc1jhs8fqbqrci8kz1y26yfq7dqjkqfy956wvfg6hz"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(native-inputs `(("texinfo" ,texinfo) (native-inputs `(("texinfo" ,texinfo)
("emacs" ,emacs-minimal))) ("emacs" ,emacs-minimal)))
@ -543,7 +543,7 @@ support for Git-SVN.")
(file-name (string-append "magit-popup-" version ".el")) (file-name (string-append "magit-popup-" version ".el"))
(sha256 (sha256
(base32 (base32
"08b6ypfiq8zavjfq0wcdh26xziwq7rqvvv3lfpib9101146kzx6d")))) "0w750kwngq63hi9drad3jxldwkg83sldb9w9r2xl2mqm3hm4l8s6"))))
(build-system emacs-build-system) (build-system emacs-build-system)
(propagated-inputs (propagated-inputs
`(("emacs-dash" ,emacs-dash))) `(("emacs-dash" ,emacs-dash)))
@ -1245,6 +1245,56 @@ written in the Go programming language.")
Maps directly inside Emacs.") Maps directly inside Emacs.")
(license license:gpl3+))) (license license:gpl3+)))
(define-public emacs-graphviz-dot-mode
(let ((commit "fdaabbcc95d9156e3dadc84f81a4750c5b692580")
(revision "1"))
(package
(name "emacs-graphviz-dot-mode")
(version (string-append "0.3.10-" revision "."
(string-take commit 7)))
(source (origin
(method git-fetch)
(uri (git-reference
(url "https://github.com/ppareit/graphviz-dot-mode.git")
(commit commit)))
(file-name (string-append name "-" version "-checkout"))
(sha256
(base32
"1s1qh5r0xp6hs0rl5yz5mkmjhpg04bh449c7vgjbb1pjsl1dl714"))))
(build-system emacs-build-system)
(arguments
`(#:phases
(modify-phases %standard-phases
(add-before 'install 'make-info
(lambda* (#:key inputs #:allow-other-keys)
(with-directory-excursion "texinfo"
(substitute* "Makefile"
(("\\/usr\\/bin\\/gzip")
(string-append (assoc-ref inputs "gzip") "/bin/gzip")))
(zero?
(system* "make"
"clean"
"info"
(string-append "TEXINFODIR="
(assoc-ref inputs "texinfo")
"/bin"))))))
(add-after 'install 'install-info
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(info (string-append out "/share/info")))
(install-file "texinfo/graphviz-dot-mode.info.gz" info)
#t))))))
(native-inputs
`(("texinfo" ,texinfo)
("gzip" ,gzip)))
(home-page "http://ppareit.github.com/graphviz-dot-mode")
(synopsis "Major mode for editing Graphviz Dot files")
(description
"This Emacs packages helps you to create @file{.dot} or @file{.gv}
files using the dot syntax, and use Graphviz to convert these files to
diagrams.")
(license license:gpl2+))))
(define-public emacs-mmm-mode (define-public emacs-mmm-mode
(package (package
(name "emacs-mmm-mode") (name "emacs-mmm-mode")
@ -2762,14 +2812,14 @@ package provides a light and a dark variant.")
(define-public emacs-ahungry-theme (define-public emacs-ahungry-theme
(package (package
(name "emacs-ahungry-theme") (name "emacs-ahungry-theme")
(version "1.4.0") (version "1.6.0")
(source (source
(origin (method url-fetch) (origin (method url-fetch)
(uri (string-append "https://elpa.gnu.org/packages/ahungry-theme-" (uri (string-append "https://elpa.gnu.org/packages/ahungry-theme-"
version ".tar")) version ".tar"))
(sha256 (sha256
(base32 (base32
"1n8k12mfn01f20j0pyd7ycj77x0y3a008xc94frklaaqjc0v26s4")))) "1b0x7g753gn7mym8286b937zmxv50jgdish2h6wc05w1g1lygwsz"))))
(build-system emacs-build-system) (build-system emacs-build-system)
(home-page "https://github.com/ahungry/color-theme-ahungry") (home-page "https://github.com/ahungry/color-theme-ahungry")
(synopsis "Ahungry color theme for Emacs") (synopsis "Ahungry color theme for Emacs")
@ -3197,14 +3247,14 @@ The purpose of this library is to wrap all the quirks and hassle of
(define-public emacs-queue (define-public emacs-queue
(package (package
(name "emacs-queue") (name "emacs-queue")
(version "0.1.1") (version "0.2")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "https://elpa.gnu.org/packages/queue-" (uri (string-append "https://elpa.gnu.org/packages/queue-"
version ".el")) version ".el"))
(sha256 (sha256
(base32 (base32
"0jw24fxqnf9qcaf2nh09cnds1kqfk7hal35dw83x1ari95say391")))) "0cx2848sqnnkkr4zisvqadzxngjyhmb36mh0q3if7q19yjjhmrkb"))))
(build-system emacs-build-system) (build-system emacs-build-system)
(home-page "http://www.dr-qubit.org/tags/computing-code-emacs.html") (home-page "http://www.dr-qubit.org/tags/computing-code-emacs.html")
(synopsis "Queue data structure for Emacs") (synopsis "Queue data structure for Emacs")
@ -3321,22 +3371,63 @@ that highlights non-conforming text. The subset of the English language called
E-Prime forbids the use of the \"to be\" form to strengthen your writing.") E-Prime forbids the use of the \"to be\" form to strengthen your writing.")
(license license:gpl3+)))) (license license:gpl3+))))
(define-public emacs-julia-mode
;; XXX: Upstream version remained stuck at 0.3. See
;; <https://github.com/JuliaEditorSupport/julia-emacs/issues/46>.
(let ((commit "115d4dc8a07445301772da8376b232fa8c7168f4")
(revision "1"))
(package
(name "emacs-julia-mode")
(version (string-append "0.3-" revision "." (string-take commit 8)))
(source
(origin
(method git-fetch)
(uri (git-reference
(url "https://github.com/JuliaEditorSupport/julia-emacs.git")
(commit commit)))
(file-name (string-append name "-" version "-checkout"))
(sha256
(base32
"1is4dcv6blslpzbjcg8l2jpxi8xj96q4cm0nxjxsyswpm8bw8ki0"))))
(build-system emacs-build-system)
(arguments
`(#:phases
(modify-phases %standard-phases
(add-before 'install 'check
(lambda _
(zero? (system* "emacs" "-batch"
"-l" "julia-mode.el"
"-l" "julia-mode-tests.el"
"-f" "ert-run-tests-batch-and-exit")))))))
(home-page "https://github.com/JuliaEditorSupport/julia-emacs")
(synopsis "Major mode for Julia")
(description "This Emacs package provides a mode for the Julia
programming language.")
(license license:expat))))
(define-public emacs-ess (define-public emacs-ess
(package (package
(name "emacs-ess") (name "emacs-ess")
(version "16.04") (version "16.10")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "http://ess.r-project.org/downloads/ess/ess-" (uri (string-append "http://ess.r-project.org/downloads/ess/ess-"
version ".tgz")) version ".tgz"))
(sha256 (sha256
(base32 (base32
"0w7mbbajn377gdmvnd21mpyr368b2ia46gq6cb99y4y5rspf9pcg")))) "04m8lwp3ylh2vl7k2bjjs7mxbm64j4sdckqpvnm9k0qhaqf02pjk"))
(modules '((guix build utils)))
(snippet
'(begin
;; Stop ESS from trying to bundle an external julia-mode.el.
(substitute* "lisp/Makefile"
(("^\tjulia-mode.elc\\\\\n") "")
(("^all: \\$\\(ELC\\) ess-custom.el julia-mode.el")
"all: $(ELC) ess-custom.el"))))))
(build-system gnu-build-system) (build-system gnu-build-system)
(arguments (arguments
(let ((base-directory "/share/emacs/site-lisp/guix.d/ess")) (let ((base-directory "/share/emacs/site-lisp/guix.d/ess"))
`(#:tests? #f ; There is no test suite. `(#:make-flags (list (string-append "PREFIX=" %output)
#:make-flags (list (string-append "PREFIX=" %output)
(string-append "ETCDIR=" %output "/" (string-append "ETCDIR=" %output "/"
,base-directory "/etc") ,base-directory "/etc")
(string-append "LISPDIR=" %output "/" (string-append "LISPDIR=" %output "/"
@ -3352,7 +3443,10 @@ E-Prime forbids the use of the \"to be\" form to strengthen your writing.")
;; FIXME: the texlive-union insists on regenerating fonts. It stores ;; FIXME: the texlive-union insists on regenerating fonts. It stores
;; them in HOME, so it needs to be writeable. ;; them in HOME, so it needs to be writeable.
(add-before 'build 'set-HOME (add-before 'build 'set-HOME
(lambda _ (setenv "HOME" "/tmp") #t)))))) (lambda _ (setenv "HOME" "/tmp") #t))
(replace 'check
(lambda _
(zero? (system* "make" "test"))))))))
(inputs (inputs
`(("emacs" ,emacs-minimal) `(("emacs" ,emacs-minimal)
("r-minimal" ,r-minimal))) ("r-minimal" ,r-minimal)))
@ -3717,7 +3811,7 @@ the file buffer.")
(define-public emacs-helm (define-public emacs-helm
(package (package
(name "emacs-helm") (name "emacs-helm")
(version "2.7.1") (version "2.8.5")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (string-append
@ -3726,7 +3820,7 @@ the file buffer.")
(file-name (string-append name "-" version ".tar.gz")) (file-name (string-append name "-" version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"0pay8pi3fszykgskfbxsp4byad497cgfz4m886mxnkba1naxf6h7")))) "15xlnjm9rsbn0xq7xc09y52h2kn41zwn7ldryammf6i46wl02kq3"))))
(build-system emacs-build-system) (build-system emacs-build-system)
(propagated-inputs (propagated-inputs
`(("emacs-async" ,emacs-async) `(("emacs-async" ,emacs-async)
@ -3988,14 +4082,14 @@ passive voice.")
(define-public emacs-org (define-public emacs-org
(package (package
(name "emacs-org") (name "emacs-org")
(version "20170917") (version "20171016")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "http://elpa.gnu.org/packages/org-" (uri (string-append "http://elpa.gnu.org/packages/org-"
version ".tar")) version ".tar"))
(sha256 (sha256
(base32 (base32
"0qyis5ph3h99zn9kx7sgraddz41c1cf6yjkwi4im6ikwxk9x8cgc")))) "1196kv83p953nd9c5gxkn8ndw2kmm2kfw34dldap6m89khqflz5a"))))
(build-system emacs-build-system) (build-system emacs-build-system)
(home-page "http://orgmode.org/") (home-page "http://orgmode.org/")
(synopsis "Outline-based notes management and organizer") (synopsis "Outline-based notes management and organizer")
@ -4005,6 +4099,50 @@ also is an authoring system with unique support for literate programming and
reproducible research.") reproducible research.")
(license license:gpl3+))) (license license:gpl3+)))
(define-public emacs-org-contrib
(package
(inherit emacs-org)
(name "emacs-org-contrib")
(source (origin
(method url-fetch)
(uri (string-append "http://orgmode.org/elpa/org-plus-contrib-"
(package-version emacs-org) ".tar"))
(sha256
(base32
"0xy2xrndlhs4kyvh6mmv24dnh3fn5p63d2gaimnrypf1p8znwzh4"))))
(arguments
`(#:modules ((guix build emacs-build-system)
(guix build utils)
(guix build emacs-utils)
(ice-9 ftw)
(srfi srfi-1))
#:phases
(modify-phases %standard-phases
(add-after 'install 'delete-org-files
(lambda* (#:key inputs outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(org (assoc-ref inputs "emacs-org"))
(contrib-files
(map basename (find-files out)))
(org+contrib-files
(map basename (find-files org)))
(duplicates (lset-intersection
string=? contrib-files org+contrib-files)))
(with-directory-excursion
(string-append
out "/share/emacs/site-lisp/guix.d/org-contrib-"
,(package-version emacs-org))
(for-each delete-file duplicates))
#t))))))
(propagated-inputs
`(("emacs-org" ,emacs-org)))
(synopsis "Contributed packages to Org-mode")
(description "Org is an Emacs mode for keeping notes, maintaining TODO
lists, and project planning with a fast and effective plain-text system.
This package is equivilent to org-plus-contrib, but only includes additional
files that you would find in @file{contrib/} from the git repository.")))
(define-public emacs-flx (define-public emacs-flx
(package (package
(name "emacs-flx") (name "emacs-flx")
@ -4691,7 +4829,7 @@ consistent and well-integrated user interface.")
(define-public emacs-adaptive-wrap (define-public emacs-adaptive-wrap
(package (package
(name "emacs-adaptive-wrap") (name "emacs-adaptive-wrap")
(version "0.5") (version "0.5.1")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (string-append
@ -4699,7 +4837,7 @@ consistent and well-integrated user interface.")
version ".el")) version ".el"))
(sha256 (sha256
(base32 (base32
"0frgmp8vrrml4iykm60j4d6cl9rbcivy9yh24q6kd10bcyx59ypy")))) "0qi7gjprcpywk2daivnlavwsx53hl5wcqvpxbwinvigg42vxh3ll"))))
(build-system emacs-build-system) (build-system emacs-build-system)
(home-page "http://elpa.gnu.org/packages/adaptive-wrap.html") (home-page "http://elpa.gnu.org/packages/adaptive-wrap.html")
(synopsis "Smart line-wrapping with wrap-prefix") (synopsis "Smart line-wrapping with wrap-prefix")
@ -5896,14 +6034,14 @@ It supports dired buffers and opens them in tree mode at destination.")
(define-public emacs-tiny (define-public emacs-tiny
(package (package
(name "emacs-tiny") (name "emacs-tiny")
(version "0.1.1") (version "0.2.1")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
(uri (string-append "http://elpa.gnu.org/packages/tiny-" version ".tar")) (uri (string-append "http://elpa.gnu.org/packages/tiny-" version ".tar"))
(sha256 (sha256
(base32 (base32
"1nhg8375qdn457wj0xmfaj72s87xbabk2w1nl6q7rjvwxv08yyn7")))) "1cr73a8gba549ja55x0c2s554f3zywf69zbnd7v82jz5q1k9wd2v"))))
(build-system emacs-build-system) (build-system emacs-build-system)
(home-page "https://github.com/abo-abo/tiny") (home-page "https://github.com/abo-abo/tiny")
(synopsis "Quickly generate linear ranges in Emacs") (synopsis "Quickly generate linear ranges in Emacs")
@ -5945,3 +6083,22 @@ an elisp expression.")
"@code{bash-completion} defines dynamic completion hooks for shell-mode "@code{bash-completion} defines dynamic completion hooks for shell-mode
and shell-command prompts that are based on bash completion.") and shell-command prompts that are based on bash completion.")
(license license:gpl2+))) (license license:gpl2+)))
(define-public emacs-easy-kill
(package
(name "emacs-easy-kill")
(version "0.9.3")
(source (origin
(method url-fetch)
(uri (string-append "https://elpa.gnu.org/packages/easy-kill-"
version ".tar"))
(sha256
(base32
"17nw0mglmg877axwg1d0gs03yc0p04lzmd3pl0nsnqbh3303fnqb"))))
(build-system emacs-build-system)
(home-page "https://github.com/leoliu/easy-kill")
(synopsis "Kill and mark things easily in Emacs")
(description
"This package provides commands @code{easy-kill} and @code{easy-mark} to
let users kill or mark things easily.")
(license license:gpl3+)))

View file

@ -416,13 +416,15 @@ language.")
with a layered architecture of JTAG interface and TAP support.") with a layered architecture of JTAG interface and TAP support.")
(license license:gpl2+))) (license license:gpl2+)))
;; The commits for all propeller tools are the latest versions as published ;; The commits for all propeller tools are the stable versions published at
;; here: https://github.com/dbetz/propeller-gcc ;; https://github.com/propellerinc/propgcc in the release_1_0. According to
;; personal correspondence with the developers in July 2017, more recent
;; versions are currently incompatible with the "Simple Libraries".
(define propeller-binutils (define propeller-binutils
(let ((xbinutils (cross-binutils "propeller-elf")) (let ((xbinutils (cross-binutils "propeller-elf"))
(commit "3bfba30076f8ce160a2f42914fdb68f24445fd44") (commit "4c46ecbe79ffbecd2ce918497ace5b956736b5a3")
(revision "1")) (revision "2"))
(package (package
(inherit xbinutils) (inherit xbinutils)
(name "propeller-binutils") (name "propeller-binutils")
@ -430,28 +432,24 @@ with a layered architecture of JTAG interface and TAP support.")
(source (origin (inherit (package-source xbinutils)) (source (origin (inherit (package-source xbinutils))
(method git-fetch) (method git-fetch)
(uri (git-reference (uri (git-reference
(url "https://github.com/totalspectrum/binutils-propeller.git") (url "https://github.com/parallaxinc/propgcc.git")
(commit commit))) (commit commit)))
(file-name (string-append name "-" commit "-checkout")) (file-name (string-append name "-" commit "-checkout"))
(sha256 (sha256
(base32 (base32
"1v3rgxwj7b8817wy5ccf8621v75qcxvcxygk4acr3hbc6yqybr8h")))) "0w0dff3s7wv2d9m78a4jhckiik58q38wx6wpbba5hzbs4yxz35ck"))
(patch-flags (list "-p1" "--directory=binutils"))))
(arguments (arguments
`(;; FIXME: For some reason there are many test failures. Some of them `(;; FIXME: For some reason there are many test failures. It's not
;; appear to be due to regular expression mismatch, but it's not
;; obvious how to fix the failures. ;; obvious how to fix the failures.
#:tests? #f #:tests? #f
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-after 'unpack 'patch-/bin/sh-in-tests (add-after 'unpack 'chdir
(lambda _ (lambda _ (chdir "binutils") #t)))
(substitute* '("sim/testsuite/Makefile.in" ,@(substitute-keyword-arguments (package-arguments xbinutils)
"sim/testsuite/mips64el-elf/Makefile.in" ((#:configure-flags flags)
"sim/testsuite/d10v-elf/Makefile.in" `(cons "--disable-werror" ,flags)))))
"sim/testsuite/sim/cris/asm/badarch1.ms")
(("/bin/sh") (which "sh")))
#t)))
,@(package-arguments xbinutils)))
(native-inputs (native-inputs
`(("bison" ,bison) `(("bison" ,bison)
("flex" ,flex) ("flex" ,flex)
@ -497,26 +495,33 @@ with a layered architecture of JTAG interface and TAP support.")
(define-public propeller-gcc-4 (define-public propeller-gcc-4
(let ((xgcc propeller-gcc-6) (let ((xgcc propeller-gcc-6)
(commit "f1b01001b760d691a91ff1db4830d41bb712557f") (commit "4c46ecbe79ffbecd2ce918497ace5b956736b5a3")
(revision "1")) (revision "2"))
(package (inherit xgcc) (package (inherit xgcc)
(name "propeller-gcc") (name "propeller-gcc")
(version (string-append "4.6.1-" revision "." (string-take commit 9))) (version (string-append "4.6.1-" revision "." (string-take commit 9)))
(source (origin (source (origin
(method git-fetch) (method git-fetch)
(uri (git-reference (uri (git-reference
(url "https://github.com/dbetz/propgcc-gcc.git") (url "https://github.com/parallaxinc/propgcc.git")
(commit commit))) (commit commit)))
(file-name (string-append name "-" commit "-checkout")) (file-name (string-append name "-" commit "-checkout"))
(sha256 (sha256
(base32 (base32
"15mxrhk2v4vqmdkvcqy33ag1wrg9x9q20kx2w33kkw8pkrijknbi")) "0w0dff3s7wv2d9m78a4jhckiik58q38wx6wpbba5hzbs4yxz35ck"))
(patch-flags (list "-p1" "--directory=gcc"))
(patches (patches
(append (append
(origin-patches (package-source gcc-4.7)) (origin-patches (package-source gcc-4.7))
(search-patches "gcc-4.6-gnu-inline.patch" (search-patches "gcc-4.6-gnu-inline.patch"
"gcc-cross-environment-variables.patch"))))) "gcc-cross-environment-variables.patch")))))
(home-page "https://github.com/dbetz/propgcc-gcc") (arguments
(substitute-keyword-arguments (package-arguments propeller-gcc-6)
((#:phases phases)
`(modify-phases ,phases
(add-after 'unpack 'chdir
(lambda _ (chdir "gcc") #t))))))
(home-page "https://github.com/parallaxinc/propgcc")
(supported-systems (delete "aarch64-linux" %supported-systems))))) (supported-systems (delete "aarch64-linux" %supported-systems)))))
;; Version 6 is experimental and may not work correctly. This is why we ;; Version 6 is experimental and may not work correctly. This is why we
@ -524,23 +529,25 @@ with a layered architecture of JTAG interface and TAP support.")
;; provided by Parallax Inc. ;; provided by Parallax Inc.
(define-public propeller-gcc propeller-gcc-4) (define-public propeller-gcc propeller-gcc-4)
;; There is no release, so we take the latest version as referenced from here:
;; https://github.com/dbetz/propeller-gcc ;; FIXME: We do not build the tiny library because that would require C++
;; headers, which are not available. This may require adding a propeller-elf
;; variant of the libstdc++ package.
(define-public proplib (define-public proplib
(let ((commit "844741fe0ceb140ab2fdf9d0667f68c1c39c31da") (let ((commit "4c46ecbe79ffbecd2ce918497ace5b956736b5a3")
(revision "1")) (revision "2"))
(package (package
(name "proplib") (name "proplib")
(version (string-append "0.0.0-" revision "." (string-take commit 9))) (version (string-append "0.0.0-" revision "." (string-take commit 9)))
(source (origin (source (origin
(method git-fetch) (method git-fetch)
(uri (git-reference (uri (git-reference
(url "https://github.com/totalspectrum/proplib.git") (url "https://github.com/parallaxinc/propgcc.git")
(commit commit))) (commit commit)))
(file-name (string-append name "-" commit "-checkout")) (file-name (string-append name "-" commit "-checkout"))
(sha256 (sha256
(base32 (base32
"0q7irf1x8iqx07n7lzksax9armrdkizs49swsz76nbks0mw67wiv")))) "0w0dff3s7wv2d9m78a4jhckiik58q38wx6wpbba5hzbs4yxz35ck"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(arguments (arguments
`(#:tests? #f ; no tests `(#:tests? #f ; no tests
@ -550,12 +557,11 @@ with a layered architecture of JTAG interface and TAP support.")
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(delete 'configure) (delete 'configure)
(add-after 'unpack 'fix-Makefile (add-after 'unpack 'chdir
(lambda _ (chdir "lib") #t))
(add-after 'chdir 'fix-Makefile
(lambda _ (lambda _
(substitute* "Makefile" (substitute* "Makefile"
;; The GCC sources are not part of this package, so we cannot
;; install the out-of-tree license file.
(("cp \\.\\..*") "")
;; Control the installation time of the headers. ;; Control the installation time of the headers.
((" install-includes") "")) ((" install-includes") ""))
#t)) #t))
@ -575,23 +581,14 @@ with a layered architecture of JTAG interface and TAP support.")
"/propeller-elf/include:" "/propeller-elf/include:"
(or (getenv "CROSS_C_INCLUDE_PATH") ""))) (or (getenv "CROSS_C_INCLUDE_PATH") "")))
#t)) #t))
(add-after 'build 'build-tiny (add-before 'install 'install-includes
(lambda* (#:key make-flags #:allow-other-keys) (lambda* (#:key make-flags #:allow-other-keys)
(zero? (apply system* "make" "tiny" make-flags)))) (zero? (apply system* "make" "install-includes" make-flags)))))))
;; The build of the tiny libraries depends on the includes to be
;; available. Since we set CROSS_C_INCLUDE_PATH to the output
;; directory, we have to install the includes first.
(add-before 'build-tiny 'install-includes
(lambda* (#:key make-flags #:allow-other-keys)
(zero? (apply system* "make" "install-includes" make-flags))))
(add-after 'install 'install-tiny
(lambda* (#:key make-flags #:allow-other-keys)
(zero? (apply system* "make" "install-tiny" make-flags)))))))
(native-inputs (native-inputs
`(("propeller-gcc" ,propeller-gcc) `(("propeller-gcc" ,propeller-gcc)
("propeller-binutils" ,propeller-binutils) ("propeller-binutils" ,propeller-binutils)
("perl" ,perl))) ("perl" ,perl)))
(home-page "https://github.com/totalspectrum/proplib") (home-page "https://github.com/parallaxinc/propgcc")
(synopsis "C library for the Parallax Propeller") (synopsis "C library for the Parallax Propeller")
(description "This is a C library for the Parallax Propeller (description "This is a C library for the Parallax Propeller
micro-controller.") micro-controller.")
@ -655,20 +652,20 @@ code.")
(license license:expat))) (license license:expat)))
(define-public propeller-load (define-public propeller-load
(let ((commit "ba9c0a7251cf751d8d292ae19ffa03132097c0c0") (let ((commit "4c46ecbe79ffbecd2ce918497ace5b956736b5a3")
(revision "1")) (revision "2"))
(package (package
(name "propeller-load") (name "propeller-load")
(version "3.4.0") (version "3.4.0")
(source (origin (source (origin
(method git-fetch) (method git-fetch)
(uri (git-reference (uri (git-reference
(url "https://github.com/dbetz/propeller-load.git") (url "https://github.com/parallaxinc/propgcc.git")
(commit commit))) (commit commit)))
(file-name (string-append name "-" commit "-checkout")) (file-name (string-append name "-" commit "-checkout"))
(sha256 (sha256
(base32 (base32
"1qv3xaapl9fmj3zn58b60sprp4rnvnlpci8ci0pdrzkw6fhvx3pg")))) "0w0dff3s7wv2d9m78a4jhckiik58q38wx6wpbba5hzbs4yxz35ck"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(arguments (arguments
`(#:tests? #f ; no tests `(#:tests? #f ; no tests
@ -677,11 +674,13 @@ code.")
(string-append "TARGET=" (assoc-ref %outputs "out"))) (string-append "TARGET=" (assoc-ref %outputs "out")))
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-after 'unpack 'chdir
(lambda _ (chdir "loader") #t))
(delete 'configure)))) (delete 'configure))))
(native-inputs (native-inputs
`(("openspin" ,openspin) `(("openspin" ,openspin)
("propeller-toolchain" ,propeller-toolchain))) ("propeller-toolchain" ,propeller-toolchain)))
(home-page "https://github.com/dbetz/propeller-load") (home-page "https://github.com/parallaxinc/propgcc")
(synopsis "Loader for Parallax Propeller micro-controllers") (synopsis "Loader for Parallax Propeller micro-controllers")
(description "This package provides the tool @code{propeller-load} to (description "This package provides the tool @code{propeller-load} to
upload binaries to a Parallax Propeller micro-controller.") upload binaries to a Parallax Propeller micro-controller.")

View file

@ -30,6 +30,7 @@
#:use-module (guix monads) #:use-module (guix monads)
#:use-module (guix store) #:use-module (guix store)
#:use-module (guix utils) #:use-module (guix utils)
#:use-module ((srfi srfi-1) #:hide (zip))
#:use-module ((guix licenses) #:prefix license:) #:use-module ((guix licenses) #:prefix license:)
#:use-module (guix build-system cmake) #:use-module (guix build-system cmake)
#:use-module (guix build-system gnu) #:use-module (guix build-system gnu)
@ -1279,3 +1280,197 @@ an embedded event driven algorithm.")
(inputs (inputs
`(("libngspice" ,libngspice) `(("libngspice" ,libngspice)
("readline" ,readline))))) ("readline" ,readline)))))
(define trilinos-serial-xyce
;; Note: This is a Trilinos containing only the packages Xyce needs, so we
;; keep it private. See
;; <https://debbugs.gnu.org/cgi/bugreport.cgi?bug=27344#248>.
;; TODO: Remove when we have modular Trilinos packages?
(package
(name "trilinos-serial-xyce")
(version "12.6.3")
(source
(origin (method url-fetch)
(uri (string-append "https://trilinos.org/oldsite/download/files/trilinos-"
version "-Source.tar.gz"))
(sha256
(base32
"07jd1qpsbf31cmbyyngr4l67xzwyan24dyx5wlcahgbw7x6my3wn"))))
(build-system cmake-build-system)
(arguments
`(#:out-of-source? #t
#:configure-flags
(list "-DCMAKE_CXX_FLAGS=-O3 -fPIC"
"-DCMAKE_C_FLAGS=-O3 -fPIC"
"-DCMAKE_Fortran_FLAGS=-O3 -fPIC"
"-DTrilinos_ENABLE_NOX=ON"
"-DNOX_ENABLE_LOCA=ON"
"-DTrilinos_ENABLE_EpetraExt=ON"
"-DEpetraExt_BUILD_BTF=ON"
"-DEpetraExt_BUILD_EXPERIMENTAL=ON"
"-DEpetraExt_BUILD_GRAPH_REORDERINGS=ON"
"-DTrilinos_ENABLE_TrilinosCouplings=ON"
"-DTrilinos_ENABLE_Ifpack=ON"
"-DTrilinos_ENABLE_Isorropia=ON"
"-DTrilinos_ENABLE_AztecOO=ON"
"-DTrilinos_ENABLE_Belos=ON"
"-DTrilinos_ENABLE_Teuchos=ON"
"-DTeuchos_ENABLE_COMPLEX=ON"
"-DTrilinos_ENABLE_Amesos=ON"
"-DAmesos_ENABLE_KLU=ON"
"-DAmesos_ENABLE_UMFPACK=ON"
"-DTrilinos_ENABLE_Sacado=ON"
"-DTrilinos_ENABLE_Kokkos=OFF"
"-DTrilinos_ENABLE_ALL_OPTIONAL_PACKAGES=OFF"
"-DTPL_ENABLE_AMD=ON"
"-DTPL_ENABLE_UMFPACK=ON"
"-DTPL_ENABLE_BLAS=ON"
"-DTPL_ENABLE_LAPACK=ON")))
(native-inputs
`(("fortran" ,gfortran)
("swig" ,swig)))
(inputs
`(("boost" ,boost)
("lapack" ,lapack-3.5)
("suitesparse" ,suitesparse)))
(home-page "https://trilinos.org")
(synopsis "Engineering and scientific problems algorithms")
(description
"The Trilinos Project is an effort to develop algorithms and enabling
technologies within an object-oriented software framework for the solution of
large-scale, complex multi-physics engineering and scientific problems. A
unique design feature of Trilinos is its focus on packages.")
(license (list license:lgpl2.1+
license:bsd-3))))
(define-public xyce-serial
(package
(name "xyce-serial")
(version "6.7")
(source
(origin (method url-fetch)
(uri (string-append "https://archive.org/download/Xyce-"
version "/Xyce-" version ".tar.gz"))
(sha256
(base32
"02k952mnvrnc5kv7r65fdrn7khwq1lbyhwyvd7jznafzdpsvgm4x"))))
(build-system gnu-build-system)
(arguments
`(#:tests? #f
#:configure-flags
(list
"CXXFLAGS=-O3 -std=c++11"
(string-append "ARCHDIR="
(assoc-ref %build-inputs "trilinos")))))
(native-inputs
`(("bison" ,bison)
("flex" ,flex)
("fortran" ,gfortran)))
(inputs
`(("fftw" ,fftw)
("suitesparse" ,suitesparse)
("lapack" ,lapack-3.5)
("trilinos" ,trilinos-serial-xyce)))
(home-page "https://xyce.sandia.gov/")
(synopsis "High-performance analog circuit simulator")
(description
"Xyce is a SPICE-compatible, high-performance analog circuit simulator,
capable of solving extremely large circuit problems by supporting large-scale
parallel computing platforms. It also supports serial execution.")
(license license:gpl3+)))
(define trilinos-parallel-xyce
(package (inherit trilinos-serial-xyce)
(name "trilinos-parallel-xyce")
(arguments
`(,@(substitute-keyword-arguments (package-arguments trilinos-serial-xyce)
((#:configure-flags flags)
`(append (list "-DTrilinos_ENABLE_ShyLU=ON"
"-DTrilinos_ENABLE_Zoltan=ON"
"-DTPL_ENABLE_MPI=ON")
,flags)))))
(inputs
`(("mpi" ,openmpi)
,@(package-inputs trilinos-serial-xyce)))))
(define-public xyce-parallel
(package (inherit xyce-serial)
(name "xyce-parallel")
(arguments
`(,@(substitute-keyword-arguments (package-arguments xyce-serial)
((#:configure-flags flags)
`(list "CXXFLAGS=-O3 -std=c++11"
"CXX=mpiCC"
"CC=mpicc"
"F77=mpif77"
"--enable-mpi"
"--enable-isorropia=no"
"--enable-zoltan=no"
(string-append
"ARCHDIR="
(assoc-ref %build-inputs "trilinos")))))))
(propagated-inputs
`(("mpi" ,openmpi)))
(inputs
`(("trilinos" ,trilinos-parallel-xyce)
,@(alist-delete "trilinos"
(package-inputs xyce-serial))))))
(define-public freehdl
(package
(name "freehdl")
(version "0.0.8")
(source (origin
(method url-fetch)
(uri (string-append "http://downloads.sourceforge.net/qucs/freehdl-"
version ".tar.gz"))
(sha256
(base32
"117dqs0d4pcgbzvr3jn5ppra7n7x2m6c161ywh6laa934pw7h2bz"))))
(build-system gnu-build-system)
(arguments
`(#:phases
(modify-phases %standard-phases
(add-before 'configure 'patch-pkg-config
(lambda* (#:key inputs #:allow-other-keys)
(substitute* "freehdl/freehdl-config"
(("pkg-config")
(string-append (assoc-ref inputs "pkg-config")
"/bin/pkg-config"))
(("cat")
(string-append (assoc-ref inputs "coreutils")
"/bin/cat")))
#t))
(add-after 'configure 'patch-freehdl-pc
(lambda* (#:key inputs #:allow-other-keys)
(substitute* "freehdl.pc"
(("=g\\+\\+")
(string-append "=" (assoc-ref inputs "gcc")
"/bin/g++"))
(("=libtool")
(string-append "=" (assoc-ref inputs "libtool")
"/bin/libtool")))
#t))
(add-after 'install-scripts 'make-wrapper
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(wrap-program (string-append out "/bin/freehdl-config")
`("PKG_CONFIG_PATH" ":" prefix (,(string-append out "/lib/pkgconfig")))))
#t)))))
(inputs
`(("coreutils" ,coreutils)
("gcc" ,gcc)
("perl" ,perl)
("pkg-config" ,pkg-config)
("libtool" ,libtool)))
(native-inputs
`(("pkg-config-native" ,pkg-config)
("libtool-native" ,libtool)))
(home-page "http://www.freehdl.seul.org/")
(synopsis "VHDL simulator")
(description
"FreeHDL is a compiler/simulator suite for the hardware description language VHDL.
VHDL'93 as well as VHDL'87 standards are supported.")
(license (list license:gpl2+
license:lgpl2.0+)))) ; freehdl's libraries

View file

@ -133,7 +133,7 @@
#:use-module (gnu packages gnuzilla) #:use-module (gnu packages gnuzilla)
#:use-module (gnu packages icu4c) #:use-module (gnu packages icu4c)
#:use-module (gnu packages networking) #:use-module (gnu packages networking)
#:use-module (guix build utils) #:use-module (gnu packages web)
#:use-module (guix build-system gnu) #:use-module (guix build-system gnu)
#:use-module (guix build-system haskell) #:use-module (guix build-system haskell)
#:use-module (guix build-system python) #:use-module (guix build-system python)
@ -2629,6 +2629,56 @@ Transport Tycoon Deluxe.")
("opensfx" ,openttd-opensfx) ("opensfx" ,openttd-opensfx)
,@(package-native-inputs openttd-engine))))) ,@(package-native-inputs openttd-engine)))))
(define-public openrct2
(package
(name "openrct2")
(version "0.1.1")
(source
(origin
(method url-fetch)
(uri (string-append "https://github.com/OpenRCT2/OpenRCT2/archive/v"
version ".tar.gz"))
(sha256
(base32
"1bahkzlf9k92cc4zs4nk4wy59323kiw8d3wm0vjps3kp7iznqyjx"))
(file-name (string-append name "-" version ".tar.gz"))))
(build-system cmake-build-system)
(arguments
`(#:tests? #f ;; no tests available
#:phases
(modify-phases %standard-phases
(add-after 'build 'fix-cmake-install-file
(lambda _
;; The build system tries to download a file and compare hashes.
;; Since we have no network, remove this so the install doesn't fail.
(substitute* "cmake_install.cmake"
(("EXPECTED_HASH SHA1=b587d83de508d0b104d14c599b76f8565900fce0")
"")))))))
(inputs `(("curl", curl)
("fontconfig", fontconfig)
("freetype", freetype)
("jansson", jansson)
("libpng", libpng)
("libzip", libzip)
("mesa", mesa)
("openssl", openssl)
("sdl2", sdl2)
("speexdsp", speexdsp)
("zlib", zlib)))
(native-inputs
`(("pkg-config", pkg-config)))
(home-page "https://github.com/OpenRCT2/OpenRCT2")
(synopsis "Free software re-implementation of RollerCoaster Tycoon 2")
(description "OpenRCT2 is a free software re-implementation of
RollerCoaster Tycoon 2 (RCT2). The gameplay revolves around building and
maintaining an amusement park containing attractions, shops and facilities.
Note that this package does @emph{not} provide the game assets (sounds,
images, etc.)")
;; See <https://github.com/OpenRCT2/OpenRCT2/wiki/Required-RCT2-files>
;; regarding assets.
(license license:gpl3+)))
(define-public pinball (define-public pinball
(package (package
(name "pinball") (name "pinball")

View file

@ -271,10 +271,10 @@ also known as DXTn or DXTC) for Mesa.")
`(#:configure-flags `(#:configure-flags
'(,@(match (%current-system) '(,@(match (%current-system)
("armhf-linux" ("armhf-linux"
;; TODO: Add etnaviv when enabled in libdrm. ;; TODO: Add etnaviv,imx when libdrm supports etnaviv.
'("--with-gallium-drivers=freedreno,imx,nouveau,r300,r600,svga,swrast,vc4,virgl")) '("--with-gallium-drivers=freedreno,nouveau,r300,r600,swrast,vc4,virgl"))
("aarch64-linux" ("aarch64-linux"
;; TODO: Fix svga driver for aarch64. ;; TODO: Fix svga driver for aarch64 and armhf.
'("--with-gallium-drivers=freedreno,nouveau,r300,r600,swrast,vc4,virgl")) '("--with-gallium-drivers=freedreno,nouveau,r300,r600,swrast,vc4,virgl"))
(_ (_
'("--with-gallium-drivers=i915,nouveau,r300,r600,svga,swrast,virgl"))) '("--with-gallium-drivers=i915,nouveau,r300,r600,svga,swrast,virgl")))

View file

@ -700,7 +700,7 @@ forgotten when the session ends.")
(define-public evince (define-public evince
(package (package
(name "evince") (name "evince")
(version "3.24.1") (version "3.26.0")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "mirror://gnome/sources/" name "/" (uri (string-append "mirror://gnome/sources/" name "/"
@ -708,7 +708,7 @@ forgotten when the session ends.")
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"0dqgzwxl0xfr341r5i8j8hn6j6rhv62lmc6xbzjppcq76hhwb84w")))) "1n69lkiagx2x8lrdbvdlz6c051cvzhma73b3ggnw7w1wfkdpnmkr"))))
(build-system glib-or-gtk-build-system) (build-system glib-or-gtk-build-system)
(arguments (arguments
`(#:configure-flags '("--disable-nautilus") `(#:configure-flags '("--disable-nautilus")
@ -866,7 +866,7 @@ GNOME and KDE desktops to the icon names proposed in the specification.")
(define-public adwaita-icon-theme (define-public adwaita-icon-theme
(package (inherit gnome-icon-theme) (package (inherit gnome-icon-theme)
(name "adwaita-icon-theme") (name "adwaita-icon-theme")
(version "3.24.0") (version "3.26.0")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "mirror://gnome/sources/" name "/" (uri (string-append "mirror://gnome/sources/" name "/"
@ -874,7 +874,7 @@ GNOME and KDE desktops to the icon names proposed in the specification.")
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"0ai73gs44yyw276xag6db0rlpvncy23qplp4girm80ilpprrzxyc")))) "04i2s6hkgzxgmq85dynmzih8rw5krc5apkks962mhgri37g8bbcw"))))
(native-inputs (native-inputs
`(("gtk-encode-symbolic-svg" ,gtk+ "bin"))))) `(("gtk-encode-symbolic-svg" ,gtk+ "bin")))))
@ -2015,7 +2015,7 @@ libraries written in C.")
(define-public vte (define-public vte
(package (package
(name "vte") (name "vte")
(version "0.48.3") (version "0.50.1")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "mirror://gnome/sources/" name "/" (uri (string-append "mirror://gnome/sources/" name "/"
@ -2023,7 +2023,7 @@ libraries written in C.")
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"1hsqc7238862mqnva5qqdfxnhpwq3ak6zx6kbjj95cs04wcgpad3")))) "1hm88nn1r38fszz770v6dgzgx208ywz4n087n4fhw5kkwpihh5yg"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(native-inputs (native-inputs
`(("pkg-config" ,pkg-config) `(("pkg-config" ,pkg-config)
@ -2681,7 +2681,7 @@ more fun.")
(define-public gnome-terminal (define-public gnome-terminal
(package (package
(name "gnome-terminal") (name "gnome-terminal")
(version "3.24.2") (version "3.26.1")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
@ -2690,7 +2690,7 @@ more fun.")
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"03zcvxlzg7n4pz65vrg5xj3qpkqr4bz162mgmaz4bjh71b1xl7i8")))) "0fh7vshhzgypd66sinns5z1vskswl7ybs1ica080pskzyx75db5r"))))
(build-system glib-or-gtk-build-system) (build-system glib-or-gtk-build-system)
(arguments (arguments
'(#:configure-flags '(#:configure-flags
@ -3581,7 +3581,7 @@ for application developers.")
(define-public totem (define-public totem
(package (package
(name "totem") (name "totem")
(version "3.24.0") (version "3.26.0")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
@ -3590,12 +3590,15 @@ for application developers.")
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"00cdlll5b0wj5ckl1pc0a3g39a0hlq0gxkcsh1f6p20fjixqzmwv")))) "04zfx47mgyd0f4p3pjrxl6iaw0awgwbvilbsr1smw14ph2kbjbz3"))
(build-system glib-or-gtk-build-system) (patches (search-patches "totem-meson-easy-codec.patch"))))
(build-system meson-build-system)
(native-inputs (native-inputs
`(("pkg-config" ,pkg-config) `(("pkg-config" ,pkg-config)
("desktop-file-utils" ,desktop-file-utils) ("desktop-file-utils" ,desktop-file-utils)
("gobject-introspection" ,gobject-introspection) ("gobject-introspection" ,gobject-introspection)
("glib:bin" ,glib "bin") ;for 'glib-mkenums'
("gtk:bin" ,gtk+ "bin") ;for 'gtk-update-icon-cache'
("intltool" ,intltool) ("intltool" ,intltool)
("itstool" ,itstool) ("itstool" ,itstool)
("xmllint" ,libxml2))) ("xmllint" ,libxml2)))
@ -3636,13 +3639,21 @@ for application developers.")
("nettle" ,nettle) ("nettle" ,nettle)
("vala" ,vala))) ("vala" ,vala)))
(arguments (arguments
`(;; Disable automatic GStreamer plugin installation via PackageKit and `(#:glib-or-gtk? #t
;; Disable parallel builds until
;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=28813 is
;; fixed. Try enabling it when updating this package in case
;; upstream has fixed it.
#:parallel-build? #f
;; Disable automatic GStreamer plugin installation via PackageKit and
;; all that. ;; all that.
#:configure-flags '("--disable-easy-codec-installation" #:configure-flags '("-D" "enable-easy-codec-installation=no"
;; Do not build .a files for the plugins, it's ;; Do not build .a files for the plugins, it's
;; completely useless. This saves 2 MiB. ;; completely useless. This saves 2 MiB.
"--disable-static") "--default-library" "shared")
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
@ -4034,23 +4045,29 @@ work and the interface is well tested.")
(define-public eolie (define-public eolie
(package (package
(name "eolie") (name "eolie")
(version "0.9.0") (version "0.9.4")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "https://github.com/gnumdk/eolie/" (uri (string-append "https://github.com/gnumdk/eolie/"
"releases/download/" "releases/download/" version
(version-major+minor version)
"/eolie-" version ".tar.xz")) "/eolie-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"1lb3rd2as12vq24fcf9nmlhggf8vka3kli2i92i8iylwi7nq5n2a")))) "0zw2zqgnpsvk35nrp4kqkh2hb5kchzpvi684xjv7a9hhrlsxkdqd"))))
(build-system glib-or-gtk-build-system) (build-system glib-or-gtk-build-system)
(arguments (arguments
`(#:modules ((guix build glib-or-gtk-build-system) `(#:phases
(guix build utils)
(ice-9 match))
#:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(delete 'configure)
(replace 'build
(lambda* (#:key outputs #:allow-other-keys)
(zero? (system* "meson" "build"
"--prefix" (assoc-ref outputs "out")))))
(replace 'check
(lambda _ (zero? (system* "ninja" "-C" "build" "test"))))
(replace 'install
(lambda* (#:key outputs #:allow-other-keys)
(zero? (system* "ninja" "-C" "build" "install"))))
(add-after 'wrap 'wrap-more (add-after 'wrap 'wrap-more
(lambda* (#:key inputs outputs #:allow-other-keys) (lambda* (#:key inputs outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out")) (let* ((out (assoc-ref outputs "out"))
@ -4071,7 +4088,11 @@ work and the interface is well tested.")
(native-inputs (native-inputs
`(("intltool" ,intltool) `(("intltool" ,intltool)
("itstool" ,itstool) ("itstool" ,itstool)
("pkg-config" ,pkg-config))) ("pkg-config" ,pkg-config)
("meson" ,meson-for-build)
("ninja" ,ninja)
("python" ,python)
("gtk+" ,gtk+ "bin")))
(inputs (inputs
`(("gobject-introspection" ,gobject-introspection) `(("gobject-introspection" ,gobject-introspection)
("glib-networking" ,glib-networking) ("glib-networking" ,glib-networking)
@ -4405,7 +4426,7 @@ share them with others via social networking and more.")
(define-public file-roller (define-public file-roller
(package (package
(name "file-roller") (name "file-roller")
(version "3.24.1") (version "3.26.1")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "mirror://gnome/sources/" name "/" (uri (string-append "mirror://gnome/sources/" name "/"
@ -4413,7 +4434,7 @@ share them with others via social networking and more.")
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"0fkz9h9a6149crmf6311fsqlmv9wyrxk86470vxib941ppl4a581")))) "1bliwib59jrlfpdbpqc4rc3kzv4ns7pfyn8c28ananj3p34y9mgc"))))
(build-system glib-or-gtk-build-system) (build-system glib-or-gtk-build-system)
(arguments (arguments
'(#:phases '(#:phases
@ -5087,7 +5108,7 @@ to virtual private networks (VPNs) via OpenVPN.")
(define-public mobile-broadband-provider-info (define-public mobile-broadband-provider-info
(package (package
(name "mobile-broadband-provider-info") (name "mobile-broadband-provider-info")
(version "20151214") (version "20170310")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (string-append
@ -5096,7 +5117,7 @@ to virtual private networks (VPNs) via OpenVPN.")
"mobile-broadband-provider-info-" version ".tar.xz")) "mobile-broadband-provider-info-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"1905nab1h8p4hx0m1w0rn4mkg9209x680dcr4l77bngy21pmvr4a")))) "0fxm11x8k9hxjg8l5inaldfmmjnwkay3ibjv899jra03bv4h6kql"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(arguments (arguments
`(#:tests? #f)) ; No tests `(#:tests? #f)) ; No tests
@ -5694,7 +5715,7 @@ files.")
(define-public baobab (define-public baobab
(package (package
(name "baobab") (name "baobab")
(version "3.24.0") (version "3.26.1")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (string-append
@ -5703,7 +5724,7 @@ files.")
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"0gzwzn8p0agidjq3wnkxcsny6jhqph3yqscqjqd7blgkz5nyk02r")))) "0zkqxyqyxd6j270jf5hbcrb3yh4k31ddh40v4cjhgngm8mcsnnbs"))))
(build-system glib-or-gtk-build-system) (build-system glib-or-gtk-build-system)
(native-inputs (native-inputs
`(("intltool" ,intltool) `(("intltool" ,intltool)
@ -5726,7 +5747,7 @@ is complete it provides a graphical representation of each selected folder.")
(define-public gnome-backgrounds (define-public gnome-backgrounds
(package (package
(name "gnome-backgrounds") (name "gnome-backgrounds")
(version "3.24.0") (version "3.26.2")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
@ -5735,7 +5756,7 @@ is complete it provides a graphical representation of each selected folder.")
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"1jkikis9k3psp6rb8axnqy86awdyg5rzfbcp9gx40a99b4hlrnnb")))) "0kzrh5h0cfby3rhsy31d1w1c0rr3wcc845kv6zibqw1x8v9si2rs"))))
(build-system glib-or-gtk-build-system) (build-system glib-or-gtk-build-system)
(native-inputs (native-inputs
`(("intltool" ,intltool))) `(("intltool" ,intltool)))
@ -5785,7 +5806,7 @@ beautifying border effects.")
(define-public dconf-editor (define-public dconf-editor
(package (package
(name "dconf-editor") (name "dconf-editor")
(version "3.22.3") (version "3.26.1")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
@ -5794,7 +5815,7 @@ beautifying border effects.")
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"1939yq3fl55c2dqkc6nzp6cbpxq9sli74gdj0rj7c50pwvbngwam")))) "0agay5zbhjbfznlwk7n3gg5cn0c7ih4vnmah6kb6m969li120cs9"))))
(build-system glib-or-gtk-build-system) (build-system glib-or-gtk-build-system)
(arguments (arguments
'(#:phases '(#:phases
@ -6679,7 +6700,7 @@ accessibility infrastructure.")
(define-public orca (define-public orca
(package (package
(name "orca") (name "orca")
(version "3.24.0") (version "3.26.0")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (string-append
@ -6688,7 +6709,7 @@ accessibility infrastructure.")
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"1la6f815drykrgqf791jx1dda6716cfv6052frqp7nhjxr75xg97")))) "0xk5k9cbswymma60nrfj00dl97wypx59c107fb1hwi75gm0i07a7"))))
(build-system glib-or-gtk-build-system) (build-system glib-or-gtk-build-system)
(arguments (arguments
'(#:phases '(#:phases

View file

@ -2,6 +2,7 @@
;;; Copyright © 2015, 2016 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2015, 2016 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2015 Eric Bavier <bavier@member.fsf.org> ;;; Copyright © 2015 Eric Bavier <bavier@member.fsf.org>
;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2017 Chris Marusich <cmmarusich@gmail.com>
;;; ;;;
;;; This file is part of GNU Guix. ;;; This file is part of GNU Guix.
;;; ;;;
@ -23,8 +24,11 @@
#:use-module (guix packages) #:use-module (guix packages)
#:use-module (guix download) #:use-module (guix download)
#:use-module (guix build-system gnu) #:use-module (guix build-system gnu)
#:use-module (guix build-system glib-or-gtk)
#:use-module (gnu packages) #:use-module (gnu packages)
#:use-module (gnu packages autotools) #:use-module (gnu packages autotools)
#:use-module (gnu packages docbook)
#:use-module (gnu packages documentation)
#:use-module (gnu packages gnome) #:use-module (gnu packages gnome)
#:use-module (gnu packages gnupg) #:use-module (gnu packages gnupg)
#:use-module (gnu packages glib) #:use-module (gnu packages glib)
@ -52,7 +56,7 @@
(base32 (base32
"0g2risryfgplxh6cxpsl7fn255vipgsx38b4l081h665nqwmz5nv")) "0g2risryfgplxh6cxpsl7fn255vipgsx38b4l081h665nqwmz5nv"))
(patches (search-patches "gnucash-price-quotes-perl.patch")))) (patches (search-patches "gnucash-price-quotes-perl.patch"))))
(build-system gnu-build-system) (build-system glib-or-gtk-build-system)
(inputs (inputs
`(("guile" ,guile-2.0) `(("guile" ,guile-2.0)
("icu4c" ,icu4c) ("icu4c" ,icu4c)
@ -69,15 +73,25 @@
(native-inputs (native-inputs
`(("glib" ,glib "bin") ; glib-compile-schemas, etc. `(("glib" ,glib "bin") ; glib-compile-schemas, etc.
("intltool" ,intltool) ("intltool" ,intltool)
("gnucash-docs" ,gnucash-docs)
("pkg-config" ,pkg-config))) ("pkg-config" ,pkg-config)))
(outputs '("out" "doc"))
(arguments (arguments
`(#:tests? #f ;FIXME: failing at /qof/gnc-date/qof print date dmy buff `(#:tests? #f ;FIXME: failing at /qof/gnc-date/qof print date dmy buff
#:configure-flags '("--disable-dbi" #:configure-flags '("--disable-dbi"
"--enable-aqbanking") "--enable-aqbanking")
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
;; There are about 100 megabytes of documentation.
(add-after (add-after
'install 'wrap-programs 'install 'install-docs
(lambda* (#:key inputs outputs #:allow-other-keys)
(let ((docs (assoc-ref inputs "gnucash-docs"))
(doc-output (assoc-ref outputs "doc")))
(symlink (string-append docs "/share/gnome")
(string-append doc-output "/share/gnome")))))
(add-after
'install-docs 'wrap-programs
(lambda* (#:key inputs outputs #:allow-other-keys) (lambda* (#:key inputs outputs #:allow-other-keys)
(for-each (lambda (prog) (for-each (lambda (prog)
(wrap-program (string-append (assoc-ref outputs "out") (wrap-program (string-append (assoc-ref outputs "out")
@ -114,6 +128,42 @@ import and transaction matching. It also automates several tasks, such as
financial calculations or scheduled transactions.") financial calculations or scheduled transactions.")
(license license:gpl3+))) (license license:gpl3+)))
;; This package is not public, since we use it to build the "doc" output of
;; the gnucash package (see above). It would be confusing if it were public.
(define gnucash-docs
(package
(name "gnucash-docs")
(version (package-version gnucash))
(source
(origin
(method url-fetch)
(uri (string-append "mirror://sourceforge/gnucash/gnucash-docs/"
version "/gnucash-docs-" version ".tar.gz"))
(sha256
(base32
"0dfb4m4084apav9kjsc4mfbj99xsyxm59qhpm1nxvhybn5h6qr3r"))))
(build-system gnu-build-system)
;; These are native-inputs because they are only required for building the
;; documentation.
(native-inputs
`(("libxml2" ,libxml2)
;; The "check" target needs the docbook xml packages for validating the
;; DocBook XML during the tests.
("docbook-xml-4.4" ,docbook-xml-4.4)
("docbook-xml-4.2" ,docbook-xml-4.2)
("docbook-xml-4.1.2" ,docbook-xml-4.1.2)
("libxslt" ,libxslt)
("docbook-xsl" ,docbook-xsl)
("scrollkeeper" ,scrollkeeper)))
(home-page "http://www.gnucash.org/")
(synopsis "Documentation for GnuCash")
(description
"User guide and other documentation for GnuCash in various languages.
This package exists because the GnuCash project maintains its documentation in
an entirely separate package from the actual GnuCash program. It is intended
to be read using the GNOME Yelp program.")
(license (list license:fdl1.1+ license:gpl3+))))
(define-public gwenhywfar (define-public gwenhywfar
(package (package
(name "gwenhywfar") (name "gwenhywfar")

View file

@ -66,14 +66,14 @@
(define-public libextractor (define-public libextractor
(package (package
(name "libextractor") (name "libextractor")
(version "1.4") (version "1.6")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "mirror://gnu/libextractor/libextractor-" (uri (string-append "mirror://gnu/libextractor/libextractor-"
version ".tar.gz")) version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"0v7ns5jhsyp1wzvbaydfgxnva5zd63gkzm9djhckmam9liq824l4")))) "17gnpgspdhfgcr27j8sn9105vb4lw22yqdrhic62l79q5v5avm16"))))
(build-system gnu-build-system) (build-system gnu-build-system)
;; WARNING: Checks require /dev/shm to be in the build chroot, especially ;; WARNING: Checks require /dev/shm to be in the build chroot, especially
;; not to be a symbolic link to /run/shm. ;; not to be a symbolic link to /run/shm.

View file

@ -2,6 +2,7 @@
;;; Copyright © 2013, 2015 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2013, 2015 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2015 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2015 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2016 Theodoros Foradis <theodoros@foradis.org> ;;; Copyright © 2016 Theodoros Foradis <theodoros@foradis.org>
;;; Copyright © 2017 Ricardo Wurmus <rekado@elephly.net>
;;; ;;;
;;; This file is part of GNU Guix. ;;; This file is part of GNU Guix.
;;; ;;;
@ -39,7 +40,7 @@
#:use-module (gnu packages compression) #:use-module (gnu packages compression)
#:use-module (gnu packages gd) #:use-module (gnu packages gd)
#:use-module (gnu packages swig) #:use-module (gnu packages swig)
#:use-module ((guix licenses) #:select (lgpl2.0+ epl1.0 lgpl3+))) #:use-module ((guix licenses) #:prefix license:))
(define-public graphviz (define-public graphviz
(package (package
@ -106,7 +107,30 @@ way of representing structural information as diagrams of abstract graphs and
networks. It has important applications in networking, bioinformatics, networks. It has important applications in networking, bioinformatics,
software engineering, database and web design, machine learning, and in visual software engineering, database and web design, machine learning, and in visual
interfaces for other technical domains.") interfaces for other technical domains.")
(license epl1.0))) (license license:epl1.0)))
(define-public python-graphviz
(package
(name "python-graphviz")
(version "0.8")
(source (origin
(method url-fetch)
(uri (pypi-uri "graphviz" version ".zip"))
(sha256
(base32
"0i738qb32w93hraxzjwkvnxmrfwcalhjd14fdbah9f2mk46p5748"))))
(build-system python-build-system)
(native-inputs
`(("unzip" ,unzip)))
(home-page "https://github.com/xflr6/graphviz")
(synopsis "Simple Python interface for Graphviz")
(description
"This package provides a simple Python interface for the Graphviz graph
visualization tool suite.")
(license license:expat)))
(define-public python2-graphviz
(package-with-python2 python-graphviz))
(define-public gts (define-public gts
(package (package
@ -142,7 +166,7 @@ interfaces for other technical domains.")
(description (description
"Library intended to provide a set of useful functions to deal with "Library intended to provide a set of useful functions to deal with
3D surfaces meshed with interconnected triangles.") 3D surfaces meshed with interconnected triangles.")
(license lgpl2.0+))) (license license:lgpl2.0+)))
(define-public xdot (define-public xdot
(package (package
@ -185,4 +209,4 @@ interfaces for other technical domains.")
@code{graphviz}s dot language. Internally, it uses the xdot output format as @code{graphviz}s dot language. Internally, it uses the xdot output format as
an intermediate format,and @code{gtk} and @code{cairo} for rendering. Xdot can an intermediate format,and @code{gtk} and @code{cairo} for rendering. Xdot can
be used either as a standalone application, or as a python library.") be used either as a standalone application, or as a python library.")
(license lgpl3+))) (license license:lgpl3+)))

View file

@ -1346,7 +1346,24 @@ users and in some situations.")
version ".tar.gz")) version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"1svzlbz2vripmyq2kjh0rig16bsrnbkwbsm558pjln9l65mcl4qq")))) "1svzlbz2vripmyq2kjh0rig16bsrnbkwbsm558pjln9l65mcl4qq"))
(modules '((guix build utils)))
(snippet
'(begin
(substitute* "configure"
(("_guile_required_version=\"2.0.11\"")
"_guile_required_version=\"2\"")
(("ac_subst_vars='")
"ac_subst_vars='GUILE_EFFECTIVE_VERSION\n"))
(substitute* (find-files "." "Makefile.in")
(("moddir = .*$")
(string-append
"moddir = "
"$(prefix)/share/guile/site/@GUILE_EFFECTIVE_VERSION@\n"))
(("godir = .*$")
(string-append
"godir = "
"$(prefix)/lib/guile/@GUILE_EFFECTIVE_VERSION@/site-ccache\n")))))))
(build-system gnu-build-system) (build-system gnu-build-system)
(arguments (arguments
'(#:configure-flags '(#:configure-flags
@ -1357,7 +1374,7 @@ users and in some situations.")
(native-inputs (native-inputs
`(("pkg-config" ,pkg-config))) `(("pkg-config" ,pkg-config)))
(propagated-inputs (propagated-inputs
`(("guile" ,guile-2.0) `(("guile" ,guile-2.2)
("guile-sdl" ,guile-sdl) ("guile-sdl" ,guile-sdl)
("guile-opengl" ,guile-opengl))) ("guile-opengl" ,guile-opengl)))
(inputs (inputs

View file

@ -31,6 +31,7 @@
#:use-module (gnu packages admin) #:use-module (gnu packages admin)
#:use-module (gnu packages aidc) #:use-module (gnu packages aidc)
#:use-module (gnu packages attr) #:use-module (gnu packages attr)
#:use-module (gnu packages avahi)
#:use-module (gnu packages base) #:use-module (gnu packages base)
#:use-module (gnu packages boost) #:use-module (gnu packages boost)
#:use-module (gnu packages bison) #:use-module (gnu packages bison)
@ -42,6 +43,7 @@
#:use-module (gnu packages flex) #:use-module (gnu packages flex)
#:use-module (gnu packages freedesktop) #:use-module (gnu packages freedesktop)
#:use-module (gnu packages gettext) #:use-module (gnu packages gettext)
#:use-module (gnu packages gl)
#:use-module (gnu packages glib) #:use-module (gnu packages glib)
#:use-module (gnu packages gnome) #:use-module (gnu packages gnome)
#:use-module (gnu packages gnupg) #:use-module (gnu packages gnupg)
@ -92,7 +94,17 @@
(lambda _ (lambda _
;; Always install into /lib and not into /lib64. ;; Always install into /lib and not into /lib64.
(substitute* "kde-modules/KDEInstallDirs.cmake" (substitute* "kde-modules/KDEInstallDirs.cmake"
(("\"lib64\"") "\"lib\"")))) (("\"lib64\"") "\"lib\"")
;; TODO: Base the following on values taken from Qt
;; Install plugins into lib/qt5/plugins
(("_define_relative\\(QTPLUGINDIR LIBDIR \"plugins\"")
"_define_relative(QTPLUGINDIR LIBDIR \"qt5/plugins\"")
;; Install imports into lib/qt5/imports
(("_define_relative\\(QTQUICKIMPORTSDIR QTPLUGINDIR \"imports\"")
"_define_relative(QTQUICKIMPORTSDIR LIBDIR \"qt5/imports\"")
;; Install qml-files into lib/qt5/qml
(("_define_relative\\(QMLDIR LIBDIR \"qml\"")
"_define_relative(QMLDIR LIBDIR \"qt5/qml\""))))
;; install and check phase are swapped to prevent install from failing ;; install and check phase are swapped to prevent install from failing
;; after testsuire has run ;; after testsuire has run
(add-after 'install 'check-post-install (add-after 'install 'check-post-install
@ -128,16 +140,17 @@ common build settings used in software produced by the KDE community.")
"177647r2jqfm32hqcz2nqfqv6v48hn5ab2vc31svba2wz23fkgk7")))) "177647r2jqfm32hqcz2nqfqv6v48hn5ab2vc31svba2wz23fkgk7"))))
(build-system cmake-build-system) (build-system cmake-build-system)
(native-inputs (native-inputs
;; TODO: Add qttools to build the Qt Designer plugin.
;; TODO: Think about adding pulseaudio. Is it required for sound? ;; TODO: Think about adding pulseaudio. Is it required for sound?
`(("extra-cmake-modules" ,extra-cmake-modules))) ;; TODO: Add building the super experimental QML support
`(("extra-cmake-modules" ,extra-cmake-modules)
("pkg-config" ,pkg-config)
("qttools", qttools)))
(inputs (inputs
`(("qtbase" ,qtbase))) `(("qtbase" ,qtbase)))
(arguments (arguments
`(#:configure-flags `(#:configure-flags
'("-DCMAKE_CXX_FLAGS=-fPIC" '("-DCMAKE_CXX_FLAGS=-fPIC"
"-DPHONON_BUILD_PHONON4QT5=ON" "-DPHONON_BUILD_PHONON4QT5=ON")
"-DPHONON_INSTALL_QT_EXTENSIONS_INTO_SYSTEM_QT=ON")
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-before 'install 'patch-installdir (add-before 'install 'patch-installdir
@ -307,8 +320,11 @@ http://freedesktop.org/wiki/Specifications/open-collaboration-services/")
`(("qtbase" ,qtbase))) `(("qtbase" ,qtbase)))
(arguments (arguments
`(#:configure-flags `(#:configure-flags
'("-DINSTALL_UDEV_RULE:BOOL=OFF") (list (string-append
#:tests? #f)) ; DBUS_FATAL_WARNINGS=0 still yields 7/8 tests failing "-DUDEV_RULES_INSTALL_DIR=" %output "/lib/udev/rules.d"))
;; TODO: Make tests pass: DBUS_FATAL_WARNINGS=0 still yields 7/8 tests
;; failing. When running after install, tests hang.
#:tests? #f))
(home-page "https://community.kde.org/Frameworks") (home-page "https://community.kde.org/Frameworks")
(synopsis "QML wrapper for BlueZ") (synopsis "QML wrapper for BlueZ")
(description "bluez-qt is a Qt-style library for accessing the bluez (description "bluez-qt is a Qt-style library for accessing the bluez
@ -540,6 +556,8 @@ propagate their changes to their respective configuration files.")
(native-inputs (native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules) `(("extra-cmake-modules" ,extra-cmake-modules)
("qttools" ,qttools) ("qttools" ,qttools)
("shared-mime-info" ,shared-mime-info)
;; TODO: FAM: File alteration notification http://oss.sgi.com/projects/fam
("xorg-server" ,xorg-server))) ; for the tests ("xorg-server" ,xorg-server))) ; for the tests
(inputs (inputs
`(("qtbase" ,qtbase))) `(("qtbase" ,qtbase)))
@ -624,7 +642,8 @@ as well as an API to create KDED modules.")
`(("extra-cmake-modules" ,extra-cmake-modules) `(("extra-cmake-modules" ,extra-cmake-modules)
("qttools" ,qttools))) ("qttools" ,qttools)))
(inputs (inputs
`(("qtbase" ,qtbase))) `(("avahi" ,avahi) ; alternativly dnssd could be used
("qtbase" ,qtbase)))
(home-page "https://community.kde.org/Frameworks") (home-page "https://community.kde.org/Frameworks")
(synopsis "Network service discovery using Zeroconf") (synopsis "Network service discovery using Zeroconf")
(description "KDNSSD is a library for handling the DNS-based Service (description "KDNSSD is a library for handling the DNS-based Service
@ -729,9 +748,11 @@ translation scripting.")
"01m4q3l2yq83f2dpbv6jry7cjkj6bqdgfpy5b8byaf1gf9w2firs")))) "01m4q3l2yq83f2dpbv6jry7cjkj6bqdgfpy5b8byaf1gf9w2firs"))))
(build-system cmake-build-system) (build-system cmake-build-system)
(native-inputs (native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules))) `(("extra-cmake-modules" ,extra-cmake-modules)
("pkg-config" ,pkg-config)))
(inputs (inputs
`(("qtbase" ,qtbase) `(("libxscrnsaver" ,libxscrnsaver) ; X-Screensaver based poller, fallback mode
("qtbase" ,qtbase)
("qtx11extras" ,qtx11extras))) ("qtx11extras" ,qtx11extras)))
(home-page "https://community.kde.org/Frameworks") (home-page "https://community.kde.org/Frameworks")
(synopsis "Reporting of idle time of user and system") (synopsis "Reporting of idle time of user and system")
@ -1042,7 +1063,7 @@ configuration pages, message boxes, and password requests.")
(begin (begin
(let ((out (assoc-ref outputs "out"))) (let ((out (assoc-ref outputs "out")))
(setenv "QT_PLUGIN_PATH" (setenv "QT_PLUGIN_PATH"
(string-append out "/lib/plugins:" (string-append out "/lib/qt5/plugins:"
(getenv "QT_PLUGIN_PATH")))) (getenv "QT_PLUGIN_PATH"))))
;; The test suite requires a running X server, setting ;; The test suite requires a running X server, setting
;; QT_QPA_PLATFORM=offscreen does not suffice and even make ;; QT_QPA_PLATFORM=offscreen does not suffice and even make
@ -1213,7 +1234,7 @@ system.")
(define-public prison (define-public prison
(package (package
(name "prison") (name "prison")
(version "5.34.0") (version "5.37.0")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
@ -1221,7 +1242,7 @@ system.")
(version-major+minor version) "/" (version-major+minor version) "/"
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 "00wj4yyfhhcq9b54civ5hy1grz70mmi676x50y12crcbbgkxm1lx")))) (base32 "1icsirwfh7zscm8x9g2gp7aqzhs81ahhjflwjcwpz9bh0r9f1wb7"))))
(build-system cmake-build-system) (build-system cmake-build-system)
(native-inputs (native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules))) `(("extra-cmake-modules" ,extra-cmake-modules)))
@ -1251,6 +1272,7 @@ provides uniform access to generation of barcodes with data.")
(build-system cmake-build-system) (build-system cmake-build-system)
(native-inputs (native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules) `(("extra-cmake-modules" ,extra-cmake-modules)
("pkg-config" ,pkg-config)
("qttools" ,qttools))) ("qttools" ,qttools)))
(inputs (inputs
`(("hunspell" ,hunspell) `(("hunspell" ,hunspell)
@ -1452,6 +1474,15 @@ application crashes.")
(("^.*xml/docbook/stylesheet.*$") (("^.*xml/docbook/stylesheet.*$")
(string-append "xml/xsl/docbook-xsl-" (string-append "xml/xsl/docbook-xsl-"
,(package-version docbook-xsl) "\n"))) ,(package-version docbook-xsl) "\n")))
#t))
(add-after 'install 'add-symlinks
;; Some package(s) (e.g. kdelibs4support) refer to this locale by a
;; different spelling.
(lambda* (#:key outputs #:allow-other-keys)
(let ((xsl (string-append (assoc-ref outputs "out")
"/share/kf5/kdoctools/customization/xsl/")))
(symlink (string-append xsl "pt_br.xml")
(string-append xsl "pt-BR.xml")))
#t))))) #t)))))
(home-page "https://community.kde.org/Frameworks") (home-page "https://community.kde.org/Frameworks")
(synopsis "Create documentation from DocBook") (synopsis "Create documentation from DocBook")
@ -1485,23 +1516,26 @@ from DocBook files.")
(lambda* (#:key outputs #:allow-other-keys) (lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out"))) (let ((out (assoc-ref outputs "out")))
(setenv "QT_PLUGIN_PATH" (setenv "QT_PLUGIN_PATH"
(string-append out "/lib/plugins:" (string-append out "/lib/qt5/plugins:"
(getenv "QT_PLUGIN_PATH")))) (getenv "QT_PLUGIN_PATH"))))
#t))))) #t)))))
(native-inputs (native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules) `(("extra-cmake-modules" ,extra-cmake-modules)
("pkg-config" ,pkg-config)
("python-2" ,python-2))) ("python-2" ,python-2)))
(inputs (inputs
`(("attr" ,attr) `(("attr" ,attr)
;; TODO: EPub http://sourceforge.net/projects/ebook-tools
("karchive" ,karchive) ("karchive" ,karchive)
("ki18n" ,ki18n) ("ki18n" ,ki18n)
("qtmultimedia" ,qtmultimedia)
("qtbase" ,qtbase) ("qtbase" ,qtbase)
;; Required run-time packages ;; Required run-time packages
("catdoc" ,catdoc) ("catdoc" ,catdoc)
;; Optional run-time packages ;; Optional run-time packages
("exiv2" ,exiv2) ("exiv2" ,exiv2)
("ffmpeg" ,ffmpeg) ("ffmpeg" ,ffmpeg)
("poppler" ,poppler) ("poppler-qt5" ,poppler-qt5)
("taglib" ,taglib))) ("taglib" ,taglib)))
(home-page "https://community.kde.org/Frameworks") (home-page "https://community.kde.org/Frameworks")
(synopsis "Extract metadata from different fileformats") (synopsis "Extract metadata from different fileformats")
@ -1995,7 +2029,8 @@ KCModules can be created with the KConfigWidgets framework.")
("kconfig" ,kconfig) ("kconfig" ,kconfig)
("kwidgetsaddons" ,kwidgetsaddons))) ("kwidgetsaddons" ,kwidgetsaddons)))
(native-inputs (native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules))) `(("extra-cmake-modules" ,extra-cmake-modules)
("kdoctools" ,kdoctools)))
(inputs (inputs
`(("kcoreaddons" ,kcoreaddons) `(("kcoreaddons" ,kcoreaddons)
("kguiaddons" ,kguiaddons) ("kguiaddons" ,kguiaddons)
@ -2036,6 +2071,7 @@ their settings.")
("kpackage" ,kpackage))) ("kpackage" ,kpackage)))
(native-inputs (native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules) `(("extra-cmake-modules" ,extra-cmake-modules)
("pkg-config" ,pkg-config)
("xorg-server" ,xorg-server))) ("xorg-server" ,xorg-server)))
(inputs (inputs
`(("kauth" ,kauth) `(("kauth" ,kauth)
@ -2055,6 +2091,7 @@ their settings.")
("kwidgetsaddons" ,kwidgetsaddons) ("kwidgetsaddons" ,kwidgetsaddons)
("kwindowsystem" ,kwindowsystem) ("kwindowsystem" ,kwindowsystem)
("kxmlgui" ,kxmlgui) ("kxmlgui" ,kxmlgui)
("libepoxy", libepoxy)
("qtbase" ,qtbase) ("qtbase" ,qtbase)
("qtdeclarative" ,qtdeclarative) ("qtdeclarative" ,qtdeclarative)
("solid" ,solid))) ("solid" ,solid)))
@ -2132,7 +2169,20 @@ started on demand.")
`(("kconfig" ,kconfig) `(("kconfig" ,kconfig)
("kcoreaddons" ,kcoreaddons) ("kcoreaddons" ,kcoreaddons)
("kdoctools" ,kdoctools) ("kdoctools" ,kdoctools)
("qtbase" ,qtbase))) ("qtbase" ,qtbase)
;; optional:
("kcompletion" ,kcompletion)
("kconfigwidgets" ,kconfigwidgets)
("kiconthemes" ,kiconthemes)
("kitemviews" ,kitemviews)
("kio" ,kio)
("kplotting" ,kplotting)
("ktextwidgets" ,ktextwidgets)
("kdewebkit" ,kdewebkit)
("kwidgetsaddons" ,kwidgetsaddons)
("kxmlgui" ,kxmlgui)
("qtwebkit" ,qtwebkit)
("sonnet" ,sonnet)))
(arguments (arguments
`(#:phases `(#:phases
(modify-phases %standard-phases (modify-phases %standard-phases
@ -2237,6 +2287,7 @@ emoticons coming from different providers.")
(build-system cmake-build-system) (build-system cmake-build-system)
(native-inputs (native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules) `(("extra-cmake-modules" ,extra-cmake-modules)
("pkg-config" ,pkg-config)
("qttools" ,qttools))) ("qttools" ,qttools)))
(inputs (inputs
`(("kconfig" ,kconfig) `(("kconfig" ,kconfig)
@ -2386,7 +2437,7 @@ makes starting KDE applications faster and reduces memory consumption.")
`(("dbus" ,dbus) `(("dbus" ,dbus)
("extra-cmake-modules" ,extra-cmake-modules))) ("extra-cmake-modules" ,extra-cmake-modules)))
(inputs (inputs
`(("acl" ,acl) `(;; TODO: LibACL , <ftp://oss.sgi.com/projects/xfs/cmd_tars>
("krb5" ,mit-krb5) ("krb5" ,mit-krb5)
("karchive" ,karchive) ("karchive" ,karchive)
("kauth" ,kauth) ("kauth" ,kauth)
@ -2411,13 +2462,30 @@ makes starting KDE applications faster and reduces memory consumption.")
`(#:tests? #f ; FIXME: 41/50 tests fail. `(#:tests? #f ; FIXME: 41/50 tests fail.
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-after 'unpack 'patch
(lambda _
;; Better error message (taken from nix)
(substitute* "src/kiod/kiod_main.cpp"
(("(^\\s*qCWarning(KIOD_CATEGORY) << \"Error loading plugin:\")( << loader.errorString();)" _ a b)
(string-append a "<< name" b)))
;; TODO: samba-search-path.patch from nix: search smbd on $PATH
#t))
(add-before 'check 'check-setup (add-before 'check 'check-setup
(lambda _ (lambda _
(setenv "HOME" (getcwd)) (setenv "HOME" (getcwd))
(setenv "XDG_RUNTIME_DIR" (getcwd)) (setenv "XDG_RUNTIME_DIR" (getcwd))
;; make Qt render "offscreen", required for tests ;; make Qt render "offscreen", required for tests
(setenv "QT_QPA_PLATFORM" "offscreen") (setenv "QT_QPA_PLATFORM" "offscreen")
#t))))) #t))
(add-after 'install 'add-symlinks
;; Some package(s) (e.g. bluedevil) refer to these service types by
;; the wrong name. I would prefer to patch those packages, but I
;; cannot find the files!
(lambda* (#:key outputs #:allow-other-keys)
(let ((kst5 (string-append (assoc-ref outputs "out")
"/share/kservicetypes5/")))
(symlink (string-append kst5 "kfileitemactionplugin.desktop")
(string-append kst5 "kfileitemaction-plugin.desktop"))))))))
;;(replace 'check ;;(replace 'check
;; (lambda _ ;; (lambda _
;; (setenv "DBUS_FATAL_WARNINGS" "0") ;; (setenv "DBUS_FATAL_WARNINGS" "0")
@ -2551,7 +2619,9 @@ notifications which can be embedded in your application.")
("ktextwidgets" ,ktextwidgets) ("ktextwidgets" ,ktextwidgets)
("kxmlgui" ,kxmlgui))) ("kxmlgui" ,kxmlgui)))
(native-inputs (native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules))) `(("extra-cmake-modules" ,extra-cmake-modules)
("shared-mime-info" ,shared-mime-info)
))
(inputs (inputs
`(("kauth" ,kauth) `(("kauth" ,kauth)
("kbookmarks" ,kbookmarks) ("kbookmarks" ,kbookmarks)
@ -2788,7 +2858,16 @@ types or handled by application specific code.")
(setenv "HOME" (getcwd)) (setenv "HOME" (getcwd))
;; make Qt render "offscreen", required for tests ;; make Qt render "offscreen", required for tests
(setenv "QT_QPA_PLATFORM" "offscreen") (setenv "QT_QPA_PLATFORM" "offscreen")
#t))))) #t))
(add-after 'install 'add-symlinks
;; Some package(s) (e.g. plasma-sdk) refer to these service types
;; by the wrong name. I would prefer to patch those packages, but
;; I cannot find the files!
(lambda* (#:key outputs #:allow-other-keys)
(let ((kst5 (string-append (assoc-ref outputs "out")
"/share/kservicetypes5/")))
(symlink (string-append kst5 "ktexteditorplugin.desktop")
(string-append kst5 "ktexteditor-plugin.desktop"))))))))
(home-page "https://community.kde.org/Frameworks") (home-page "https://community.kde.org/Frameworks")
(synopsis "Full text editor component") (synopsis "Full text editor component")
(description "KTextEditor provides a powerful text editor component that you (description "KTextEditor provides a powerful text editor component that you
@ -2861,7 +2940,7 @@ It supports rich text as well as plain text.")
(native-inputs (native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules))) `(("extra-cmake-modules" ,extra-cmake-modules)))
(inputs (inputs
`(("gpgme" ,gpgme) ;; TODO: Add gpgme Qt-bindings `(("gpgme" ,gpgme)
("kauth" ,kauth) ("kauth" ,kauth)
("kcodecs" ,kcodecs) ("kcodecs" ,kcodecs)
("kconfig" ,kconfig) ("kconfig" ,kconfig)
@ -2877,6 +2956,7 @@ It supports rich text as well as plain text.")
("kwindowsystem" ,kwindowsystem) ("kwindowsystem" ,kwindowsystem)
("libgcrypt" ,libgcrypt) ("libgcrypt" ,libgcrypt)
("phonon" ,phonon) ("phonon" ,phonon)
("qgpgme" ,qgpgme)
("qtbase" ,qtbase))) ("qtbase" ,qtbase)))
(home-page "https://community.kde.org/Frameworks") (home-page "https://community.kde.org/Frameworks")
(synopsis "Safe desktop-wide storage for passwords") (synopsis "Safe desktop-wide storage for passwords")
@ -2885,6 +2965,38 @@ desktop-wide storage for passwords and the kwalletd daemon used to safely store
the passwords on KDE work spaces.") the passwords on KDE work spaces.")
(license license:lgpl2.1+))) (license license:lgpl2.1+)))
(define-public kdewebkit
(package
(name "kdewebkit")
(version "5.37.0")
(source (origin
(method url-fetch)
(uri (string-append
"mirror://kde/stable/frameworks/"
(version-major+minor version) "/"
name "-" version ".tar.xz"))
(sha256
(base32
"1ph3a50wix42hmsbc9jbfxla172aihjx9yzp9rza09j1a7va3hg1"))))
(build-system cmake-build-system)
(native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules)))
(inputs
`(("kconfig" ,kconfig)
("kcoreaddons" ,kcoreaddons)
("kio" ,kio)
("kjobwidgets" ,kjobwidgets)
("kparts" ,kparts)
("kservice" ,kservice)
("kwallet" ,kwallet)
("qtbase" ,qtbase)
("qtwebkit" ,qtwebkit)))
(home-page "https://community.kde.org/Frameworks")
(synopsis "KDE Integration for QtWebKit")
(description "This library provides KDE integration of the HTML rendering
engine WebKit via QtWebKit.")
(license license:lgpl2.1+)))
(define-public kxmlgui (define-public kxmlgui
(package (package
(name "kxmlgui") (name "kxmlgui")
@ -3182,12 +3294,8 @@ workspace.")
(inputs (inputs
`(("kcompletion" ,kcompletion) `(("kcompletion" ,kcompletion)
("kconfig" ,kconfig) ("kconfig" ,kconfig)
("kconfigwidgets" ,kconfigwidgets)
("kded" ,kded) ("kded" ,kded)
("kdesignerplugin" ,kdesignerplugin)
("kdoctools" ,kdoctools)
("kglobalaccel" ,kglobalaccel) ("kglobalaccel" ,kglobalaccel)
("kguiaddons" ,kguiaddons)
("ki18n" ,ki18n) ("ki18n" ,ki18n)
("kio" ,kio) ("kio" ,kio)
("kservice" ,kservice) ("kservice" ,kservice)

View file

@ -1,6 +1,10 @@
;;; GNU Guix --- Functional package management for GNU ;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2012, 2013, 2014 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2012, 2013, 2014 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2014 Federico Beffa <beffa@fbengineering.ch>
;;; Copyright © 2015 Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
;;; Copyright © 2016, 2017 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2016, 2017 Ben Woodcroft <donttrustben@gmail.com>
;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com>
;;; ;;;
;;; This file is part of GNU Guix. ;;; This file is part of GNU Guix.
;;; ;;;
@ -22,7 +26,12 @@
#:use-module (guix licenses) #:use-module (guix licenses)
#:use-module (guix packages) #:use-module (guix packages)
#:use-module (guix download) #:use-module (guix download)
#:use-module (guix build-system gnu)) #:use-module (gnu packages pkg-config)
#:use-module (gnu packages python)
#:use-module (gnu packages ruby)
#:use-module (guix build-system gnu)
#:use-module (guix build-system python)
#:use-module (guix build-system ruby))
(define-public libffi (define-public libffi
(let ((post-install-phase (let ((post-install-phase
@ -66,3 +75,103 @@ conversions for values passed between the two languages.")
;; See <https://github.com/atgreen/libffi/blob/master/LICENSE>. ;; See <https://github.com/atgreen/libffi/blob/master/LICENSE>.
(license expat)))) (license expat))))
(define-public python-cffi
(package
(name "python-cffi")
(version "1.11.2")
(source
(origin
(method url-fetch)
(uri (pypi-uri "cffi" version))
(sha256
(base32 "19h0wwz9cww74gw8cyq0izj8zkhjyzjw2d3ks1c3f1y4q28xv1xb"))))
(build-system python-build-system)
(outputs '("out" "doc"))
(inputs
`(("libffi" ,libffi)))
(propagated-inputs ; required at run-time
`(("python-pycparser" ,python-pycparser)))
(native-inputs
`(("pkg-config" ,pkg-config)
("python-sphinx" ,python-sphinx)
("python-pytest" ,python-pytest)))
(arguments
`(#:modules ((ice-9 ftw)
(srfi srfi-26)
(guix build utils)
(guix build python-build-system))
#:phases
(modify-phases %standard-phases
(replace 'check
(lambda _
(setenv "PYTHONPATH"
(string-append
(getenv "PYTHONPATH")
":" (getcwd) "/build/"
(car (scandir "build" (cut string-prefix? "lib." <>)))))
;; XXX The "normal" approach of setting CC and friends does
;; not work here. Is this the correct way of doing things?
(substitute* "testing/embedding/test_basic.py"
(("c = distutils\\.ccompiler\\.new_compiler\\(\\)")
(string-append "c = distutils.ccompiler.new_compiler();"
"c.set_executables(compiler='gcc',"
"compiler_so='gcc',linker_exe='gcc',"
"linker_so='gcc -shared')")))
(substitute* "testing/cffi0/test_ownlib.py"
(("'cc testownlib") "'gcc testownlib"))
(zero? (system* "py.test" "-v" "c/" "testing/"))))
(add-before 'check 'disable-failing-test
;; This is assumed to be a libffi issue:
;; https://bitbucket.org/cffi/cffi/issues/312/tests-failed-with-armv8
(lambda _
(substitute* "testing/cffi0/test_ownlib.py"
(("ret.left") "ownlib.left"))
#t))
(add-after 'install 'install-doc
(lambda* (#:key outputs #:allow-other-keys)
(let* ((data (string-append (assoc-ref outputs "doc") "/share"))
(doc (string-append data "/doc/" ,name "-" ,version))
(html (string-append doc "/html")))
(with-directory-excursion "doc"
(system* "make" "html")
(mkdir-p html)
(copy-recursively "build/html" html))
(copy-file "LICENSE" (string-append doc "/LICENSE"))
#t))))))
(home-page "https://cffi.readthedocs.org")
(synopsis "Foreign function interface for Python")
(description
"Foreign Function Interface for Python calling C code.")
(license expat)))
(define-public python2-cffi
(package-with-python2 python-cffi))
(define-public ruby-ffi
(package
(name "ruby-ffi")
(version "1.9.18")
(source (origin
(method url-fetch)
(uri (rubygems-uri "ffi" version))
(sha256
(base32
"034f52xf7zcqgbvwbl20jwdyjwznvqnwpbaps9nk18v9lgb1dpx0"))))
(build-system ruby-build-system)
;; FIXME: Before running tests the build system attempts to build libffi
;; from sources.
(arguments `(#:tests? #f))
(native-inputs
`(("ruby-rake-compiler" ,ruby-rake-compiler)
("ruby-rspec" ,ruby-rspec)
("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
(inputs
`(("libffi" ,libffi)))
(synopsis "Ruby foreign function interface library")
(description "Ruby-FFI is a Ruby extension for programmatically loading
dynamic libraries, binding functions within them, and calling those functions
from Ruby code. Moreover, a Ruby-FFI extension works without changes on Ruby
and JRuby.")
(home-page "http://wiki.github.com/ffi/ffi")
(license bsd-3)))

View file

@ -367,8 +367,8 @@ It has been modified to remove all non-free binary blobs.")
(define %intel-compatible-systems '("x86_64-linux" "i686-linux")) (define %intel-compatible-systems '("x86_64-linux" "i686-linux"))
(define %linux-libre-version "4.13.5") (define %linux-libre-version "4.13.7")
(define %linux-libre-hash "1crw61x7qrijhpw0azxf9b3fra0cxq87ncni2419p0s23jfdpc4m") (define %linux-libre-hash "1znf2zrhfb6wmlv09c14y6sawl4nb0jr7gzwwnakspvy0yjs95r3")
(define-public linux-libre (define-public linux-libre
(make-linux-libre %linux-libre-version (make-linux-libre %linux-libre-version
@ -377,14 +377,14 @@ It has been modified to remove all non-free binary blobs.")
#:configuration-file kernel-config)) #:configuration-file kernel-config))
(define-public linux-libre-4.9 (define-public linux-libre-4.9
(make-linux-libre "4.9.53" (make-linux-libre "4.9.56"
"174i53cd090akbjq34dj4z00h1nyfmy3sl3fk6svcmbx6h34381h" "05wy73yh4jbn1881djs21wl4hws62lyc1frb5di6cg6m3z7j658i"
%intel-compatible-systems %intel-compatible-systems
#:configuration-file kernel-config)) #:configuration-file kernel-config))
(define-public linux-libre-4.4 (define-public linux-libre-4.4
(make-linux-libre "4.4.90" (make-linux-libre "4.4.92"
"1sqzvz8yrcf99vhphkxp1wm2agq6q9nshxb1mkypspm8rhm11vhw" "038mrv36n2521xd1f4nlpn00ar4vwzbwkldf6pk7rflbc3zi0p8g"
%intel-compatible-systems %intel-compatible-systems
#:configuration-file kernel-config)) #:configuration-file kernel-config))
@ -398,11 +398,11 @@ It has been modified to remove all non-free binary blobs.")
(origin (origin
(method url-fetch) (method url-fetch)
(uri "\ (uri "\
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git/patch/?id=4a01092a5fa819397484fe2b50e9518356858156") https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git/patch/?id=f7ec367c8ea7021517c9c04b0022c225d2d0785a")
(file-name "linux-libre-4.4-CVE-2017-1000251.patch") (file-name "linux-libre-4.4-CVE-2017-1000251.patch")
(sha256 (sha256
(base32 (base32
"0zmkw9zvzpwy2ihiyfrw6mrf8qzv77cm23lxadr20qvzqlc1xzb3")))))) "1glnjvs3xkvana2wfdv47dxi7jz2s4dz3v0b8ryglf2vbflm388w"))))))
(define-public linux-libre-arm-generic (define-public linux-libre-arm-generic
(make-linux-libre %linux-libre-version (make-linux-libre %linux-libre-version
@ -3071,6 +3071,16 @@ Bluetooth audio output devices like headphones or loudspeakers.")
(string-append "--with-udevdir=" out "/lib/udev"))) (string-append "--with-udevdir=" out "/lib/udev")))
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
,@(if (string=? (%current-system) "armhf-linux")
;; This test fails unpredictably.
;; TODO: skip it for all architectures.
`((add-before 'check 'skip-wonky-test
(lambda _
(substitute* "unit/test-gatt.c"
(("tester_init\\(&argc, &argv\\);") "return 77;"))
#t)))
`())
(add-after 'install 'post-install (add-after 'install 'post-install
(lambda* (#:key inputs outputs #:allow-other-keys) (lambda* (#:key inputs outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out")) (let* ((out (assoc-ref outputs "out"))
@ -3089,13 +3099,7 @@ Bluetooth audio output devices like headphones or loudspeakers.")
(string-append out "/lib/udev/hid2hci --method")) (string-append out "/lib/udev/hid2hci --method"))
(("/sbin/udevadm") (("/sbin/udevadm")
(string-append (assoc-ref inputs "eudev") "/bin/udevadm"))) (string-append (assoc-ref inputs "eudev") "/bin/udevadm")))
#t)))) #t))))))
;; FIXME: Skip a test that segfaults on some machines. Seems to be a
;; timing issue (discussion on upstream mailing list:
;; https://marc.info/?t=149578476300002&r=1&w=2)
#:make-flags '("XFAIL_TESTS=unit/test-gatt")))
(native-inputs (native-inputs
`(("pkg-config" ,pkg-config) `(("pkg-config" ,pkg-config)
("gettext" ,gettext-minimal))) ("gettext" ,gettext-minimal)))
@ -3689,14 +3693,14 @@ the default @code{nsswitch} and the experimental @code{umich_ldap}.")
(define-public mcelog (define-public mcelog
(package (package
(name "mcelog") (name "mcelog")
(version "153") (version "154")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "https://git.kernel.org/cgit/utils/cpu/mce/" (uri (string-append "https://git.kernel.org/cgit/utils/cpu/mce/"
"mcelog.git/snapshot/v" version ".tar.gz")) "mcelog.git/snapshot/v" version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"0q40d60p1klzg0aznvxhxgjlddwcxfj2q59s4q86sf9ild6rcdhl")) "07628cr05f50m7lsvw26wxlnb7qcl0x6rymdpp5spqzhz91l58p3"))
(file-name (string-append name "-" version ".tar.gz")) (file-name (string-append name "-" version ".tar.gz"))
(modules '((guix build utils))) (modules '((guix build utils)))
(snippet (snippet
@ -3715,7 +3719,7 @@ the default @code{nsswitch} and the experimental @code{umich_ldap}.")
;; The tests will only run as root on certain supported CPU models. ;; The tests will only run as root on certain supported CPU models.
#:tests? #f)) #:tests? #f))
(supported-systems (list "i686-linux" "x86_64-linux")) (supported-systems (list "i686-linux" "x86_64-linux"))
(home-page "http://mcelog.org/") (home-page "https://mcelog.org/")
(synopsis "Machine check monitor for x86 Linux systems") (synopsis "Machine check monitor for x86 Linux systems")
(description (description
"The mcelog daemon is required by the Linux kernel to log memory, I/O, CPU, "The mcelog daemon is required by the Linux kernel to log memory, I/O, CPU,

View file

@ -14,7 +14,7 @@
;;; Copyright © 2016 Leo Famulari <leo@famulari.name> ;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org> ;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org>
;;; Copyright © 2016 Alex Kost <alezost@gmail.com> ;;; Copyright © 2016 Alex Kost <alezost@gmail.com>
;;; Copyright © 2016 Troy Sankey <sankeytms@gmail.com> ;;; Copyright © 2016, 2017 Troy Sankey <sankeytms@gmail.com>
;;; Copyright © 2016, 2017 ng0 <ng0@infotropique.org> ;;; Copyright © 2016, 2017 ng0 <ng0@infotropique.org>
;;; Copyright © 2016 Clément Lassieur <clement@lassieur.org> ;;; Copyright © 2016 Clément Lassieur <clement@lassieur.org>
;;; Copyright © 2016, 2017 Arun Isaac <arunisaac@systemreboot.net> ;;; Copyright © 2016, 2017 Arun Isaac <arunisaac@systemreboot.net>
@ -265,7 +265,7 @@ operating systems.")
(package (package
(inherit mutt) (inherit mutt)
(name "neomutt") (name "neomutt")
(version "20170912") (version "20171013")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
@ -273,7 +273,7 @@ operating systems.")
"/archive/" name "-" version ".tar.gz")) "/archive/" name "-" version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"0mv60kii933hq52mhwrcz29diaajbs5ryqibgsvdvfyvx27i43cz")))) "0mcs5rhlajyxl0bw2hpwcwx14rzrgk6sf8yr0gdj1di3sq166z2s"))))
(inputs (inputs
`(("cyrus-sasl" ,cyrus-sasl) `(("cyrus-sasl" ,cyrus-sasl)
("gdbm" ,gdbm) ("gdbm" ,gdbm)
@ -583,7 +583,7 @@ attachments, create new maildirs, and so on.")
(define-public alot (define-public alot
(package (package
(name "alot") (name "alot")
(version "0.4") (version "0.5.1")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
;; package author intends on distributing via github rather ;; package author intends on distributing via github rather
@ -594,13 +594,14 @@ attachments, create new maildirs, and so on.")
(file-name (string-append "alot-" version ".tar.gz")) (file-name (string-append "alot-" version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"0sl1kl2fhkv208llnbny4blcvrfdk4vx6bcw5pnyh9ylwb0pipi2")))) "0wax30hjzmkqfml7hig1dqw1v1y63yc0cgbzl96x58b9h2ggqx3a"))))
(build-system python-build-system) (build-system python-build-system)
(arguments (arguments
`(#:tests? #f ; no tests `(;; python 3 is currently unsupported, more info:
;; python 3 is currently unsupported, more info:
;; https://github.com/pazz/alot/blob/master/docs/source/faq.rst ;; https://github.com/pazz/alot/blob/master/docs/source/faq.rst
#:python ,python-2)) #:python ,python-2))
(native-inputs
`(("python2-mock" ,python2-mock)))
(inputs (inputs
`(("python2-magic" ,python2-magic) `(("python2-magic" ,python2-magic)
("python2-configobj" ,python2-configobj) ("python2-configobj" ,python2-configobj)
@ -1096,7 +1097,7 @@ facilities for checking incoming mail.")
(define-public dovecot (define-public dovecot
(package (package
(name "dovecot") (name "dovecot")
(version "2.2.32") (version "2.2.33.1")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
@ -1104,7 +1105,7 @@ facilities for checking incoming mail.")
(version-major+minor version) "/" (version-major+minor version) "/"
name "-" version ".tar.gz")) name "-" version ".tar.gz"))
(sha256 (base32 (sha256 (base32
"0bmwyvi1crmrca2knvknsf517x53w7gxrclwyrvrhddgw98j22qn")))) "02w932hq8v9889k709gbg94jl983lzwd3nh51vkxq041821a3ng4"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(native-inputs (native-inputs
`(("pkg-config" ,pkg-config))) `(("pkg-config" ,pkg-config)))

View file

@ -473,6 +473,19 @@ problems in numerical linear algebra.")
(license (license:non-copyleft "file://LICENSE" (license (license:non-copyleft "file://LICENSE"
"See LICENSE in the distribution.")))) "See LICENSE in the distribution."))))
(define-public lapack-3.5
(package
(inherit lapack)
(version "3.5.0")
(source
(origin
(method url-fetch)
(uri (string-append "http://www.netlib.org/lapack/lapack-"
version ".tgz"))
(sha256
(base32
"0lk3f97i9imqascnlf6wr5mjpyxqcdj73pgj97dj2mgvyg9z1n4s"))))))
(define-public scalapack (define-public scalapack
(package (package
(name "scalapack") (name "scalapack")
@ -2374,7 +2387,7 @@ to BMP, JPEG or PNG image formats.")
(define-public maxima (define-public maxima
(package (package
(name "maxima") (name "maxima")
(version "5.40.0") (version "5.41.0")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
@ -2382,7 +2395,7 @@ to BMP, JPEG or PNG image formats.")
version "-source/" name "-" version ".tar.gz")) version "-source/" name "-" version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"15pp35ayglv723bjbqc60gcdv2bm54s6pywsm4i4cwbjsf64dzkl")) "0x0n81z0s4pl8nwpf7ivlsbvsdphm9w42250g7qdkizl0132by6s"))
(patches (search-patches "maxima-defsystem-mkdir.patch")))) (patches (search-patches "maxima-defsystem-mkdir.patch"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(inputs (inputs

View file

@ -296,7 +296,7 @@ This package contains the binary.")
(define-public mpg123 (define-public mpg123
(package (package
(name "mpg123") (name "mpg123")
(version "1.25.6") (version "1.25.7")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (list (string-append "mirror://sourceforge/mpg123/mpg123/" (uri (list (string-append "mirror://sourceforge/mpg123/mpg123/"
@ -306,7 +306,7 @@ This package contains the binary.")
version ".tar.bz2"))) version ".tar.bz2")))
(sha256 (sha256
(base32 (base32
"13jsbh1gwypjksim2fxlblj5wc2driwm4igrkcnbr6bpp34mh10g")))) "1ws40fglyyk51jvmz8gfapjkw1g51pkch1rffdsbh4b1yay5xc9i"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(arguments '(#:configure-flags '("--with-default-audio=pulse"))) (arguments '(#:configure-flags '("--with-default-audio=pulse")))
(native-inputs `(("pkg-config" ,pkg-config))) (native-inputs `(("pkg-config" ,pkg-config)))

View file

@ -486,7 +486,7 @@ which can be used to encrypt a password with @code{crypt(3)}.")
(define-public wireshark (define-public wireshark
(package (package
(name "wireshark") (name "wireshark")
(version "2.4.1") (version "2.4.2")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
@ -494,7 +494,7 @@ which can be used to encrypt a password with @code{crypt(3)}.")
version ".tar.xz")) version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"1k8zj44pkb2ny2x46f100y7cxddm1kh0zh7f6qggm78gn7wvrp82")))) "0zglapd3sz08p2z9x8a5va3jnz17b3n5a1bskf7f2dgx6m3v5b6i"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(inputs `(("c-ares" ,c-ares) (inputs `(("c-ares" ,c-ares)
("glib" ,glib) ("glib" ,glib)
@ -510,12 +510,12 @@ which can be used to encrypt a password with @code{crypt(3)}.")
("openssl" ,openssl) ("openssl" ,openssl)
("portaudio" ,portaudio) ("portaudio" ,portaudio)
("qtbase" ,qtbase) ("qtbase" ,qtbase)
("qttools" ,qttools)
("sbc" ,sbc) ("sbc" ,sbc)
("zlib" ,zlib))) ("zlib" ,zlib)))
(native-inputs `(("perl" ,perl) (native-inputs `(("perl" ,perl)
("pkg-config" ,pkg-config) ("pkg-config" ,pkg-config)
("python" ,python-wrapper))) ("python" ,python-wrapper)
("qttools" ,qttools)))
(arguments (arguments
`(#:configure-flags `(#:configure-flags
(list (string-append "--with-c-ares=" (assoc-ref %build-inputs "c-ares")) (list (string-append "--with-c-ares=" (assoc-ref %build-inputs "c-ares"))
@ -529,7 +529,6 @@ which can be used to encrypt a password with @code{crypt(3)}.")
(string-append "--with-sbc=" (assoc-ref %build-inputs "sbc")) (string-append "--with-sbc=" (assoc-ref %build-inputs "sbc"))
(string-append "--with-ssl=" (assoc-ref %build-inputs "openssl")) (string-append "--with-ssl=" (assoc-ref %build-inputs "openssl"))
(string-append "--with-zlib=" (assoc-ref %build-inputs "zlib"))))) (string-append "--with-zlib=" (assoc-ref %build-inputs "zlib")))))
(home-page "https://www.wireshark.org/")
(synopsis "Network traffic analyzer") (synopsis "Network traffic analyzer")
(description "Wireshark is a network protocol analyzer, or @dfn{packet (description "Wireshark is a network protocol analyzer, or @dfn{packet
sniffer}, that lets you capture and interactively browse the contents of sniffer}, that lets you capture and interactively browse the contents of

View file

@ -46,6 +46,7 @@
#:use-module (gnu packages gtk) #:use-module (gnu packages gtk)
#:use-module (gnu packages guile) #:use-module (gnu packages guile)
#:use-module (gnu packages kerberos) #:use-module (gnu packages kerberos)
#:use-module (gnu packages libffi)
#:use-module (gnu packages linux) #:use-module (gnu packages linux)
#:use-module (gnu packages man) #:use-module (gnu packages man)
#:use-module (gnu packages multiprecision) #:use-module (gnu packages multiprecision)

View file

@ -0,0 +1,65 @@
Fix a bug whereby the 'have_easy_codec' would be left undefined
when passing '-D enable-easy-codec-installation=no'. Likewise,
don't rely on GStreamer's plug-in support when it's disabled.
--- totem-3.26.0/meson.build 2017-10-11 22:29:44.506280919 +0200
+++ totem-3.26.0/meson.build 2017-10-11 22:29:50.902252058 +0200
@@ -203,6 +203,8 @@ if easy_codec_option != 'no'
missing_plugins_deps += gst_pbutils_dep
config_h.set('ENABLE_MISSING_PLUGIN_INSTALLATION', have_easy_codec,
description: 'Whether we can and want to do installation of missing plugins')
+else
+ have_easy_codec = false
endif
# python support
--- totem-3.26.0/src/backend/bacon-video-widget.c 2017-10-11 22:40:52.531217356 +0200
+++ totem-3.26.0/src/backend/bacon-video-widget.c 2017-10-11 22:45:44.973847231 +0200
@@ -341,6 +341,22 @@ get_type_name (GType class_type, int typ
return value->value_nick;
}
+#ifndef ENABLE_MISSING_PLUGIN_INSTALLATION
+
+gchar *
+gst_missing_plugin_message_get_installer_detail (GstMessage *message)
+{
+ return NULL;
+}
+
+char *
+gst_missing_plugin_message_get_description (GstMessage *message)
+{
+ return NULL;
+}
+
+#endif
+
static gchar **
bvw_get_missing_plugins_foo (const GList * missing_plugins, MsgToStrFunc func)
{
@@ -1654,10 +1670,12 @@ bvw_handle_element_message (BaconVideoWi
}
}
goto done;
+#ifdef ENABLE_MISSING_PLUGIN_INSTALLATION
} else if (gst_is_missing_plugin_message (msg)) {
bvw->priv->missing_plugins =
g_list_prepend (bvw->priv->missing_plugins, gst_message_ref (msg));
goto done;
+#endif
} else if (strcmp (type_name, "not-mounted") == 0) {
const GValue *val;
GFile *file;
@@ -6109,7 +6127,9 @@ bacon_video_widget_initable_init (GInita
GST_DEBUG ("Initialised %s", version_str);
g_free (version_str);
+#ifdef ENABLE_MISSING_PLUGIN_INSTALLATION
gst_pb_utils_init ();
+#endif
/* Instantiate all the fallible plugins */
bvw->priv->play = element_make_or_warn ("playbin", "play");

File diff suppressed because it is too large Load diff

View file

@ -22,8 +22,8 @@
;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com> ;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com>
;;; Copyright © 2016 Daniel Pimentel <d4n1@d4n1.org> ;;; Copyright © 2016 Daniel Pimentel <d4n1@d4n1.org>
;;; Copyright © 2016 Sou Bunnbu <iyzsong@gmail.com> ;;; Copyright © 2016 Sou Bunnbu <iyzsong@gmail.com>
;;; Copyright © 2016 Troy Sankey <sankeytms@gmail.com> ;;; Copyright © 2016, 2017 Troy Sankey <sankeytms@gmail.com>
;;; Copyright © 2016, 2017 ng0 <contact.ng0@cryptolab.net> ;;; Copyright © 2016, 2017 ng0 <ng0@infotropique.org>
;;; Copyright © 2016 Dylan Jeffers <sapientech@sapientech@openmailbox.org> ;;; Copyright © 2016 Dylan Jeffers <sapientech@sapientech@openmailbox.org>
;;; Copyright © 2016 David Craven <david@craven.ch> ;;; Copyright © 2016 David Craven <david@craven.ch>
;;; Copyright © 2016, 2017 Marius Bakke <mbakke@fastmail.com> ;;; Copyright © 2016, 2017 Marius Bakke <mbakke@fastmail.com>
@ -4512,7 +4512,8 @@ operators such as union, intersection, and difference.")
(scandir (string-append cwd "/build"))) (scandir (string-append cwd "/build")))
":" ":"
(getenv "PYTHONPATH")))) (getenv "PYTHONPATH"))))
(zero? (system* "python" "-m" "rpy2.tests" "-v"))))))) ;; FIXME: Even when all tests pass, the check phase will fail.
(system* "python" "-m" "rpy2.tests" "-v"))))))
(propagated-inputs (propagated-inputs
`(("python-six" ,python-six) `(("python-six" ,python-six)
("python-jinja2" ,python-jinja2) ("python-jinja2" ,python-jinja2)
@ -5133,72 +5134,6 @@ a front-end for C compilers or analysis tools.")
(define-public python2-pycparser (define-public python2-pycparser
(package-with-python2 python-pycparser)) (package-with-python2 python-pycparser))
(define-public python-cffi
(package
(name "python-cffi")
(version "1.10.0")
(source
(origin
(method url-fetch)
(uri (pypi-uri "cffi" version))
(sha256
(base32 "1mffyilq4qycm8gs4wkgb18rnqil8a9blqq77chdlshzxc8jkc5k"))))
(build-system python-build-system)
(outputs '("out" "doc"))
(inputs
`(("libffi" ,libffi)))
(propagated-inputs ; required at run-time
`(("python-pycparser" ,python-pycparser)))
(native-inputs
`(("pkg-config" ,pkg-config)
("python-sphinx" ,python-sphinx)
("python-pytest" ,python-pytest)))
(arguments
`(#:modules ((ice-9 ftw)
(srfi srfi-26)
(guix build utils)
(guix build python-build-system))
#:phases
(modify-phases %standard-phases
(replace 'check
(lambda _
(setenv "PYTHONPATH"
(string-append
(getenv "PYTHONPATH")
":" (getcwd) "/build/"
(car (scandir "build" (cut string-prefix? "lib." <>)))))
;; XXX The "normal" approach of setting CC and friends does
;; not work here. Is this the correct way of doing things?
(substitute* "testing/embedding/test_basic.py"
(("c = distutils\\.ccompiler\\.new_compiler\\(\\)")
(string-append "c = distutils.ccompiler.new_compiler();"
"c.set_executables(compiler='gcc',"
"compiler_so='gcc',linker_exe='gcc',"
"linker_so='gcc -shared')")))
(substitute* "testing/cffi0/test_ownlib.py"
(("'cc testownlib") "'gcc testownlib"))
(zero? (system* "py.test" "-v" "c/" "testing/"))))
(add-after 'install 'install-doc
(lambda* (#:key outputs #:allow-other-keys)
(let* ((data (string-append (assoc-ref outputs "doc") "/share"))
(doc (string-append data "/doc/" ,name "-" ,version))
(html (string-append doc "/html")))
(with-directory-excursion "doc"
(system* "make" "html")
(mkdir-p html)
(copy-recursively "build/html" html))
(copy-file "LICENSE" (string-append doc "/LICENSE"))
#t))))))
(home-page "http://cffi.readthedocs.org")
(synopsis "Foreign function interface for Python")
(description
"Foreign Function Interface for Python calling C code.")
(license license:expat)))
(define-public python2-cffi
(package-with-python2 python-cffi))
(define-public python-xcffib (define-public python-xcffib
(package (package
(name "python-xcffib") (name "python-xcffib")
@ -5854,6 +5789,12 @@ tools for mocking system commands and recording calls to those.")
("python-numpy" ,python-numpy) ("python-numpy" ,python-numpy)
("python-numpydoc" ,python-numpydoc) ("python-numpydoc" ,python-numpydoc)
("python-jinja2" ,python-jinja2) ("python-jinja2" ,python-jinja2)
("python-jupyter-console"
;; The python-ipython and python-jupyter-console require each
;; other. To get the functionality in both packages working, strip
;; down the python-jupyter-console package when using it as an input
;; to python-ipython.
,python-jupyter-console-minimal)
("python-mistune" ,python-mistune) ("python-mistune" ,python-mistune)
("python-pexpect" ,python-pexpect) ("python-pexpect" ,python-pexpect)
("python-pickleshare" ,python-pickleshare) ("python-pickleshare" ,python-pickleshare)
@ -6607,6 +6548,26 @@ providing a clean and modern domain specific specification language (DSL) in
Python style, together with a fast and comfortable execution environment.") Python style, together with a fast and comfortable execution environment.")
(license license:expat))) (license license:expat)))
(define-public python-pyqrcode
(package
(name "python-pyqrcode")
(version "1.2.1")
(source
(origin
(method url-fetch)
(uri (pypi-uri "PyQRCode" version))
(sha256
(base32
"1m9ln8k9v7dfbh1i81225hx5mdsh8mpf9g7r4wpbfmiyfcs7dgzx"))))
(build-system python-build-system)
(home-page
"https://github.com/mnooner256/pyqrcode")
(synopsis "QR code generator")
(description
"Pyqrcode is a QR code generator written purely in Python with
SVG, EPS, PNG and terminal output.")
(license license:bsd-3)))
(define-public python-seaborn (define-public python-seaborn
(package (package
(name "python-seaborn") (name "python-seaborn")
@ -7415,15 +7376,13 @@ add functionality and customization to your projects with their own plugins.")
(define-public python-fonttools (define-public python-fonttools
(package (package
(name "python-fonttools") (name "python-fonttools")
(version "2.5") (version "3.15.1")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (pypi-uri "fonttools" version ".zip"))
"https://pypi.python.org/packages/source/F/FontTools/"
"fonttools-" version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"08ay3x4ijarwhl60gqx2i9jzq6pxs20p4snc2d1q5jagh4rn39lb")))) "1hhj97izwliy0vybmza72d90l5d4mcn50y8akq7kyccfl82vdx4d"))))
(build-system python-build-system) (build-system python-build-system)
(arguments (arguments
'(#:test-target "check" '(#:test-target "check"
@ -7437,6 +7396,8 @@ add functionality and customization to your projects with their own plugins.")
(substitute* "setup.py" (substitute* "setup.py"
(("^[ \t]*extra_path *= *'FontTools',") "")) (("^[ \t]*extra_path *= *'FontTools',") ""))
#t))))) #t)))))
(native-inputs
`(("unzip" ,unzip)))
(home-page "https://github.com/behdad/fonttools") (home-page "https://github.com/behdad/fonttools")
(synopsis "Tools to manipulate font files") (synopsis "Tools to manipulate font files")
(description (description
@ -8560,6 +8521,31 @@ Jupyter kernels such as IJulia and IRKernel.")
(define-public python2-jupyter-console (define-public python2-jupyter-console
(package-with-python2 python-jupyter-console)) (package-with-python2 python-jupyter-console))
;; The python-ipython and python-jupyter-console require each other. To get
;; the functionality in both packages working, strip down the
;; python-jupyter-console package when using it as an input to python-ipython.
(define python-jupyter-console-minimal
(package
(inherit python-jupyter-console)
(arguments
(substitute-keyword-arguments
(package-arguments python-jupyter-console)
((#:phases phases)
`(modify-phases ,phases
(add-after 'install 'delete-bin
(lambda* (#:key outputs #:allow-other-keys)
;; Delete the bin files, to avoid conflicts in profiles
;; where python-ipython and python-jupyter-console are
;; both present.
(delete-file-recursively
(string-append
(assoc-ref outputs "out") "/bin"))))))))
;; Remove the python-ipython propagated input, to avoid the cycle
(propagated-inputs
(alist-delete
"python-ipython"
(package-propagated-inputs python-jupyter-console)))))
(define-public jupyter (define-public jupyter
(package (package
(name "jupyter") (name "jupyter")
@ -10784,14 +10770,14 @@ introspection of @code{zope.interface} instances in code.")
(define-public python-psycopg2 (define-public python-psycopg2
(package (package
(name "python-psycopg2") (name "python-psycopg2")
(version "2.6.2") (version "2.7.3.1")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
(uri (pypi-uri "psycopg2" version)) (uri (pypi-uri "psycopg2" version))
(sha256 (sha256
(base32 (base32
"0p60z2gwfcal30y2w8gprflchp1kcg9qblc5rn782p4wxl90wjbh")))) "0rda1j02ds6s28752fhmpwg761sh6jsxi1gpczqkrd28cki1cywv"))))
(build-system python-build-system) (build-system python-build-system)
(arguments (arguments
;; Tests would require a postgresql database "psycopg2_test" ;; Tests would require a postgresql database "psycopg2_test"
@ -11746,13 +11732,13 @@ format.")
(define-public python-twisted (define-public python-twisted
(package (package
(name "python-twisted") (name "python-twisted")
(version "16.2.0") (version "17.1.0")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (pypi-uri "Twisted" version ".tar.bz2")) (uri (pypi-uri "Twisted" version ".tar.bz2"))
(sha256 (sha256
(base32 (base32
"0ydxrp9myw1mvsz3qfzx5579y5llmqa82pxvqchgp5syczffi450")))) "1p245mg15hkxp7hy5cyq2fgvlgjkb4cg0gwkwd148nzy1bbi3wnv"))))
(build-system python-build-system) (build-system python-build-system)
(arguments (arguments
'(#:tests? #f)) ; FIXME: Some tests are failing. '(#:tests? #f)) ; FIXME: Some tests are failing.
@ -11762,7 +11748,10 @@ format.")
;; (lambda _ ;; (lambda _
;; (zero? (system* "./bin/trial" "twisted"))))) ;; (zero? (system* "./bin/trial" "twisted")))))
(propagated-inputs (propagated-inputs
`(("python-zope-interface" ,python-zope-interface))) `(("python-zope-interface" ,python-zope-interface)
("python-incremental" ,python-incremental)
("python-constantly" ,python-constantly)
("python-automat" ,python-automat)))
(home-page "https://twistedmatrix.com/") (home-page "https://twistedmatrix.com/")
(synopsis "Asynchronous networking framework written in Python") (synopsis "Asynchronous networking framework written in Python")
(description (description
@ -14229,6 +14218,133 @@ Python. It is based on Parsing Expression Grammars, PEG. With pyPEG you can
parse many formal languages.") parse many formal languages.")
(license license:gpl2))) (license license:gpl2)))
(define-public python-incremental
(package
(name "python-incremental")
(version "17.5.0")
(source
(origin
(method url-fetch)
(uri (pypi-uri "incremental" version))
(sha256
(base32
"1cylxdz1cnkm5g3pklna3h2n0i0rks95ir1pnpxfnvpkmab1cxbv"))))
(build-system python-build-system)
(home-page "https://github.com/hawkowl/incremental")
(synopsis "Library for versioning Python projects")
(description "Incremental is a small library that versions your Python
projects.")
(license license:expat)))
(define-public python2-incremental
(package-with-python2 python-incremental))
(define-public python-automat
(package
(name "python-automat")
(version "0.6.0")
(source (origin
(method url-fetch)
(uri (pypi-uri "Automat" version))
(sha256
(base32
"1a7nsrljysfmdqmpn2apfa1gg6rfah4y9sizvns8gb08rx7d07rw"))))
(build-system python-build-system)
;; We disable the tests because they require python-twisted, while
;; python-twisted depends on python-automat. Twisted is optional, but the
;; tests fail if it is not available. Also see
;; <https://github.com/glyph/automat/issues/71>.
(arguments '(#:tests? #f))
(native-inputs
`(("python-m2r" ,python-m2r)
("python-setuptools-scm" ,python-setuptools-scm)
("python-graphviz" ,python-graphviz)))
(propagated-inputs
`(("python-six" ,python-six)
("python-attrs" ,python-attrs)))
(home-page "https://github.com/glyph/Automat")
(synopsis "Self-service finite-state machines")
(description "Automat is a library for concise, idiomatic Python
expression of finite-state automata (particularly deterministic finite-state
transducers).")
(license license:expat)))
(define-public python2-automat
(package-with-python2 python-automat))
(define-public python-m2r
(package
(name "python-m2r")
(version "0.1.12")
(source (origin
(method url-fetch)
(uri (pypi-uri "m2r" version))
(sha256
(base32
"1axrwnf425sz4qz3c0qc7yhhki4myzb8rki7pczcsgzznzmqdyxd"))))
(build-system python-build-system)
(propagated-inputs
`(("python-docutils" ,python-docutils)
("python-mistune" ,python-mistune)))
(native-inputs
`(("python-pygments" ,python-pygments)
("python-mock" ,python-mock)))
(home-page "https://github.com/miyakogi/m2r")
(synopsis "Markdown to reStructuredText converter")
(description "M2R converts a markdown file including reST markups to valid
reST format.")
(license license:expat)))
(define-public python2-m2r
(package-with-python2 python-m2r))
(define-public python-constantly
(package
(name "python-constantly")
(version "15.1.0")
(source (origin
(method url-fetch)
(uri (pypi-uri "constantly" version))
(sha256
(base32
"0dgwdla5kfpqz83hfril716inm41hgn9skxskvi77605jbmp4qsq"))))
(build-system python-build-system)
(home-page "https://github.com/twisted/constantly")
(synopsis "Symbolic constants in Python")
(description "Constantly is a Python library that provides symbolic
constant support. It includes collections and constants with text, numeric,
and bit flag values.")
(license license:expat)))
(define-public python2-constantly
(package-with-python2 python-constantly))
(define-public python-attrs
(package
(name "python-attrs")
(version "17.2.0")
(source (origin
(method url-fetch)
(uri (pypi-uri "attrs" version))
(sha256
(base32
"04gx08ikpk26wnq22f7l42gapcvk8iz1512r927k6sadz6cinkax"))))
(build-system python-build-system)
(native-inputs
`(("python-pytest" ,python-pytest)
("python-hypothesis" ,python-hypothesis)
("python-zope-interface" ,python-zope-interface)
("python-six" ,python-six)))
(home-page "https://github.com/python-attrs/attrs/")
(synopsis "Attributes without boilerplate")
(description "@code{attrs} is a Python package with class decorators that
ease the chores of implementing the most common attribute-related object
protocols.")
(license license:expat)))
(define-public python2-attrs
(package-with-python2 python-attrs))
(define-public python2-cliapp (define-public python2-cliapp
(package (package
(name "python2-cliapp") (name "python2-cliapp")

View file

@ -78,6 +78,7 @@
(sha256 (sha256
(base32 "1lf9rkv0i0kd7fvpgg5l8jb87zw8dzcwd1liv6hji7g4wlpmfdiq")))) (base32 "1lf9rkv0i0kd7fvpgg5l8jb87zw8dzcwd1liv6hji7g4wlpmfdiq"))))
(native-inputs (native-inputs
;; Optional: lcov and cccc, both are for code coverage
`(("doxygen" ,doxygen))) `(("doxygen" ,doxygen)))
(inputs (inputs
`(("qtbase" ,qtbase) `(("qtbase" ,qtbase)
@ -86,10 +87,11 @@
(arguments (arguments
`(#:phases `(#:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(replace 'check (add-before 'check 'check-setup
(lambda _ (lambda _
(zero? (system* "ctest" ;; exclude 2 tests which require a display ;; make Qt render "offscreen", required for tests
"-E" "htmlbuildertest|plainmarkupbuildertest"))))))) (setenv "QT_QPA_PLATFORM" "offscreen")
#t)))))
(home-page "https://github.com/steveire/grantlee") (home-page "https://github.com/steveire/grantlee")
(synopsis "Libraries for text templating with Qt") (synopsis "Libraries for text templating with Qt")
(description "Grantlee Templates can be used for theming and generation of (description "Grantlee Templates can be used for theming and generation of
@ -100,7 +102,8 @@ system, and the core design of Django is reused in Grantlee.")
(define-public qt (define-public qt
(package (package
(name "qt") (name "qt")
(version "5.6.2") (version "5.9.2")
(outputs '("out" "examples"))
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (uri
@ -112,7 +115,7 @@ system, and the core design of Django is reused in Grantlee.")
version ".tar.xz")) version ".tar.xz"))
(sha256 (sha256
(base32 (base32
"1cw93mrlkqbwndfqyjpsvjzkpzi39px2is040xvk18mvg3y1prl3")) "1zr0hvhryn2ada53ln7cycymh602cncli86n291bsgzas6j72qbc"))
(modules '((guix build utils))) (modules '((guix build utils)))
(snippet (snippet
'(begin '(begin
@ -124,32 +127,52 @@ system, and the core design of Django is reused in Grantlee.")
;; Alternatively, we could use the "-skip qtwebengine" ;; Alternatively, we could use the "-skip qtwebengine"
;; configuration option. ;; configuration option.
(delete-file-recursively "qtwebengine") (delete-file-recursively "qtwebengine")
;; Remove one of the two bundled harfbuzz copies in addition ;; The following snippets are copied from their mondular-qt counterparts.
;; to passing "-system-harfbuzz". (for-each
(delete-file-recursively "qtbase/src/3rdparty/harfbuzz-ng") (lambda (dir)
;; Remove the bundled sqlite copy in addition to (delete-file-recursively (string-append "qtbase/src/3rdparty/" dir)))
;; passing "-system-sqlite". (list "double-conversion" "freetype" "harfbuzz-ng"
(delete-file-recursively "qtbase/src/3rdparty/sqlite"))))) "libpng" "libjpeg" "pcre2" "sqlite" "xcb"
"xkbcommon" "zlib"))
(for-each
(lambda (dir)
(delete-file-recursively dir))
(list "qtimageformats/src/3rdparty"
"qtmultimedia/examples/multimedia/spectrum/3rdparty"
"qtwayland/examples"
"qtcanvas3d/examples/canvas3d/3rdparty"))
;; Tests depend on this example, which depends on the 3rd party code.
(substitute* "qtmultimedia/examples/multimedia/multimedia.pro"
(("spectrum") "#"))))))
(build-system gnu-build-system) (build-system gnu-build-system)
(propagated-inputs (propagated-inputs
`(("mesa" ,mesa))) `(("mesa" ,mesa)))
(inputs (inputs
`(("alsa-lib" ,alsa-lib) `(("alsa-lib" ,alsa-lib)
("dbus" ,dbus) ("bluez" ,bluez)
("cups" ,cups) ("cups" ,cups)
("dbus" ,dbus)
("double-conversion" ,double-conversion)
("expat" ,expat) ("expat" ,expat)
("fontconfig" ,fontconfig) ("fontconfig" ,fontconfig)
("freetype" ,freetype) ("freetype" ,freetype)
("glib" ,glib) ("glib" ,glib)
("gstreamer" ,gstreamer)
("gst-plugins-base" ,gst-plugins-base)
("harfbuzz" ,harfbuzz) ("harfbuzz" ,harfbuzz)
("icu4c" ,icu4c) ("icu4c" ,icu4c)
("jasper" ,jasper)
("libinput" ,libinput-minimal)
("libjpeg" ,libjpeg) ("libjpeg" ,libjpeg)
("libmng" ,libmng) ("libmng" ,libmng)
("libpci" ,pciutils) ("libpci" ,pciutils)
("libpng" ,libpng) ("libpng" ,libpng)
("libtiff" ,libtiff)
("libwebp" ,libwebp)
("libx11" ,libx11) ("libx11" ,libx11)
("libxcomposite" ,libxcomposite) ("libxcomposite" ,libxcomposite)
("libxcursor" ,libxcursor) ("libxcursor" ,libxcursor)
("libxext" ,libxext)
("libxfixes" ,libxfixes) ("libxfixes" ,libxfixes)
("libxi" ,libxi) ("libxi" ,libxi)
("libxinerama" ,libxinerama) ("libxinerama" ,libxinerama)
@ -165,10 +188,11 @@ system, and the core design of Django is reused in Grantlee.")
("openssl" ,openssl) ("openssl" ,openssl)
("postgresql" ,postgresql) ("postgresql" ,postgresql)
("pulseaudio" ,pulseaudio) ("pulseaudio" ,pulseaudio)
("pcre" ,pcre) ("pcre2" ,pcre2)
("sqlite" ,sqlite) ("sqlite" ,sqlite)
("udev" ,eudev) ("udev" ,eudev)
("unixodbc" ,unixodbc) ("unixodbc" ,unixodbc)
("wayland" ,wayland)
("xcb-util" ,xcb-util) ("xcb-util" ,xcb-util)
("xcb-util-image" ,xcb-util-image) ("xcb-util-image" ,xcb-util-image)
("xcb-util-keysyms" ,xcb-util-keysyms) ("xcb-util-keysyms" ,xcb-util-keysyms)
@ -185,24 +209,19 @@ system, and the core design of Django is reused in Grantlee.")
("ruby" ,ruby) ("ruby" ,ruby)
("which" ,(@ (gnu packages base) which)))) ("which" ,(@ (gnu packages base) which))))
(arguments (arguments
`(;; FIXME: Disabling parallel building is a quick hack to avoid the `(#:phases
;; failure described in
;; https://lists.gnu.org/archive/html/guix-devel/2016-01/msg00837.html
;; A more structural fix is needed.
#:parallel-build? #f
#:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-after 'configure 'patch-bin-sh (add-after 'configure 'patch-bin-sh
(lambda _ (lambda _
(substitute* '("qtbase/config.status" (substitute* '("qtbase/configure"
"qtbase/configure"
"qtbase/mkspecs/features/qt_functions.prf" "qtbase/mkspecs/features/qt_functions.prf"
"qtbase/qmake/library/qmakebuiltins.cpp") "qtbase/qmake/library/qmakebuiltins.cpp")
(("/bin/sh") (which "sh"))) (("/bin/sh") (which "sh")))
#t)) #t))
(replace 'configure (replace 'configure
(lambda* (#:key outputs #:allow-other-keys) (lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out"))) (let ((out (assoc-ref outputs "out"))
(examples (assoc-ref outputs "examples")))
(substitute* '("configure" "qtbase/configure") (substitute* '("configure" "qtbase/configure")
(("/bin/pwd") (which "pwd"))) (("/bin/pwd") (which "pwd")))
(substitute* "qtbase/src/corelib/global/global.pri" (substitute* "qtbase/src/corelib/global/global.pri"
@ -213,12 +232,12 @@ system, and the core design of Django is reused in Grantlee.")
"./configure" "./configure"
"-verbose" "-verbose"
"-prefix" out "-prefix" out
"-examplesdir" examples ; 89MiB
"-opensource" "-opensource"
"-confirm-license" "-confirm-license"
;; Do not build examples; if desired, these could go ;; Do not build examples; for the time being, we
;; into a separate output, but for the time being, we
;; prefer to save the space and build time. ;; prefer to save the space and build time.
"-nomake" "examples" "-no-compile-examples"
;; Most "-system-..." are automatic, but some use ;; Most "-system-..." are automatic, but some use
;; the bundled copy by default. ;; the bundled copy by default.
"-system-sqlite" "-system-sqlite"
@ -227,6 +246,8 @@ system, and the core design of Django is reused in Grantlee.")
"-openssl-linked" "-openssl-linked"
;; explicitly link with dbus instead of dlopening it ;; explicitly link with dbus instead of dlopening it
"-dbus-linked" "-dbus-linked"
;; don't use the precompiled headers
"-no-pch"
;; drop special machine instructions not supported ;; drop special machine instructions not supported
;; on all instances of the target ;; on all instances of the target
,@(if (string-prefix? "x86_64" ,@(if (string-prefix? "x86_64"
@ -234,12 +255,6 @@ system, and the core design of Django is reused in Grantlee.")
(%current-system))) (%current-system)))
'() '()
'("-no-sse2")) '("-no-sse2"))
"-no-sse3"
"-no-ssse3"
"-no-sse4.1"
"-no-sse4.2"
"-no-avx"
"-no-avx2"
"-no-mips_dsp" "-no-mips_dsp"
"-no-mips_dspr2")))))))) "-no-mips_dspr2"))))))))
(home-page "https://www.qt.io/") (home-page "https://www.qt.io/")
@ -376,7 +391,8 @@ developers using C++ or QML, a CSS & JavaScript like language.")
#t)))) #t))))
(build-system gnu-build-system) (build-system gnu-build-system)
(propagated-inputs (propagated-inputs
`(("mesa" ,mesa))) `(("mesa" ,mesa)
("which" ,(@ (gnu packages base) which))))
(inputs (inputs
`(("alsa-lib" ,alsa-lib) `(("alsa-lib" ,alsa-lib)
("cups" ,cups) ("cups" ,cups)
@ -427,8 +443,7 @@ developers using C++ or QML, a CSS & JavaScript like language.")
("perl" ,perl) ("perl" ,perl)
("pkg-config" ,pkg-config) ("pkg-config" ,pkg-config)
("python" ,python-2) ("python" ,python-2)
("ruby" ,ruby) ("ruby" ,ruby)))
("which" ,(@ (gnu packages base) which))))
(arguments (arguments
`(#:phases `(#:phases
(modify-phases %standard-phases (modify-phases %standard-phases
@ -460,6 +475,12 @@ developers using C++ or QML, a CSS & JavaScript like language.")
"./configure" "./configure"
"-verbose" "-verbose"
"-prefix" out "-prefix" out
"-docdir" (string-append out "/share/doc/qt5")
"-headerdir" (string-append out "/include/qt5")
"-archdatadir" (string-append out "/lib/qt5")
"-datadir" (string-append out "/share/qt5")
"-examplesdir" (string-append
out "/share/doc/qt5/examples")
"-opensource" "-opensource"
"-confirm-license" "-confirm-license"
;; Do not build examples; if desired, these could go ;; Do not build examples; if desired, these could go
@ -486,41 +507,49 @@ developers using C++ or QML, a CSS & JavaScript like language.")
'("-no-sse2")) '("-no-sse2"))
"-no-mips_dsp" "-no-mips_dsp"
"-no-mips_dspr2"))))) "-no-mips_dspr2")))))
(add-after 'install 'patch-qt_config.prf (add-after 'install 'patch-mkspecs
(lambda* (#:key outputs #:allow-other-keys) (lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out")) (let* ((out (assoc-ref outputs "out"))
(archdata (string-append out "/lib/qt5"))
(mkspecs (string-append archdata "/mkspecs"))
(qt_config.prf (string-append (qt_config.prf (string-append
out "/mkspecs/features/qt_config.prf"))) mkspecs "/features/qt_config.prf")))
;; For each Qt module, let `qmake' uses search paths in the ;; For each Qt module, let `qmake' uses search paths in the
;; module directory instead of all in QT_INSTALL_PREFIX. ;; module directory instead of all in QT_INSTALL_PREFIX.
(substitute* qt_config.prf (substitute* qt_config.prf
(("\\$\\$\\[QT_INSTALL_HEADERS\\]") (("\\$\\$\\[QT_INSTALL_HEADERS\\]")
"$$replace(dir, mkspecs/modules, include)") "$$clean_path($$replace(dir, mkspecs/modules, ../../include/qt5))")
(("\\$\\$\\[QT_INSTALL_LIBS\\]") (("\\$\\$\\[QT_INSTALL_LIBS\\]")
"$$replace(dir, mkspecs/modules, lib)") "$$clean_path($$replace(dir, mkspecs/modules, ../../lib))")
(("\\$\\$\\[QT_HOST_LIBS\\]") (("\\$\\$\\[QT_HOST_LIBS\\]")
"$$replace(dir, mkspecs/modules, lib)") "$$clean_path($$replace(dir, mkspecs/modules, ../../lib))")
(("\\$\\$\\[QT_INSTALL_PLUGINS\\]")
"$$replace(dir, mkspecs/modules, plugins)")
(("\\$\\$\\[QT_INSTALL_LIBEXECS\\]")
"$$replace(dir, mkspecs/modules, libexec)")
(("\\$\\$\\[QT_INSTALL_BINS\\]") (("\\$\\$\\[QT_INSTALL_BINS\\]")
"$$replace(dir, mkspecs/modules, bin)") "$$clean_path($$replace(dir, mkspecs/modules, ../../bin))"))
(("\\$\\$\\[QT_INSTALL_IMPORTS\\]")
"$$replace(dir, mkspecs/modules, imports)") ;; Searches Qt tools in the current PATH instead of QT_HOST_BINS.
(("\\$\\$\\[QT_INSTALL_QML\\]") (substitute* (string-append mkspecs "/features/qt_functions.prf")
"$$replace(dir, mkspecs/modules, qml)")) (("cmd = \\$\\$\\[QT_HOST_BINS\\]/\\$\\$2")
"cmd = $$system(which $${2}.pl 2>/dev/null || which $${2})"))
;; Resolve qmake spec files within qtbase by absolute paths.
(substitute*
(map (lambda (file)
(string-append mkspecs "/features/" file))
'("device_config.prf" "moc.prf" "qt_build_config.prf"
"qt_config.prf" "winrt/package_manifest.prf"))
(("\\$\\$\\[QT_HOST_DATA/get\\]") archdata)
(("\\$\\$\\[QT_HOST_DATA/src\\]") archdata))
#t)))))) #t))))))
(native-search-paths (native-search-paths
(list (search-path-specification (list (search-path-specification
(variable "QMAKEPATH") (variable "QMAKEPATH")
(files '(""))) (files '("lib/qt5")))
(search-path-specification (search-path-specification
(variable "QML2_IMPORT_PATH") (variable "QML2_IMPORT_PATH")
(files '("qml"))) (files '("lib/qt5/qml")))
(search-path-specification (search-path-specification
(variable "QT_PLUGIN_PATH") (variable "QT_PLUGIN_PATH")
(files '("plugins"))) (files '("lib/qt5/plugins")))
(search-path-specification (search-path-specification
(variable "XDG_DATA_DIRS") (variable "XDG_DATA_DIRS")
(files '("share"))) (files '("share")))
@ -555,26 +584,51 @@ developers using C++ or QML, a CSS & JavaScript like language.")
(arguments (arguments
`(#:phases `(#:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(replace 'configure (add-before 'configure 'configure-qmake
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
;; Valid QT_BUILD_PARTS variables are:
;; libs tools tests examples demos docs translations
(zero? (system* "qmake" "QT_BUILD_PARTS = libs tools tests"
(string-append "PREFIX=" out))))))
(add-before 'install 'fix-Makefiles
(lambda* (#:key inputs outputs #:allow-other-keys) (lambda* (#:key inputs outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")) (let* ((out (assoc-ref outputs "out"))
(qtbase (assoc-ref inputs "qtbase"))) (qtbase (assoc-ref inputs "qtbase"))
(substitute* (find-files "." "Makefile") (tmpdir (string-append (getenv "TMPDIR")))
(((string-append "INSTALL_ROOT)" qtbase)) (qmake (string-append tmpdir "/qmake"))
(string-append "INSTALL_ROOT)" out))) (qt.conf (string-append tmpdir "/qt.conf")))
;; Use qmake with a customized qt.conf to override install
;; paths to $out.
(symlink (which "qmake") qmake)
(setenv "PATH" (string-append tmpdir ":" (getenv "PATH")))
(with-output-to-file qt.conf
(lambda ()
(format #t "[Paths]
Prefix=~a
ArchData=lib/qt5
Data=share/qt5
Documentation=share/doc/qt5
Headers=include/qt5
Libraries=lib
LibraryExecutables=lib/qt5/libexec
Binaries=bin
Tests=tests
Plugins=lib/qt5/plugins
Imports=lib/qt5/imports
Qml2Imports=lib/qt5/qml
Translations=share/qt5/translations
Settings=etc/xdg
Examples=share/doc/qt5/examples
HostPrefix=~a
HostData=lib/qt5
HostBinaries=bin
HostLibraries=lib
" out out)))
#t))) #t)))
(add-before 'check 'set-display (replace 'configure
(lambda _ (lambda* (#:key inputs outputs #:allow-other-keys)
;; make Qt render "offscreen", required for tests ;; Valid QT_BUILD_PARTS variables are:
(setenv "QT_QPA_PLATFORM" "offscreen") ;; libs tools tests examples demos docs translations
#t))))) (zero? (system* "qmake" "QT_BUILD_PARTS = libs tools tests"))))
(add-before 'check 'set-display
(lambda _
;; make Qt render "offscreen", required for tests
(setenv "QT_QPA_PLATFORM" "offscreen")
#t)))))
(synopsis "Qt module for displaying SVGs") (synopsis "Qt module for displaying SVGs")
(description "The QtSvg module provides classes for displaying the (description "The QtSvg module provides classes for displaying the
contents of SVG files."))) contents of SVG files.")))
@ -853,6 +907,18 @@ set of plugins for interacting with pulseaudio and GStreamer.")))
(snippet (snippet
;; The examples try to build and cause the build to fail ;; The examples try to build and cause the build to fail
'(delete-file-recursively "examples")))) '(delete-file-recursively "examples"))))
(arguments
(substitute-keyword-arguments (package-arguments qtsvg)
((#:phases phases)
`(modify-phases ,phases
(add-before 'check 'set-ld-library-path
;; <https://lists.gnu.org/archive/html/guix-devel/2017-09/msg00019.html>
;;
;; Make the uninstalled libQt5WaylandClient.so.5 available to the
;; wayland platform plugin.
(lambda _
(setenv "LD_LIBRARY_PATH" (string-append (getcwd) "/lib"))
#t))))))
(native-inputs (native-inputs
`(("glib" ,glib) `(("glib" ,glib)
("perl" ,perl) ("perl" ,perl)
@ -1609,8 +1675,10 @@ contain over 620 classes.")
(string-append out "/include")) (string-append out "/include"))
(("\\$\\$\\[QT_INSTALL_TRANSLATIONS\\]") (("\\$\\$\\[QT_INSTALL_TRANSLATIONS\\]")
(string-append out "/translations")) (string-append out "/translations"))
(("\\$\\$\\[QT_INSTALL_DATA\\]") out) (("\\$\\$\\[QT_INSTALL_DATA\\]")
(("\\$\\$\\[QT_HOST_DATA\\]") out)) (string-append out "/lib/qt$${QT_MAJOR_VERSION}"))
(("\\$\\$\\[QT_HOST_DATA\\]")
(string-append out "/lib/qt$${QT_MAJOR_VERSION}")))
(zero? (system* "qmake")))))))) (zero? (system* "qmake"))))))))
(native-inputs `(("qtbase" ,qtbase))) (native-inputs `(("qtbase" ,qtbase)))
(home-page "http://www.riverbankcomputing.co.uk/software/qscintilla/intro") (home-page "http://www.riverbankcomputing.co.uk/software/qscintilla/intro")
@ -1699,7 +1767,8 @@ This package provides the Python bindings.")))
(base32 "0bxi5pfhxdvwk8yxa06lk2d7lcibmfqhahbin82bqf3m341zd4ml")))) (base32 "0bxi5pfhxdvwk8yxa06lk2d7lcibmfqhahbin82bqf3m341zd4ml"))))
(build-system cmake-build-system) (build-system cmake-build-system)
(native-inputs (native-inputs
`(("qttools" ,qttools))) `(("pkg-config" ,pkg-config)
("qttools" ,qttools)))
(inputs (inputs
`(("qtbase" ,qtbase))) `(("qtbase" ,qtbase)))
(arguments (arguments
@ -1742,11 +1811,27 @@ securely. It will not store any data unencrypted unless explicitly requested.")
(modify-phases %standard-phases (modify-phases %standard-phases
(replace 'configure (replace 'configure
(lambda* (#:key outputs #:allow-other-keys) (lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out"))) (let* ((out (assoc-ref outputs "out"))
(docdir (string-append out "/share/doc/qwt"))
(incdir (string-append out "/include/qwt"))
(pluginsdir (string-append out "/lib/qt5/plugins/designer"))
(featuresdir (string-append out "/lib/qt5/mkspecs/features")))
(substitute* '("qwtconfig.pri") (substitute* '("qwtconfig.pri")
(("/usr/local/qwt-\\$\\$QWT\\_VERSION") out)) (("^(\\s*QWT_INSTALL_PREFIX)\\s*=.*" _ x)
(format #f "~a = ~a\n" x out))
(("^(QWT_INSTALL_DOCS)\\s*=.*" _ x)
(format #f "~a = ~a\n" x docdir))
(("^(QWT_INSTALL_HEADERS)\\s*=.*" _ x)
(format #f "~a = ~a\n" x incdir))
(("^(QWT_INSTALL_PLUGINS)\\s*=.*" _ x)
(format #f "~a = ~a\n" x pluginsdir))
(("^(QWT_INSTALL_FEATURES)\\s*=.*" _ x)
(format #f "~a = ~a\n" x featuresdir)))
(substitute* '("doc/doc.pro")
;; We'll install them in the 'install-man-pages' phase.
(("^unix:doc\\.files.*") ""))
(zero? (system* "qmake"))))) (zero? (system* "qmake")))))
(add-after 'install 'install-documentation (add-after 'install 'install-man-pages
(lambda* (#:key outputs #:allow-other-keys) (lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out")) (let* ((out (assoc-ref outputs "out"))
(man (string-append out "/share/man"))) (man (string-append out "/share/man")))
@ -1810,6 +1895,15 @@ different kinds of sliders, and much more.")
(arguments (arguments
`(#:phases `(#:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-before 'configure 'fix-qmlwebkit-plugins-rpath
(lambda _
(substitute* "Source/WebKit/qt/declarative/experimental/experimental.pri"
(("RPATHDIR_RELATIVE_TO_DESTDIR = \\.\\./\\.\\./lib")
"RPATHDIR_RELATIVE_TO_DESTDIR = ../../../../../lib"))
(substitute* "Source/WebKit/qt/declarative/public.pri"
(("RPATHDIR_RELATIVE_TO_DESTDIR = \\.\\./\\.\\./lib")
"RPATHDIR_RELATIVE_TO_DESTDIR = ../../../../lib"))
#t))
(replace 'configure (replace 'configure
(lambda* (#:key outputs #:allow-other-keys) (lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out"))) (let ((out (assoc-ref outputs "out")))

View file

@ -1021,34 +1021,6 @@ Ruby Gems.")
(home-page "http://github.com/rubyzip/rubyzip") (home-page "http://github.com/rubyzip/rubyzip")
(license license:bsd-2))) (license license:bsd-2)))
(define-public ruby-ffi
(package
(name "ruby-ffi")
(version "1.9.18")
(source (origin
(method url-fetch)
(uri (rubygems-uri "ffi" version))
(sha256
(base32
"034f52xf7zcqgbvwbl20jwdyjwznvqnwpbaps9nk18v9lgb1dpx0"))))
(build-system ruby-build-system)
;; FIXME: Before running tests the build system attempts to build libffi
;; from sources.
(arguments `(#:tests? #f))
(native-inputs
`(("ruby-rake-compiler" ,ruby-rake-compiler)
("ruby-rspec" ,ruby-rspec)
("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
(inputs
`(("libffi" ,libffi)))
(synopsis "Ruby foreign function interface library")
(description "Ruby-FFI is a Ruby extension for programmatically loading
dynamic libraries, binding functions within them, and calling those functions
from Ruby code. Moreover, a Ruby-FFI extension works without changes on Ruby
and JRuby.")
(home-page "http://wiki.github.com/ffi/ffi")
(license license:bsd-3)))
(define-public ruby-simplecov-html (define-public ruby-simplecov-html
(package (package
(name "ruby-simplecov-html") (name "ruby-simplecov-html")

View file

@ -403,13 +403,18 @@ directory.")
("xorg-server" ,xorg-server) ("xorg-server" ,xorg-server)
("libjpeg" ,libjpeg))) ("libjpeg" ,libjpeg)))
(inputs (inputs
`(("guile" ,guile-2.0) `(("guile" ,guile-2.2)
("sdl-union" ,(sdl-union)))) ("sdl-union" ,(sdl-union))))
(arguments (arguments
'(#:configure-flags '(#:configure-flags
(list (string-append "--with-sdl-prefix=" (list (string-append "--with-sdl-prefix="
(assoc-ref %build-inputs "sdl-union"))) (assoc-ref %build-inputs "sdl-union")))
#:modules ((ice-9 popen)
(guix build utils)
(guix build gnu-build-system))
#:parallel-build? #f ; parallel build fails #:parallel-build? #f ; parallel build fails
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-before 'configure 'fix-env-and-patch (add-before 'configure 'fix-env-and-patch
@ -418,9 +423,16 @@ directory.")
;; SDL_image needs to dlopen libjpeg in the test suite. ;; SDL_image needs to dlopen libjpeg in the test suite.
(setenv "LD_LIBRARY_PATH" (setenv "LD_LIBRARY_PATH"
(string-append (assoc-ref inputs "libjpeg") "/lib")) (string-append (assoc-ref inputs "libjpeg") "/lib"))
;; Change the site directory /site/2.0 like Guile expects.
;; Change the site directory /site/X.Y like Guile expects.
(substitute* "build-aux/guile-baux/re-prefixed-site-dirs" (substitute* "build-aux/guile-baux/re-prefixed-site-dirs"
(("\"/site\"") "\"/site/2.0\"")) (("\"/site\"")
(let ((effective
(read
(open-pipe* OPEN_READ
"guile" "-c"
"(write (effective-version))"))))
(string-append "\"/site/" effective "\""))))
;; Skip tests that rely on sound support, which is unavailable in ;; Skip tests that rely on sound support, which is unavailable in
;; the build environment. ;; the build environment.
@ -434,6 +446,16 @@ directory.")
(system (format #f "~a/bin/Xvfb :1 &" (system (format #f "~a/bin/Xvfb :1 &"
(assoc-ref inputs "xorg-server"))) (assoc-ref inputs "xorg-server")))
(setenv "DISPLAY" ":1") (setenv "DISPLAY" ":1")
#t))
(add-before 'check 'skip-cursor-test
(lambda _
;; XXX: This test sometimes enters an endless loop, and sometimes
;; crashes with:
;; guile: xcb_io.c:147: append_pending_request: Assertion `!xcb_xlib_unknown_seq_number' failed.
;; Skip it.
(substitute* "test/cursor.scm"
(("\\(SDL:init .*" all)
(string-append "(exit 77) ;" all "\n")))
#t))))) #t)))))
(synopsis "Guile interface for SDL (Simple DirectMedia Layer)") (synopsis "Guile interface for SDL (Simple DirectMedia Layer)")
(description "Guile-SDL is a set of bindings to the Simple DirectMedia (description "Guile-SDL is a set of bindings to the Simple DirectMedia

View file

@ -44,15 +44,15 @@
(define-public ccid (define-public ccid
(package (package
(name "ccid") (name "ccid")
(version "1.4.27") (version "1.4.28")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (string-append
"https://alioth.debian.org/frs/download.php/file/4218/" "https://alioth.debian.org/frs/download.php/file/4230/"
"ccid-" version ".tar.bz2")) "ccid-" version ".tar.bz2"))
(sha256 (sha256
(base32 (base32
"0dyikpmhsph36ndgd61bs4yx437v5y0bmm8ahjacp1k9c1ly4q56")))) "1q5dz1l049m3hmr370adhrqicdkldrr3l98svi02p5cxbnn3cn47"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(arguments (arguments
`(#:configure-flags (list (string-append "--enable-usbdropdir=" %output `(#:configure-flags (list (string-append "--enable-usbdropdir=" %output

View file

@ -7,6 +7,7 @@
;;; Copyright © 2017 Corentin Bocquillon <corentin@nybble.fr> ;;; Copyright © 2017 Corentin Bocquillon <corentin@nybble.fr>
;;; Copyright © 2017 Gregor Giesen <giesen@zaehlwerk.net> ;;; Copyright © 2017 Gregor Giesen <giesen@zaehlwerk.net>
;;; Copyright © 2017 Frederick M. Muriithi <fredmanglis@gmail.com> ;;; Copyright © 2017 Frederick M. Muriithi <fredmanglis@gmail.com>
;;; Copyright © 2017 ng0 <ng0@infotropique.org>
;;; ;;;
;;; This file is part of GNU Guix. ;;; This file is part of GNU Guix.
;;; ;;;
@ -385,3 +386,25 @@ style and key ordering are kept, so you can diff the source.")
(define-public python2-ruamel.yaml (define-public python2-ruamel.yaml
(package-with-python2 python-ruamel.yaml)) (package-with-python2 python-ruamel.yaml))
(define-public python-cbor
(package
(name "python-cbor")
(version "1.0.0")
(source
(origin
(method url-fetch)
(uri (pypi-uri "cbor" version))
(sha256
(base32
"1dmv163cnslyqccrybkxn0c9s1jk1mmafmgxv75iamnz5lk5l8hk"))))
(build-system python-build-system)
(home-page "https://bitbucket.org/bodhisnarkva/cbor")
(synopsis "Implementation of the Concise Binary Object Representation")
(description
"Python-cbor provides an implementation of the Concise Binary Object
Representation (CBOR). CBOR is comparable to JSON, has a superset of JSON's
ability, but serializes to a binary format which is smaller and faster to
generate and parse. The two primary functions are @code{cbor.loads} and
@code{cbor.dumps}.")
(license license:asl2.0)))

View file

@ -1057,6 +1057,32 @@ multidimensional conditioning system and a consistent interface to map data to
aesthetic attributes.") aesthetic attributes.")
(license license:gpl2+))) (license license:gpl2+)))
(define-public r-ggdendro
(package
(name "r-ggdendro")
(version "0.1-20")
(source (origin
(method url-fetch)
(uri (cran-uri "ggdendro" version))
(sha256
(base32
"1zzq1hxd0d1qa5hrzwfkdw6fzscpcafbwbpkrb62dm559y8awp0j"))))
(build-system r-build-system)
(propagated-inputs
`(("r-ggplot2" ,r-ggplot2)
("r-mass" ,r-mass)
("r-knitr" ,r-knitr)))
(home-page "https://github.com/andrie/ggdendro")
(synopsis "Create Dendrograms and Tree Diagrams Using ggplot2")
(description "This is a set of tools for dendrograms and tree plots using
ggplot2. The ggplot2 philosophy is to clearly separate data from the
presentation. Unfortunately the plot method for dendrograms plots directly
to a plot device with out exposing the data. The ggdendro package resolves
this by making available functions that extract the dendrogram plot data.
The package provides implementations for tree, rpart, as well as diana and
agnes cluster diagrams.")
(license license:gpl2+)))
(define-public r-gdtools (define-public r-gdtools
(package (package
(name "r-gdtools") (name "r-gdtools")

1821
gnu/packages/syncthing.scm Normal file

File diff suppressed because it is too large Load diff

View file

@ -34,7 +34,7 @@
(define-public tmux (define-public tmux
(package (package
(name "tmux") (name "tmux")
(version "2.5") (version "2.6")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri (string-append
@ -42,7 +42,7 @@
version "/tmux-" version ".tar.gz")) version "/tmux-" version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"1pwm5nqm3by8452h6gll0sl3646rjdga7qw419svgxhvgk1mw4xf")))) "1s6pgk63ar1swpvhs8r5fk26vav3ybsf2ll7d705hysdm5qd2z5i"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(inputs (inputs
`(("libevent" ,libevent) `(("libevent" ,libevent)

View file

@ -1115,7 +1115,7 @@ access to mpv's powerful playback capabilities.")
(define-public youtube-dl (define-public youtube-dl
(package (package
(name "youtube-dl") (name "youtube-dl")
(version "2017.10.07") (version "2017.10.15.1")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "https://yt-dl.org/downloads/" (uri (string-append "https://yt-dl.org/downloads/"
@ -1123,7 +1123,7 @@ access to mpv's powerful playback capabilities.")
version ".tar.gz")) version ".tar.gz"))
(sha256 (sha256
(base32 (base32
"10xs3d3ksfhalmvacpw2drkzi84y3rgy2jjr0wrzmqn1hx897a6r")))) "0zr9sx0nxk36si8xbvhlnazb69xzlygrhsxcyiydm0dy5y5ycsns"))))
(build-system python-build-system) (build-system python-build-system)
(arguments (arguments
;; The problem here is that the directory for the man page and completion ;; The problem here is that the directory for the man page and completion

View file

@ -5365,3 +5365,22 @@ file links.")
file upload, download, on-screen display, namespace operations (move/copy), file upload, download, on-screen display, namespace operations (move/copy),
collection creation and deletion, and locking operations.") collection creation and deletion, and locking operations.")
(license l:gpl2))) (license l:gpl2)))
(define-public python-py-ubjson
(package
(name "python-py-ubjson")
(version "0.10.0")
(source
(origin
(method url-fetch)
(uri (pypi-uri "py-ubjson" version))
(sha256
(base32
"03l9m9w5ip4hw0y69wlys5gzsfb7zcq3a77blj88grgiqhn5vm5n"))))
(build-system python-build-system)
(home-page "https://github.com/Iotic-Labs/py-ubjson")
(synopsis "Universal Binary JSON encoder/decoder")
(description
"Py-ubjson is a Python module providing an Universal Binary JSON
encoder/decoder based on the draft-12 specification for UBJSON.")
(license l:asl2.0)))

View file

@ -138,7 +138,7 @@
(string-append "SHELL=" (which "bash")) (string-append "SHELL=" (which "bash"))
(string-append "--prefix=" out))) (string-append "--prefix=" out)))
(zero? (system* "make" "install")))))))))) (zero? (system* "make" "install"))))))))))
(home-page "http://www.x.org") (home-page "https://www.x.org/")
(synopsis "Source code configuration and build system") (synopsis "Source code configuration and build system")
(description (description
"Imake is a deprecated source code configuration and build system which "Imake is a deprecated source code configuration and build system which
@ -167,7 +167,7 @@ autotools system.")
`(("pkg-config" ,pkg-config))) `(("pkg-config" ,pkg-config)))
(inputs (inputs
`(("xproto" ,xproto))) `(("xproto" ,xproto)))
(home-page "http://www.x.org") (home-page "https://www.x.org/")
(synopsis "Symlink directory into tree") (synopsis "Symlink directory into tree")
(description "Create a shadow directory of symbolic links to another (description "Create a shadow directory of symbolic links to another
directory tree.") directory tree.")
@ -1037,7 +1037,7 @@ of new capabilities and controls for text keyboards.")
(build-system gnu-build-system) (build-system gnu-build-system)
(native-inputs `(("pkg-config" ,pkg-config))) (native-inputs `(("pkg-config" ,pkg-config)))
(inputs `(("xproto" ,xproto))) (inputs `(("xproto" ,xproto)))
(home-page "http://xorg.freedesktop.org") (home-page "https://www.x.org/")
(synopsis "Xorg shared memory fences library") (synopsis "Xorg shared memory fences library")
(description (description
"This library provides an interface to shared-memory fences for "This library provides an interface to shared-memory fences for
@ -4454,7 +4454,7 @@ formatted dump file, such as produced by xwd.")
`(("xproto" ,xproto))) `(("xproto" ,xproto)))
(native-inputs (native-inputs
`(("pkg-config" ,pkg-config))) `(("pkg-config" ,pkg-config)))
(home-page "http://www.x.org/wiki/") (home-page "https://www.x.org/wiki/")
(synopsis "X color name database") (synopsis "X color name database")
(description (description
"This package provides the X color name database.") "This package provides the X color name database.")
@ -5070,7 +5070,7 @@ over Xlib, including:
(define-public xorg-server (define-public xorg-server
(package (package
(name "xorg-server") (name "xorg-server")
(version "1.19.4") (version "1.19.5")
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
@ -5079,7 +5079,7 @@ over Xlib, including:
name "-" version ".tar.bz2")) name "-" version ".tar.bz2"))
(sha256 (sha256
(base32 (base32
"1a690fzv5l5ks45g9zhlzdskdq8q73mcbpb9a3wz3shxm778lxda")) "0iql4pgsgpyqcrd3256pv227cdadvz01ych61n0d41ixp67gmzqq"))
(patches (patches
(list (list
;; See: ;; See:
@ -5205,20 +5205,23 @@ draggable titlebars and borders.")
(license license:x11))) (license license:x11)))
;; This package is intended to be used when building GTK+. ;; This package is intended to be used when building GTK+.
;; Note: It's currently marked as "hidden" to avoid having two non-eq?
;; packages with the same name and version.
(define-public xorg-server-1.19.3 (define-public xorg-server-1.19.3
(package (hidden-package
(inherit xorg-server) (package
(name "xorg-server") (inherit xorg-server)
(version "1.19.3") (name "xorg-server")
(source (version "1.19.3")
(origin (source
(method url-fetch) (origin
(uri (string-append (method url-fetch)
"mirror://xorg/individual/xserver/" (uri (string-append
name "-" version ".tar.bz2")) "mirror://xorg/individual/xserver/"
(sha256 name "-" version ".tar.bz2"))
(base32 (sha256
"162s1v901djr57gxmmk4airk8hiwcz79dqyz72972x1lw1k82yk7")))))) (base32
"162s1v901djr57gxmmk4airk8hiwcz79dqyz72972x1lw1k82yk7")))))))
(define-public xorg-server-xwayland (define-public xorg-server-xwayland
(package (package
@ -5630,7 +5633,7 @@ The XCB util-wm module provides the following libraries:
`(("pkg-config" ,pkg-config))) `(("pkg-config" ,pkg-config)))
(propagated-inputs (propagated-inputs
`(("xauth" ,xauth))) `(("xauth" ,xauth)))
(home-page "http://x.org") (home-page "https://www.x.org/")
(synopsis "Commands to start the X Window server") (synopsis "Commands to start the X Window server")
(description (description
"The xinit program is used to start the X Window System server and a "The xinit program is used to start the X Window System server and a
@ -5764,7 +5767,7 @@ to answer a question. Xmessage can also exit after a specified time.")
("libXt" ,libxt) ("libXt" ,libxt)
("xproto" ,xproto) ("xproto" ,xproto)
("libXaw" ,libxaw))) ("libXaw" ,libxaw)))
(home-page "http://invisible-island.net/xterm") (home-page "http://invisible-island.net/xterm/")
(synopsis "Terminal emulator for the X Window System") (synopsis "Terminal emulator for the X Window System")
(description (description
"The xterm program is a terminal emulator for the X Window System. It "The xterm program is a terminal emulator for the X Window System. It

View file

@ -368,6 +368,12 @@ boot."
#t)))) #t))))
;; Ignore I/O errors so the system can boot. ;; Ignore I/O errors so the system can boot.
(fail-safe (fail-safe
;; Remove stale Shadow lock files as they would lead to
;; failures of 'useradd' & co.
(delete-file "/etc/group.lock")
(delete-file "/etc/passwd.lock")
(delete-file "/etc/.pwd.lock") ;from 'lckpwdf'
(delete-file-recursively "/tmp") (delete-file-recursively "/tmp")
(delete-file-recursively "/var/run") (delete-file-recursively "/var/run")
(mkdir "/tmp") (mkdir "/tmp")

View file

@ -307,7 +307,8 @@ FILE-SYSTEM."
'#$packages)))) '#$packages))))
(lambda () (lambda ()
(mount-file-system (mount-file-system
'#$(file-system->spec file-system) (spec->file-system
'#$(file-system->spec file-system))
#:root "/")) #:root "/"))
(lambda () (lambda ()
(setenv "PATH" $PATH))) (setenv "PATH" $PATH)))
@ -322,9 +323,10 @@ FILE-SYSTEM."
(umount #$target) (umount #$target)
#f)) #f))
;; We need an additional module. ;; We need additional modules.
(modules `(((gnu build file-systems) (modules `(((gnu build file-systems)
#:select (mount-file-system)) #:select (mount-file-system))
(gnu system file-systems)
,@%default-modules))))))) ,@%default-modules)))))))
(define (file-system-shepherd-services file-systems) (define (file-system-shepherd-services file-systems)

View file

@ -780,15 +780,23 @@ accountsservice web site} for more information."
gnome-desktop-configuration gnome-desktop-configuration
(gnome-package gnome-package (default gnome))) (gnome-package gnome-package (default gnome)))
(define (gnome-polkit-settings config)
"Return the list of GNOME dependencies that provide polkit actions and
rules."
(let ((gnome (gnome-package config)))
(map (lambda (name)
((package-direct-input-selector name) gnome))
'("gnome-settings-daemon"
"gnome-control-center"
"gnome-system-monitor"
"gvfs"))))
(define gnome-desktop-service-type (define gnome-desktop-service-type
(service-type (service-type
(name 'gnome-desktop) (name 'gnome-desktop)
(extensions (extensions
(list (service-extension polkit-service-type (list (service-extension polkit-service-type
(compose list gnome-polkit-settings)
(package-direct-input-selector
"gnome-settings-daemon")
gnome-package))
(service-extension profile-service-type (service-extension profile-service-type
(compose list (compose list
gnome-package)))))) gnome-package))))))

View file

@ -17,16 +17,16 @@
(bootloader grub-efi-bootloader) (bootloader grub-efi-bootloader)
(target "/boot/efi"))) (target "/boot/efi")))
;; Assume the target root file system is labelled "my-root". ;; Assume the target root file system is labelled "my-root",
;; and the EFI System Partition has UUID 1234-ABCD.
(file-systems (cons* (file-system (file-systems (cons* (file-system
(device "my-root") (device "my-root")
(title 'label) (title 'label)
(mount-point "/") (mount-point "/")
(type "ext4")) (type "ext4"))
(file-system (file-system
;; Specify partition here since FAT (device (uuid "1234-ABCD" 'fat))
;; labels are currently unsupported. (title 'uuid)
(device "/dev/sda1")
(mount-point "/boot/efi") (mount-point "/boot/efi")
(type "vfat")) (type "vfat"))
%base-file-systems)) %base-file-systems))

View file

@ -18,6 +18,7 @@
(define-module (gnu system file-systems) (define-module (gnu system file-systems)
#:use-module (ice-9 match) #:use-module (ice-9 match)
#:use-module (rnrs bytevectors)
#:use-module (srfi srfi-1) #:use-module (srfi srfi-1)
#:use-module (guix records) #:use-module (guix records)
#:use-module (gnu system uuid) #:use-module (gnu system uuid)
@ -161,7 +162,7 @@ initrd code."
(match fs (match fs
(($ <file-system> device title mount-point type flags options _ _ check?) (($ <file-system> device title mount-point type flags options _ _ check?)
(list (if (uuid? device) (list (if (uuid? device)
(uuid-bytevector device) `(uuid ,(uuid-type device) ,(uuid-bytevector device))
device) device)
title mount-point type flags options check?)))) title mount-point type flags options check?))))
@ -170,7 +171,12 @@ initrd code."
(match sexp (match sexp
((device title mount-point type flags options check?) ((device title mount-point type flags options check?)
(file-system (file-system
(device device) (title title) (device (match device
(('uuid (? symbol? type) (? bytevector? bv))
(bytevector->uuid bv type))
(_
device)))
(title title)
(mount-point mount-point) (type type) (mount-point mount-point) (type type)
(flags flags) (options options) (flags flags) (options options)
(check? check?))))) (check? check?)))))

View file

@ -187,9 +187,11 @@ to it are lost."
'((gnu build linux-boot) '((gnu build linux-boot)
(guix build utils) (guix build utils)
(guix build bournish) (guix build bournish)
(gnu system file-systems)
(gnu build file-systems))) (gnu build file-systems)))
#~(begin #~(begin
(use-modules (gnu build linux-boot) (use-modules (gnu build linux-boot)
(gnu system file-systems)
(guix build utils) (guix build utils)
(guix build bournish) ;add the 'bournish' meta-command (guix build bournish) ;add the 'bournish' meta-command
(srfi srfi-26) (srfi srfi-26)
@ -206,7 +208,9 @@ to it are lost."
(set-path-environment-variable "PATH" '("bin" "sbin") (set-path-environment-variable "PATH" '("bin" "sbin")
'#$helper-packages))) '#$helper-packages)))
(boot-system #:mounts '#$(map file-system->spec file-systems) (boot-system #:mounts
(map spec->file-system
'#$(map file-system->spec file-systems))
#:pre-mount (lambda () #:pre-mount (lambda ()
(and #$@device-mapping-commands)) (and #$@device-mapping-commands))
#:linux-modules '#$linux-modules #:linux-modules '#$linux-modules

View file

@ -42,7 +42,7 @@
string->ext3-uuid string->ext3-uuid
string->ext4-uuid string->ext4-uuid
string->btrfs-uuid string->btrfs-uuid
string->fat32-uuid string->fat-uuid
iso9660-uuid->string iso9660-uuid->string
;; XXX: For lack of a better place. ;; XXX: For lack of a better place.
@ -164,25 +164,25 @@ ISO9660 UUID representation."
;;; ;;;
;;; FAT32. ;;; FAT32/FAT16.
;;; ;;;
(define-syntax %fat32-endianness (define-syntax %fat-endianness
;; Endianness of FAT file systems. ;; Endianness of FAT32/FAT16 file systems.
(identifier-syntax (endianness little))) (identifier-syntax (endianness little)))
(define (fat32-uuid->string uuid) (define (fat-uuid->string uuid)
"Convert fat32 UUID, a 4-byte bytevector, to its string representation." "Convert FAT32/FAT16 UUID, a 4-byte bytevector, to its string representation."
(let ((high (bytevector-uint-ref uuid 0 %fat32-endianness 2)) (let ((high (bytevector-uint-ref uuid 0 %fat-endianness 2))
(low (bytevector-uint-ref uuid 2 %fat32-endianness 2))) (low (bytevector-uint-ref uuid 2 %fat-endianness 2)))
(format #f "~:@(~x-~x~)" low high))) (format #f "~:@(~x-~x~)" low high)))
(define %fat32-uuid-rx (define %fat-uuid-rx
(make-regexp "^([[:xdigit:]]{4})-([[:xdigit:]]{4})$")) (make-regexp "^([[:xdigit:]]{4})-([[:xdigit:]]{4})$"))
(define (string->fat32-uuid str) (define (string->fat-uuid str)
"Parse STR, which is in FAT32 format, and return a bytevector or #f." "Parse STR, which is in FAT32/FAT16 format, and return a bytevector or #f."
(match (regexp-exec %fat32-uuid-rx str) (match (regexp-exec %fat-uuid-rx str)
(#f (#f
#f) #f)
(rx-match (rx-match
@ -190,7 +190,7 @@ ISO9660 UUID representation."
(match:substring rx-match 2) 16) (match:substring rx-match 2) 16)
(string->number (string->number
(match:substring rx-match 1) 16)) (match:substring rx-match 1) 16))
%fat32-endianness %fat-endianness
2)))) 2))))
@ -216,14 +216,14 @@ ISO9660 UUID representation."
(define %uuid-parsers (define %uuid-parsers
(vhashq (vhashq
('dce 'ext2 'ext3 'ext4 'btrfs 'luks => string->dce-uuid) ('dce 'ext2 'ext3 'ext4 'btrfs 'luks => string->dce-uuid)
('fat32 'fat => string->fat32-uuid) ('fat32 'fat16 'fat => string->fat-uuid)
('iso9660 => string->iso9660-uuid))) ('iso9660 => string->iso9660-uuid)))
(define %uuid-printers (define %uuid-printers
(vhashq (vhashq
('dce 'ext2 'ext3 'ext4 'btrfs 'luks => dce-uuid->string) ('dce 'ext2 'ext3 'ext4 'btrfs 'luks => dce-uuid->string)
('iso9660 => iso9660-uuid->string) ('iso9660 => iso9660-uuid->string)
('fat32 'fat => fat32-uuid->string))) ('fat32 'fat16 'fat => fat-uuid->string)))
(define* (string->uuid str #:optional (type 'dce)) (define* (string->uuid str #:optional (type 'dce))
"Parse STR as a UUID of the given TYPE. On success, return the "Parse STR as a UUID of the given TYPE. On success, return the

132
guix/build-system/go.scm Normal file
View file

@ -0,0 +1,132 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2016 Petter <petter@mykolab.ch>
;;; Copyright © 2017 Leo Famulari <leo@famulari.name>
;;;
;;; 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 (guix build-system go)
#:use-module (guix utils)
#:use-module (guix derivations)
#:use-module (guix search-paths)
#:use-module (guix build-system)
#:use-module (guix build-system gnu)
#:use-module (guix packages)
#:use-module (ice-9 match)
#:export (%go-build-system-modules
go-build
go-build-system))
;; Commentary:
;;
;; Standard build procedure for packages using the Go build system. It is
;; implemented as an extension of 'gnu-build-system'.
;;
;; Code:
(define %go-build-system-modules
;; Build-side modules imported and used by default.
`((guix build go-build-system)
,@%gnu-build-system-modules))
(define (default-go)
;; Lazily resolve the binding to avoid a circular dependency.
(let ((go (resolve-interface '(gnu packages golang))))
(module-ref go 'go)))
(define* (lower name
#:key source inputs native-inputs outputs system target
(go (default-go))
#:allow-other-keys
#:rest arguments)
"Return a bag for NAME."
(define private-keywords
'(#:source #:target #:go #:inputs #:native-inputs))
(and (not target) ;XXX: no cross-compilation
(bag
(name name)
(system system)
(host-inputs `(,@(if source
`(("source" ,source))
'())
,@inputs
;; Keep the standard inputs of 'gnu-build-system'.
,@(standard-packages)))
(build-inputs `(("go" ,go)
,@native-inputs))
(outputs outputs)
(build go-build)
(arguments (strip-keyword-arguments private-keywords arguments)))))
(define* (go-build store name inputs
#:key
(phases '(@ (guix build go-build-system)
%standard-phases))
(outputs '("out"))
(search-paths '())
(import-path "")
(unpack-path "")
(tests? #t)
(system (%current-system))
(guile #f)
(imported-modules %go-build-system-modules)
(modules '((guix build go-build-system)
(guix build utils))))
(define builder
`(begin
(use-modules ,@modules)
(go-build #:name ,name
#:source ,(match (assoc-ref inputs "source")
(((? derivation? source))
(derivation->output-path source))
((source)
source)
(source
source))
#:system ,system
#:phases ,phases
#:outputs %outputs
#:search-paths ',(map search-path-specification->sexp
search-paths)
#:import-path ,import-path
#:unpack-path ,unpack-path
#:tests? ,tests?
#:inputs %build-inputs)))
(define guile-for-build
(match guile
((? package?)
(package-derivation store guile system #:graft? #f))
(#f ; the default
(let* ((distro (resolve-interface '(gnu packages commencement)))
(guile (module-ref distro 'guile-final)))
(package-derivation store guile system
#:graft? #f)))))
(build-expression->derivation store name builder
#:inputs inputs
#:system system
#:modules imported-modules
#:outputs outputs
#:guile-for-build guile-for-build))
(define go-build-system
(build-system
(name 'go)
(description
"Build system for Go programs")
(lower lower)))

View file

@ -92,8 +92,12 @@ store in '.el' files."
(el-dir (string-append out %install-suffix "/" elpa-name-ver)) (el-dir (string-append out %install-suffix "/" elpa-name-ver))
(substitute-cmd (lambda () (substitute-cmd (lambda ()
(substitute* (find-files "." "\\.el$") (substitute* (find-files "." "\\.el$")
(("\"/bin/([^.].*)\"" _ cmd) (("\"/bin/([^.]\\S*)\"" _ cmd-name)
(string-append "\"" (which cmd) "\"")))))) (let ((cmd (which cmd-name)))
(unless cmd
(error
"patch-el-files: unable to locate " cmd-name))
(string-append "\"" cmd "\"")))))))
(with-directory-excursion el-dir (with-directory-excursion el-dir
;; Some old '.el' files (e.g., tex-buf.el in AUCTeX) are still encoded ;; Some old '.el' files (e.g., tex-buf.el in AUCTeX) are still encoded
;; with the "ISO-8859-1" locale. ;; with the "ISO-8859-1" locale.

View file

@ -0,0 +1,217 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2016 Petter <petter@mykolab.ch>
;;; Copyright © 2017 Leo Famulari <leo@famulari.name>
;;;
;;; 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 (guix build go-build-system)
#:use-module ((guix build gnu-build-system) #:prefix gnu:)
#:use-module (guix build utils)
#:use-module (ice-9 match)
#:use-module (srfi srfi-1)
#:export (%standard-phases
go-build))
;; Commentary:
;;
;; Build procedures for Go packages. This is the builder-side code.
;;
;; Software written in Go is either a 'package' (i.e. library) or 'command'
;; (i.e. executable). Both types can be built with either the `go build` or `go
;; install` commands. However, `go build` discards the result of the build
;; process for Go libraries, so we use `go install`, which preserves the
;; results. [0]
;; Go software is developed and built within a particular filesystem hierarchy
;; structure called a 'workspace' [1]. This workspace is found by Go
;; via the GOPATH environment variable. Typically, all Go source code
;; and compiled objects are kept in a single workspace, but it is
;; possible for GOPATH to contain a list of directories, and that is
;; what we do in this go-build-system. [2]
;;
;; Go software, whether a package or a command, is uniquely named using
;; an 'import path'. The import path is based on the URL of the
;; software's source. Since most source code is provided over the
;; internet, the import path is typically a combination of the remote
;; URL and the source repository's filesystem structure. For example,
;; the Go port of the common `du` command is hosted on github.com, at
;; <https://github.com/calmh/du>. Thus, the import path is
;; <github.com/calmh/du>. [3]
;;
;; It may be possible to programatically guess a package's import path
;; based on the source URL, but we don't try that in this revision of
;; the go-build-system.
;;
;; Modules of modular Go libraries are named uniquely with their
;; filesystem paths. For example, the supplemental but "standardized"
;; libraries developed by the Go upstream developers are available at
;; <https://golang.org/x/{net,text,crypto, et cetera}>. The Go IPv4
;; library's import path is <golang.org/x/net/ipv4>. The source of
;; such modular libraries must be unpacked at the top-level of the
;; filesystem structure of the library. So the IPv4 library should be
;; unpacked to <golang.org/x/net>. This is handled in the
;; go-build-system with the optional #:unpack-path key.
;;
;; In general, Go software is built using a standardized build mechanism
;; that does not require any build scripts like Makefiles. This means
;; that all modules of modular libraries cannot be built with a single
;; command. Each module must be built individually. This complicates
;; certain cases, and these issues are currently resolved by creating a
;; filesystem union of the required modules of such libraries. I think
;; this could be improved in future revisions of the go-build-system.
;;
;; [0] `go build`:
;; https://golang.org/cmd/go/#hdr-Compile_packages_and_dependencies
;; `go install`:
;; https://golang.org/cmd/go/#hdr-Compile_and_install_packages_and_dependencies
;; [1] Go workspace example, from <https://golang.org/doc/code.html#Workspaces>:
;; bin/
;; hello # command executable
;; outyet # command executable
;; pkg/
;; linux_amd64/
;; github.com/golang/example/
;; stringutil.a # package object
;; src/
;; github.com/golang/example/
;; .git/ # Git repository metadata
;; hello/
;; hello.go # command source
;; outyet/
;; main.go # command source
;; main_test.go # test source
;; stringutil/
;; reverse.go # package source
;; reverse_test.go # test source
;; golang.org/x/image/
;; .git/ # Git repository metadata
;; bmp/
;; reader.go # package source
;; writer.go # package source
;; ... (many more repositories and packages omitted) ...
;;
;; [2] https://golang.org/doc/code.html#GOPATH
;; [3] https://golang.org/doc/code.html#ImportPaths
;;
;; Code:
(define* (unpack #:key source import-path unpack-path #:allow-other-keys)
"Unpack SOURCE in the UNPACK-PATH, or the IMPORT-PATH is the UNPACK-PATH is
unset. When SOURCE is a directory, copy it instead of unpacking."
(if (string-null? import-path)
((display "WARNING: The Go import path is unset.\n")))
(if (string-null? unpack-path)
(set! unpack-path import-path))
(mkdir "src")
(let ((dest (string-append "src/" unpack-path)))
(mkdir-p dest)
(if (file-is-directory? source)
(begin
(copy-recursively source dest #:keep-mtime? #t)
#t)
(if (string-suffix? ".zip" source)
(zero? (system* "unzip" "-d" dest source))
(zero? (system* "tar" "-C" dest "-xvf" source))))))
(define* (install-source #:key outputs #:allow-other-keys)
"Install the source code to the output directory."
(let* ((out (assoc-ref outputs "out"))
(source "src")
(dest (string-append out "/" source)))
(copy-recursively source dest #:keep-mtime? #t)
#t))
(define (go-package? name)
(string-prefix? "go-" name))
(define (go-inputs inputs)
"Return the alist of INPUTS that are Go software."
;; XXX This should not check the file name of the store item. Instead we
;; should pass, from the host side, the list of inputs that are packages using
;; the go-build-system.
(alist-delete "go" ; Exclude the Go compiler
(alist-delete "source" ; Exclude the source code of the package being built
(filter (match-lambda
((label . directory)
(go-package? ((compose package-name->name+version
strip-store-file-name)
directory)))
(_ #f))
inputs))))
(define* (setup-environment #:key inputs outputs #:allow-other-keys)
"Export the variables GOPATH and GOBIN, which are based on INPUTS and OUTPUTS,
respectively."
(let ((out (assoc-ref outputs "out")))
;; GOPATH is where Go looks for the source code of the build's dependencies.
(set-path-environment-variable "GOPATH"
;; XXX Matching "." hints that we could do
;; something simpler here...
(list ".")
(match (go-inputs inputs)
(((_ . dir) ...)
dir)))
;; Add the source code of the package being built to GOPATH.
(if (getenv "GOPATH")
(setenv "GOPATH" (string-append (getcwd) ":" (getenv "GOPATH")))
(setenv "GOPATH" (getcwd)))
;; Where to install compiled executable files ('commands' in Go parlance').
(setenv "GOBIN" out)
#t))
(define* (build #:key import-path #:allow-other-keys)
"Build the package named by IMPORT-PATH."
(or
(zero? (system* "go" "install"
"-v" ; print the name of packages as they are compiled
"-x" ; print each command as it is invoked
import-path))
(begin
(display (string-append "Building '" import-path "' failed.\n"
"Here are the results of `go env`:\n"))
(system* "go" "env")
#f)))
(define* (check #:key tests? import-path #:allow-other-keys)
"Run the tests for the package named by IMPORT-PATH."
(if tests?
(zero? (system* "go" "test" import-path))))
(define* (install #:key outputs #:allow-other-keys)
"Install the compiled libraries. `go install` installs these files to
$GOPATH/pkg, so we have to copy them into the output direcotry manually.
Compiled executable files should have already been installed to the store based
on $GOBIN in the build phase."
(when (file-exists? "pkg")
(copy-recursively "pkg" (string-append (assoc-ref outputs "out") "/pkg")))
#t)
(define %standard-phases
(modify-phases gnu:%standard-phases
(delete 'configure)
(delete 'patch-generated-file-shebangs)
(replace 'unpack unpack)
(add-after 'unpack 'install-source install-source)
(add-before 'build 'setup-environment setup-environment)
(replace 'build build)
(replace 'check check)
(replace 'install install)))
(define* (go-build #:key inputs (phases %standard-phases)
#:allow-other-keys #:rest args)
"Build the given Go package, applying all of PHASES in order."
(apply gnu:gnu-build #:inputs inputs #:phases phases args))

View file

@ -38,7 +38,6 @@
#:use-module (guix packages) #:use-module (guix packages)
#:use-module (guix upstream) #:use-module (guix upstream)
#:use-module (guix derivations) #:use-module (guix derivations)
#:use-module (gnu packages perl)
#:export (cpan->guix-package #:export (cpan->guix-package
%cpan-updater)) %cpan-updater))
@ -133,21 +132,28 @@ or #f on failure. MODULE should be e.g. \"Test::Script\""
(number->string version)) (number->string version))
(version version))) (version version)))
(define (perl-package)
"Return the 'perl' package. This is a lazy reference so that we don't
depend on (gnu packages perl)."
(module-ref (resolve-interface '(gnu packages perl)) 'perl))
(define %corelist (define %corelist
(delay (delay
(let* ((perl (with-store store (let* ((perl (with-store store
(derivation->output-path (derivation->output-path
(package-derivation store perl)))) (package-derivation store (perl-package)))))
(core (string-append perl "/bin/corelist"))) (core (string-append perl "/bin/corelist")))
(and (access? core X_OK) (and (access? core X_OK)
core)))) core))))
(define core-module? (define core-module?
(let ((perl-version (package-version perl)) (let ((rx (make-regexp
(rx (make-regexp
(string-append "released with perl v?([0-9\\.]*)" (string-append "released with perl v?([0-9\\.]*)"
"(.*and removed from v?([0-9\\.]*))?")))) "(.*and removed from v?([0-9\\.]*))?"))))
(lambda (name) (lambda (name)
(define perl-version
(package-version (perl-package)))
(define (version-between? lower version upper) (define (version-between? lower version upper)
(and (version>=? version lower) (and (version>=? version lower)
(or (not upper) (or (not upper)

View file

@ -44,7 +44,6 @@
#:use-module (guix upstream) #:use-module (guix upstream)
#:use-module ((guix licenses) #:prefix license:) #:use-module ((guix licenses) #:prefix license:)
#:use-module (guix build-system python) #:use-module (guix build-system python)
#:use-module (gnu packages python)
#:export (guix-package->pypi-name #:export (guix-package->pypi-name
pypi->guix-package pypi->guix-package
%pypi-updater)) %pypi-updater))

View file

@ -414,8 +414,7 @@ for connections to complete; when TIMEOUT is #f, wait as long as needed."
(close-connection port)))) (close-connection port))))
(case (response-code response) (case (response-code response)
((301 ; moved permanently ((302 ; found (redirection)
302 ; found (redirection)
303 ; see other 303 ; see other
307 ; temporary redirection 307 ; temporary redirection
308) ; permanent redirection 308) ; permanent redirection
@ -423,6 +422,22 @@ for connections to complete; when TIMEOUT is #f, wait as long as needed."
(if (or (not location) (member location visited)) (if (or (not location) (member location visited))
(values 'http-response response) (values 'http-response response)
(loop location (cons location visited))))) ;follow the redirect (loop location (cons location visited))))) ;follow the redirect
((301) ; moved permanently
(let ((location (response-location response)))
;; Return RESPONSE, unless the final response as we follow
;; redirects is not 200.
(if location
(let-values (((status response2)
(loop location (cons location visited))))
(case status
((http-response)
(values 'http-response
(if (= 200 (response-code response2))
response
response2)))
(else
(values status response2))))
(values 'http-response response)))) ;invalid redirect
(else (else
(values 'http-response response))))) (values 'http-response response)))))
(lambda (key . args) (lambda (key . args)
@ -474,31 +489,46 @@ warning for PACKAGE mentionning the FIELD."
(probe-uri uri #:timeout 3))) ;wait at most 3 seconds (probe-uri uri #:timeout 3))) ;wait at most 3 seconds
(case status (case status
((http-response) ((http-response)
(if (= 200 (response-code argument)) (cond ((= 200 (response-code argument))
(match (response-content-length argument) (match (response-content-length argument)
((? number? length) ((? number? length)
;; As of July 2016, SourceForge returns 200 (instead of 404) ;; As of July 2016, SourceForge returns 200 (instead of 404)
;; with a small HTML page upon failure. Attempt to detect such ;; with a small HTML page upon failure. Attempt to detect
;; malicious behavior. ;; such malicious behavior.
(or (> length 1000) (or (> length 1000)
(begin
(emit-warning package
(format #f
(G_ "URI ~a returned \
suspiciously small file (~a bytes)")
(uri->string uri)
length))
#f)))
(_ #t)))
((= 301 (response-code argument))
(if (response-location argument)
(begin (begin
(emit-warning package (emit-warning package
(format #f (format #f (G_ "permanent redirect from ~a to ~a")
(G_ "URI ~a returned \
suspiciously small file (~a bytes)")
(uri->string uri) (uri->string uri)
length)) (uri->string
(response-location argument))))
#t)
(begin
(emit-warning package
(format #f (G_ "invalid permanent redirect \
from ~a")
(uri->string uri)))
#f))) #f)))
(_ #t)) (else
(begin (emit-warning package
(emit-warning package (format #f
(format #f (G_ "URI ~a not reachable: ~a (~s)")
(G_ "URI ~a not reachable: ~a (~s)") (uri->string uri)
(uri->string uri) (response-code argument)
(response-code argument) (response-reason-phrase argument))
(response-reason-phrase argument)) field)
field) #f)))
#f)))
((ftp-response) ((ftp-response)
(match argument (match argument
(('ok) #t) (('ok) #t)
@ -534,7 +564,7 @@ suspiciously small file (~a bytes)")
((invalid-http-response gnutls-error) ((invalid-http-response gnutls-error)
;; Probably a misbehaving server; ignore. ;; Probably a misbehaving server; ignore.
#f) #f)
((unknown-protocol) ;nothing we can do ((unknown-protocol) ;nothing we can do
#f) #f)
(else (else
(error "internal linter error" status))))) (error "internal linter error" status)))))

View file

@ -428,6 +428,23 @@ allowed on MACHINE. Return +∞ if MACHINE is unreachable."
"Return the name of the file used as a lock when choosing a build machine." "Return the name of the file used as a lock when choosing a build machine."
(string-append %state-directory "/offload/machine-choice.lock")) (string-append %state-directory "/offload/machine-choice.lock"))
(define (random-seed)
(logxor (getpid) (car (gettimeofday))))
(define shuffle
(let ((state (seed->random-state (random-seed))))
(lambda (lst)
"Return LST shuffled (using the Fisher-Yates algorithm.)"
(define vec (list->vector lst))
(let loop ((result '())
(i (vector-length vec)))
(if (zero? i)
result
(let* ((j (random i state))
(val (vector-ref vec j)))
(vector-set! vec j (vector-ref vec (- i 1)))
(loop (cons val result) (- i 1))))))))
(define (choose-build-machine machines) (define (choose-build-machine machines)
"Return two values: the best machine among MACHINES and its build "Return two values: the best machine among MACHINES and its build
slot (which must later be released with 'release-build-slot'), or #f and #f." slot (which must later be released with 'release-build-slot'), or #f and #f."
@ -441,39 +458,35 @@ slot (which must later be released with 'release-build-slot'), or #f and #f."
;; 5. Release the global machine-choice lock. ;; 5. Release the global machine-choice lock.
(with-file-lock (machine-choice-lock-file) (with-file-lock (machine-choice-lock-file)
(define machines+slots+loads (define machines+slots
(filter-map (lambda (machine) (filter-map (lambda (machine)
;; Call 'machine-load' from here to make sure it is called
;; only once per machine (it is expensive).
(let ((slot (acquire-build-slot machine))) (let ((slot (acquire-build-slot machine)))
(and slot (and slot (list machine slot))))
(list machine slot (machine-load machine))))) (shuffle machines)))
machines))
(define (undecorate pred) (define (undecorate pred)
(lambda (a b) (lambda (a b)
(match a (match a
((machine1 slot1 load1) ((machine1 slot1)
(match b (match b
((machine2 slot2 load2) ((machine2 slot2)
(pred machine1 load1 machine2 load2))))))) (pred machine1 machine2)))))))
(define (machine-less-loaded-or-faster? m1 l1 m2 l2) (define (machine-faster? m1 m2)
;; Return #t if M1 is either less loaded or faster than M2, with L1 ;; Return #t if M1 is faster than M2.
;; being the load of M1 and L2 the load of M2. (This relation defines a (> (build-machine-speed m1)
;; total order on machines.) (build-machine-speed m2)))
(> (/ (build-machine-speed m1) (+ 1 l1))
(/ (build-machine-speed m2) (+ 1 l2))))
(let loop ((machines+slots+loads (let loop ((machines+slots
(sort machines+slots+loads (sort machines+slots (undecorate machine-faster?))))
(undecorate machine-less-loaded-or-faster?)))) (match machines+slots
(match machines+slots+loads (((best slot) others ...)
(((best slot load) others ...)
;; Return the best machine unless it's already overloaded. ;; Return the best machine unless it's already overloaded.
(if (< load 2.) ;; Note: We call 'machine-load' only as a last resort because it is
;; too costly to call it once for every machine.
(if (< (machine-load best) 2.)
(match others (match others
(((machines slots loads) ...) (((machines slots) ...)
;; Release slots from the uninteresting machines. ;; Release slots from the uninteresting machines.
(for-each release-build-slot slots) (for-each release-build-slot slots)

View file

@ -962,6 +962,7 @@ DESTINATION as a nar file. Verify the substitute against ACL."
;; Unpack the Nar at INPUT into DESTINATION. ;; Unpack the Nar at INPUT into DESTINATION.
(restore-file input destination) (restore-file input destination)
(close-port input) (close-port input)
(close-port progress)
;; Skip a line after what 'progress-reporter/file' printed, and another ;; Skip a line after what 'progress-reporter/file' printed, and another
;; one to visually separate substitutions. ;; one to visually separate substitutions.

View file

@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU ;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2014, 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org>
;;; ;;;
;;; This file is part of GNU Guix. ;;; This file is part of GNU Guix.
;;; ;;;
@ -25,7 +25,7 @@
#:export (with-http-server #:export (with-http-server
call-with-http-server call-with-http-server
%http-server-port %http-server-port
%http-server-socket http-server-can-listen?
%local-url)) %local-url))
;;; Commentary: ;;; Commentary:
@ -38,75 +38,85 @@
;; TCP port to use for the stub HTTP server. ;; TCP port to use for the stub HTTP server.
(make-parameter 9999)) (make-parameter 9999))
(define (open-http-server-socket)
"Return a listening socket for the web server. It is useful to export it so
that tests can check whether we succeeded opening the socket and tests skip if
needed."
(catch 'system-error
(lambda ()
(let ((sock (socket PF_INET SOCK_STREAM 0)))
(setsockopt sock SOL_SOCKET SO_REUSEADDR 1)
(bind sock
(make-socket-address AF_INET INADDR_LOOPBACK
(%http-server-port)))
sock))
(lambda args
(let ((err (system-error-errno args)))
(format (current-error-port)
"warning: cannot run Web server for tests: ~a~%"
(strerror err))
#f))))
(define (http-server-can-listen?)
"Return #t if we managed to open a listening socket."
(and=> (open-http-server-socket)
(lambda (socket)
(close-port socket)
#t)))
(define (%local-url) (define (%local-url)
;; URL to use for 'home-page' tests. ;; URL to use for 'home-page' tests.
(string-append "http://localhost:" (number->string (%http-server-port)) (string-append "http://localhost:" (number->string (%http-server-port))
"/foo/bar")) "/foo/bar"))
(define %http-server-socket (define* (call-with-http-server code data thunk
;; Listening socket for the web server. It is useful to export it so that #:key (headers '()))
;; tests can check whether we succeeded opening the socket and tests skip if
;; needed.
(delay
(catch 'system-error
(lambda ()
(let ((sock (socket PF_INET SOCK_STREAM 0)))
(setsockopt sock SOL_SOCKET SO_REUSEADDR 1)
(bind sock
(make-socket-address AF_INET INADDR_LOOPBACK
(%http-server-port)))
sock))
(lambda args
(let ((err (system-error-errno args)))
(format (current-error-port)
"warning: cannot run Web server for tests: ~a~%"
(strerror err))
#f)))))
(define (http-write server client response body)
"Write RESPONSE."
(let* ((response (write-response response client))
(port (response-port response)))
(cond
((not body)) ;pass
(else
(write-response-body response body)))
(close-port port)
(quit #t) ;exit the server thread
(values)))
;; Mutex and condition variable to synchronize with the HTTP server.
(define %http-server-lock (make-mutex))
(define %http-server-ready (make-condition-variable))
(define (http-open . args)
"Start listening for HTTP requests and signal %HTTP-SERVER-READY."
(with-mutex %http-server-lock
(let ((result (apply (@@ (web server http) http-open) args)))
(signal-condition-variable %http-server-ready)
result)))
(define-server-impl stub-http-server
;; Stripped-down version of Guile's built-in HTTP server.
http-open
(@@ (web server http) http-read)
http-write
(@@ (web server http) http-close))
(define (call-with-http-server code data thunk)
"Call THUNK with an HTTP server running and returning CODE and DATA (a "Call THUNK with an HTTP server running and returning CODE and DATA (a
string) on HTTP requests." string) on HTTP requests."
(define (http-write server client response body)
"Write RESPONSE."
(let* ((response (write-response response client))
(port (response-port response)))
(cond
((not body)) ;pass
(else
(write-response-body response body)))
(close-port port)
(quit #t) ;exit the server thread
(values)))
;; Mutex and condition variable to synchronize with the HTTP server.
(define %http-server-lock (make-mutex))
(define %http-server-ready (make-condition-variable))
(define (http-open . args)
"Start listening for HTTP requests and signal %HTTP-SERVER-READY."
(with-mutex %http-server-lock
(let ((result (apply (@@ (web server http) http-open) args)))
(signal-condition-variable %http-server-ready)
result)))
(define-server-impl stub-http-server
;; Stripped-down version of Guile's built-in HTTP server.
http-open
(@@ (web server http) http-read)
http-write
(@@ (web server http) http-close))
(define (server-body) (define (server-body)
(define (handle request body) (define (handle request body)
(values (build-response #:code code (values (build-response #:code code
#:reason-phrase "Such is life") #:reason-phrase "Such is life"
#:headers headers)
data)) data))
(catch 'quit (let ((socket (open-http-server-socket)))
(lambda () (catch 'quit
(run-server handle stub-http-server (lambda ()
`(#:socket ,(force %http-server-socket)))) (run-server handle stub-http-server
(const #t))) `(#:socket ,socket)))
(lambda _
(close-port socket)))))
(with-mutex %http-server-lock (with-mutex %http-server-lock
(let ((server (make-thread server-body))) (let ((server (make-thread server-body)))
@ -114,7 +124,12 @@ string) on HTTP requests."
;; Normally SERVER exits automatically once it has received a request. ;; Normally SERVER exits automatically once it has received a request.
(thunk)))) (thunk))))
(define-syntax-rule (with-http-server code data body ...) (define-syntax with-http-server
(call-with-http-server code data (lambda () body ...))) (syntax-rules ()
((_ (code headers) data body ...)
(call-with-http-server code data (lambda () body ...)
#:headers headers))
((_ code data body ...)
(call-with-http-server code data (lambda () body ...)))))
;;; http.scm ends here ;;; http.scm ends here

View file

@ -257,6 +257,15 @@ ARGS is the list of arguments received by the 'throw' handler."
(('system-error . rest) (('system-error . rest)
(let ((err (system-error-errno args))) (let ((err (system-error-errno args)))
(report-error (G_ "failed to load '~a': ~a~%") file (strerror err)))) (report-error (G_ "failed to load '~a': ~a~%") file (strerror err))))
(('read-error "scm_i_lreadparen" message _ ...)
;; Guile's missing-paren messages are obscure so we make them more
;; intelligible here.
(if (string-suffix? "end of file" message)
(let ((location (string-drop-right message
(string-length "end of file"))))
(format (current-error-port) (G_ "~amissing closing parenthesis~%")
location))
(apply throw args)))
(('syntax-error proc message properties form . rest) (('syntax-error proc message properties form . rest)
(let ((loc (source-properties->location properties))) (let ((loc (source-properties->location properties)))
(format (current-error-port) (G_ "~a: error: ~a~%") (format (current-error-port) (G_ "~a: error: ~a~%")

View file

@ -149,6 +149,31 @@ the number of uncompressed bytes written, a strictly positive integer."
;; Z_DEFAULT_COMPRESSION. ;; Z_DEFAULT_COMPRESSION.
-1) -1)
(define (close-procedure gzfile port)
"Return a procedure that closes GZFILE, ensuring its underlying PORT is
closed even if closing GZFILE triggers an exception."
(let-syntax ((ignore-EBADF
(syntax-rules ()
((_ exp)
(catch 'system-error
(lambda ()
exp)
(lambda args
(unless (= EBADF (system-error-errno args))
(apply throw args))))))))
(lambda ()
(catch 'zlib-error
(lambda ()
;; 'gzclose' closes the underlying file descriptor. 'close-port'
;; calls close(2) and gets EBADF, which we swallow.
(gzclose gzfile)
(ignore-EBADF (close-port port)))
(lambda args
;; Make sure PORT is closed despite the zlib error.
(ignore-EBADF (close-port port))
(apply throw args))))))
(define* (make-gzip-input-port port #:key (buffer-size %default-buffer-size)) (define* (make-gzip-input-port port #:key (buffer-size %default-buffer-size))
"Return an input port that decompresses data read from PORT, a file port. "Return an input port that decompresses data read from PORT, a file port.
PORT is automatically closed when the resulting port is closed. BUFFER-SIZE PORT is automatically closed when the resulting port is closed. BUFFER-SIZE
@ -158,11 +183,7 @@ buffered input, which would be lost (and is lost anyway)."
(define gzfile (define gzfile
(match (drain-input port) (match (drain-input port)
("" ;PORT's buffer is empty ("" ;PORT's buffer is empty
;; Since 'gzclose' will eventually close the file descriptor beneath (gzdopen (fileno port) "r"))
;; PORT, we increase PORT's revealed count and never call 'close-port'
;; on PORT since we would get EBADF if 'gzclose' already closed it (on
;; 2.0 EBADF is swallowed by 'fport_close' but on 2.2 it is raised).
(gzdopen (port->fdes port) "r"))
(_ (_
;; This is unrecoverable but it's better than having the buffered input ;; This is unrecoverable but it's better than having the buffered input
;; be lost, leading to unclear end-of-file or corrupt-data errors down ;; be lost, leading to unclear end-of-file or corrupt-data errors down
@ -177,8 +198,7 @@ buffered input, which would be lost (and is lost anyway)."
(gzbuffer! gzfile buffer-size)) (gzbuffer! gzfile buffer-size))
(make-custom-binary-input-port "gzip-input" read! #f #f (make-custom-binary-input-port "gzip-input" read! #f #f
(lambda () (close-procedure gzfile port)))
(gzclose gzfile))))
(define* (make-gzip-output-port port (define* (make-gzip-output-port port
#:key #:key
@ -190,7 +210,7 @@ port is closed."
(define gzfile (define gzfile
(begin (begin
(force-output port) ;empty PORT's buffer (force-output port) ;empty PORT's buffer
(gzdopen (port->fdes port) (gzdopen (fileno port)
(string-append "w" (number->string level))))) (string-append "w" (number->string level)))))
(define (write! bv start count) (define (write! bv start count)
@ -200,8 +220,7 @@ port is closed."
(gzbuffer! gzfile buffer-size)) (gzbuffer! gzfile buffer-size))
(make-custom-binary-output-port "gzip-output" write! #f #f (make-custom-binary-output-port "gzip-output" write! #f #f
(lambda () (close-procedure gzfile port)))
(gzclose gzfile))))
(define* (call-with-gzip-input-port port proc (define* (call-with-gzip-input-port port proc
#:key (buffer-size %default-buffer-size)) #:key (buffer-size %default-buffer-size))

View file

@ -222,7 +222,7 @@
(build-derivations %store (list drv)) (build-derivations %store (list drv))
#f))) #f)))
(unless (force %http-server-socket) (unless (http-server-can-listen?)
(test-skip 1)) (test-skip 1))
(test-assert "'download' built-in builder" (test-assert "'download' built-in builder"
(let ((text (random-text))) (let ((text (random-text)))
@ -238,7 +238,7 @@
get-string-all) get-string-all)
text)))))) text))))))
(unless (force %http-server-socket) (unless (http-server-can-listen?)
(test-skip 1)) (test-skip 1))
(test-assert "'download' built-in builder, invalid hash" (test-assert "'download' built-in builder, invalid hash"
(with-http-server 200 "hello, world!" (with-http-server 200 "hello, world!"
@ -253,7 +253,7 @@
(build-derivations %store (list drv)) (build-derivations %store (list drv))
#f)))) #f))))
(unless (force %http-server-socket) (unless (http-server-can-listen?)
(test-skip 1)) (test-skip 1))
(test-assert "'download' built-in builder, not found" (test-assert "'download' built-in builder, not found"
(with-http-server 404 "not found" (with-http-server 404 "not found"
@ -279,7 +279,7 @@
(build-derivations %store (list drv)) (build-derivations %store (list drv))
#f))) #f)))
(unless (force %http-server-socket) (unless (http-server-can-listen?)
(test-skip 1)) (test-skip 1))
(test-assert "'download' built-in builder, check mode" (test-assert "'download' built-in builder, check mode"
;; Make sure rebuilding the 'builtin:download' derivation in check mode ;; Make sure rebuilding the 'builtin:download' derivation in check mode

View file

@ -53,6 +53,21 @@ else
fi fi
cat > "$tmpfile"<<EOF
;; This is line 1, and the next one is line 2.
(operating-system
;; This is line 3, and there is no closing paren!
EOF
if guix system vm "$tmpfile" 2> "$errorfile"
then
# This must not succeed.
exit 1
else
grep "$tmpfile:4:1: missing closing paren" "$errorfile"
fi
# Reporting of unbound variables. # Reporting of unbound variables.
cat > "$tmpfile" <<EOF cat > "$tmpfile" <<EOF

View file

@ -37,6 +37,7 @@
#:use-module (gnu packages glib) #:use-module (gnu packages glib)
#:use-module (gnu packages pkg-config) #:use-module (gnu packages pkg-config)
#:use-module (gnu packages python) #:use-module (gnu packages python)
#:use-module (web uri)
#:use-module (web server) #:use-module (web server)
#:use-module (web server http) #:use-module (web server http)
#:use-module (web response) #:use-module (web response)
@ -388,7 +389,7 @@
(check-home-page pkg))) (check-home-page pkg)))
"domain not found"))) "domain not found")))
(test-skip (if (force %http-server-socket) 0 1)) (test-skip (if (http-server-can-listen?) 0 1))
(test-assert "home-page: Connection refused" (test-assert "home-page: Connection refused"
(->bool (->bool
(string-contains (string-contains
@ -399,7 +400,7 @@
(check-home-page pkg))) (check-home-page pkg)))
"Connection refused"))) "Connection refused")))
(test-skip (if (force %http-server-socket) 0 1)) (test-skip (if (http-server-can-listen?) 0 1))
(test-equal "home-page: 200" (test-equal "home-page: 200"
"" ""
(with-warnings (with-warnings
@ -409,7 +410,7 @@
(home-page (%local-url))))) (home-page (%local-url)))))
(check-home-page pkg))))) (check-home-page pkg)))))
(test-skip (if (force %http-server-socket) 0 1)) (test-skip (if (http-server-can-listen?) 0 1))
(test-assert "home-page: 200 but short length" (test-assert "home-page: 200 but short length"
(->bool (->bool
(string-contains (string-contains
@ -421,7 +422,7 @@
(check-home-page pkg)))) (check-home-page pkg))))
"suspiciously small"))) "suspiciously small")))
(test-skip (if (force %http-server-socket) 0 1)) (test-skip (if (http-server-can-listen?) 0 1))
(test-assert "home-page: 404" (test-assert "home-page: 404"
(->bool (->bool
(string-contains (string-contains
@ -433,6 +434,52 @@
(check-home-page pkg)))) (check-home-page pkg))))
"not reachable: 404"))) "not reachable: 404")))
(test-skip (if (http-server-can-listen?) 0 1))
(test-assert "home-page: 301, invalid"
(->bool
(string-contains
(with-warnings
(with-http-server 301 %long-string
(let ((pkg (package
(inherit (dummy-package "x"))
(home-page (%local-url)))))
(check-home-page pkg))))
"invalid permanent redirect")))
(test-skip (if (http-server-can-listen?) 0 1))
(test-assert "home-page: 301 -> 200"
(->bool
(string-contains
(with-warnings
(with-http-server 200 %long-string
(let ((initial-url (%local-url)))
(parameterize ((%http-server-port (+ 1 (%http-server-port))))
(with-http-server (301 `((location
. ,(string->uri initial-url))))
""
(let ((pkg (package
(inherit (dummy-package "x"))
(home-page (%local-url)))))
(check-home-page pkg)))))))
"permanent redirect")))
(test-skip (if (http-server-can-listen?) 0 1))
(test-assert "home-page: 301 -> 404"
(->bool
(string-contains
(with-warnings
(with-http-server 404 "booh!"
(let ((initial-url (%local-url)))
(parameterize ((%http-server-port (+ 1 (%http-server-port))))
(with-http-server (301 `((location
. ,(string->uri initial-url))))
""
(let ((pkg (package
(inherit (dummy-package "x"))
(home-page (%local-url)))))
(check-home-page pkg)))))))
"not reachable: 404")))
(test-assert "source-file-name" (test-assert "source-file-name"
(->bool (->bool
(string-contains (string-contains
@ -510,7 +557,7 @@
(check-source-file-name pkg))) (check-source-file-name pkg)))
"file name should contain the package name")))) "file name should contain the package name"))))
(test-skip (if (force %http-server-socket) 0 1)) (test-skip (if (http-server-can-listen?) 0 1))
(test-equal "source: 200" (test-equal "source: 200"
"" ""
(with-warnings (with-warnings
@ -523,7 +570,7 @@
(sha256 %null-sha256)))))) (sha256 %null-sha256))))))
(check-source pkg))))) (check-source pkg)))))
(test-skip (if (force %http-server-socket) 0 1)) (test-skip (if (http-server-can-listen?) 0 1))
(test-assert "source: 200 but short length" (test-assert "source: 200 but short length"
(->bool (->bool
(string-contains (string-contains
@ -538,7 +585,7 @@
(check-source pkg)))) (check-source pkg))))
"suspiciously small"))) "suspiciously small")))
(test-skip (if (force %http-server-socket) 0 1)) (test-skip (if (http-server-can-listen?) 0 1))
(test-assert "source: 404" (test-assert "source: 404"
(->bool (->bool
(string-contains (string-contains
@ -553,6 +600,42 @@
(check-source pkg)))) (check-source pkg))))
"not reachable: 404"))) "not reachable: 404")))
(test-skip (if (http-server-can-listen?) 0 1))
(test-equal "source: 301 -> 200"
""
(with-warnings
(with-http-server 200 %long-string
(let ((initial-url (%local-url)))
(parameterize ((%http-server-port (+ 1 (%http-server-port))))
(with-http-server (301 `((location . ,(string->uri initial-url))))
""
(let ((pkg (package
(inherit (dummy-package "x"))
(source (origin
(method url-fetch)
(uri (%local-url))
(sha256 %null-sha256))))))
(check-source pkg))))))))
(test-skip (if (http-server-can-listen?) 0 1))
(test-assert "source: 301 -> 404"
(->bool
(string-contains
(with-warnings
(with-http-server 404 "booh!"
(let ((initial-url (%local-url)))
(parameterize ((%http-server-port (+ 1 (%http-server-port))))
(with-http-server (301 `((location . ,(string->uri initial-url))))
""
(let ((pkg (package
(inherit (dummy-package "x"))
(source (origin
(method url-fetch)
(uri (%local-url))
(sha256 %null-sha256))))))
(check-source pkg)))))))
"not reachable: 404")))
(test-assert "mirror-url" (test-assert "mirror-url"
(string-null? (string-null?
(with-warnings (with-warnings

View file

@ -57,16 +57,7 @@
(match (waitpid pid) (match (waitpid pid)
((_ . status) ((_ . status)
(and (zero? status) (and (zero? status)
(port-closed? parent)
;; PORT itself isn't closed but its underlying file
;; descriptor must have been closed by 'gzclose'.
(catch 'system-error
(lambda ()
(seek (fileno parent) 0 SEEK_CUR)
#f)
(lambda args
(= EBADF (system-error-errno args))))
(bytevector=? received data)))))))))))) (bytevector=? received data))))))))))))
(test-end) (test-end)