summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gnu/local.mk1
-rw-r--r--gnu/packages/admin.scm4
-rw-r--r--gnu/packages/cluster.scm18
-rw-r--r--gnu/packages/cran.scm107
-rw-r--r--gnu/packages/crypto.scm17
-rw-r--r--gnu/packages/emacs-xyz.scm48
-rw-r--r--gnu/packages/firmware.scm6
-rw-r--r--gnu/packages/gnome-xyz.scm4
-rw-r--r--gnu/packages/kde.scm179
-rw-r--r--gnu/packages/networking.scm41
-rw-r--r--gnu/packages/nss.scm8
-rw-r--r--gnu/packages/patches/nss-CVE-2019-11745.patch24
-rw-r--r--gnu/packages/pretty-print.scm2
-rw-r--r--gnu/packages/python-xyz.scm40
-rw-r--r--gnu/packages/ssh.scm14
-rw-r--r--gnu/packages/version-control.scm4
-rw-r--r--gnu/packages/video.scm1
-rw-r--r--gnu/packages/virtualization.scm4
-rw-r--r--gnu/packages/vpn.scm12
-rw-r--r--gnu/packages/xiph.scm2
-rw-r--r--guix/import/cran.scm4
-rw-r--r--guix/import/crate.scm17
-rw-r--r--guix/import/utils.scm84
-rw-r--r--guix/scripts/import/cran.scm7
-rw-r--r--guix/scripts/import/crate.scm5
-rw-r--r--guix/scripts/import/elpa.scm7
-rw-r--r--guix/scripts/import/gem.scm5
-rw-r--r--guix/scripts/import/hackage.scm5
-rw-r--r--guix/scripts/import/opam.scm5
-rw-r--r--guix/scripts/import/pypi.scm5
-rw-r--r--guix/scripts/import/stackage.scm5
-rw-r--r--tests/crate.scm357
-rw-r--r--tests/gem.scm25
-rw-r--r--tests/import-utils.scm23
34 files changed, 815 insertions, 275 deletions
diff --git a/gnu/local.mk b/gnu/local.mk
index 21102514a9..4d89f17bbe 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1179,6 +1179,7 @@ dist_patch_DATA = \
%D%/packages/patches/ngircd-handle-zombies.patch \
%D%/packages/patches/nm-plugin-path.patch \
%D%/packages/patches/nsis-env-passthru.patch \
+ %D%/packages/patches/nss-CVE-2019-11745.patch \
%D%/packages/patches/nss-freebl-stubs.patch \
%D%/packages/patches/nss-increase-test-timeout.patch \
%D%/packages/patches/nss-pkgconfig.patch \
diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm
index e0f239a6ae..c2be85e81e 100644
--- a/gnu/packages/admin.scm
+++ b/gnu/packages/admin.scm
@@ -629,7 +629,7 @@ would need and has several interesting built-in capabilities.")
(define-public netcat-openbsd
(package
(name "netcat-openbsd")
- (version "1.203-2")
+ (version "1.206-1")
(source (origin
(method git-fetch)
(uri (git-reference
@@ -638,7 +638,7 @@ would need and has several interesting built-in capabilities.")
(file-name (git-file-name name version))
(sha256
(base32
- "0j85gzbjzs6yrhgabh3zkwzd27qkr5s0zjjczl0hah8q7yhrjk3m"))))
+ "08r3mmck3s5pbvwyq19wp5g8jqcxza3cm8nkc6jm7rqn4jdydc4z"))))
(build-system gnu-build-system)
(arguments
`(#:tests? #f ; no test suite
diff --git a/gnu/packages/cluster.scm b/gnu/packages/cluster.scm
index 9548352d12..03700b0bcb 100644
--- a/gnu/packages/cluster.scm
+++ b/gnu/packages/cluster.scm
@@ -26,6 +26,7 @@
#:use-module (guix packages)
#:use-module (gnu packages autotools)
#:use-module (gnu packages gettext)
+ #:use-module (gnu packages libevent)
#:use-module (gnu packages linux)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages sphinx)
@@ -87,7 +88,7 @@ independently or together to provide resilient infrastructures.")
(define-public libraft
(package
(name "libraft")
- (version "0.9.5")
+ (version "0.9.11")
(home-page "https://github.com/canonical/raft")
(source (origin
(method git-fetch)
@@ -96,10 +97,17 @@ independently or together to provide resilient infrastructures.")
(file-name (git-file-name name version))
(sha256
(base32
- "1q49f5mmv6nr6dxhnp044xwc6jlczgh0nj0bl6718wiqh28411x0"))))
- (arguments '(#:configure-flags '("--disable-uv")))
- ;; The uv plugin tests fail, if libuv (or the example) is enabled,
- ;; because setting up the environment requires too much privileges.
+ "00rsq4z9nykmf7r5rlpv1y6bvckcmg3zv57vh1h681y5pij6cch1"))))
+ (arguments '(#:configure-flags '("--enable-uv")
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'disable-failing-tests
+ (lambda _
+ (substitute* "Makefile.am"
+ ((".*test_uv_append.c.*") ""))
+ #t)))))
+ (inputs
+ `(("libuv" ,libuv)))
(native-inputs
`(("autoconf" ,autoconf)
("automake" ,automake)
diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm
index 11d254001f..ad8c6ebe67 100644
--- a/gnu/packages/cran.scm
+++ b/gnu/packages/cran.scm
@@ -4168,6 +4168,30 @@ supports arbitrary vertex/edge/graph attributes.")
software developed by the Statnet Project.")
(license license:gpl3)))
+(define-public r-statcheck
+ (package
+ (name "r-statcheck")
+ (version "1.3.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (cran-uri "statcheck" version))
+ (sha256
+ (base32
+ "0ivybdcrymlsfv6pg6p5bv70qdvgxf2vgp0kf4r0pf2fcvav1mcp"))))
+ (build-system r-build-system)
+ (propagated-inputs
+ `(("r-ggplot2" ,r-ggplot2)
+ ("r-plyr" ,r-plyr)
+ ("r-rmarkdown" ,r-rmarkdown)))
+ (home-page "https://cran.r-project.org/web/packages/statcheck/")
+ (synopsis "Extract statistics from articles and recompute p-values")
+ (description "This package can automatically extract statistical
+null-hypothesis significant testing (NHST) results from articles and recompute
+the p-values based on the reported test statistic and degrees of freedom to
+detect possible inconsistencies.")
+ (license license:gpl2)))
+
(define-public r-sna
(package
(name "r-sna")
@@ -14695,6 +14719,89 @@ they are often difficult to interpret. Rex allows you to build complex
regular expressions from human readable expressions")
(license license:expat)))
+(define-public r-xmlparsedata
+ (package
+ (name "r-xmlparsedata")
+ (version "1.0.3")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (cran-uri "xmlparsedata" version))
+ (sha256
+ (base32
+ "0gjr3l5z5dp276lchr2649as1rkj56d2mlvbr66yg393zzw50lsh"))))
+ (properties `((upstream-name . "xmlparsedata")))
+ (build-system r-build-system)
+ (home-page "https://github.com/r-lib/xmlparsedata#readme")
+ (synopsis "Parse data of @code{R} code as an @code{XML} tree")
+ (description
+ "This package provides tools to convert the output of
+@code{utils::getParseData()} to an @code{XML} tree, that one can search via
+@code{XPath}, and is easier to manipulate in general.")
+ (license license:expat)))
+
+(define-public r-cyclocomp
+ (package
+ (name "r-cyclocomp")
+ (version "1.1.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (cran-uri "cyclocomp" version))
+ (sha256
+ (base32
+ "0gky3svk02wiajw7nfjh30684h3qxili4bvsab0m7b6cggw6bgyd"))))
+ (properties `((upstream-name . "cyclocomp")))
+ (build-system r-build-system)
+ (propagated-inputs
+ `(("r-callr" ,r-callr)
+ ("r-crayon" ,r-crayon)
+ ("r-desc" ,r-desc)
+ ("r-remotes" ,r-remotes)
+ ("r-withr" ,r-withr)))
+ (home-page "https://github.com/MangoTheCat/cyclocomp")
+ (synopsis "Cyclomatic complexity of R code")
+ (description
+ "Cyclomatic complexity is a software metric, used to indicate the
+complexity of a program. It is a quantitative measure of the number of
+linearly independent paths through a program's source code. This package
+provides tools to compute this metric.")
+ (license license:expat)))
+
+(define-public r-lintr
+ (package
+ (name "r-lintr")
+ (version "2.0.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (cran-uri "lintr" version))
+ (sha256
+ (base32
+ "09gbci4v5n4gsfzminly8332fw7faxdi1kkyvpa10dydx02sjcwb"))))
+ (properties `((upstream-name . "lintr")))
+ (build-system r-build-system)
+ (propagated-inputs
+ `(("r-codetools" ,r-codetools)
+ ("r-crayon" ,r-crayon)
+ ("r-cyclocomp" ,r-cyclocomp)
+ ("r-digest" ,r-digest)
+ ("r-httr" ,r-httr)
+ ("r-jsonlite" ,r-jsonlite)
+ ("r-knitr" ,r-knitr)
+ ("r-rex" ,r-rex)
+ ("r-rstudioapi" ,r-rstudioapi)
+ ("r-stringdist" ,r-stringdist)
+ ("r-testthat" ,r-testthat)
+ ("r-xml2" ,r-xml2)
+ ("r-xmlparsedata" ,r-xmlparsedata)))
+ (home-page "https://github.com/jimhester/lintr")
+ (synopsis "Linter for R code")
+ (description "This package checks adherence to a given style, syntax
+errors and possible semantic issues. It supports on the fly checking of R
+code edited with @code{RStudio IDE}, @code{Emacs} and @code{Vim}.")
+ (license license:expat)))
+
(define-public r-sctransform
(package
(name "r-sctransform")
diff --git a/gnu/packages/crypto.scm b/gnu/packages/crypto.scm
index 80c598ed86..e63823de2c 100644
--- a/gnu/packages/crypto.scm
+++ b/gnu/packages/crypto.scm
@@ -852,15 +852,16 @@ cannot sign messages in OpenBSD format yet.")
(define-public enchive
(package
(name "enchive")
- (version "3.4")
+ (version "3.5")
(source (origin
- (method url-fetch)
- (uri (string-append "https://github.com/skeeto/" name "/archive/"
- version ".tar.gz"))
- (sha256
- (base32
- "17hrxpp4cpn10bk48sfvfjc8hghky34agsnypam1v9f36kbalqfk"))
- (file-name (string-append name "-" version ".tar.gz"))))
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/skeeto/enchive")
+ (commit version)))
+ (sha256
+ (base32
+ "0fdrfc5l42lj2bvmv9dmkmhmm7qiszwk7cmdvnqad3fs7652g0qa"))
+ (file-name (git-file-name name version))))
(build-system gnu-build-system)
(arguments
'(#:tests? #f ; no check target '
diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index 8207088db7..c7da8b9556 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -19734,6 +19734,54 @@ You can customize: @code{tao-theme-scale-fn}, that returns 16 2-digit numbers;
@code{tao-theme-use-height}.")
(license license:gpl3+))))
+(define-public emacs-almost-mono-themes
+ (let ((commit "c3a85c1a665530a5d830665969725cdba8eceb75")
+ (revision "0"))
+ (package
+ (name "emacs-almost-mono-themes")
+ (version (git-version "0" revision commit))
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/cryon/almost-mono-themes.git")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "034k32xkr5ma415hlkbl35z0jxc4sa1inf87hg3y6lrlfl83fyjh"))))
+ (build-system emacs-build-system)
+ (home-page "https://github.com/cryon/almost-mono-themes")
+ (synopsis "Almost monochromatic themes for emacs in a few variants")
+ (description
+ "This package provides a collection of almost monochrome Emacs themes:
+@code{almost-mono-black} and @code{almost-mono-white}.")
+ (license license:gpl3+))))
+
+(define-public emacs-quasi-monochrome
+ (let ((commit "68060dbbc0bbfe4924387392874186c5a29bb434")
+ (revision "0"))
+ (package
+ (name "emacs-quasi-monochrome")
+ (version (git-version "1.2" revision commit))
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/lbolla/emacs-quasi-monochrome.git")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0zp2xr0bjfqrpb0bqczzick1vvbjmipjavrdi70kw6a9caynvq22"))))
+ (build-system emacs-build-system)
+ (home-page "https://github.com/lbolla/emacs-quasi-monochrome")
+ (synopsis "Dark color theme for Emacs")
+ (description
+ "This package provides a dark color theme with a black background, high
+contrast and few colors.")
+ (license license:gpl3+))))
+
(define-public emacs-doom-themes
(package
(name "emacs-doom-themes")
diff --git a/gnu/packages/firmware.scm b/gnu/packages/firmware.scm
index cc92c228ad..12b40389d0 100644
--- a/gnu/packages/firmware.scm
+++ b/gnu/packages/firmware.scm
@@ -186,7 +186,7 @@ by the b43-open driver of Linux-libre.")
(define-public seabios
(package
(name "seabios")
- (version "1.12.1")
+ (version "1.13.0")
(source
(origin
(method git-fetch)
@@ -195,10 +195,10 @@ by the b43-open driver of Linux-libre.")
(commit (string-append "rel-" version))))
(file-name (git-file-name name version))
(sha256
- (base32 "1g9y03r5ky58q2g9rhbwfhs42z0zb9f59wfxpwh6zjqa6fyv1r80"))))
+ (base32 "1n1bd6msfs7xn8844sz2qnm7hb5x2qfl3zb06kp4bx9vdc3i6619"))))
(build-system gnu-build-system)
(native-inputs
- `(("python-2" ,python-2)))
+ `(("python" ,python-wrapper)))
(arguments
`(#:tests? #f ; no check target
#:phases
diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm
index bc5e4047dd..d05bdf0ac0 100644
--- a/gnu/packages/gnome-xyz.scm
+++ b/gnu/packages/gnome-xyz.scm
@@ -117,7 +117,7 @@ the Obsidian icon theme.")
(define-public gnome-shell-extension-dash-to-dock
(package
(name "gnome-shell-extension-dash-to-dock")
- (version "65")
+ (version "66")
(source (origin
(method git-fetch)
(uri (git-reference
@@ -126,7 +126,7 @@ the Obsidian icon theme.")
version))))
(sha256
(base32
- "0ln49l9s0yfl30pi77pz7xlmh63l9vjppi863kry5lay10dsvz47"))
+ "04krl6rxlp1qc97psraf2kwin7h0mx4c7pnfpi7vhplmvasrwkfh"))
(file-name (git-file-name name version))))
(build-system gnu-build-system)
(arguments
diff --git a/gnu/packages/kde.scm b/gnu/packages/kde.scm
index 9e6a2cff3e..24d8eedd84 100644
--- a/gnu/packages/kde.scm
+++ b/gnu/packages/kde.scm
@@ -27,6 +27,7 @@
(define-module (gnu packages kde)
#:use-module (guix build-system cmake)
#:use-module (guix build-system qt)
+ #:use-module (guix deprecation)
#:use-module (guix download)
#:use-module (guix git-download)
#:use-module ((guix licenses) #:prefix license:)
@@ -37,6 +38,7 @@
#:use-module (gnu packages apr)
#:use-module (gnu packages audio)
#:use-module (gnu packages boost)
+ #:use-module (gnu packages code)
#:use-module (gnu packages compression)
#:use-module (gnu packages curl)
#:use-module (gnu packages documentation)
@@ -145,7 +147,7 @@ projects.")
(define-public kdevelop
(package
(name "kdevelop")
- (version "5.1.2")
+ (version "5.4.5")
(source
(origin
(method url-fetch)
@@ -154,73 +156,79 @@ projects.")
version ".tar.xz"))
(sha256
(base32
- "1iqaq0ilijjigqb34v5wq9in6bnjs0p9cmgbygjmy53xhh3yhm5g"))))
- (build-system cmake-build-system)
+ "08vhbg9ql0402bw3y3xw1kdxhig9sv3ss8g0h4477vy3z17m1h4j"))))
+ (build-system qt-build-system)
(native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules)
("pkg-config" ,pkg-config)
+ ("shared-mime-info" ,shared-mime-info)
("qttools" ,qttools)))
(inputs
- `(("kdevplatform" ,kdevplatform)
- ("kdevelop-pg-qt" ,kdevelop-pg-qt)
- ("qtbase" ,qtbase)
- ("qtdeclarative" ,qtdeclarative)
- ("qtquickcontrols" ,qtquickcontrols)
- ("qtwebkit" ,qtwebkit)
+ `(("boost" ,boost)
+ ("clang" ,clang)
+ ("grantlee" ,grantlee)
("karchive" ,karchive)
("kcmutils" ,kcmutils)
- ("kconfig" ,kconfig)
+ ("kcrash" ,kcrash)
("kdeclarative" ,kdeclarative)
("kdoctools" ,kdoctools)
("kguiaddons" ,kguiaddons)
("ki18n" ,ki18n)
- ("kio" ,kio)
("kiconthemes" ,kiconthemes)
+ ("kio" ,kio) ;; not checked as requirement
("kitemmodels" ,kitemmodels)
("kitemviews" ,kitemviews)
("kjobwidgets" ,kjobwidgets)
- ("knotifyconfig" ,knotifyconfig)
("knotifications" ,knotifications)
+ ("knotifyconfig" ,knotifyconfig)
("kparts" ,kparts)
- ("kcrash" ,kcrash)
- ("knewstuff" ,knewstuff)
- ("krunner" ,krunner)
- ("kxmlgui" ,kxmlgui)
- ("libksysguard" ,libksysguard)
- ("threadweaver" ,threadweaver)
+ ("kservice" ,kservice)
("ktexteditor" ,ktexteditor)
("kwindowsystem" ,kwindowsystem)
+ ("kxmlgui" ,kxmlgui)
+ ("libkomparediff2" ,libkomparediff2)
+ ("oxygen-icons" ,oxygen-icons)
+ ("qtbase" ,qtbase)
+ ("qtdeclarative" ,qtdeclarative)
+ ("qtquickcontrols" ,qtquickcontrols) ;; not checked as requirement
+ ("qtquickcontrols2" ,qtquickcontrols2) ;; not checked as requirement
+ ("qtwebkit" ,qtwebkit)
+ ("threadweaver" ,threadweaver)
+
+ ;; recommendes
+ ("astyle" ,astyle)
+ ("kdevelop-pg-qt" ,kdevelop-pg-qt)
+ ("libksysguard" ,libksysguard)
+
+ ;; optional
+ ("apr" ,apr) ; required for subversion support
+ ("apr-util" ,apr-util) ; required for subversion support
+ ("attica" ,attica)
+ ("kconfigwidgets" ,kconfigwidgets)
+ ("knewstuff" ,knewstuff)
+ ("krunner" ,krunner)
+ ;; TODO: OktetaGui, OktetaKastenControllers
("plasma" ,plasma-framework)
- ("grantlee" ,grantlee)
- ("libepoxy" ,libepoxy)
- ("clang" ,clang)
- ("shared-mime-info" ,shared-mime-info)))
+ ;; TODO: purpose
+ ("sonnet" ,sonnet)
+ ("subversion" ,subversion)))
+
+ ;; run-time packages - TODO
+ ;; ClazyStandalone
+ ;; Cppcheck
+ ;; heaptrack
+ ;; heaptrack_gui
+ ;; meson
(arguments
- `(#:phases
- (modify-phases %standard-phases
- (delete 'check) ;; there are some issues with the test suite
- (add-after 'install 'wrap-executable
- (lambda* (#:key inputs outputs #:allow-other-keys)
- (let* ((out (assoc-ref outputs "out"))
- (kdevplatform (assoc-ref inputs "kdevplatform"))
- (kio (assoc-ref inputs "kio"))
- (kcmutils (assoc-ref inputs "kcmutils"))
- (qtquickcontrols (assoc-ref inputs "qtquickcontrols"))
- (qtbase (assoc-ref inputs "qtbase"))
- (qtdeclarative (assoc-ref inputs "qtdeclarative"))
- (qml "/qml"))
- (wrap-program (string-append out "/bin/kdevelop")
- `("XDG_DATA_DIRS" ":" prefix
- ,(map (lambda (s) (string-append s "/share"))
- (list out kdevplatform kcmutils)))
- `("QT_QPA_PLATFORM_PLUGIN_PATH" ":" =
- (,(string-append qtbase "/plugins/platforms")))
- `("QT_PLUGIN_PATH" ":" prefix
- ,(map (lambda (s) (string-append s "/lib/plugins"))
- (list out kdevplatform kio)))
- `("QML2_IMPORT_PATH" ":" prefix
- (,(string-append qtquickcontrols qml)
- ,(string-append qtdeclarative qml))))))))))
+ `(#:tests? #f ;; there are some issues with the test suite
+ #:phases
+ (modify-phases (@ (guix build qt-build-system) %standard-phases)
+ (add-before 'configure 'add-include-path
+ (lambda* (#:key inputs #:allow-other-keys)
+ (substitute* "cmake/modules/FindClang.cmake"
+ (("^\\s*PATHS \"\\$\\{CLANG_LIBRARY_DIRS\\}\"" line)
+ (string-append line " " (assoc-ref inputs "clang") "/lib")))
+ #t)))))
(home-page "https://kdevelop.org")
(synopsis "IDE for C, C++, Python, Javascript and PHP")
(description "The KDevelop IDE provides semantic syntax highlighting, as
@@ -233,7 +241,7 @@ software (Git, Subversion, Mercurial, CVS and Bazaar).")
(define-public kdevelop-pg-qt
(package
(name "kdevelop-pg-qt")
- (version "2.0.0")
+ (version "2.2.0")
(source
(origin
(method url-fetch)
@@ -241,7 +249,7 @@ software (Git, Subversion, Mercurial, CVS and Bazaar).")
version ".tar.gz"))
(file-name (string-append name "-" version ".tar.gz"))
(sha256
- (base32 "1av8plqz7hyhrd07avnmn6ryslqlarmxn0pw7swzvb6ddiqp59j4"))))
+ (base32 "15ja19gg6x7gww4ch12hy585x55ghbkpsiyr8fqiyjk0j6v07hh5"))))
(native-inputs
`(("extra-cmake-modules" ,extra-cmake-modules)))
(inputs
@@ -253,77 +261,8 @@ software (Git, Subversion, Mercurial, CVS and Bazaar).")
for some KDevelop language plugins (Ruby, PHP, CSS...).")
(license license:lgpl2.0+)))
-(define-public kdevplatform
- (package
- (name "kdevplatform")
- (version "5.1.2")
- (source (origin
- (method url-fetch)
- (uri (string-append "mirror://kde/stable/kdevelop"
- "/" version "/src/kdevplatform-"
- version ".tar.xz"))
- (sha256
- (base32
- "0jk6g1kiqpyjy8pca0236b9944gxqnymqv8ny6m8nrraannxs8p6"))))
- (build-system cmake-build-system)
- (native-inputs
- `(("extra-cmake-modules" ,extra-cmake-modules)
- ("pkg-config" ,pkg-config)))
- (inputs
- `(("apr" ,apr)
- ("apr-util" ,apr-util)
- ("boost" ,boost)
- ("karchive" ,karchive)
- ("kconfigwidgets" ,kconfigwidgets)
- ("kcmutils" ,kcmutils)
- ("kiconthemes" ,kiconthemes)
- ("kdeclarative" ,kdeclarative)
- ("kdoctools" ,kdoctools)
- ("kguiaddons" ,kguiaddons)
- ("kinit" ,kinit)
- ("kitemmodels" ,kitemmodels)
- ("knewstuff" ,knewstuff)
- ("knotifications" ,knotifications)
- ("knotifyconfig" ,knotifyconfig)
- ("kwindowsystem" ,kwindowsystem)
- ("kio" ,kio)
- ("ki18n" ,ki18n)
- ("kparts" ,kparts)
- ("kservice" ,kservice)
- ("grantlee" ,grantlee)
- ("libkomparediff2" ,libkomparediff2)
- ("sonnet" ,sonnet)
- ("threadweaver" ,threadweaver)
- ("ktexteditor" ,ktexteditor)
- ("qtbase" ,qtbase)
- ("qtdeclarative" ,qtdeclarative)
- ("qtscript" ,qtscript)
- ("qtwebkit" ,qtwebkit)
- ("qtx11extras" ,qtx11extras)
- ("plasma" ,plasma-framework)
- ("subversion" ,subversion)
- ("zlib" ,zlib)))
- (arguments
- `(#:phases
- (modify-phases %standard-phases
- (delete 'check)
- (add-after 'install 'check
- (lambda* (#:key outputs #:allow-other-keys)
- (let ((out (assoc-ref outputs "out")))
- (setenv "CTEST_OUTPUT_ON_FAILURE" "1")
- (setenv "QT_PLUGIN_PATH"
- (string-append out "/lib/plugins:"
- (getenv "QT_PLUGIN_PATH")))
- (setenv "XDG_DATA_DIRS"
- (string-append out "/share:"
- (getenv "XDG_DATA_DIRS")))
- (invoke "ctest" "-R" ; almost all tests require a display
- "filteringstrategy|kdevvarlengtharray|kdevhash")))))))
- (home-page "https://github.com/KDE/kdevplatform")
- (synopsis "Framework to build integrated development environments (IDEs)")
- (description "KDevPlatform is the basis of KDevelop and contains some
-plugins, as well as code to create plugins, or complete applications.")
- (license license:gpl3+)))
+;; kdevplatform was merged into kdevelop as of 5.2.x
+(define-deprecated kdevplatform kdevelop kdevelop)
(define-public krita
(package
diff --git a/gnu/packages/networking.scm b/gnu/packages/networking.scm
index 3ddf5975d7..cfa244c39b 100644
--- a/gnu/packages/networking.scm
+++ b/gnu/packages/networking.scm
@@ -35,6 +35,7 @@
;;; Copyright © 2019 Alex Griffin <a@ajgrf.com>
;;; Copyright © 2019 Jan Wielkiewicz <tona_kosmicznego_smiecia@interia.pl>
;;; Copyright © 2019 Daniel Schaefer <git@danielschaefer.me>
+;;; Copyright © 2019 Diego N. Barbato <dnbarbato@posteo.de>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -2522,12 +2523,6 @@ communication over HTTP.")
(home-page "https://github.com/Corvusoft/restbed")
(license license:agpl3+))))
-(define fmt-restinio
- (package
- (inherit fmt)
- (arguments
- '(#:configure-flags '("-DCMAKE_CXX_FLAGS=-fPIC")))))
-
(define-public restinio
(package
(name "restinio")
@@ -2552,7 +2547,7 @@ communication over HTTP.")
("sobjectizer" ,sobjectizer)))
(propagated-inputs
`(("asio", asio)
- ("fmt" ,fmt-restinio)
+ ("fmt" ,fmt)
("http-parser", http-parser)))
(arguments
`(#:configure-flags '("-DRESTINIO_INSTALL=on")
@@ -2591,7 +2586,7 @@ and targeted primarily for asynchronous processing of HTTP-requests.")
("readline" ,readline)
("jsoncpp" ,jsoncpp)
("openssl" ,openssl)
- ("fmt" ,fmt-restinio)))
+ ("fmt" ,fmt)))
(propagated-inputs
`(("argon2" ,argon2) ; TODO: Needed for the pkg-config .pc file to work?
("msgpack" ,msgpack))) ;included in several installed headers
@@ -2822,3 +2817,33 @@ to be a teaching tool and presents the subnetting results as
easy-to-understand binary values.")
(home-page "http://jodies.de/ipcalc")
(license license:gpl2+)))
+
+(define-public vde2
+ (package
+ (name "vde2")
+ (version "2.3.2")
+ (source
+ (origin
+ (method url-fetch)
+ (uri "mirror://sourceforge/vde/vde2/2.3.2/vde2-2.3.2.tar.gz")
+ (sha256
+ (base32 "14xga0ib6p1wrv3hkl4sa89yzjxv7f1vfqaxsch87j6scdm59pr2"))))
+ (build-system gnu-build-system)
+ (arguments
+ `(#:parallel-build? #f)) ; Build fails if #t.
+ (inputs
+ `(("python" ,python)
+ ("libpcap" ,libpcap)
+ ("openssl" ,openssl-1.0))) ; Build fails with 1.1.
+ (home-page "https://github.com/virtualsquare/vde-2")
+ (synopsis "Virtual Distributed Ethernet")
+ (description "VDE is a set of programs to provide virtual software-defined
+Ethernet network interface controllers across multiple virtual or
+physical, local or remote devices. The VDE architecture provides
+virtual counterparts to hardware components such as switches and
+cables.")
+ (license (list license:gpl2
+ license:lgpl2.1 ; libvdeplug
+ (license:non-copyleft ; slirpvde
+ "file://COPYING.slirpvde"
+ "See COPYING.slirpvde in the distribution.")))))
diff --git a/gnu/packages/nss.scm b/gnu/packages/nss.scm
index 2e34f8e26f..e81c859a51 100644
--- a/gnu/packages/nss.scm
+++ b/gnu/packages/nss.scm
@@ -183,3 +183,11 @@ applications. Applications built with NSS can support SSL v2 and v3, TLS,
PKCS #5, PKCS #7, PKCS #11, PKCS #12, S/MIME, X.509 v3 certificates, and other
security standards.")
(license license:mpl2.0)))
+
+(define nss/fixed
+ (package
+ (inherit nss)
+ (source (origin
+ (inherit (package-source nss))
+ (patches (append (search-patches "nss-CVE-2019-11745.patch")
+ (origin-patches (package-source nss))))))))
diff --git a/gnu/packages/patches/nss-CVE-2019-11745.patch b/gnu/packages/patches/nss-CVE-2019-11745.patch
new file mode 100644
index 0000000000..ae0eeda3c8
--- /dev/null
+++ b/gnu/packages/patches/nss-CVE-2019-11745.patch
@@ -0,0 +1,24 @@
+Fix CVE-2019-11745 (Out-of-bounds write when passing an output buffer smaller
+than the block size to NSC_EncryptUpdate).
+
+Copied from Debian, equivalent to upstream fix:
+<https://hg.mozilla.org/projects/nss/rev/1e22a0c93afe9f46545560c86caedef9dab6cfda>.
+
+# HG changeset patch
+# User Craig Disselkoen <cdisselk@cs.ucsd.edu>
+# Date 1574189697 25200
+# Node ID 60bca7c6dc6dc44579b9b3e0fb62ca3b82d92eec
+# Parent 64e55c9f658e2a75f0835d00a8a1cdc2f25c74d6
+Bug 1586176 - EncryptUpdate should use maxout not block size. r=franziskus
+
+--- a/nss/lib/softoken/pkcs11c.c
++++ b/nss/lib/softoken/pkcs11c.c
+@@ -1285,7 +1285,7 @@ NSC_EncryptUpdate(CK_SESSION_HANDLE hSes
+ }
+ /* encrypt the current padded data */
+ rv = (*context->update)(context->cipherInfo, pEncryptedPart,
+- &padoutlen, context->blockSize, context->padBuf,
++ &padoutlen, maxout, context->padBuf,
+ context->blockSize);
+ if (rv != SECSuccess) {
+ return sftk_MapCryptError(PORT_GetError());
diff --git a/gnu/packages/pretty-print.scm b/gnu/packages/pretty-print.scm
index cfe06a0be2..6f2b3f78ea 100644
--- a/gnu/packages/pretty-print.scm
+++ b/gnu/packages/pretty-print.scm
@@ -174,6 +174,8 @@ different programming languages.")
(base32
"0h148anbaqgch6n69pxsvs1c9wmykgd052wmzgdia7qpz8w6p8dl"))))
(build-system cmake-build-system)
+ (arguments
+ '(#:configure-flags '("-DBUILD_SHARED_LIBS=ON")))
(native-inputs
`(("unzip" ,unzip)))
(home-page "http://fmtlib.net/")
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 57c40aa3f0..03dddcde43 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -11768,19 +11768,41 @@ PNG, JPEG, JPEG2000 and GIF files in pure Python.")
(define-public python-argcomplete
(package
(name "python-argcomplete")
- (version "1.7.0")
+ (version "1.10.3")
(source
- (origin
- (method url-fetch)
- (uri (pypi-uri "argcomplete" version))
- (sha256
- (base32
- "11bwiw6j0nilgz81xnw6f1npyga3prp8asjqrm87cdr3ria5l03x"))))
+ (origin
+ (method url-fetch)
+ (uri (pypi-uri "argcomplete" version))
+ (sha256
+ (base32
+ "02jkc44drb0yjz6x28lvg6rj607n8r2irdpdvyylm8xnycn54zx3"))))
(build-system python-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'embed-tool-references
+ (lambda _
+ (substitute* "argcomplete/bash_completion.d/python-argcomplete.sh"
+ ((" grep")
+ (string-append " " (which "grep")))
+ ((" egrep")
+ (string-append " " (which "egrep")))
+ (("elif which")
+ (string-append "elif " (which "which")))
+ (("\\$\\(which")
+ (string-append "$(" (which "which"))))
+ #t)))))
+ (inputs
+ `(("grep" ,grep)
+ ("which" ,which)))
(native-inputs
- `(("python-pexpect" ,python-pexpect)
+ `(("python-coverage" ,python-coverage)
+ ("python-flake8" ,python-flake8)
+ ("python-pexpect" ,python-pexpect)
+ ("python-wheel" ,python-wheel)
("tcsh" ,tcsh)
- ("bash-full" ,bash))) ;full Bash for 'test_file_completion'
+ ("fish" ,fish)
+ ("bash-full" ,bash))) ;full Bash for 'test_file_completion'
(home-page "https://github.com/kislyuk/argcomplete")
(synopsis "Shell tab completion for Python argparse")
(description "argcomplete provides extensible command line tab completion
diff --git a/gnu/packages/ssh.scm b/gnu/packages/ssh.scm
index b82d280089..de33effc89 100644
--- a/gnu/packages/ssh.scm
+++ b/gnu/packages/ssh.scm
@@ -71,7 +71,7 @@
(define-public libssh
(package
(name "libssh")
- (version "0.9.2")
+ (version "0.9.3")
(source (origin
(method git-fetch)
(uri (git-reference
@@ -79,23 +79,13 @@
(commit (string-append "libssh-" version))))
(sha256
(base32
- "14g4rvp91skn2hlsjyhkv58vhng65xrf34cfqffixa4al869hzgj"))
+ "175i3xybg69d5lb078334v6dd3njm743kww8f67ix9w33969rmzf"))
(file-name (git-file-name name version))))
(build-system cmake-build-system)
(outputs '("out" "debug"))
(arguments
'(#:configure-flags '("-DWITH_GCRYPT=ON")
- #:phases (modify-phases %standard-phases
- (add-before 'configure 'avoid-werror
- (lambda _
- ;; Avoid '-Werror'. Presumably this works fine with
- ;; gcc@8 on x86_64 but leads to errors with our older
- ;; compiler.
- (substitute* "CompilerChecks.cmake"
- (("-Werror=") "-W"))
- #t)))
-
;; TODO: Add 'CMockery' and '-DWITH_TESTING=ON' for the test suite.
#:tests? #f))
(inputs `(("zlib" ,zlib)
diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm
index 21b3d76796..0e08edda1f 100644
--- a/gnu/packages/version-control.scm
+++ b/gnu/packages/version-control.scm
@@ -531,7 +531,7 @@ everything from small to very large projects with speed and efficiency.")
(define-public libgit2
(package
(name "libgit2")
- (version "0.28.3")
+ (version "0.28.4")
(source (origin
(method git-fetch)
(uri (git-reference
@@ -540,7 +540,7 @@ everything from small to very large projects with speed and efficiency.")
(file-name (git-file-name name version))
(sha256
(base32
- "07068flm9xi25wmcs65nyfg6a7ikgfv96i2nhgyj5gzs9gljqiz2"))
+ "171b25aym4q88bidc4c76y4l6jmdwifm3q9zjqsll0wjhlkycfy1"))
(patches (search-patches "libgit2-avoid-python.patch"
"libgit2-mtime-0.patch"))
diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
index 3bf5a22c87..3280114878 100644
--- a/gnu/packages/video.scm
+++ b/gnu/packages/video.scm
@@ -1454,6 +1454,7 @@ projects while introducing many more.")
(build-system gnu-build-system)
(arguments
`(#:configure-flags (list "--enable-shared"
+ "--disable-static"
"--as=yasm"
;; Limit size to avoid CVE-2015-1258
"--size-limit=16384x16384"
diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm
index dd0222730f..e83ae43da2 100644
--- a/gnu/packages/virtualization.scm
+++ b/gnu/packages/virtualization.scm
@@ -220,7 +220,7 @@ exec smbd $@")))
("spice" ,spice)
("usbredir" ,usbredir)
("util-linux" ,util-linux)
- ;; ("vde2" ,vde2)
+ ("vde2" ,vde2)
("virglrenderer" ,virglrenderer)
("zlib" ,zlib)))
(native-inputs `(("gettext" ,gettext-minimal)
@@ -268,7 +268,7 @@ server and embedded PowerPC, and S390 guests.")
'("gettext")))
(inputs (fold alist-delete (package-inputs qemu)
'("libusb" "mesa" "sdl2" "spice" "virglrenderer" "gtk+"
- "usbredir" "libdrm" "libepoxy" "pulseaudio")))))
+ "usbredir" "libdrm" "libepoxy" "pulseaudio" "vde2")))))
;; The GRUB test suite fails with later versions of Qemu, so we
;; keep it at 2.10 for now. See
diff --git a/gnu/packages/vpn.scm b/gnu/packages/vpn.scm
index 1fd313c46c..1c2228c426 100644
--- a/gnu/packages/vpn.scm
+++ b/gnu/packages/vpn.scm
@@ -10,6 +10,7 @@
;;; Copyright © 2018 Meiyo Peng <meiyo.peng@gmail.com>
;;; Copyright © 2019 Leo Famulari <leo@famulari.name>
;;; Copyright © 2019 Rutger Helling <rhelling@mykolab.com>
+;;; Copyright © 2019 Ricardo Wurmus <rekado@elephly.net>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -42,6 +43,7 @@
#:use-module (gnu packages compression)
#:use-module (gnu packages gettext)
#:use-module (gnu packages gnupg)
+ #:use-module (gnu packages guile)
#:use-module (gnu packages libevent)
#:use-module (gnu packages linux)
#:use-module (gnu packages nss)
@@ -134,7 +136,8 @@ Only \"Universal TUN/TAP device driver support\" is needed in the kernel.")
(base32
"1g41yarz2bl0f73kbjqnywr485ghanbp7nmspklfb0n07yp0z6ak"))))
(build-system gnu-build-system)
- (inputs `(("coreutils" ,coreutils)
+ (inputs `(("guile" ,guile-2.2) ; for the wrapper scripts
+ ("coreutils" ,coreutils)
("grep" ,grep)
("iproute2" ,iproute) ; for ‘ip’
("net-tools" ,net-tools) ; for ‘ifconfig’, ‘route’
@@ -177,7 +180,7 @@ Only \"Universal TUN/TAP device driver support\" is needed in the kernel.")
(let ((out (assoc-ref outputs "out")))
(for-each
(lambda (script)
- (wrap-program script
+ (wrap-script (string-append out "/etc/vpnc/" script)
`("PATH" ":" prefix
,(map (lambda (name)
(let ((input (assoc-ref inputs name)))
@@ -189,8 +192,9 @@ Only \"Universal TUN/TAP device driver support\" is needed in the kernel.")
"net-tools"
"sed"
"which")))))
- (find-files (string-append out "/etc/vpnc/vpnc-script")
- "^vpnc-script"))
+ (list "vpnc-script-ptrtd"
+ "vpnc-script-sshd"
+ "vpnc-script"))
#t))))
#:tests? #f)) ; no tests
(home-page "http://git.infradead.org/users/dwmw2/vpnc-scripts.git")
diff --git a/gnu/packages/xiph.scm b/gnu/packages/xiph.scm
index be02106f9a..61d836a50b 100644
--- a/gnu/packages/xiph.scm
+++ b/gnu/packages/xiph.scm
@@ -143,6 +143,8 @@ compressed video format.")
(base32
"150047wnllz4r94whb9r73l5qf0z5z3rlhy98bawfbblmkq8mbpa"))))
(build-system gnu-build-system)
+ (arguments
+ '(#:configure-flags '("--disable-static")))
(native-inputs
`(("pkg-config" ,pkg-config)))
(inputs
diff --git a/guix/import/cran.scm b/guix/import/cran.scm
index e47aff2b12..d9018cc7da 100644
--- a/guix/import/cran.scm
+++ b/guix/import/cran.scm
@@ -1,6 +1,6 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2015, 2016, 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
-;;; Copyright © 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright © 2015, 2016, 2017, 2019 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com>
;;;
;;; This file is part of GNU Guix.
@@ -505,7 +505,7 @@ s-expression corresponding to that package, or #f on failure."
((bioconductor)
;; Retry import from CRAN
(cran->guix-package package-name 'cran))
- (else #f)))))))
+ (else (values #f '()))))))))
(define* (cran-recursive-import package-name #:optional (repo 'cran))
(recursive-import package-name repo
diff --git a/guix/import/crate.scm b/guix/import/crate.scm
index 8dc014d232..4c3f8000d0 100644
--- a/guix/import/crate.scm
+++ b/guix/import/crate.scm
@@ -178,21 +178,20 @@ and LICENSE."
(close-port port)
pkg))
-(define %dual-license-rx
- ;; Dual licensing is represented by a string such as "MIT OR Apache-2.0".
- ;; This regexp matches that.
- (make-regexp "^(.*) OR (.*)$"))
+(define (string->license string)
+ (filter-map (lambda (license)
+ (and (not (string-null? license))
+ (not (any (lambda (elem) (string=? elem license))
+ '("AND" "OR" "WITH")))
+ (or (spdx-string->license license)
+ 'unknown-license!)))
+ (string-split string (string->char-set " /"))))
(define* (crate->guix-package crate-name #:optional version)
"Fetch the metadata for CRATE-NAME from crates.io, and return the
`package' s-expression corresponding to that package, or #f on failure.
When VERSION is specified, attempt to fetch that version; otherwise fetch the
latest version of CRATE-NAME."
- (define (string->license string)
- (match (regexp-exec %dual-license-rx string)
- (#f (list (spdx-string->license string)))
- (m (list (spdx-string->license (match:substring m 1))
- (spdx-string->license (match:substring m 2))))))
(define (normal-dependency? dependency)
(eq? (crate-dependency-kind dependency) 'normal))
diff --git a/guix/import/utils.scm b/guix/import/utils.scm
index 4694b6e7ef..47fc8276a9 100644
--- a/guix/import/utils.scm
+++ b/guix/import/utils.scm
@@ -34,15 +34,16 @@
#:use-module (guix gexp)
#:use-module (guix store)
#:use-module (guix download)
+ #:use-module (guix sets)
#:use-module (gnu packages)
#:use-module (ice-9 match)
#:use-module (ice-9 rdelim)
#:use-module (ice-9 receive)
#:use-module (ice-9 regex)
#:use-module (srfi srfi-1)
+ #:use-module (srfi srfi-9)
#:use-module (srfi srfi-11)
#:use-module (srfi srfi-26)
- #:use-module (srfi srfi-41)
#:export (factorize-uri
flatten
@@ -377,40 +378,53 @@ separated by PRED."
(chr (char-downcase chr)))
name)))
+(define (topological-sort nodes
+ node-dependencies
+ node-name)
+ "Perform a breadth-first traversal of the graph rooted at NODES, a list of
+nodes, and return the list of nodes sorted in topological order. Call
+NODE-DEPENDENCIES to obtain the dependencies of a node, and NODE-NAME to
+obtain a node's uniquely identifying \"key\"."
+ (let loop ((nodes nodes)
+ (result '())
+ (visited (set)))
+ (match nodes
+ (()
+ result)
+ ((head . tail)
+ (if (set-contains? visited (node-name head))
+ (loop tail result visited)
+ (let ((dependencies (node-dependencies head)))
+ (loop (append dependencies tail)
+ (cons head result)
+ (set-insert (node-name head) visited))))))))
+
(define* (recursive-import package-name repo
#:key repo->guix-package guix-name
#:allow-other-keys)
- "Generate a stream of package expressions for PACKAGE-NAME and all its
-dependencies."
- (define (exists? dependency)
- (not (null? (find-packages-by-name (guix-name dependency)))))
- (define initial-state (list #f (list package-name) (list)))
- (define (step state)
- (match state
- ((prev (next . rest) done)
- (define (handle? dep)
- (and
- (not (equal? dep next))
- (not (member dep done))
- (not (exists? dep))))
- (receive (package . dependencies) (repo->guix-package next repo)
- (list
- (if package package '()) ;; default #f on failure would interrupt
- (if package
- (lset-union equal? rest (filter handle? (car dependencies)))
- rest)
- (cons next done))))
- ((prev '() done)
- (list #f '() done))))
-
- ;; Generate a lazy stream of package expressions for all unknown
- ;; dependencies in the graph.
- (stream-unfold
- ;; map: produce a stream element
- (match-lambda ((latest queue done) latest))
- ;; predicate
- (match-lambda ((latest queue done) latest))
- ;; generator: update the queue
- step
- ;; initial state
- (step initial-state)))
+ "Return a stream of package expressions for PACKAGE-NAME and all its
+dependencies, sorted in topological order. For each package,
+call (REPO->GUIX-PACKAGE NAME REPO), which should return a package expression
+and a list of dependencies; call (GUIX-NAME NAME) to obtain the Guix package
+name corresponding to the upstream name."
+ (define-record-type <node>
+ (make-node name package dependencies)
+ node?
+ (name node-name)
+ (package node-package)
+ (dependencies node-dependencies))
+
+ (define (exists? name)
+ (not (null? (find-packages-by-name (guix-name name)))))
+
+ (define (lookup-node name)
+ (receive (package dependencies) (repo->guix-package name repo)
+ (make-node name package dependencies)))
+
+ (map node-package
+ (topological-sort (list (lookup-node package-name))
+ (lambda (node)
+ (map lookup-node
+ (remove exists?
+ (node-dependencies node))))
+ node-name)))
diff --git a/guix/scripts/import/cran.scm b/guix/scripts/import/cran.scm
index b6592f78a9..d6f371ef3a 100644
--- a/guix/scripts/import/cran.scm
+++ b/guix/scripts/import/cran.scm
@@ -27,7 +27,6 @@
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-11)
#:use-module (srfi srfi-37)
- #:use-module (srfi srfi-41)
#:use-module (ice-9 match)
#:use-module (ice-9 format)
#:export (guix-import-cran))
@@ -98,10 +97,8 @@ Import and convert the CRAN package for PACKAGE-NAME.\n"))
(if (assoc-ref opts 'recursive)
;; Recursive import
(map package->definition
- (reverse
- (stream->list
- (cran-recursive-import package-name
- (or (assoc-ref opts 'repo) 'cran)))))
+ (cran-recursive-import package-name
+ (or (assoc-ref opts 'repo) 'cran)))
;; Single import
(let ((sexp (cran->guix-package package-name
(or (assoc-ref opts 'repo) 'cran))))
diff --git a/guix/scripts/import/crate.scm b/guix/scripts/import/crate.scm
index 4690cceb4d..92034dab3c 100644
--- a/guix/scripts/import/crate.scm
+++ b/guix/scripts/import/crate.scm
@@ -28,7 +28,6 @@
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-11)
#:use-module (srfi srfi-37)
- #:use-module (srfi srfi-41)
#:use-module (ice-9 match)
#:use-module (ice-9 format)
#:export (guix-import-crate))
@@ -101,9 +100,7 @@ Import and convert the crate.io package for PACKAGE-NAME.\n"))
`(define-public ,(string->symbol name)
,pkg))
(_ #f))
- (reverse
- (stream->list
- (crate-recursive-import name))))
+ (crate-recursive-import name))
(let ((sexp (crate->guix-package name version)))
(unless sexp
(leave (G_ "failed to download meta-data for package '~a'~%")
diff --git a/guix/scripts/import/elpa.scm b/guix/scripts/import/elpa.scm
index f1ed5016ba..d270d2b4bc 100644
--- a/guix/scripts/import/elpa.scm
+++ b/guix/scripts/import/elpa.scm
@@ -27,7 +27,6 @@
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-11)
#:use-module (srfi srfi-37)
- #:use-module (srfi srfi-41)
#:use-module (ice-9 match)
#:use-module (ice-9 format)
#:export (guix-import-elpa))
@@ -101,10 +100,8 @@ Import the latest package named PACKAGE-NAME from an ELPA repository.\n"))
`(define-public ,(string->symbol name)
,pkg))
(_ #f))
- (reverse
- (stream->list
- (elpa-recursive-import package-name
- (or (assoc-ref opts 'repo) 'gnu)))))
+ (elpa-recursive-import package-name
+ (or (assoc-ref opts 'repo) 'gnu)))
(let ((sexp (elpa->guix-package package-name (assoc-ref opts 'repo))))
(unless sexp
(leave (G_ "failed to download package '~a'~%") package-name))
diff --git a/guix/scripts/import/gem.scm b/guix/scripts/import/gem.scm
index b6d9ccaae4..c64596b514 100644
--- a/guix/scripts/import/gem.scm
+++ b/guix/scripts/import/gem.scm
@@ -26,7 +26,6 @@
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-11)
#:use-module (srfi srfi-37)
- #:use-module (srfi srfi-41)
#:use-module (ice-9 match)
#:use-module (ice-9 format)
#:export (guix-import-gem))
@@ -95,9 +94,7 @@ Import and convert the RubyGems package for PACKAGE-NAME.\n"))
`(define-public ,(string->symbol name)
,pkg))
(_ #f))
- (reverse
- (stream->list
- (gem-recursive-import package-name 'rubygems))))
+ (gem-recursive-import package-name 'rubygems))
(let ((sexp (gem->guix-package package-name)))
(unless sexp
(leave (G_ "failed to download meta-data for package '~a'~%")
diff --git a/guix/scripts/import/hackage.scm b/guix/scripts/import/hackage.scm
index f4aac61078..710e786a79 100644
--- a/guix/scripts/import/hackage.scm
+++ b/guix/scripts/import/hackage.scm
@@ -27,7 +27,6 @@
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-11)
#:use-module (srfi srfi-37)
- #:use-module (srfi srfi-41)
#:use-module (ice-9 match)
#:use-module (ice-9 format)
#:export (guix-import-hackage))
@@ -130,9 +129,7 @@ version.\n"))
`(define-public ,(string->symbol name)
,pkg))
(_ #f))
- (reverse
- (stream->list
- (apply hackage-recursive-import arguments))))
+ (apply hackage-recursive-import arguments))
;; Single import
(apply hackage->guix-package arguments))))
(unless sexp (error-fn))
diff --git a/guix/scripts/import/opam.scm b/guix/scripts/import/opam.scm
index 2d249a213f..20da1437fe 100644
--- a/guix/scripts/import/opam.scm
+++ b/guix/scripts/import/opam.scm
@@ -25,7 +25,6 @@
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-11)
#:use-module (srfi srfi-37)
- #:use-module (srfi srfi-41)
#:use-module (ice-9 match)
#:use-module (ice-9 format)
#:export (guix-import-opam))
@@ -94,9 +93,7 @@ Import and convert the opam package for PACKAGE-NAME.\n"))
`(define-public ,(string->symbol name)
,pkg))
(_ #f))
- (reverse
- (stream->list
- (opam-recursive-import package-name))))
+ (opam-recursive-import package-name))
;; Single import
(let ((sexp (opam->guix-package package-name)))
(unless sexp
diff --git a/guix/scripts/import/pypi.scm b/guix/scripts/import/pypi.scm
index 7bd83818ba..33167174e2 100644
--- a/guix/scripts/import/pypi.scm
+++ b/guix/scripts/import/pypi.scm
@@ -26,7 +26,6 @@
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-11)
#:use-module (srfi srfi-37)
- #:use-module (srfi srfi-41)
#:use-module (ice-9 match)
#:use-module (ice-9 format)
#:export (guix-import-pypi))
@@ -95,9 +94,7 @@ Import and convert the PyPI package for PACKAGE-NAME.\n"))
`(define-public ,(string->symbol name)
,pkg))
(_ #f))
- (reverse
- (stream->list
- (pypi-recursive-import package-name))))
+ (pypi-recursive-import package-name))
;; Single import
(let ((sexp (pypi->guix-package package-name)))
(unless sexp
diff --git a/guix/scripts/import/stackage.scm b/guix/scripts/import/stackage.scm
index b4b12581bf..d77328dcbf 100644
--- a/guix/scripts/import/stackage.scm
+++ b/guix/scripts/import/stackage.scm
@@ -27,7 +27,6 @@
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-11)
#:use-module (srfi srfi-37)
- #:use-module (srfi srfi-41)
#:use-module (ice-9 match)
#:use-module (ice-9 format)
#:export (guix-import-stackage))
@@ -110,9 +109,7 @@ Import and convert the LTS Stackage package for PACKAGE-NAME.\n"))
`(define-public ,(string->symbol name)
,pkg))
(_ #f))
- (reverse
- (stream->list
- (apply stackage-recursive-import arguments))))
+ (apply stackage-recursive-import arguments))
;; Single import
(apply stackage->guix-package arguments))))
(unless sexp (error-fn))
diff --git a/tests/crate.scm b/tests/crate.scm
index c14862ad9f..61933a8de8 100644
--- a/tests/crate.scm
+++ b/tests/crate.scm
@@ -28,7 +28,7 @@
#:use-module (ice-9 match)
#:use-module (srfi srfi-64))
-(define test-crate
+(define test-foo-crate
"{
\"crate\": {
\"max_version\": \"1.0.0\",
@@ -50,7 +50,7 @@
}
}")
-(define test-dependencies
+(define test-foo-dependencies
"{
\"dependencies\": [
{
@@ -60,9 +60,182 @@
]
}")
+(define test-root-crate
+ "{
+ \"crate\": {
+ \"max_version\": \"1.0.0\",
+ \"name\": \"root\",
+ \"description\": \"summary\",
+ \"homepage\": \"http://example.com\",
+ \"repository\": \"http://example.com\",
+ \"keywords\": [\"dummy\" \"test\"],
+ \"categories\": [\"test\"]
+ \"actual_versions\": [
+ { \"id\": \"foo\",
+ \"num\": \"1.0.0\",
+ \"license\": \"MIT OR Apache-2.0\",
+ \"links\": {
+ \"dependencies\": \"/api/v1/crates/root/1.0.0/dependencies\"
+ }
+ }
+ ]
+ }
+}")
+
+(define test-root-dependencies
+ "{
+ \"dependencies\": [
+ {
+ \"crate_id\": \"intermediate-1\",
+ \"kind\": \"normal\",
+ },
+ {
+ \"crate_id\": \"intermediate-2\",
+ \"kind\": \"normal\",
+ }
+ {
+ \"crate_id\": \"leaf-alice\",
+ \"kind\": \"normal\",
+ },
+ {
+ \"crate_id\": \"leaf-bob\",
+ \"kind\": \"normal\",
+ },
+ ]
+}")
+
+(define test-intermediate-1-crate
+ "{
+ \"crate\": {
+ \"max_version\": \"1.0.0\",
+ \"name\": \"intermediate-1\",
+ \"description\": \"summary\",
+ \"homepage\": \"http://example.com\",
+ \"repository\": \"http://example.com\",
+ \"keywords\": [\"dummy\" \"test\"],
+ \"categories\": [\"test\"]
+ \"actual_versions\": [
+ { \"id\": \"intermediate-1\",
+ \"num\": \"1.0.0\",
+ \"license\": \"MIT OR Apache-2.0\",
+ \"links\": {
+ \"dependencies\": \"/api/v1/crates/intermediate-1/1.0.0/dependencies\"
+ }
+ }
+ ]
+ }
+}")
+
+(define test-intermediate-1-dependencies
+ "{
+ \"dependencies\": [
+ {
+ \"crate_id\": \"intermediate-2\",
+ \"kind\": \"normal\",
+ },
+ {
+ \"crate_id\": \"leaf-alice\",
+ \"kind\": \"normal\",
+ },
+ {
+ \"crate_id\": \"leaf-bob\",
+ \"kind\": \"normal\",
+ }
+ ]
+}")
+
+(define test-intermediate-2-crate
+ "{
+ \"crate\": {
+ \"max_version\": \"1.0.0\",
+ \"name\": \"intermediate-2\",
+ \"description\": \"summary\",
+ \"homepage\": \"http://example.com\",
+ \"repository\": \"http://example.com\",
+ \"keywords\": [\"dummy\" \"test\"],
+ \"categories\": [\"test\"]
+ \"actual_versions\": [
+ { \"id\": \"intermediate-2\",
+ \"num\": \"1.0.0\",
+ \"license\": \"MIT OR Apache-2.0\",
+ \"links\": {
+ \"dependencies\": \"/api/v1/crates/intermediate-2/1.0.0/dependencies\"
+ }
+ }
+ ]
+ }
+}")
+
+(define test-intermediate-2-dependencies
+ "{
+ \"dependencies\": [
+ {
+ \"crate_id\": \"leaf-bob\",
+ \"kind\": \"normal\",
+ },
+ ]
+}")
+
+(define test-leaf-alice-crate
+ "{
+ \"crate\": {
+ \"max_version\": \"1.0.0\",
+ \"name\": \"leaf-alice\",
+ \"description\": \"summary\",
+ \"homepage\": \"http://example.com\",
+ \"repository\": \"http://example.com\",
+ \"keywords\": [\"dummy\" \"test\"],
+ \"categories\": [\"test\"]
+ \"actual_versions\": [
+ { \"id\": \"leaf-alice\",
+ \"num\": \"1.0.0\",
+ \"license\": \"MIT OR Apache-2.0\",
+ \"links\": {
+ \"dependencies\": \"/api/v1/crates/leaf-alice/1.0.0/dependencies\"
+ }
+ }
+ ]
+ }
+}")
+
+(define test-leaf-alice-dependencies
+ "{
+ \"dependencies\": []
+}")
+
+(define test-leaf-bob-crate
+ "{
+ \"crate\": {
+ \"max_version\": \"1.0.0\",
+ \"name\": \"leaf-bob\",
+ \"description\": \"summary\",
+ \"homepage\": \"http://example.com\",
+ \"repository\": \"http://example.com\",
+ \"keywords\": [\"dummy\" \"test\"],
+ \"categories\": [\"test\"]
+ \"actual_versions\": [
+ { \"id\": \"leaf-bob\",
+ \"num\": \"1.0.0\",
+ \"license\": \"MIT OR Apache-2.0\",
+ \"links\": {
+ \"dependencies\": \"/api/v1/crates/leaf-bob/1.0.0/dependencies\"
+ }
+ }
+ ]
+ }
+}")
+
+(define test-leaf-bob-dependencies
+ "{
+ \"dependencies\": []
+}")
+
(define test-source-hash
"")
+(define string->license
+ (@@ (guix import crate) string->license))
+
(test-begin "crate")
(test-equal "guix-package->crate-name"
@@ -79,14 +252,14 @@
(lambda (url . rest)
(match url
("https://crates.io/api/v1/crates/foo"
- (open-input-string test-crate))
+ (open-input-string test-foo-crate))
("https://crates.io/api/v1/crates/foo/1.0.0/download"
(set! test-source-hash
(bytevector->nix-base32-string
(sha256 (string->bytevector "empty file\n" "utf-8"))))
(open-input-string "empty file\n"))
("https://crates.io/api/v1/crates/foo/1.0.0/dependencies"
- (open-input-string test-dependencies))
+ (open-input-string test-foo-dependencies))
(_ (error "Unexpected URL: " url)))))
(match (crate->guix-package "foo")
(('package
@@ -111,4 +284,180 @@
(x
(pk 'fail x #f)))))
+(test-assert "cargo-recursive-import"
+ ;; Replace network resources with sample data.
+ (mock ((guix http-client) http-fetch
+ (lambda (url . rest)
+ (match url
+ ("https://crates.io/api/v1/crates/root"
+ (open-input-string test-root-crate))
+ ("https://crates.io/api/v1/crates/root/1.0.0/download"
+ (set! test-source-hash
+ (bytevector->nix-base32-string
+ (sha256 (string->bytevector "empty file\n" "utf-8"))))
+ (open-input-string "empty file\n"))
+ ("https://crates.io/api/v1/crates/root/1.0.0/dependencies"
+ (open-input-string test-root-dependencies))
+ ("https://crates.io/api/v1/crates/intermediate-1"
+ (open-input-string test-intermediate-1-crate))
+ ("https://crates.io/api/v1/crates/intermediate-1/1.0.0/download"
+ (set! test-source-hash
+ (bytevector->nix-base32-string
+ (sha256 (string->bytevector "empty file\n" "utf-8"))))
+ (open-input-string "empty file\n"))
+ ("https://crates.io/api/v1/crates/intermediate-1/1.0.0/dependencies"
+ (open-input-string test-intermediate-1-dependencies))
+ ("https://crates.io/api/v1/crates/intermediate-2"
+ (open-input-string test-intermediate-2-crate))
+ ("https://crates.io/api/v1/crates/intermediate-2/1.0.0/download"
+ (set! test-source-hash
+ (bytevector->nix-base32-string
+ (sha256 (string->bytevector "empty file\n" "utf-8"))))
+ (open-input-string "empty file\n"))
+ ("https://crates.io/api/v1/crates/intermediate-2/1.0.0/dependencies"
+ (open-input-string test-intermediate-2-dependencies))
+ ("https://crates.io/api/v1/crates/leaf-alice"
+ (open-input-string test-leaf-alice-crate))
+ ("https://crates.io/api/v1/crates/leaf-alice/1.0.0/download"
+ (set! test-source-hash
+ (bytevector->nix-base32-string
+ (sha256 (string->bytevector "empty file\n" "utf-8"))))
+ (open-input-string "empty file\n"))
+ ("https://crates.io/api/v1/crates/leaf-alice/1.0.0/dependencies"
+ (open-input-string test-leaf-alice-dependencies))
+ ("https://crates.io/api/v1/crates/leaf-bob"
+ (open-input-string test-leaf-bob-crate))
+ ("https://crates.io/api/v1/crates/leaf-bob/1.0.0/download"
+ (set! test-source-hash
+ (bytevector->nix-base32-string
+ (sha256 (string->bytevector "empty file\n" "utf-8"))))
+ (open-input-string "empty file\n"))
+ ("https://crates.io/api/v1/crates/leaf-bob/1.0.0/dependencies"
+ (open-input-string test-leaf-bob-dependencies))
+ (_ (error "Unexpected URL: " url)))))
+ (match (crate-recursive-import "root")
+ ;; rust-intermediate-2 has no dependency on the rust-leaf-alice package, so this is a valid ordering
+ ((('package
+ ('name "rust-leaf-alice")
+ ('version (? string? ver))
+ ('source
+ ('origin
+ ('method 'url-fetch)
+ ('uri ('crate-uri "leaf-alice" 'version))
+ ('file-name
+ ('string-append 'name "-" 'version ".tar.gz"))
+ ('sha256
+ ('base32
+ (? string? hash)))))
+ ('build-system 'cargo-build-system)
+ ('home-page "http://example.com")
+ ('synopsis "summary")
+ ('description "summary")
+ ('license ('list 'license:expat 'license:asl2.0)))
+ ('package
+ ('name "rust-leaf-bob")
+ ('version (? string? ver))
+ ('source
+ ('origin
+ ('method 'url-fetch)
+ ('uri ('crate-uri "leaf-bob" 'version))
+ ('file-name
+ ('string-append 'name "-" 'version ".tar.gz"))
+ ('sha256
+ ('base32
+ (? string? hash)))))
+ ('build-system 'cargo-build-system)
+ ('home-page "http://example.com")
+ ('synopsis "summary")
+ ('description "summary")
+ ('license ('list 'license:expat 'license:asl2.0)))
+ ('package
+ ('name "rust-intermediate-2")
+ ('version (? string? ver))
+ ('source
+ ('origin
+ ('method 'url-fetch)
+ ('uri ('crate-uri "intermediate-2" 'version))
+ ('file-name
+ ('string-append 'name "-" 'version ".tar.gz"))
+ ('sha256
+ ('base32
+ (? string? hash)))))
+ ('build-system 'cargo-build-system)
+ ('arguments
+ ('quasiquote
+ ('#:cargo-inputs (("rust-leaf-bob" ('unquote rust-leaf-bob))))))
+ ('home-page "http://example.com")
+ ('synopsis "summary")
+ ('description "summary")
+ ('license ('list 'license:expat 'license:asl2.0)))
+ ('package
+ ('name "rust-intermediate-1")
+ ('version (? string? ver))
+ ('source
+ ('origin
+ ('method 'url-fetch)
+ ('uri ('crate-uri "intermediate-1" 'version))
+ ('file-name
+ ('string-append 'name "-" 'version ".tar.gz"))
+ ('sha256
+ ('base32
+ (? string? hash)))))
+ ('build-system 'cargo-build-system)
+ ('arguments
+ ('quasiquote
+ ('#:cargo-inputs (("rust-intermediate-2" ('unquote rust-intermediate-2))
+ ("rust-leaf-alice" ('unquote rust-leaf-alice))
+ ("rust-leaf-bob" ('unquote rust-leaf-bob))))))
+ ('home-page "http://example.com")
+ ('synopsis "summary")
+ ('description "summary")
+ ('license ('list 'license:expat 'license:asl2.0)))
+ ('package
+ ('name "rust-root")
+ ('version (? string? ver))
+ ('source
+ ('origin
+ ('method 'url-fetch)
+ ('uri ('crate-uri "root" 'version))
+ ('file-name
+ ('string-append 'name "-" 'version ".tar.gz"))
+ ('sha256
+ ('base32
+ (? string? hash)))))
+ ('build-system 'cargo-build-system)
+ ('arguments
+ ('quasiquote
+ ('#:cargo-inputs (("rust-intermediate-1" ('unquote rust-intermediate-1))
+ ("rust-intermediate-2" ('unquote rust-intermediate-2))
+ ("rust-leaf-alice" ('unquote rust-leaf-alice))
+ ("rust-leaf-bob" ('unquote rust-leaf-bob))))))
+ ('home-page "http://example.com")
+ ('synopsis "summary")
+ ('description "summary")
+ ('license ('list 'license:expat 'license:asl2.0))))
+ #t)
+ (x
+ (pk 'fail x #f)))))
+
+(test-equal "licenses: MIT OR Apache-2.0"
+ '(license:expat license:asl2.0)
+ (string->license "MIT OR Apache-2.0"))
+
+(test-equal "licenses: Apache-2.0 / MIT"
+ '(license:asl2.0 license:expat)
+ (string->license "Apache-2.0 / MIT"))
+
+(test-equal "licenses: Apache-2.0 WITH LLVM-exception"
+ '(license:asl2.0 unknown-license!)
+ (string->license "Apache-2.0 WITH LLVM-exception"))
+
+(test-equal "licenses: MIT/Apache-2.0 AND BSD-2-Clause"
+ '(license:expat license:asl2.0 unknown-license!)
+ (string->license "MIT/Apache-2.0 AND BSD-2-Clause"))
+
+(test-equal "licenses: MIT/Apache-2.0"
+ '(license:expat license:asl2.0)
+ (string->license "MIT/Apache-2.0"))
+
(test-end "crate")
diff --git a/tests/gem.scm b/tests/gem.scm
index a12edb294c..5158238d18 100644
--- a/tests/gem.scm
+++ b/tests/gem.scm
@@ -24,7 +24,6 @@
#:use-module (gcrypt hash)
#:use-module (guix tests)
#:use-module ((guix build utils) #:select (delete-file-recursively))
- #:use-module (srfi srfi-41)
#:use-module (srfi srfi-64)
#:use-module (ice-9 match))
@@ -121,24 +120,23 @@
(values (open-input-string test-bundler-json)
(string-length test-bundler-json)))
(_ (error "Unexpected URL: " url)))))
- (match (stream->list (gem-recursive-import "foo"))
+ (match (gem-recursive-import "foo")
((('package
- ('name "ruby-foo")
+ ('name "ruby-bar")
('version "1.0.0")
('source
('origin
('method 'url-fetch)
- ('uri ('rubygems-uri "foo" 'version))
+ ('uri ('rubygems-uri "bar" 'version))
('sha256
('base32
"1a270mlajhrmpqbhxcqjqypnvgrq4pgixpv3w9gwp1wrrapnwrzk"))))
('build-system 'ruby-build-system)
('propagated-inputs
('quasiquote
- (("bundler" ('unquote 'bundler))
- ("ruby-bar" ('unquote 'ruby-bar)))))
- ('synopsis "A cool gem")
- ('description "This package provides a cool gem")
+ (('"bundler" ('unquote 'bundler)))))
+ ('synopsis "Another cool gem")
+ ('description "Another cool gem")
('home-page "https://example.com")
('license ('list 'license:expat 'license:asl2.0)))
('package
@@ -157,21 +155,22 @@
('home-page "https://bundler.io/")
('license 'license:expat))
('package
- ('name "ruby-bar")
+ ('name "ruby-foo")
('version "1.0.0")
('source
('origin
('method 'url-fetch)
- ('uri ('rubygems-uri "bar" 'version))
+ ('uri ('rubygems-uri "foo" 'version))
('sha256
('base32
"1a270mlajhrmpqbhxcqjqypnvgrq4pgixpv3w9gwp1wrrapnwrzk"))))
('build-system 'ruby-build-system)
('propagated-inputs
('quasiquote
- (('"bundler" ('unquote 'bundler)))))
- ('synopsis "Another cool gem")
- ('description "Another cool gem")
+ (("bundler" ('unquote 'bundler))
+ ("ruby-bar" ('unquote 'ruby-bar)))))
+ ('synopsis "A cool gem")
+ ('description "This package provides a cool gem")
('home-page "https://example.com")
('license ('list 'license:expat 'license:asl2.0))))
#t)
diff --git a/tests/import-utils.scm b/tests/import-utils.scm
index c3ab25d788..87dda3238f 100644
--- a/tests/import-utils.scm
+++ b/tests/import-utils.scm
@@ -24,7 +24,8 @@
#:use-module (guix packages)
#:use-module (guix build-system)
#:use-module (gnu packages)
- #:use-module (srfi srfi-64))
+ #:use-module (srfi srfi-64)
+ #:use-module (ice-9 match))
(test-begin "import-utils")
@@ -41,6 +42,26 @@
'license:lgpl2.0
(license->symbol license:lgpl2.0))
+(test-equal "recursive-import"
+ '((package ;package expressions in topological order
+ (name "bar"))
+ (package
+ (name "foo")
+ (inputs `(("bar" ,bar)))))
+ (recursive-import "foo" 'repo
+ #:repo->guix-package
+ (match-lambda*
+ (("foo" 'repo)
+ (values '(package
+ (name "foo")
+ (inputs `(("bar" ,bar))))
+ '("bar")))
+ (("bar" 'repo)
+ (values '(package
+ (name "bar"))
+ '())))
+ #:guix-name identity))
+
(test-assert "alist->package with simple source"
(let* ((meta '(("name" . "hello")
("version" . "2.10")