From 03b630686fe96793e87f1323330d3c724abd2e14 Mon Sep 17 00:00:00 2001 From: Kei Kebreau Date: Fri, 24 May 2019 15:31:58 -0400 Subject: gnu: squirrel: Build from a source archive instead of a Git checkout. * gnu/packages/squirrel.scm (squirrel)[source]: Use url-fetch and adjust the source URL accordingly. --- gnu/packages/squirrel.scm | 48 +++++++++++++++++++++++------------------------ 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/gnu/packages/squirrel.scm b/gnu/packages/squirrel.scm index 1da0ad9fe..8cd9aaab8 100644 --- a/gnu/packages/squirrel.scm +++ b/gnu/packages/squirrel.scm @@ -20,36 +20,36 @@ #:use-module (gnu packages) #:use-module (gnu packages cmake) #:use-module (guix build-system cmake) - #:use-module (guix git-download) + #:use-module (guix download) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix build utils) #:use-module (guix packages) #:use-module (guix utils)) (define-public squirrel - (let ((commit "51137b84e66c4d526809fd8a59f4ba1d38138c76")) - (package - (name "squirrel") - (version "3.1") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/albertodemichelis/squirrel.git") - (commit commit))) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "0vbiv1q3qcy2vj8y0b9a2ckswl9ld398n3jnxijvwddrjgya5zav")))) - (build-system cmake-build-system) - (arguments - '(#:tests? #f)) ; no tests - (native-inputs - `(("cmake" ,cmake))) - (home-page "https://squirrel-lang.org/") - (synopsis "High level imperative, object-oriented programming language") - (description - "Squirrel is a high level imperative, object-oriented programming + (package + (name "squirrel") + (version "3.1") + (source (origin + (method url-fetch) + (uri (string-append "mirror://sourceforge/squirrel/squirrel3/" + "squirrel " version " stable/squirrel_" + (string-join (string-split version #\.) "_") + "_stable.tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "1jyh1523zrrnh9swanfrda0s14mvwc9431dh07g0nx74hbxsfia8")))) + (build-system cmake-build-system) + (arguments + '(#:tests? #f)) ; no tests + (native-inputs + `(("cmake" ,cmake))) + (home-page "https://squirrel-lang.org/") + (synopsis "High level imperative, object-oriented programming language") + (description + "Squirrel is a high level imperative, object-oriented programming language, designed to be a light-weight scripting language that fits in the size, memory bandwidth, and real-time requirements of applications like video games.") - (license license:expat)))) + (license license:expat))) -- cgit v1.3 From 608d148c50962bc217b6481f60507873801464cf Mon Sep 17 00:00:00 2001 From: Kei Kebreau Date: Fri, 24 May 2019 15:48:01 -0400 Subject: gnu: squirrel: Install headers and documentation. * gnu/packages/squirrel.scm (squirrel)[arguments]: Disable building static libraries. Add 'install-documentation' and 'install-headers' phases. [native-inputs]: Add python-sphinx. --- gnu/packages/squirrel.scm | 32 ++++++++++++++++++++++++++++++-- 1 file changed, 30 insertions(+), 2 deletions(-) diff --git a/gnu/packages/squirrel.scm b/gnu/packages/squirrel.scm index 8cd9aaab8..12affe61e 100644 --- a/gnu/packages/squirrel.scm +++ b/gnu/packages/squirrel.scm @@ -19,6 +19,7 @@ (define-module (gnu packages squirrel) #:use-module (gnu packages) #:use-module (gnu packages cmake) + #:use-module (gnu packages python-xyz) #:use-module (guix build-system cmake) #:use-module (guix download) #:use-module ((guix licenses) #:prefix license:) @@ -42,9 +43,36 @@ "1jyh1523zrrnh9swanfrda0s14mvwc9431dh07g0nx74hbxsfia8")))) (build-system cmake-build-system) (arguments - '(#:tests? #f)) ; no tests + '(#:configure-flags '("-DDISABLE_STATIC=ON") + #:tests? #f ; no tests + #:phases + (modify-phases %standard-phases + (add-after 'install 'install-documentation + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (doc-dir (string-append out "/share/doc/squirrel"))) + (for-each + (lambda (file) + (install-file (string-append "../squirrel3/" file) doc-dir)) + '("COPYRIGHT" "HISTORY" "README" + "doc/sqstdlib3.pdf" "doc/squirrel3.pdf"))) + #t)) + (add-after 'install 'install-headers + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (include-dir (string-append out "/include/squirrel"))) + (mkdir-p include-dir) + (for-each + (lambda (header-file) + (copy-recursively header-file + (string-append include-dir + "/" + (basename header-file)))) + (find-files "../squirrel3/include"))) + #t))))) (native-inputs - `(("cmake" ,cmake))) + `(("cmake" ,cmake) + ("python-sphinx" ,python-sphinx))) (home-page "https://squirrel-lang.org/") (synopsis "High level imperative, object-oriented programming language") (description -- cgit v1.3 From 8698d986db21d6399fb57f1af1e38d6223bf9b92 Mon Sep 17 00:00:00 2001 From: Kei Kebreau Date: Fri, 24 May 2019 20:50:31 -0400 Subject: gnu: supertux: Update to 0.6.0. * gnu/packages/games.scm (supertux): Update to 0.6.0. [source]: Add patches. [arguments]: Add -DUSE_SYSTEM_PHYSFS=ON. Add 'patch-squirrel-path' phase. [inputs]: Add freetype and squirrel. * gnu/packages/patches/supertux-fix-build-with-gcc5.patch, gnu/packages/patches/supertux-unbundle-squirrel.patch: New files. * gnu/local.mk (dist_patch_DATA): Add them. --- gnu/local.mk | 2 + gnu/packages/games.scm | 28 ++++++-- .../patches/supertux-fix-build-with-gcc5.patch | 75 ++++++++++++++++++++++ .../patches/supertux-unbundle-squirrel.patch | 53 +++++++++++++++ 4 files changed, 154 insertions(+), 4 deletions(-) create mode 100644 gnu/packages/patches/supertux-fix-build-with-gcc5.patch create mode 100644 gnu/packages/patches/supertux-unbundle-squirrel.patch diff --git a/gnu/local.mk b/gnu/local.mk index d0745b005..57d3590b5 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1283,6 +1283,8 @@ dist_patch_DATA = \ %D%/packages/patches/superlu-dist-awpm-grid.patch \ %D%/packages/patches/superlu-dist-fix-mpi-deprecations.patch \ %D%/packages/patches/superlu-dist-scotchmetis.patch \ + %D%/packages/patches/supertux-fix-build-with-gcc5.patch \ + %D%/packages/patches/supertux-unbundle-squirrel.patch \ %D%/packages/patches/swig-guile-gc.patch \ %D%/packages/patches/swish-e-search.patch \ %D%/packages/patches/swish-e-format-security.patch \ diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm index 541587e05..4fdc9b01e 100644 --- a/gnu/packages/games.scm +++ b/gnu/packages/games.scm @@ -141,6 +141,7 @@ #:use-module (gnu packages sdl) #:use-module (gnu packages serialization) #:use-module (gnu packages sqlite) + #:use-module (gnu packages squirrel) #:use-module (gnu packages swig) #:use-module (gnu packages tcl) #:use-module (gnu packages terminals) @@ -3495,19 +3496,36 @@ with the \"Stamp\" tool within Tux Paint.") (define-public supertux (package (name "supertux") - (version "0.5.1") + (version "0.6.0") (source (origin (method url-fetch) (uri (string-append "https://github.com/SuperTux/supertux/" "releases/download/v" version "/SuperTux-v" version "-Source.tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 - "1i8avad7w7ikj870z519j383ldy29r6f956bs38cbr8wk513pp69")))) + "1h1s4abirkdv4ag22zvyk6zkk64skqbjmcnnba67ps4hdzxfbhy4")) + (patches + (search-patches "supertux-fix-build-with-gcc5.patch" + "supertux-unbundle-squirrel.patch")))) (arguments '(#:tests? #f #:configure-flags '("-DINSTALL_SUBDIR_BIN=bin" - "-DENABLE_BOOST_STATIC_LIBS=OFF"))) + "-DENABLE_BOOST_STATIC_LIBS=OFF" + "-DUSE_SYSTEM_PHYSFS=ON") + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'patch-squirrel-path + (lambda* (#:key inputs #:allow-other-keys) + (let ((squirrel (assoc-ref inputs "squirrel"))) + (substitute* "CMakeLists.txt" + (("set\\(SQUIRREL_PREFIX.*") + (string-append "set(SQUIRREL_PREFIX " squirrel ")")) + (("add_dependencies\\(supertux2_lib squirrel\\)") "") + (("\\$\\{SQUIRREL_PREFIX\\}/include") + (string-append "${SQUIRREL_PREFIX}/include/squirrel")))) + #t))))) (build-system cmake-build-system) (inputs `(("sdl2" ,sdl2) ("sdl2-image" ,sdl2-image) @@ -3519,7 +3537,9 @@ with the \"Stamp\" tool within Tux Paint.") ("libogg" ,libogg) ("physfs" ,physfs) ("curl" ,curl) - ("boost" ,boost))) + ("boost" ,boost) + ("freetype" ,freetype) + ("squirrel" ,squirrel))) (native-inputs `(("pkg-config" ,pkg-config))) (synopsis "2D platformer game") (description "SuperTux is a free classic 2D jump'n run sidescroller game diff --git a/gnu/packages/patches/supertux-fix-build-with-gcc5.patch b/gnu/packages/patches/supertux-fix-build-with-gcc5.patch new file mode 100644 index 000000000..6393215ca --- /dev/null +++ b/gnu/packages/patches/supertux-fix-build-with-gcc5.patch @@ -0,0 +1,75 @@ +Taken from https://github.com/SuperTux/supertux/commit/a75317ef0a94847d9b6a7833b9c6652ef29edde3. +This patch fixes building with gcc versions earlier than 6. + +From a75317ef0a94847d9b6a7833b9c6652ef29edde3 Mon Sep 17 00:00:00 2001 +From: Ingo Ruhnke +Date: Fri, 28 Dec 2018 22:45:35 +0100 +Subject: [PATCH] Add workaround for backwards compatibilty with gcc5 + +Fixes #1014 +--- + src/video/gl/gl_painter.cpp | 11 ++++++----- + src/video/ttf_surface.cpp | 16 +++++++++------- + 2 files changed, 15 insertions(+), 12 deletions(-) + +diff --git a/src/video/gl/gl_painter.cpp b/src/video/gl/gl_painter.cpp +index 5e0d1e7b1e..32fb7a09b6 100644 +--- a/src/video/gl/gl_painter.cpp ++++ b/src/video/gl/gl_painter.cpp +@@ -37,12 +37,13 @@ namespace { + + inline std::tuple blend_factor(Blend blend) + { ++ using B = std::tuple; + switch(blend) { +- case Blend::NONE: return {GL_ONE, GL_ZERO}; +- case Blend::BLEND: return {GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA}; +- case Blend::ADD: return {GL_SRC_ALPHA, GL_ONE}; +- case Blend::MOD: return {GL_DST_COLOR, GL_ZERO}; +- default: return {GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA}; ++ case Blend::NONE: return B(GL_ONE, GL_ZERO); ++ case Blend::BLEND: return B(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); ++ case Blend::ADD: return B(GL_SRC_ALPHA, GL_ONE); ++ case Blend::MOD: return B(GL_DST_COLOR, GL_ZERO); ++ default: return B(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); + } + } + +diff --git a/src/video/ttf_surface.cpp b/src/video/ttf_surface.cpp +index 7c9505004f..b41d67b2c8 100644 +--- a/src/video/ttf_surface.cpp ++++ b/src/video/ttf_surface.cpp +@@ -55,12 +55,13 @@ TTFSurface::create(const TTFFont& font, const std::string& text) + SDL_SetSurfaceColorMod(text_surface.get(), 0, 0, 0); + SDL_SetSurfaceBlendMode(text_surface.get(), SDL_BLENDMODE_BLEND); + ++ using P = std::tuple; + const std::initializer_list > positions[] = { + {}, +- {{0, 0}}, +- {{-1, 0}, {1, 0}, {0, -1}, {0, 1}}, +- {{-2, 0}, {2, 0}, {0, -2}, {0, 2}, +- {-1, -1}, {1, -1}, {-1, 1}, {1, 1}} ++ {P{0, 0}}, ++ {P{-1, 0}, P{1, 0}, P{0, -1}, P{0, 1}}, ++ {P{-2, 0}, P{2, 0}, P{0, -2}, P{0, 2}, ++ P{-1, -1}, P{1, -1}, P{-1, 1}, P{1, 1}} + }; + + int shadow_size = std::min(2, font.get_shadow_size()); +@@ -77,11 +78,12 @@ TTFSurface::create(const TTFFont& font, const std::string& text) + SDL_SetSurfaceColorMod(text_surface.get(), 0, 0, 0); + SDL_SetSurfaceBlendMode(text_surface.get(), SDL_BLENDMODE_BLEND); + ++ using P = std::tuple; + const std::initializer_list > positions[] = { + {}, +- {{-1, 0}, {1, 0}, {0, -1}, {0, 1}}, +- {{-2, 0}, {2, 0}, {0, -2}, {0, 2}, +- {-1, -1}, {1, -1}, {-1, 1}, {1, 1}} ++ {P{-1, 0}, P{1, 0}, P{0, -1}, P{0, 1}}, ++ {P{-2, 0}, P{2, 0}, P{0, -2}, P{0, 2}, ++ P{-1, -1}, P{1, -1}, P{-1, 1}, P{1, 1}} + }; + + int border = std::min(2, font.get_border()); diff --git a/gnu/packages/patches/supertux-unbundle-squirrel.patch b/gnu/packages/patches/supertux-unbundle-squirrel.patch new file mode 100644 index 000000000..054183b75 --- /dev/null +++ b/gnu/packages/patches/supertux-unbundle-squirrel.patch @@ -0,0 +1,53 @@ +diff -ur a/CMakeLists.txt b/CMakeLists.txt +--- a/CMakeLists.txt 2019-05-24 17:58:19.693090158 -0400 ++++ b/CMakeLists.txt 2019-05-24 17:57:43.349473252 -0400 +@@ -375,44 +375,15 @@ + + include(ConfigureChecks) + +- +-## Also build external/squirrel +- +-if(NOT EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/external/squirrel/CMakeLists.txt) +- message(FATAL_ERROR "squirrel submodule is not checked out or ${CMAKE_CURRENT_SOURCE_DIR}/external/squirrel/CMakeLists.txt is missing") +-endif() +- + set(SQUIRREL_PREFIX ${CMAKE_BINARY_DIR}/squirrel/ex) +-ExternalProject_Add(squirrel +- SOURCE_DIR "${CMAKE_SOURCE_DIR}/external/squirrel/" +- CMAKE_ARGS +- -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} +- -DCMAKE_C_COMPILER=${CMAKE_C_COMPILER} +- -DCMAKE_C_FLAGS=${CMAKE_C_FLAGS} +- -DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER} +- -DCMAKE_CXX_FLAGS=${CMAKE_CXX_FLAGS} +- -DCMAKE_INSTALL_PREFIX=${SQUIRREL_PREFIX} +- -DINSTALL_INC_DIR=include) +- +-if(WIN32) +- add_library(squirrel_lib SHARED IMPORTED) +- set_target_properties(squirrel_lib PROPERTIES IMPORTED_LOCATION "${SQUIRREL_PREFIX}/bin/${CMAKE_SHARED_LIBRARY_PREFIX}squirrel${CMAKE_SHARED_LIBRARY_SUFFIX}") +- set_target_properties(squirrel_lib PROPERTIES IMPORTED_IMPLIB "${SQUIRREL_PREFIX}/lib/squirrel${CMAKE_LINK_LIBRARY_SUFFIX}") +- add_library(sqstdlib_lib SHARED IMPORTED) +- set_target_properties(sqstdlib_lib PROPERTIES IMPORTED_LOCATION "${SQUIRREL_PREFIX}/bin/${CMAKE_SHARED_LIBRARY_PREFIX}sqstdlib${CMAKE_SHARED_LIBRARY_SUFFIX}") +- set_target_properties(sqstdlib_lib PROPERTIES IMPORTED_IMPLIB "${SQUIRREL_PREFIX}/lib/sqstdlib${CMAKE_LINK_LIBRARY_SUFFIX}") +- +- #For debug run purposes +- configure_file("${CMAKE_CURRENT_SOURCE_DIR}/mk/msvc/run_supertux.bat.in" "${PROJECT_BINARY_DIR}/run_supertux.bat") +-else() +- add_library(squirrel_lib STATIC IMPORTED) +- set_target_properties(squirrel_lib PROPERTIES IMPORTED_LOCATION "${SQUIRREL_PREFIX}/lib/${CMAKE_STATIC_LIBRARY_PREFIX}squirrel_static${CMAKE_STATIC_LIBRARY_SUFFIX}") +- add_library(sqstdlib_lib STATIC IMPORTED) +- set_target_properties(sqstdlib_lib PROPERTIES IMPORTED_LOCATION "${SQUIRREL_PREFIX}/lib/${CMAKE_STATIC_LIBRARY_PREFIX}sqstdlib_static${CMAKE_STATIC_LIBRARY_SUFFIX}") +-endif() + + include_directories(SYSTEM ${SQUIRREL_PREFIX}/include) + ++add_library(squirrel_lib SHARED IMPORTED) ++set_target_properties(squirrel_lib PROPERTIES IMPORTED_LOCATION "${SQUIRREL_PREFIX}/lib/${CMAKE_SHARED_LIBRARY_PREFIX}squirrel${CMAKE_SHARED_LIBRARY_SUFFIX}") ++add_library(sqstdlib_lib SHARED IMPORTED) ++set_target_properties(sqstdlib_lib PROPERTIES IMPORTED_LOCATION "${SQUIRREL_PREFIX}/lib/${CMAKE_SHARED_LIBRARY_PREFIX}sqstdlib${CMAKE_SHARED_LIBRARY_SUFFIX}") ++ + ## Also build external/tinygettext + + if(NOT EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/external/tinygettext/CMakeLists.txt) -- cgit v1.3 From d2928fa63f97844f8b60b9baf8e9a023ee7f2f80 Mon Sep 17 00:00:00 2001 From: Arun Isaac Date: Wed, 22 May 2019 01:46:54 +0530 Subject: linux-container: Check if nscd run directory exists when container is run. * gnu/system/linux-container.scm (containerized-operating-system): (container-script): Check for existence of the host nscd run directory in the container script. This check should be run when the container is started, not when the container script is created. [network-mappings]: Delete variable. [nscd-run-directory, nscd-mapping]: New variables. --- gnu/system/linux-container.scm | 53 ++++++++++++++++++++++++------------------ 1 file changed, 31 insertions(+), 22 deletions(-) diff --git a/gnu/system/linux-container.scm b/gnu/system/linux-container.scm index 16eee7a3c..c1e963d04 100644 --- a/gnu/system/linux-container.scm +++ b/gnu/system/linux-container.scm @@ -109,7 +109,10 @@ containerized OS. EXTRA-FILE-SYSTEMS is a list of file systems to add to OS." (memq (service-kind service) useless-services)) (operating-system-user-services os))) - (file-systems (append (map mapping->fs mappings) + (file-systems (append (map mapping->fs + (if shared-network? + (append %network-file-mappings mappings) + mappings)) extra-file-systems user-file-systems @@ -124,32 +127,33 @@ containerized OS. EXTRA-FILE-SYSTEMS is a list of file systems to add to OS." "Return a derivation of a script that runs OS as a Linux container. MAPPINGS is a list of objects that specify the files/directories that will be shared with the host system." - (define network-mappings - ;; Files to map if network is to be shared with the host - (append %network-file-mappings - (let ((nscd-run-directory "/var/run/nscd")) - (if (file-exists? nscd-run-directory) - (list (file-system-mapping - (source nscd-run-directory) - (target nscd-run-directory))) - '())))) + (define nscd-run-directory "/var/run/nscd") + + (define nscd-mapping + (file-system-mapping + (source nscd-run-directory) + (target nscd-run-directory))) (define (mountable-file-system? file-system) ;; Return #t if FILE-SYSTEM should be mounted in the container. (and (not (string=? "/" (file-system-mount-point file-system))) (file-system-needed-for-boot? file-system))) - (let* ((os (containerized-operating-system - os - (cons %store-mapping - (if shared-network? - (append network-mappings mappings) - mappings)) - #:shared-network? shared-network? - #:extra-file-systems %container-file-systems)) - (file-systems (filter mountable-file-system? - (operating-system-file-systems os))) - (specs (map file-system->spec file-systems))) + (define (os-file-system-specs os) + (map file-system->spec + (filter mountable-file-system? + (operating-system-file-systems os)))) + + (let* ((os (containerized-operating-system + os (cons %store-mapping mappings) + #:shared-network? shared-network? + #:extra-file-systems %container-file-systems)) + (nscd-os (containerized-operating-system + os (cons* nscd-mapping %store-mapping mappings) + #:shared-network? shared-network? + #:extra-file-systems %container-file-systems)) + (specs (os-file-system-specs os)) + (nscd-specs (os-file-system-specs nscd-os))) (define script (with-imported-modules (source-module-closure @@ -160,7 +164,12 @@ that will be shared with the host system." (gnu system file-systems) ;spec->file-system (guix build utils)) - (call-with-container (map spec->file-system '#$specs) + (call-with-container + (map spec->file-system + (if (and #$shared-network? + (file-exists? #$nscd-run-directory)) + '#$nscd-specs + '#$specs)) (lambda () (setenv "HOME" "/root") (setenv "TMPDIR" "/tmp") -- cgit v1.3 From eea4ed9869f6fb4249631afd1c7c5d4229043fec Mon Sep 17 00:00:00 2001 From: Brian Leung Date: Tue, 14 May 2019 00:12:49 +0200 Subject: gnu: emacs-highlight-symbol: Update to 1.3.1-7a789c7. * gnu/packages/emacs-xyz.scm (emacs-highlight-symbol): Update to 1.3.1-7a789c7. Signed-off-by: Ricardo Wurmus --- gnu/packages/emacs-xyz.scm | 42 ++++++++++++++++++++++++------------------ 1 file changed, 24 insertions(+), 18 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index beb35c812..b686582d6 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -4074,23 +4074,29 @@ well as completely new features.") (license license:gpl3+))) (define-public emacs-highlight-symbol - (package - (name "emacs-highlight-symbol") - (version "1.3") - (source - (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/nschum/highlight-symbol.el.git") - (commit version))) - (file-name (git-file-name name version)) - (sha256 - (base32 "09z13kv2g21kjjkkm3iyaz93sdjmdy2d563r8n7r7ng94acrn7f6")))) - (build-system emacs-build-system) - (home-page "https://nschum.de/src/emacs/highlight-symbol") - (synopsis "Automatic and manual symbol highlighting for Emacs") - (description - "Use @code{highlight-symbol} to toggle highlighting of the symbol at + ;; We prefer a more recent commit that provides an option to squelch + ;; echo-area alerts that can drown out useful information like eldoc + ;; messages. + (let ((commit "7a789c779648c55b16e43278e51be5898c121b3a") + (version "1.3") + (revision "1")) + (package + (name "emacs-highlight-symbol") + (version (git-version version revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/nschum/highlight-symbol.el.git") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "19cgyk0sh8nsmf3jbi92i8qsdx4l4yilfq5jj9zfdbj9p5gvwx96")))) + (build-system emacs-build-system) + (home-page "https://nschum.de/src/emacs/highlight-symbol/") + (synopsis "Automatic and manual symbol highlighting for Emacs") + (description + "Use @code{highlight-symbol} to toggle highlighting of the symbol at point throughout the current buffer. Use @code{highlight-symbol-mode} to keep the symbol at point highlighted. @@ -4103,7 +4109,7 @@ bindings @code{M-p} and @code{M-p} for navigation. When regardless of @code{highlight-symbol-idle-delay}. @code{highlight-symbol-query-replace} can be used to replace the symbol. ") - (license license:gpl2+))) + (license license:gpl2+)))) (define-public emacs-hl-todo (package -- cgit v1.3 From c799fd63f655868ab95c54ef062d7c16f71514d4 Mon Sep 17 00:00:00 2001 From: Brian Leung Date: Tue, 14 May 2019 00:13:42 +0200 Subject: gnu: emacs-avy: Update to 0.5.0. * gnu/packages/emacs-xyz.scm (emacs-avy): Update to 0.5.0. Signed-off-by: Ricardo Wurmus --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index b686582d6..ae2403dbc 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -4461,7 +4461,7 @@ show icons as well.") (define-public emacs-avy (package (name "emacs-avy") - (version "0.4.0") + (version "0.5.0") (source (origin (method git-fetch) @@ -4470,7 +4470,7 @@ show icons as well.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "0rq9ab264565z83cly743nbhrd9m967apmnlhqr1gy8dm4hcy7nm")))) + (base32 "09qdni1s74i5pv8741szl5g4ynj8fxn0x65qmwa9rmfkbimnc0fs")))) (build-system emacs-build-system) (home-page "https://github.com/abo-abo/avy") (synopsis "Tree-based completion for Emacs") -- cgit v1.3 From 7547648091e4a4ac915896b09ff1625c6e69c4d2 Mon Sep 17 00:00:00 2001 From: Brian Leung Date: Sat, 25 May 2019 06:45:46 +0200 Subject: gnu: emacs-lispy: Update to 0.27.0. * gnu/packages/emacs-xyz.scm (emacs-lispy): Update to 0.27.0. Signed-off-by: Ricardo Wurmus --- gnu/packages/emacs-xyz.scm | 50 ++++++++++++++++++++++------------------------ 1 file changed, 24 insertions(+), 26 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index ae2403dbc..9199b45e4 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -4560,37 +4560,35 @@ navigate code in a tree-like fashion.") (license license:gpl3+)))) (define-public emacs-lispy - ;; Release 0.26.0 was almost 3 years ago, and there have been ~772 commits - ;; since. - (let ((commit "f94cfc6b8f9c3afe7d028c366928049c011023de") - (revision "1")) - (package - (name "emacs-lispy") - (version (git-version "0.26.0" revision commit)) - (home-page "https://github.com/abo-abo/lispy") - (source (origin - (method git-fetch) - (uri (git-reference (url home-page) (commit commit))) - (sha256 - (base32 - "1bm2cpwizg1qfpm377gpx1af1hm5maw69if1csnk5vwaphmv8c4g")) - (file-name (git-file-name name version)))) - (build-system emacs-build-system) - (propagated-inputs - `(("emacs-ace-window" ,emacs-ace-window) - ("emacs-iedit" ,emacs-iedit) - ("emacs-ivy" ,emacs-ivy) - ("emacs-hydra" ,emacs-hydra) - ("emacs-zoutline" ,emacs-zoutline))) - (synopsis "Modal S-expression editing") - (description - "Due to the structure of Lisp syntax it's very rare for the programmer + (package + (name "emacs-lispy") + (version "0.27.0") + (home-page "https://github.com/abo-abo/lispy") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/abo-abo/lispy") + (commit version))) + (sha256 + (base32 + "1cm7f4pyl73f3vhkb7ah6bbbrj2sa7n0p31g09k7dy4zgx04bgw6")) + (file-name (git-file-name name version)))) + (build-system emacs-build-system) + (propagated-inputs + `(("emacs-ace-window" ,emacs-ace-window) + ("emacs-iedit" ,emacs-iedit) + ("emacs-ivy" ,emacs-ivy) + ("emacs-hydra" ,emacs-hydra) + ("emacs-zoutline" ,emacs-zoutline))) + (synopsis "Modal S-expression editing") + (description + "Due to the structure of Lisp syntax it's very rare for the programmer to want to insert characters right before \"(\" or right after \")\". Thus unprefixed printable characters can be used to call commands when the point is at one of these special locations. Lispy provides unprefixed keybindings for S-expression editing when point is at the beginning or end of an S-expression.") - (license license:gpl3+)))) + (license license:gpl3+))) (define-public emacs-lispyville (let ((commit "d28b937f0cabd8ce61e2020fe9a733ca80d82c74") -- cgit v1.3 From 41cdaf47e1a398f91a1a06648ebb2a997cfdf224 Mon Sep 17 00:00:00 2001 From: Kei Kebreau Date: Sat, 25 May 2019 06:01:13 -0400 Subject: gnu: squirrel: Fix build. This follows commit 9d0c291e3e. * gnu/packages/squirrel.scm: Adjust module reference. --- gnu/packages/squirrel.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/squirrel.scm b/gnu/packages/squirrel.scm index 12affe61e..2c3ed6e57 100644 --- a/gnu/packages/squirrel.scm +++ b/gnu/packages/squirrel.scm @@ -19,7 +19,7 @@ (define-module (gnu packages squirrel) #:use-module (gnu packages) #:use-module (gnu packages cmake) - #:use-module (gnu packages python-xyz) + #:use-module (gnu packages sphinx) #:use-module (guix build-system cmake) #:use-module (guix download) #:use-module ((guix licenses) #:prefix license:) -- cgit v1.3 From 336674549dfd2102479da0d2b92aaaf583f52c92 Mon Sep 17 00:00:00 2001 From: Arun Isaac Date: Sat, 25 May 2019 15:54:24 +0530 Subject: services: cgit: Fix typo. * gnu/services/cgit.scm (cgit-configuration)[root-readme]: Replace "thef" with "the". --- gnu/services/cgit.scm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/services/cgit.scm b/gnu/services/cgit.scm index a84a2dadb..94ca9e281 100644 --- a/gnu/services/cgit.scm +++ b/gnu/services/cgit.scm @@ -2,6 +2,7 @@ ;;; Copyright © 2018 Oleg Pykhalov ;;; Copyright © 2018 Clément Lassieur ;;; Copyright © 2018 Christopher Baines +;;; Copyright © 2019 Arun Isaac ;;; ;;; This file is part of GNU Guix. ;;; @@ -581,7 +582,7 @@ removed for the URL and name.") (root-readme (string "") "The content of the file specified with this option will be included -verbatim below thef \"about\" link on the repository index page.") +verbatim below the \"about\" link on the repository index page.") (root-title (string "") "Text printed as heading on the repository index page.") -- cgit v1.3 From ed90104cc82fdd6b762a159b06c0ea37b417a9a5 Mon Sep 17 00:00:00 2001 From: Reza Alizadeh Majd Date: Tue, 21 May 2019 17:51:09 +0430 Subject: services: sddm: Fix root login failure issue. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/services/sddm.scm (sdm-pam-service): Set uid from CONFIG. (sdm-autologin-pam-service): Set uid from CONFIG. (sdm-pam-services): Pass CONFIG to 'sddm-pam-service' and 'sddm-autologin-pam-service'. * doc/guix.texi (X Window): Adjust 'minimum-uid' documentation. Co-authored-by: Ludovic Courtès --- doc/guix.texi | 8 ++++---- gnu/services/sddm.scm | 16 ++++++++++------ 2 files changed, 14 insertions(+), 10 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index ee10e65be..d60f453b2 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -13623,11 +13623,11 @@ Directory to look for faces. @item @code{default-path} (default "/run/current-system/profile/bin") Default PATH to use. -@item @code{minimum-uid} (default 1000) -Minimum UID to display in SDDM. +@item @code{minimum-uid} (default: 1000) +Minimum UID displayed in SDDM and allowed for log-in. -@item @code{maximum-uid} (default 2000) -Maximum UID to display in SDDM +@item @code{maximum-uid} (default: 2000) +Maximum UID to display in SDDM. @item @code{remember-last-user?} (default #t) Remember last user. diff --git a/gnu/services/sddm.scm b/gnu/services/sddm.scm index b433c59e1..b0e6d4026 100644 --- a/gnu/services/sddm.scm +++ b/gnu/services/sddm.scm @@ -175,7 +175,7 @@ Relogin=" (if (sddm-configuration-relogin? config) (define (sddm-etc-service config) (list `("sddm.conf" ,(sddm-configuration-file config)))) -(define (sddm-pam-service) +(define (sddm-pam-service config) "Return a PAM service for @command{sddm}." (pam-service (name "sddm") @@ -190,7 +190,9 @@ Relogin=" (if (sddm-configuration-relogin? config) (pam-entry (control "required") (module "pam_succeed_if.so") - (arguments (list "uid >= 1000" "quiet"))) + (arguments (list (string-append "uid >= " + (number->string (sddm-configuration-minimum-uid config))) + "quiet"))) ;; should be factored out into system-auth (pam-entry (control "required") @@ -249,7 +251,7 @@ Relogin=" (if (sddm-configuration-relogin? config) (control "required") (module "pam_unix.so")))))) -(define (sddm-autologin-pam-service) +(define (sddm-autologin-pam-service config) "Return a PAM service for @command{sddm-autologin}" (pam-service (name "sddm-autologin") @@ -261,7 +263,9 @@ Relogin=" (if (sddm-configuration-relogin? config) (pam-entry (control "required") (module "pam_succeed_if.so") - (arguments (list "uid >= 1000" "quiet"))) + (arguments (list (string-append "uid >= " + (number->string (sddm-configuration-minimum-uid config))) + "quiet"))) (pam-entry (control "required") (module "pam_permit.so")))) @@ -282,9 +286,9 @@ Relogin=" (if (sddm-configuration-relogin? config) (module "sddm")))))) (define (sddm-pam-services config) - (list (sddm-pam-service) + (list (sddm-pam-service config) (sddm-greeter-pam-service) - (sddm-autologin-pam-service))) + (sddm-autologin-pam-service config))) (define %sddm-accounts (list (user-group (name "sddm") (system? #t)) -- cgit v1.3 From 493375cdb23fc1416348da584f17bec7171faadd Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sun, 26 May 2019 01:18:53 +0200 Subject: publish: Maintain a hash-part-to-store-item mapping in cache. Fixes . * guix/scripts/publish.scm (hash-part-mapping-cache-file) (hash-part->path*): New procedures. * guix/scripts/publish.scm (render-narinfo/cached)[delete-entry]: Delete the 'hash-part-mapping-cache-file'. Use 'hash-part->path*' instead of 'hash-part->path'. * tests/publish.scm ("with cache, vanishing item"): New test. --- guix/scripts/publish.scm | 38 +++++++++++++++++++++++++++++++++----- tests/publish.scm | 29 +++++++++++++++++++++++++++++ 2 files changed, 62 insertions(+), 5 deletions(-) diff --git a/guix/scripts/publish.scm b/guix/scripts/publish.scm index a236f3e45..db64d6483 100644 --- a/guix/scripts/publish.scm +++ b/guix/scripts/publish.scm @@ -350,6 +350,9 @@ appropriate duration. NAR-PATH specifies the prefix for nar URLs." "/" (basename item) ".narinfo")) +(define (hash-part-mapping-cache-file directory hash) + (string-append directory "/hashes/" hash)) + (define run-single-baker (let ((baking (make-weak-value-hash-table)) (mutex (make-mutex))) @@ -403,6 +406,27 @@ items. Failing that, we could eventually have to recompute them and return +inf.0 (expiration-time file)))))) +(define (hash-part->path* store hash cache) + "Like 'hash-part->path' but cached results under CACHE. This ensures we can +still map HASH to the corresponding store file name, even if said store item +vanished from the store in the meantime." + (let ((cached (hash-part-mapping-cache-file cache hash))) + (catch 'system-error + (lambda () + (call-with-input-file cached read-string)) + (lambda args + (if (= ENOENT (system-error-errno args)) + (match (hash-part->path store hash) + ("" "") + (result + (mkdir-p (dirname cached)) + (call-with-output-file (string-append cached ".tmp") + (lambda (port) + (display result port))) + (rename-file (string-append cached ".tmp") cached) + result)) + (apply throw args)))))) + (define* (render-narinfo/cached store request hash #:key ttl (compression %no-compression) (nar-path "nar") @@ -412,13 +436,17 @@ CACHE, then send it; otherwise, return 404 and \"bake\" that nar and narinfo requested using POOL." (define (delete-entry narinfo) ;; Delete NARINFO and the corresponding nar from CACHE. - (let ((nar (string-append (string-drop-right narinfo - (string-length ".narinfo")) - ".nar"))) + (let* ((nar (string-append (string-drop-right narinfo + (string-length ".narinfo")) + ".nar")) + (base (basename narinfo ".narinfo")) + (hash (string-take base (string-index base #\-))) + (mapping (hash-part-mapping-cache-file cache hash))) (delete-file* narinfo) - (delete-file* nar))) + (delete-file* nar) + (delete-file* mapping))) - (let* ((item (hash-part->path store hash)) + (let* ((item (hash-part->path* store hash cache)) (compression (actual-compression item compression)) (cached (and (not (string-null? item)) (narinfo-cache-file cache item diff --git a/tests/publish.scm b/tests/publish.scm index 097ac036e..7f44bc700 100644 --- a/tests/publish.scm +++ b/tests/publish.scm @@ -469,6 +469,35 @@ FileSize: ~a~%" (assoc-ref narinfo "FileSize")) (response-code compressed)))))))))) +(test-equal "with cache, vanishing item" ; + 200 + (call-with-temporary-directory + (lambda (cache) + (let ((thread (with-separate-output-ports + (call-with-new-thread + (lambda () + (guix-publish "--port=6795" + (string-append "--cache=" cache))))))) + (wait-until-ready 6795) + + ;; Make sure that, even if ITEM disappears, we're still able to fetch + ;; it. + (let* ((base "http://localhost:6795/") + (item (add-text-to-store %store "random" (random-text))) + (part (store-path-hash-part item)) + (url (string-append base part ".narinfo")) + (cached (string-append cache + (if (zlib-available?) + "/gzip/" "/none/") + (basename item) + ".narinfo")) + (response (http-get url))) + (and (= 404 (response-code response)) + (wait-for-file cached) + (begin + (delete-paths %store (list item)) + (response-code (pk 'response (http-get url)))))))))) + (test-equal "/log/NAME" `(200 #t application/x-bzip2) (let ((drv (run-with-store %store -- cgit v1.3 From 7fcb86da2b1923a9f7d3cd04ce922632f52af5a0 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sun, 26 May 2019 01:33:39 +0200 Subject: store: Fix 'hash-part->path' docstring. * guix/store.scm (hash-part->path): Adjust docstring to match reality. --- guix/store.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/guix/store.scm b/guix/store.scm index 5c6e4e0ca..738c0fb5f 100644 --- a/guix/store.scm +++ b/guix/store.scm @@ -980,7 +980,7 @@ store directory (/gnu/store)." store-path))) (lambda (server hash-part) "Return the store path whose hash part is HASH-PART (a nix-base32 -string). Raise an error if no such path exists." +string). Return the empty string if no such path exists." ;; This RPC is primarily used by Hydra to reply to HTTP GETs of ;; /HASH.narinfo. (query-path-from-hash-part server hash-part)))) -- cgit v1.3 From 8a8597819e3ac8efc99b5efada489730961a0ee9 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sat, 25 May 2019 22:39:04 +0200 Subject: gnu: duplicity: Update to 0.7.19. * gnu/packages/backup.scm (duplicity): Update to 0.7.19. --- gnu/packages/backup.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/backup.scm b/gnu/packages/backup.scm index 262c6efc2..70cc06c73 100644 --- a/gnu/packages/backup.scm +++ b/gnu/packages/backup.scm @@ -73,7 +73,7 @@ (define-public duplicity (package (name "duplicity") - (version "0.7.18.2") + (version "0.7.19") (source (origin (method url-fetch) @@ -82,7 +82,7 @@ "-series/" version "/+download/duplicity-" version ".tar.gz")) (sha256 - (base32 "0j37dgyji36hvb5dbzlmh5rj83jwhni02yq16g6rd3hj8f7qhdn2")))) + (base32 "0ag9dknslxlasslwfjhqgcqbkb1mvzzx93ry7lch2lfzcdd91am6")))) (build-system python-build-system) (native-inputs `(("util-linux" ,util-linux) ; setsid command, for the tests -- cgit v1.3 From a4cf65c804f44218072982ecbcac45f37cd1e793 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 26 May 2019 01:00:41 +0200 Subject: gnu: pidgin: Don't use NAME in source URI. * gnu/packages/messaging.scm (pidgin)[source]: Hard-code NAME. --- gnu/packages/messaging.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 827b7f800..f87dc0d5f 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -376,7 +376,7 @@ authentication.") (origin (method url-fetch) (uri (string-append "mirror://sourceforge/pidgin/Pidgin/" - version "/" name "-" version ".tar.bz2")) + version "/pidgin-" version ".tar.bz2")) (sha256 (base32 "1y5p2mq3bfw35b66jsafmbva0w5gg1k99y9z8fyp3jfksqv3agcc")) -- cgit v1.3 From 0fcb0e5076c732d279e1736f65f872c2e8804402 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 26 May 2019 02:02:53 +0200 Subject: gnu: pidgin: Update to 2.13.0. * gnu/packages/messaging.scm (pidgin): Update to 2.13.0. --- gnu/packages/messaging.scm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index f87dc0d5f..b47627ef3 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -371,15 +371,14 @@ authentication.") (define-public pidgin (package (name "pidgin") - (version "2.12.0") + (version "2.13.0") (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/pidgin/Pidgin/" version "/pidgin-" version ".tar.bz2")) (sha256 - (base32 - "1y5p2mq3bfw35b66jsafmbva0w5gg1k99y9z8fyp3jfksqv3agcc")) + (base32 "13vdqj70315p9rzgnbxjp9c51mdzf1l4jg1kvnylc4bidw61air7")) (patches (search-patches "pidgin-add-search-path.patch")))) (build-system glib-or-gtk-build-system) (native-inputs -- cgit v1.3 From 569958aeb56a49e59d107892a8786e737b6c967d Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 26 May 2019 02:04:12 +0200 Subject: gnu: pidgin: Add network-manager support. * gnu/packages/messaging.scm (pidgin)[inputs]: Add network-manager. [arguments]: Undisable it in #:configure-flags. --- gnu/packages/messaging.scm | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index b47627ef3..fd092e71d 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -402,13 +402,13 @@ authentication.") ;; TODO: gstreamer: patches needed to support gstreamer-1.0 or later ;; TODO: farstream ;; TODO: meanwhile - ;; TODO: network-manager ;; TODO: gtkspell ;; TODO: libxephyr ;; TODO: libgadu ("libxslt" ,libxslt) ("avahi" ,avahi) ("ncurses" ,ncurses) + ("network-manager" ,network-manager) ("sqlite" ,sqlite) ("libice" ,libice) ("libsm" ,libsm) @@ -419,7 +419,6 @@ authentication.") (list "--disable-gtkspell" "--disable-tcl" "--disable-meanwhile" - "--disable-nm" ; XXX remove when we have network-manager "--disable-vv" ; XXX remove when we have farstream and gstreamer "--disable-gstreamer" ; XXX patches needed to support gstreamer-1.0 "--enable-cyrus-sasl" -- cgit v1.3 From dbe2dfa5289924a8eb218137111a169ab3ab91ff Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 26 May 2019 02:09:50 +0200 Subject: gnu: pidgin: Use HTTPS home page. * gnu/packages/messaging.scm (pidgin)[home-page]: Use HTTPS. --- gnu/packages/messaging.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index fd092e71d..7d036ad47 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -431,7 +431,7 @@ authentication.") (files (list (string-append "lib/purple-" (version-major version)) "lib/pidgin"))))) - (home-page "http://www.pidgin.im/") + (home-page "https://www.pidgin.im/") (synopsis "Graphical multi-protocol instant messaging client") (description "Pidgin is a modular instant messaging client that supports many popular -- cgit v1.3 From f3addff21c074e3f655d2108be6a21b93f598498 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 26 May 2019 03:26:55 +0200 Subject: gnu: libelf: Use archived home page and mirrored source. * gnu/packages/elf.scm (libelf)[source]: Use mirror URLs. [home-page]: Use archived home page. --- gnu/packages/elf.scm | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/gnu/packages/elf.scm b/gnu/packages/elf.scm index 09be3a75a..4f365cf20 100644 --- a/gnu/packages/elf.scm +++ b/gnu/packages/elf.scm @@ -160,13 +160,19 @@ static analysis of the ELF binaries at hand.") (package (name "libelf") (version "0.8.13") - (source (origin - (method url-fetch) - (uri (string-append "http://www.mr511.de/software/libelf-" - version ".tar.gz")) - (sha256 - (base32 - "0vf7s9dwk2xkmhb79aigqm0x0yfbw1j0b9ksm51207qwr179n6jr")))) + (source + (origin + (method url-fetch) + (uri (list + ;; As of May 2019, the original URL at mr511.de redirects to a + ;; domain that doesn't resolve. Use these two mirrors instead. + (string-append "https://fossies.org/linux/misc/old/" + "libelf-" version ".tar.gz") + (string-append "https://ftp.osuosl.org/pub/blfs/conglomeration/" + "libelf/libelf-" version ".tar.gz"))) + (sha256 + (base32 + "0vf7s9dwk2xkmhb79aigqm0x0yfbw1j0b9ksm51207qwr179n6jr")))) (build-system gnu-build-system) (arguments `(#:phases @@ -183,7 +189,8 @@ static analysis of the ELF binaries at hand.") (%current-system)) '("--host=aarch64-unknown-linux-gnu") '())))))))) - (home-page "http://www.mr511.de/software/english.html") + (home-page (string-append "https://web.archive.org/web/20181111033959/" + "http://www.mr511.de/software/english.html")) (synopsis "ELF object file access library") (description "Libelf is a C library to access ELF object files.") (license lgpl2.0+))) -- cgit v1.3 From e91a0bff01ea7bba764118839be89acdaee8b8c0 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 26 May 2019 04:07:28 +0200 Subject: gnu: rxcpp: Update to 4.1.0. * gnu/packages/machine-learning.scm (rxcpp): Update to 4.1.0. --- gnu/packages/machine-learning.scm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm index 77e12f83e..69156ad8b 100644 --- a/gnu/packages/machine-learning.scm +++ b/gnu/packages/machine-learning.scm @@ -573,15 +573,14 @@ in terms of new algorithms.") (define-public rxcpp (package (name "rxcpp") - (version "4.0.0") + (version "4.1.0") (source (origin (method url-fetch) (uri (string-append "https://github.com/ReactiveX/RxCpp/archive/v" version ".tar.gz")) (sha256 - (base32 - "0y2isr8dy2n1yjr9c5570kpc9lvdlch6jv0jvw000amwn5d3krsh")) + (base32 "1smxrcm0s6bz05185dx1i2xjgn47rq7m247pblil6p3bmk3lkfyk")) (file-name (string-append name "-" version ".tar.gz")))) (build-system cmake-build-system) (arguments -- cgit v1.3 From 5daafe0b5d2752c05330e2452d1c87b396b7ed2a Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 26 May 2019 05:00:21 +0200 Subject: gnu: rxcpp: Don't use unstable tarball. * gnu/packages/machine-learning.scm (rxcpp)[source]: Use GIT-FETCH and GIT-FILE-NAME. --- gnu/packages/machine-learning.scm | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm index 69156ad8b..b330b2357 100644 --- a/gnu/packages/machine-learning.scm +++ b/gnu/packages/machine-learning.scm @@ -576,12 +576,13 @@ in terms of new algorithms.") (version "4.1.0") (source (origin - (method url-fetch) - (uri (string-append "https://github.com/ReactiveX/RxCpp/archive/v" - version ".tar.gz")) + (method git-fetch) + (uri (git-reference + (url "https://github.com/ReactiveX/RxCpp.git") + (commit (string-append "v" version)))) (sha256 - (base32 "1smxrcm0s6bz05185dx1i2xjgn47rq7m247pblil6p3bmk3lkfyk")) - (file-name (string-append name "-" version ".tar.gz")))) + (base32 "1rdpa3jlc181jd08nk437aar085h28i45s6nzrv65apb3xyyz0ij")) + (file-name (git-file-name name version)))) (build-system cmake-build-system) (arguments `(#:phases -- cgit v1.3 From ac12a01394c8d3294a6b257cf0e42fde043e8094 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 26 May 2019 05:22:10 +0200 Subject: gnu: wine-staging: Update to 4.9. * gnu/packages/wine.scm (wine-staging-patchset-data, wine-staging): Update to 4.9. --- gnu/packages/wine.scm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/gnu/packages/wine.scm b/gnu/packages/wine.scm index 59716928f..eb8ac8193 100644 --- a/gnu/packages/wine.scm +++ b/gnu/packages/wine.scm @@ -4,7 +4,7 @@ ;;; Copyright © 2016, 2017, 2018 Efraim Flashner ;;; Copyright © 2017, 2018, 2019 Rutger Helling ;;; Copyright © 2017 Nicolas Goaziou -;;; Copyright © 2018 Tobias Geerinckx-Rice +;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice ;;; ;;; This file is part of GNU Guix. ;;; @@ -310,7 +310,7 @@ integrate Windows applications into your desktop.") (define-public wine-staging-patchset-data (package (name "wine-staging-patchset-data") - (version "4.8") + (version "4.9") (source (origin (method git-fetch) @@ -320,7 +320,7 @@ integrate Windows applications into your desktop.") (file-name (git-file-name name version)) (sha256 (base32 - "0npm44zdys78qbqqyvjczqqjdgacpsfds3jxyy1y4yj2xjqzagsq")))) + "17v66rsxvm3grglidxxzllw4msfrgwg35hmzanvrf8x8jfzjlvv2")))) (build-system trivial-build-system) (native-inputs `(("bash" ,bash) @@ -366,7 +366,7 @@ integrate Windows applications into your desktop.") (file-name (string-append name "-" version ".tar.xz")) (sha256 (base32 - "0dd1vw3bq47ypdpflgmmbi68pjw5z3wz26kfwvnkxqbp28fapfa8")))) + "16vrzhhk0x862mfhninx5515s76j2kbjgmz7gzdigjzkzwi8x14i")))) (inputs `(("autoconf" ,autoconf) ; for autoreconf ("faudio" ,faudio) ("ffmpeg" ,ffmpeg) -- cgit v1.3 From d21c68ac46702c2e249cc644c12839670b1c9d30 Mon Sep 17 00:00:00 2001 From: Rutger Helling Date: Sun, 26 May 2019 10:08:49 +0200 Subject: gnu: kitty: Update to 0.14.0. * gnu/packages/terminals.scm (kitty): Update to 0.14.0. --- gnu/packages/terminals.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm index 84454b2e0..2eb273097 100644 --- a/gnu/packages/terminals.scm +++ b/gnu/packages/terminals.scm @@ -924,7 +924,7 @@ tmux.") (define-public kitty (package (name "kitty") - (version "0.13.3") + (version "0.14.0") (home-page "https://sw.kovidgoyal.net/kitty/") (source (origin @@ -935,7 +935,7 @@ tmux.") (file-name (git-file-name name version)) (sha256 (base32 - "1y0vd75j8g61jdj8miml79w5ri3pqli5rv9iq6zdrxvzfa4b2rmb")) + "122573l7xirs9dsi5p8gra47qpgxb3vahqp2r0c043pgz4i22v5z")) (modules '((guix build utils))) (snippet '(begin -- cgit v1.3 From 9c11ba9282d37d7a6790e3a6f9bbe273d51a882a Mon Sep 17 00:00:00 2001 From: Rutger Helling Date: Sun, 26 May 2019 10:13:40 +0200 Subject: gnu: mgba: Update to 0.7.2. * gnu/packages/emulators.scm (mgba): Update to 0.7.2. --- gnu/packages/emulators.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emulators.scm b/gnu/packages/emulators.scm index 23e5a976c..98e7b44cc 100644 --- a/gnu/packages/emulators.scm +++ b/gnu/packages/emulators.scm @@ -407,7 +407,7 @@ Super Game Boy, BS-X Satellaview, and Sufami Turbo.") (define-public mgba (package (name "mgba") - (version "0.7.1") + (version "0.7.2") (source (origin (method git-fetch) (uri (git-reference @@ -416,7 +416,7 @@ Super Game Boy, BS-X Satellaview, and Sufami Turbo.") (file-name (git-file-name name version)) (sha256 (base32 - "0q0yg2zna7gjbvpaswyykbg3lr9k3c8l8fydqa407xrgq77lahq4")) + "0g0xa1mzvan0sl1p5c784j2g5mcw9kd2b7wiahy06gy0c1nmbcnp")) (modules '((guix build utils))) (snippet ;; Make sure we don't use the bundled software. -- cgit v1.3 From 414f545ee6f541d3b46839663b01f048fe812b76 Mon Sep 17 00:00:00 2001 From: Dan Frumin Date: Thu, 23 May 2019 18:58:02 +0200 Subject: gnu: coq-equations: Update to 1.2. Signed-off-by: Marius Bakke --- gnu/packages/coq.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/coq.scm b/gnu/packages/coq.scm index 6c48af4fc..2b24b7580 100644 --- a/gnu/packages/coq.scm +++ b/gnu/packages/coq.scm @@ -499,7 +499,7 @@ uses Ltac to synthesize the substitution operation.") (define-public coq-equations (package (name "coq-equations") - (version "1.2-beta2") + (version "1.2") (source (origin (method git-fetch) (uri (git-reference @@ -508,7 +508,7 @@ uses Ltac to synthesize the substitution operation.") (file-name (git-file-name name version)) (sha256 (base32 - "0y2zwv7jxs1crprj5qvg46h0v9wyfn99ln40yskq91y9h1lj5h3j")))) + "1q3wvicr43bgy7xn1diwh4j43mnrhprrc2xd22qlbz9cl6bhf8bj")))) (build-system gnu-build-system) (native-inputs `(("ocaml" ,ocaml) -- cgit v1.3 From 7abf3cbf710300fa4024ed3cefbb96c6ecd36c39 Mon Sep 17 00:00:00 2001 From: Brett Gilio Date: Fri, 24 May 2019 19:08:56 -0500 Subject: gnu: python-psutil: Update to 5.6.2. * gnu/packages/python-xyz.scm (python-psutil): Update to 5.6.2. Signed-off-by: Marius Bakke --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index f8bfdc521..88cf57a30 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -157,14 +157,14 @@ (define-public python-psutil (package (name "python-psutil") - (version "5.4.3") + (version "5.6.2") (source (origin (method url-fetch) (uri (pypi-uri "psutil" version)) (sha256 (base32 - "063v69x7spyclyaxrd3gmzj3p16q5ayg97xqhwb1kyn22a9pwip2")))) + "1v95vb5385qscfdvphv8l2w22bmir3d7yhpi02n58v3mlqy1r3l2")))) (build-system python-build-system) (arguments ;; FIXME: some tests does not return and times out. -- cgit v1.3 From 6d94465b4eb4b4c1446fff6129a16b7bcc0c5eb0 Mon Sep 17 00:00:00 2001 From: Brett Gilio Date: Fri, 24 May 2019 19:10:03 -0500 Subject: gnu: python-shapely: Update to 1.6.4.post2. * gnu/packages/python-xyz.scm (python-shapely): Update to 1.6.4.post2. Signed-off-by: Marius Bakke --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 88cf57a30..a58b788ca 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -193,14 +193,14 @@ pidof, tty, taskset, pmap.") (define-public python-shapely (package (name "python-shapely") - (version "1.6.3") + (version "1.6.4.post2") (source (origin (method url-fetch) (uri (pypi-uri "Shapely" version)) (sha256 (base32 - "0svc58dzcw9gj92b4sgq35sdxkf85z0qwlzxarkzq4bp3h8jy58l")))) + "03r42fmd9alp6r3q95ad6rldq2f7n1wimrw53zy5kpn33yv7pf64")))) (build-system python-build-system) (native-inputs `(("python-cython" ,python-cython) -- cgit v1.3 From 0607f890888d1212ed1005c067bab3e4b9759812 Mon Sep 17 00:00:00 2001 From: Robert Vollmert Date: Sat, 25 May 2019 22:09:51 +0200 Subject: import: hackage: Recognize "BSD-3-Clause" and "PublicDomain". * guix/import/hackage.scm (string->license): Add two licenses. Signed-off-by: Marius Bakke --- guix/import/hackage.scm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/guix/import/hackage.scm b/guix/import/hackage.scm index 2a51420d1..2731b4cbe 100644 --- a/guix/import/hackage.scm +++ b/guix/import/hackage.scm @@ -145,10 +145,12 @@ version." ("LGPL" "'lgpl??") ("BSD2" 'bsd-2) ("BSD3" 'bsd-3) + ("BSD-3-Clause" 'bsd-3) ("MIT" 'expat) ("ISC" 'isc) ("MPL" 'mpl2.0) ("Apache-2.0" 'asl2.0) + ("PublicDomain" 'public-domain) ((x) (string->license x)) ((lst ...) `(list ,@(map string->license lst))) (_ #f))) -- cgit v1.3 From 164cb4da63b929e1b89928fc721a20f912cdd1f0 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sun, 26 May 2019 10:39:23 +0200 Subject: gnu: pigx-chipseq: Update to 0.0.41. * gnu/packages/bioinformatics.scm (pigx-chipseq): Update to 0.0.41. --- gnu/packages/bioinformatics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index 8aba7f1c5..352b7ab72 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -12603,7 +12603,7 @@ expression report comparing samples in an easily configurable manner.") (define-public pigx-chipseq (package (name "pigx-chipseq") - (version "0.0.40") + (version "0.0.41") (source (origin (method url-fetch) (uri (string-append "https://github.com/BIMSBbioinfo/pigx_chipseq/" @@ -12611,7 +12611,7 @@ expression report comparing samples in an easily configurable manner.") "/pigx_chipseq-" version ".tar.gz")) (sha256 (base32 - "0y9x62cfwzhsp82imnawyamxp58bcb00yjxdy44spylqnjdlsaj8")))) + "0akbxdmsjsq5fzbwaap04hqjpsfgv1l6yrc2pwgbya1xgqvcq6vy")))) (build-system gnu-build-system) ;; parts of the tests rely on access to the network (arguments '(#:tests? #f)) -- cgit v1.3 From 51daf2f553ef587ac300f2d2768868b75dcddae7 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Sun, 26 May 2019 20:22:36 +0300 Subject: gnu: ioquake: Build on all architectures. * gnu/packages/game-development.scm (ioquake)[supported-systems]: Remove field. --- gnu/packages/game-development.scm | 1 - 1 file changed, 1 deletion(-) diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm index 62f6051e9..c3177a0b1 100644 --- a/gnu/packages/game-development.scm +++ b/gnu/packages/game-development.scm @@ -1521,5 +1521,4 @@ the original, ioquake3 has been cleaned up, bugs have been fixed and features added. The permanent goal is to create the open source Quake 3 distribution upon which people base their games, ports to new platforms, and other projects.") - (supported-systems '("x86_64-linux" "i686-linux")) (license license:gpl2)))) -- cgit v1.3 From 304fb7000ab2ccafa5861f8be15212dc1ef850ef Mon Sep 17 00:00:00 2001 From: Alex Vong Date: Mon, 27 May 2019 01:30:26 +0800 Subject: gnu: youtube-dl: Update to 2019.05.20. * gnu/packages/video.scm (youtube-dl): Update to 2019.05.20. Signed-off-by: Alex Vong --- gnu/packages/video.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index 9c03719e7..088c637b4 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -1446,7 +1446,7 @@ access to mpv's powerful playback capabilities.") (define-public youtube-dl (package (name "youtube-dl") - (version "2019.05.11") + (version "2019.05.20") (source (origin (method url-fetch) (uri (string-append "https://github.com/rg3/youtube-dl/releases/" @@ -1454,7 +1454,7 @@ access to mpv's powerful playback capabilities.") version ".tar.gz")) (sha256 (base32 - "1y272jgdqwhf2njzqfln80zb2pmw83rvp6lxza6wghb7cld249j1")))) + "18xwdfvpkqrnj0kb8xj8hgwhgiqpv7x7x7zzr4x3vynb9grcv9m8")))) (build-system python-build-system) (arguments ;; The problem here is that the directory for the man page and completion -- cgit v1.3 From 0d3dbe3f56949ad07d8a3816a8a884d3726d2c7d Mon Sep 17 00:00:00 2001 From: Marius Bakke Date: Sun, 26 May 2019 14:18:26 +0200 Subject: gnu: libevent: Update to 2.1.0. * gnu/packages/patches/libevent-2.1-dns-tests.patch, gnu/packages/patches/libevent-2.1-skip-failing-test.patch: Delete files. * gnu/local.mk (dist_patch_DATA): Adjust accordingly. * gnu/packages/libevent.scm (libevent): Update to 2.1.10. [source](patches): Remove. --- gnu/local.mk | 2 -- gnu/packages/libevent.scm | 10 +++------ gnu/packages/patches/libevent-2.1-dns-tests.patch | 26 ---------------------- .../patches/libevent-2.1-skip-failing-test.patch | 24 -------------------- 4 files changed, 3 insertions(+), 59 deletions(-) delete mode 100644 gnu/packages/patches/libevent-2.1-dns-tests.patch delete mode 100644 gnu/packages/patches/libevent-2.1-skip-failing-test.patch diff --git a/gnu/local.mk b/gnu/local.mk index 57d3590b5..3a199f82f 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -989,8 +989,6 @@ dist_patch_DATA = \ %D%/packages/patches/libevent-2.0-CVE-2016-10196.patch \ %D%/packages/patches/libevent-2.0-CVE-2016-10197.patch \ %D%/packages/patches/libevent-2.0-evbuffer-add-use-last-with-datap.patch \ - %D%/packages/patches/libevent-2.1-dns-tests.patch \ - %D%/packages/patches/libevent-2.1-skip-failing-test.patch \ %D%/packages/patches/libexif-CVE-2016-6328.patch \ %D%/packages/patches/libexif-CVE-2017-7544.patch \ %D%/packages/patches/libgcrypt-make-yat2m-reproducible.patch \ diff --git a/gnu/packages/libevent.scm b/gnu/packages/libevent.scm index 01e1e3b00..72227c1d9 100644 --- a/gnu/packages/libevent.scm +++ b/gnu/packages/libevent.scm @@ -3,7 +3,7 @@ ;;; Copyright © 2015, 2017 Mark H Weaver ;;; Copyright © 2015 Eric Dvorsak ;;; Copyright © 2016 David Thompson -;;; Copyright © 2017 Marius Bakke +;;; Copyright © 2017, 2019 Marius Bakke ;;; Copyright © 2017 Efraim Flashner ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice ;;; Copyright © 2019 Pierre Neidhardt @@ -41,7 +41,7 @@ (define-public libevent (package (name "libevent") - (version "2.1.8") + (version "2.1.10") (source (origin (method url-fetch) (uri (string-append @@ -49,11 +49,7 @@ version "-stable/libevent-" version "-stable.tar.gz")) (sha256 (base32 - "1hhxnxlr0fsdv7bdmzsnhdz16fxf3jg2r6vyljcl3kj6pflcap4n")) - (patches (search-patches "libevent-2.1-dns-tests.patch" - ;; XXX: Try removing this for > 2.1.8. - ;; https://github.com/libevent/libevent/issues/452 - "libevent-2.1-skip-failing-test.patch")))) + "1c25928gdv495clxk2v1d4gkr5py7ack4gx2n7d13frnld0syr78")))) (build-system gnu-build-system) (arguments ;; This skips some of the tests which fail on armhf and aarch64. diff --git a/gnu/packages/patches/libevent-2.1-dns-tests.patch b/gnu/packages/patches/libevent-2.1-dns-tests.patch deleted file mode 100644 index 091752a49..000000000 --- a/gnu/packages/patches/libevent-2.1-dns-tests.patch +++ /dev/null @@ -1,26 +0,0 @@ -Disable tests that rely on usable DNS lookups, which aren't available -in build chroots. - ---- libevent-2.0.21-stable/test/regress_dns.c 2013-01-20 22:32:09.000000000 +0100 -+++ libevent-2.0.21-stable/test/regress_dns.c 2013-01-20 22:32:30.000000000 +0100 -@@ -2120,10 +2120,6 @@ - - struct testcase_t dns_testcases[] = { - DNS_LEGACY(server, TT_FORK|TT_NEED_BASE), -- DNS_LEGACY(gethostbyname, TT_FORK|TT_NEED_BASE|TT_NEED_DNS|TT_OFF_BY_DEFAULT), -- DNS_LEGACY(gethostbyname6, TT_FORK|TT_NEED_BASE|TT_NEED_DNS|TT_OFF_BY_DEFAULT), -- DNS_LEGACY(gethostbyaddr, TT_FORK|TT_NEED_BASE|TT_NEED_DNS|TT_OFF_BY_DEFAULT), -- { "resolve_reverse", dns_resolve_reverse, TT_FORK|TT_OFF_BY_DEFAULT, NULL, NULL }, - { "search_empty", dns_search_empty_test, TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, - { "search", dns_search_test, TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, - { "search_lower", dns_search_lower_test, TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, -@@ -2163,9 +2159,6 @@ - - { "client_fail_requests", dns_client_fail_requests_test, - TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, -- { "client_fail_requests_getaddrinfo", -- dns_client_fail_requests_getaddrinfo_test, -- TT_FORK|TT_NEED_BASE, &basic_setup, NULL }, - - END_OF_TESTCASES - }; diff --git a/gnu/packages/patches/libevent-2.1-skip-failing-test.patch b/gnu/packages/patches/libevent-2.1-skip-failing-test.patch deleted file mode 100644 index d9ea1d422..000000000 --- a/gnu/packages/patches/libevent-2.1-skip-failing-test.patch +++ /dev/null @@ -1,24 +0,0 @@ -These fail on 32-bit due to an overflow bug in the test program. - -See test/regress_util.c:1448. - -Upstream bug URL: - -https://github.com/libevent/libevent/issues/452 - -diff --git a/test/regress_util.c b/test/regress_util.c -index ef6a1487..4de501fc 100644 ---- a/test/regress_util.c -+++ b/test/regress_util.c -@@ -1413,9 +1413,9 @@ static struct date_rfc1123_case { - { 1323648000, "Mon, 12 Dec 2011 00:00:00 GMT"}, - #ifndef _WIN32 - /** In win32 case we have max "23:59:59 January 18, 2038, UTC" for time32 */ -- { 4294967296, "Sun, 07 Feb 2106 06:28:16 GMT"} /* 2^32 */, -+ //{ 4294967296, "Sun, 07 Feb 2106 06:28:16 GMT"} /* 2^32 */, - /** In win32 case we have max "23:59:59, December 31, 3000, UTC" for time64 */ -- {253402300799, "Fri, 31 Dec 9999 23:59:59 GMT"} /* long long future no one can imagine */, -+ //{253402300799, "Fri, 31 Dec 9999 23:59:59 GMT"} /* long long future no one can imagine */, - { 1456704000, "Mon, 29 Feb 2016 00:00:00 GMT"} /* leap year */, - #endif - { 1435708800, "Wed, 01 Jul 2015 00:00:00 GMT"} /* leap second */, -- cgit v1.3 From 7024846181a24e32343d49a192cca4be96b1e1ca Mon Sep 17 00:00:00 2001 From: Marius Bakke Date: Sun, 26 May 2019 14:21:19 +0200 Subject: gnu: node: Update to 10.15.3. * gnu/packages/libevent.scm (libuv-1.19): Remove variable. * gnu/packages/node.scm (node): Update to 10.15.3. [source]: Use XZ-compressed tarball. [arguments]: Add #:test-target. Use DELETE-FILE instead of DELETE-IF-EXISTS. Remove obsolete test deletions. [inputs]: Change OPENSSL to OPENSSL-NEXT. Change LIBUV-1.19 to LIBUV. (node-lts): Remove variable. --- gnu/packages/libevent.scm | 13 ------------- gnu/packages/node.scm | 48 +++++++++++------------------------------------ 2 files changed, 11 insertions(+), 50 deletions(-) diff --git a/gnu/packages/libevent.scm b/gnu/packages/libevent.scm index 72227c1d9..bb96fd6ab 100644 --- a/gnu/packages/libevent.scm +++ b/gnu/packages/libevent.scm @@ -150,19 +150,6 @@ resolution, asynchronous file system operations, and threading primitives.") ;; details. Documentation is CC-BY 4.0 as of 1.12.0; see 'LICENSE-docs'. (license (list expat cc-by4.0)))) -;; This version is required for Node versions < 10. -(define-public libuv-1.19 - (package - (inherit libuv) - (version "1.19.2") - (source (origin - (method url-fetch) - (uri (string-append "https://dist.libuv.org/dist/v" version - "/libuv-v" version ".tar.gz")) - (sha256 - (base32 - "1msk9ac1z69whww88ibrwjqkd1apdla6l77cm2fwy5kigq0z5g3w")))))) - (define-public perl-anyevent (package (name "perl-anyevent") diff --git a/gnu/packages/node.scm b/gnu/packages/node.scm index a0221601d..fc43fcb04 100644 --- a/gnu/packages/node.scm +++ b/gnu/packages/node.scm @@ -5,7 +5,7 @@ ;;; Copyright © 2016 Ludovic Courtès ;;; Copyright © 2017 Mike Gerwitz ;;; Copyright © 2018 Tobias Geerinckx-Rice -;;; Copyright © 2018 Marius Bakke +;;; Copyright © 2018, 2019 Marius Bakke ;;; ;;; This file is part of GNU Guix. ;;; @@ -45,14 +45,14 @@ (define-public node (package (name "node") - (version "9.11.1") + (version "10.15.3") (source (origin (method url-fetch) (uri (string-append "https://nodejs.org/dist/v" version - "/node-v" version ".tar.gz")) + "/node-v" version ".tar.xz")) (sha256 (base32 - "1vjh9zvw7wkdz6b0l99ya7mqjk0l8lbg9isr1q8rxwp400dhkk32")) + "1mcijznh481s44i59p571a38bfvcxm9f8x2l0l1005aly0kdj8jf")) (modules '((guix build utils))) (snippet `(begin @@ -83,18 +83,14 @@ "--shared-zlib" "--without-snapshot" "--with-intl=system-icu") + ;; Run only the CI tests. The default test target requires additional + ;; add-ons from NPM that are not distributed with the source. + #:test-target "test-ci-js" #:phases (modify-phases %standard-phases (add-before 'configure 'patch-files (lambda* (#:key inputs #:allow-other-keys) - ;; This phase is inherited by Node LTS, which does not have all - ;; the files listed here. Use this helper for convenience. - (define (delete-if-exists file) - (if (file-exists? file) - (delete-file file) - '())) - ;; Fix hardcoded /bin/sh references. (substitute* '("lib/child_process.js" "lib/internal/v8_prof_polyfill.js" @@ -110,17 +106,9 @@ (("'/usr/bin/env'") (string-append "'" (which "env") "'"))) - ;; FIXME: These tests depend on being able to install eslint. - ;; See https://github.com/nodejs/node/issues/17098. - (for-each delete-if-exists - '("test/parallel/test-eslint-alphabetize-errors.js" - "test/parallel/test-eslint-buffer-constructor.js" - "test/parallel/test-eslint-documented-errors.js" - "test/parallel/test-eslint-inspector-check.js")) - ;; FIXME: These tests fail in the build container, but they don't ;; seem to be indicative of real problems in practice. - (for-each delete-if-exists + (for-each delete-file '("test/async-hooks/test-ttywrap.readstream.js" "test/parallel/test-util-inspect.js" "test/parallel/test-v8-serdes.js" @@ -132,14 +120,13 @@ "test/parallel/test-net-listen-after-destroying-stdin.js" "test/parallel/test-npm-install.js" "test/sequential/test-child-process-emfile.js" - "test/sequential/test-benchmark-child-process.js" "test/sequential/test-http-regr-gh-2928.js")) ;; These tests have an expiry date: they depend on the validity of ;; TLS certificates that are bundled with the source. We want this ;; package to be reproducible forever, so remove those. ;; TODO: Regenerate certs instead. - (for-each delete-if-exists + (for-each delete-file '("test/parallel/test-tls-passphrase.js" "test/parallel/test-tls-server-verify.js")) #t)) @@ -184,9 +171,9 @@ `(("c-ares" ,c-ares) ("http-parser" ,http-parser) ("icu4c" ,icu4c) - ("libuv" ,libuv-1.19) + ("libuv" ,libuv) ("nghttp2" ,nghttp2 "lib") - ("openssl" ,openssl) + ("openssl" ,openssl-next) ("zlib" ,zlib))) (synopsis "Evented I/O for V8 JavaScript") (description "Node.js is a platform built on Chrome's JavaScript runtime @@ -197,16 +184,3 @@ devices.") (home-page "https://nodejs.org/") (license expat) (properties '((timeout . 3600))))) ; 1 h - -(define-public node-lts - (package - (inherit node) - (name "node-lts") - (version "8.12.0") - (source (origin - (inherit (package-source node)) - (uri (string-append "https://nodejs.org/dist/v" version - "/node-v" version ".tar.xz")) - (sha256 - (base32 - "16j1rrxkhmvpcw689ndw1raql1gz4jqn7n82z55zn63c05cgz7as")))))) -- cgit v1.3 From efbbf9a15cd80d8372e5136d90775594c086368e Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Wed, 22 May 2019 19:03:31 -0400 Subject: gnu: vhba-module: Remove duplicate definition. This is a followup to commit e1f640db8fa2a3aee018ce80df47b37e245c4b52. * gnu/packages/linux.scm (vhba-module): Remove duplicate definition. --- gnu/packages/linux.scm | 22 ---------------------- 1 file changed, 22 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index b64524964..cbb5fdca1 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -535,28 +535,6 @@ It has been modified to remove all non-free binary blobs.") #:defconfig "omap2plus_defconfig" #:extra-version "arm-omap2plus")) -(define-public vhba-module - (package - (name "vhba-module") - (version "20190410") - (source (origin - (method url-fetch) - (uri (string-append - "http://downloads.sourceforge.net/cdemu/vhba-module/vhba-module-" - version ".tar.bz2")) - (sha256 - (base32 - "1513hq130raxp9z5grj54cwfjfxj05apipxg425j0zicii59a60c")))) - (build-system linux-module-build-system) - (arguments - ;; TODO: No tests? - `(#:tests? #f)) - (home-page "https://cdemu.sourceforge.io/") - (synopsis "Kernel module that emulates SCSI devices") - (description "VHBA module provides a Virtual (SCSI) HBA, which is the link -between the CDemu userspace daemon and linux kernel.") - (license license:gpl2+))) - ;;; ;;; Linux kernel modules. -- cgit v1.3 From 403b3a8c6113bcdae387ed92af61fb49921ab592 Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Wed, 22 May 2019 19:06:18 -0400 Subject: gnu: linux-libre-arm-generic: Move definition. * gnu/packages/linux.scm (linux-libre-arm-generic): Move the definition down, next to the other linux-libre-arm-generic-* packages. --- gnu/packages/linux.scm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index cbb5fdca1..8a353acb3 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -481,21 +481,21 @@ It has been modified to remove all non-free binary blobs.") ("CONFIG_DEVPTS_MULTIPLE_INSTANCES" . #t)) %default-extra-linux-options))) -(define-public linux-libre-arm-generic +(define-public linux-libre-arm-veyron (make-linux-libre %linux-libre-version %linux-libre-hash '("armhf-linux") #:patches %linux-libre-5.1-patches - #:defconfig "multi_v7_defconfig" - #:extra-version "arm-generic")) + #:configuration-file kernel-config-veyron + #:extra-version "arm-veyron")) -(define-public linux-libre-arm-veyron +(define-public linux-libre-arm-generic (make-linux-libre %linux-libre-version %linux-libre-hash '("armhf-linux") #:patches %linux-libre-5.1-patches - #:configuration-file kernel-config-veyron - #:extra-version "arm-veyron")) + #:defconfig "multi_v7_defconfig" + #:extra-version "arm-generic")) (define-public linux-libre-arm-generic-4.19 (make-linux-libre %linux-libre-4.19-version -- cgit v1.3 From 2bdce7a654edd014a8860c81d01c1db41b2d5598 Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Sat, 18 May 2019 02:53:32 -0400 Subject: gnu: linux-libre: Rename a patch. * gnu/packages/linux.scm (%linux-libre-arm-export-__sync_icache_dcache-patch): Remove the version from the file name, since it applies to multiple versions. --- gnu/packages/linux.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 8a353acb3..83c23dc20 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -246,7 +246,7 @@ defconfig. Return the appropriate make target if applicable, otherwise return "/raw/34a7d9011fcfcfa38b68282fd2b1a8797e6834f0" "/debian/patches/bugfix/arm/" "arm-mm-export-__sync_icache_dcache-for-xen-privcmd.patch")) - (file-name "linux-libre-4.19-arm-export-__sync_icache_dcache.patch") + (file-name "linux-libre-arm-export-__sync_icache_dcache.patch") (sha256 (base32 "1ifnfhpakzffn4b8n7x7w5cps9mzjxlkcfz9zqak2vaw8nzvl39f")))) -- cgit v1.3 From 5f3f63e5ad901815f6a2e8bdc50202ae5d09173c Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Sun, 26 May 2019 14:12:43 -0400 Subject: gnu: linux-libre@4.9: Update to 4.9.179. * gnu/packages/linux.scm (linux-libre-4.9): Update to 4.9.179. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 83c23dc20..9ac038221 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -464,8 +464,8 @@ It has been modified to remove all non-free binary blobs.") #:configuration-file kernel-config)) (define-public linux-libre-4.9 - (make-linux-libre "4.9.178" - "1ridlkymf382qnkc6hi07pkghrrxfv2avx55snjnkfcpdccvsmrb" + (make-linux-libre "4.9.179" + "0nc9a7b7g5a18fdc8dswm3la7srn5sgz8adavp8r9h3ya9zh3wim" '("x86_64-linux" "i686-linux") #:configuration-file kernel-config)) -- cgit v1.3 From d87d375b64f3392885f0b5a890d3fa093e141de6 Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Sun, 26 May 2019 14:13:21 -0400 Subject: gnu: linux-libre@4.14: Update to 4.14.122. * gnu/packages/linux.scm (%linux-libre-4.14-version): Update to 4.14.122. (%linux-libre-4.14-hash): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 9ac038221..72305345c 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -454,8 +454,8 @@ It has been modified to remove all non-free binary blobs.") #:patches %linux-libre-4.19-patches #:configuration-file kernel-config)) -(define %linux-libre-4.14-version "4.14.121") -(define %linux-libre-4.14-hash "1g7gyjmp056pasf9m34dqs8pa15my6hqasdd551jw8mgkbhsfnxg") +(define %linux-libre-4.14-version "4.14.122") +(define %linux-libre-4.14-hash "0923m61b3gwm69w6m9zhb8az57lrwn7igdysf8wb7ld9z4hzpag8") (define-public linux-libre-4.14 (make-linux-libre %linux-libre-4.14-version -- cgit v1.3 From 5b7be798b2dce8b52db7021943ca896855fa657c Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Sun, 26 May 2019 14:14:13 -0400 Subject: gnu: linux-libre@4.19: Update to 4.19.46. * gnu/packages/linux.scm (%linux-libre-4.19-version): Update to 4.19.46. (%linux-libre-4.19-hash): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 72305345c..5f69e5b24 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -440,8 +440,8 @@ It has been modified to remove all non-free binary blobs.") #:patches %linux-libre-5.1-patches #:configuration-file kernel-config)) -(define %linux-libre-4.19-version "4.19.45") -(define %linux-libre-4.19-hash "1wiy8vzpzzml4k76nv3ycjx7ky55x7dqx3mgpjqbh73mj2gcr5bx") +(define %linux-libre-4.19-version "4.19.46") +(define %linux-libre-4.19-hash "17yy3h064kr7zck07wdrw3fmmmnfk15m17xvkpkc4yv5vxxi76vh") (define %linux-libre-4.19-patches (list %boot-logo-patch -- cgit v1.3 From 5ea87197f6f075df184a5c28f4414c4cc9351246 Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Sun, 26 May 2019 14:15:03 -0400 Subject: gnu: linux-libre: Update to 5.1.5. * gnu/packages/linux.scm (%linux-libre-version): Update to 5.1.5. (%linux-libre-hash): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 5f69e5b24..9cf423291 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -426,8 +426,8 @@ for ARCH and optionally VARIANT, or #f if there is no such configuration." It has been modified to remove all non-free binary blobs.") (license license:gpl2))) -(define %linux-libre-version "5.1.4") -(define %linux-libre-hash "02pzad29w2apcqsk4r4fq93539z3by8kvk1f59lb8xnl0gvhdi5v") +(define %linux-libre-version "5.1.5") +(define %linux-libre-hash "1zz0hlv509mf2vvrkvj8w19g3fhws6jk5j4ml47kzyr0lbs56iwa") (define %linux-libre-5.1-patches (list %boot-logo-patch -- cgit v1.3 From 45bdb6625115959dbf3874b69f89dd506b68fbb6 Mon Sep 17 00:00:00 2001 From: Alex Vong Date: Mon, 27 May 2019 02:18:37 +0800 Subject: gnu: you-get: Update to 0.4.1302. * gnu/packages/video.scm (you-get): Update to 0.4.1302. --- gnu/packages/video.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index 088c637b4..5e687bac5 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -1565,7 +1565,7 @@ other site that youtube-dl supports.") (define-public you-get (package (name "you-get") - (version "0.4.1270") + (version "0.4.1302") (source (origin (method git-fetch) (uri (git-reference @@ -1574,7 +1574,7 @@ other site that youtube-dl supports.") (file-name (git-file-name name version)) (sha256 (base32 - "123g6x8sh32v4yn4ss55lfw7j79hgl3l6aiwgrk4ndq7dzhnz46q")))) + "1fwwzslv1vpjr8q0fq10dbngr8zai1n3d6na700cgpky4j9y0y99")))) (build-system python-build-system) (inputs `(("ffmpeg" ,ffmpeg))) ; for multi-part and >=1080p videos -- cgit v1.3 From dfc69e4b6d4bbc41a4d37b3cc6ea12adb34aaafa Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sun, 26 May 2019 22:01:42 +0200 Subject: self: 'guix-daemon' honors %localstatedir, %sysconfdir, and %storedir. Fixes . Reported by Ricardo Wurmus . Previously, the 'guix-daemon' program provided by 'guix pull' would systematically use default directory locations for these. * guix/self.scm (whole-package)[wrap]: Set GUIX_STATE_DIRECTORY, GUIX_CONFIGURATION_DIRECTORY, and NIX_STORE_DIR. --- guix/self.scm | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/guix/self.scm b/guix/self.scm index 6d7569ec1..8cc82de64 100644 --- a/guix/self.scm +++ b/guix/self.scm @@ -603,7 +603,21 @@ Info manual." (define (wrap daemon) (program-file "guix-daemon" #~(begin + ;; Refer to the right 'guix' command for 'guix + ;; substitute' & co. (setenv "GUIX" #$command) + + ;; Honor the user's settings rather than those hardcoded + ;; in the 'guix-daemon' package. + (unless (getenv "GUIX_STATE_DIRECTORY") + (setenv "GUIX_STATE_DIRECTORY" + #$(string-append %localstatedir "/guix"))) + (unless (getenv "GUIX_CONFIGURATION_DIRECTORY") + (setenv "GUIX_CONFIGURATION_DIRECTORY" + #$(string-append %sysconfdir "/guix"))) + (unless (getenv "NIX_STORE_DIR") + (setenv "NIX_STORE_DIR" %storedir)) + (apply execl #$(file-append daemon "/bin/guix-daemon") "guix-daemon" (cdr (command-line)))))) -- cgit v1.3 From 002d17dcaacba0f86265b34f2509419d9e21224d Mon Sep 17 00:00:00 2001 From: Robert Vollmert Date: Sat, 25 May 2019 08:40:38 +0200 Subject: discovery: 'all-modules' returns modules in path order. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit A particular effect of this is that if there are ambiguous packages in a directory specified with `-L module_dir` and the distribution, the version from `module_dir` will be loaded, which is usually what would be expected. (E.g. for `guix build` or `guix package -i`.) * guix/discovery.scm (all-modules): Return modules in path order. * tests/guix-package.sh: Test local definitions take precedence. Signed-off-by: Ludovic Courtès --- guix/discovery.scm | 4 ++-- tests/guix-package.sh | 14 ++++++++++++++ 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/guix/discovery.scm b/guix/discovery.scm index ef5ae7397..5bb494941 100644 --- a/guix/discovery.scm +++ b/guix/discovery.scm @@ -145,8 +145,8 @@ Call (PROC MODULE RESULT) for each module that is found." "Return the list of package modules found in PATH, a list of directories to search. Entries in PATH can be directory names (strings) or (DIRECTORY . SUB-DIRECTORY) pairs, in which case modules are searched for beneath -SUB-DIRECTORY." - (fold-modules cons '() path #:warn warn)) +SUB-DIRECTORY. Modules are listed in the order they appear on the path." + (reverse (fold-modules cons '() path #:warn warn))) (define (fold-module-public-variables* proc init modules) "Call (PROC MODULE SYMBOL VARIABLE) for each variable exported by one of MODULES, diff --git a/tests/guix-package.sh b/tests/guix-package.sh index 767c3f8a6..79d6ec65e 100644 --- a/tests/guix-package.sh +++ b/tests/guix-package.sh @@ -280,6 +280,20 @@ export GUIX_PACKAGE_PATH guix package -A emacs-foo-bar | grep 42 guix package -i emacs-foo-bar@42 -n +# Make sure GUIX_PACKAGE_PATH/'-L' takes precedence in case of duplicate packages. +cat > "$module_dir/bar.scm"<&1 | grep choosing.*bar.scm +( unset GUIX_PACKAGE_PATH; \ + guix package -i hello -n -L "$module_dir" 2>&1 | grep choosing.*bar.scm ) + # Make sure patches that live under $GUIX_PACKAGE_PATH are found. cat > "$module_dir/emacs.patch"< Date: Sun, 26 May 2019 23:18:21 +0200 Subject: import: hackage: Fix Cabal test. * guix/import/hackage.scm (hackage->guix-package): Remove call to 'memoize'. (hackage->guix-package/m): New procedure. (hackage-recursive-import): Use it. * tests/hackage.scm ("hackage->guix-package test 6"): Adjust. Co-authored-by: Robert Vollmert --- guix/import/hackage.scm | 32 +++++++++++++++++--------------- tests/hackage.scm | 37 +++++++++++++++++++++++++++++++++++-- 2 files changed, 52 insertions(+), 17 deletions(-) diff --git a/guix/import/hackage.scm b/guix/import/hackage.scm index 2731b4cbe..bf7e99df1 100644 --- a/guix/import/hackage.scm +++ b/guix/import/hackage.scm @@ -279,13 +279,11 @@ representation of a Cabal file as produced by 'read-cabal'." (license ,(string->license (cabal-package-license cabal)))) (append hackage-dependencies hackage-native-dependencies)))) -(define hackage->guix-package - (memoize - (lambda* (package-name #:key - (include-test-dependencies? #t) - (port #f) - (cabal-environment '())) - "Fetch the Cabal file for PACKAGE-NAME from hackage.haskell.org, or, if the +(define* (hackage->guix-package package-name #:key + (include-test-dependencies? #t) + (port #f) + (cabal-environment '())) + "Fetch the Cabal file for PACKAGE-NAME from hackage.haskell.org, or, if the called with keyword parameter PORT, from PORT. Return the `package' S-expression corresponding to that package, or #f on failure. CABAL-ENVIRONMENT is an alist defining the environment in which the Cabal @@ -295,18 +293,22 @@ symbol 'true' or 'false'. The value associated with other keys has to conform to the Cabal file format definition. The default value associated with the keys \"os\", \"arch\" and \"impl\" is \"linux\", \"x86_64\" and \"ghc\" respectively." - (let ((cabal-meta (if port - (read-cabal (canonical-newline-port port)) - (hackage-fetch package-name)))) - (and=> cabal-meta (compose (cut hackage-module->sexp <> - #:include-test-dependencies? - include-test-dependencies?) - (cut eval-cabal <> cabal-environment))))))) + (let ((cabal-meta (if port + (read-cabal (canonical-newline-port port)) + (hackage-fetch package-name)))) + (and=> cabal-meta (compose (cut hackage-module->sexp <> + #:include-test-dependencies? + include-test-dependencies?) + (cut eval-cabal <> cabal-environment))))) + +(define hackage->guix-package/m ;memoized variant + (memoize hackage->guix-package)) (define* (hackage-recursive-import package-name . args) (recursive-import package-name #f #:repo->guix-package (lambda (name repo) - (apply hackage->guix-package (cons name args))) + (apply hackage->guix-package/m + (cons name args))) #:guix-name hackage-name->package-name)) (define (hackage-package? package) diff --git a/tests/hackage.scm b/tests/hackage.scm index e17851a21..0efad0638 100644 --- a/tests/hackage.scm +++ b/tests/hackage.scm @@ -207,8 +207,41 @@ library #:cabal-environment '(("impl" . "ghc-7.8")))) (test-assert "hackage->guix-package test 6" - (eval-test-with-cabal test-cabal-6 - #:cabal-environment '(("impl" . "ghc-7.8")))) + (mock + ((guix import hackage) hackage-fetch + (lambda (name-version) + (call-with-input-string test-cabal-6 + read-cabal))) + (match (hackage->guix-package "foo") + (('package + ('name "ghc-foo") + ('version "1.0.0") + ('source + ('origin + ('method 'url-fetch) + ('uri ('string-append + "https://hackage.haskell.org/package/foo/foo-" + 'version + ".tar.gz")) + ('sha256 + ('base32 + (? string? hash))))) + ('build-system 'haskell-build-system) + ('inputs + ('quasiquote + (("ghc-b" ('unquote 'ghc-b)) + ("ghc-http" ('unquote 'ghc-http)) + ("ghc-mtl" ('unquote 'ghc-mtl))))) + ('native-inputs + ('quasiquote + (("ghc-haskell-gi" ('unquote 'ghc-haskell-gi))))) + ('home-page "http://test.org") + ('synopsis (? string?)) + ('description (? string?)) + ('license 'bsd-3)) + #t) + (x + (pk 'fail x #f))))) (test-assert "read-cabal test 1" (match (call-with-input-string test-read-cabal-1 read-cabal) -- cgit v1.3 From 66fca5041be01f5466a9afc618f66608b4484357 Mon Sep 17 00:00:00 2001 From: guy fleury iteriteka Date: Fri, 17 May 2019 09:15:35 +0200 Subject: gnu: MATE: Use mirror://mate/ in source URIs. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/mate.scm(MATE packages)[source](uri): Use "mirror://mate/" instead of "https://pub.mate-desktop.org/releases/" directly. Signed-off-by: Ludovic Courtès --- gnu/packages/mate.scm | 165 +++++++++++++++++++++----------------------------- 1 file changed, 70 insertions(+), 95 deletions(-) diff --git a/gnu/packages/mate.scm b/gnu/packages/mate.scm index f234d2c86..c2a6aaf01 100644 --- a/gnu/packages/mate.scm +++ b/gnu/packages/mate.scm @@ -79,8 +79,7 @@ (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -136,14 +135,14 @@ actions.") (package (name "mate-icon-theme") (version "1.22.0") - (source (origin - (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" - name "-" version ".tar.xz")) - (sha256 - (base32 - "090vfxpn1b1wwvkilv1j3cx4swdm4z0s7xyvhvqhdzj58zsf2000")))) + (source + (origin + (method url-fetch) + (uri (string-append "mirror://mate/" (version-major+minor version) "/" + name "-" version ".tar.xz")) + (sha256 + (base32 + "090vfxpn1b1wwvkilv1j3cx4swdm4z0s7xyvhvqhdzj58zsf2000")))) (build-system gnu-build-system) (native-inputs `(("pkg-config" ,pkg-config) @@ -159,14 +158,14 @@ actions.") (package (name "mate-icon-theme-faenza") (version "1.20.0") - (source (origin - (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" - name "-" version ".tar.xz")) - (sha256 - (base32 - "000vr9cnbl2qlysf2gyg1lsjirqdzmwrnh6d3hyrsfc0r2vh4wna")))) + (source + (origin + (method url-fetch) + (uri (string-append "mirror://mate/" (version-major+minor version) "/" + name "-" version ".tar.xz")) + (sha256 + (base32 + "000vr9cnbl2qlysf2gyg1lsjirqdzmwrnh6d3hyrsfc0r2vh4wna")))) (build-system gnu-build-system) (arguments `(#:phases @@ -197,11 +196,11 @@ from Mint-X-F and Faenza-Fresh icon packs.") (package (name "mate-themes") (version "3.22.19") - (source (origin - (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/themes/" - (version-major+minor version) "/mate-themes-" - version ".tar.xz")) + (source + (origin + (method url-fetch) + (uri (string-append "mirror://mate/themes/" (version-major+minor version) + "/mate-themes-" version ".tar.xz")) (sha256 (base32 "1ycb8b8r0s8d1h1477135mynr53s5781gdb2ap8xlvj2g58492wq")))) @@ -225,14 +224,14 @@ themes for both gtk+-2 and gtk+-3.") (package (name "mate-desktop") (version "1.22.0") - (source (origin - (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" - name "-" version ".tar.xz")) - (sha256 - (base32 - "09gn840p6qds21kxab4pidjd53g76s76i7178fdibrz462mda217")))) + (source + (origin + (method url-fetch) + (uri (string-append "mirror://mate/" (version-major+minor version) "/" + name "-" version ".tar.xz")) + (sha256 + (base32 + "09gn840p6qds21kxab4pidjd53g76s76i7178fdibrz462mda217")))) (build-system gnu-build-system) (native-inputs `(("pkg-config" ,pkg-config) @@ -259,14 +258,14 @@ desktop and the mate-about program.") (package (name "libmateweather") (version "1.22.0") - (source (origin - (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" - name "-" version ".tar.xz")) - (sha256 - (base32 - "1ribgcwl4ncfbcf9bkcbxrgc7yzajdnxg12837psngymkqswlp6a")))) + (source + (origin + (method url-fetch) + (uri (string-append "mirror://mate/" (version-major+minor version) "/" + name "-" version ".tar.xz")) + (sha256 + (base32 + "1ribgcwl4ncfbcf9bkcbxrgc7yzajdnxg12837psngymkqswlp6a")))) (build-system gnu-build-system) (arguments '(#:configure-flags @@ -308,8 +307,7 @@ the MATE desktop environment.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -349,8 +347,7 @@ configurations (profiles).") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -417,8 +414,7 @@ configuration program to choose applications starting on login.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -460,8 +456,7 @@ configuration program to choose applications starting on login.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -490,8 +485,7 @@ sound systems.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -519,14 +513,14 @@ MATE desktop environment.") (package (name "mate-menus") (version "1.22.0") - (source (origin - (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" - name "-" version ".tar.xz")) - (sha256 - (base32 - "1lkakbf2f1815c146z4xp5f0h4lim6jzr02681wbvzalc6k97v5c")))) + (source + (origin + (method url-fetch) + (uri (string-append "mirror://mate/" (version-major+minor version) "/" + name "-" version ".tar.xz")) + (sha256 + (base32 + "1lkakbf2f1815c146z4xp5f0h4lim6jzr02681wbvzalc6k97v5c")))) (build-system gnu-build-system) (arguments `(#:phases @@ -563,8 +557,7 @@ assorted menu related utility programs.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -637,8 +630,7 @@ Interactive Weather Information Network (IWIN). (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -674,8 +666,7 @@ mate-volume-control, a MATE volume control application and applet.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -748,8 +739,7 @@ infamous 'Wanda the Fish'.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -852,8 +842,7 @@ infamous 'Wanda the Fish'.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -911,8 +900,7 @@ icons on the MATE desktop. It works on local and remote file systems.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -966,8 +954,7 @@ icons on the MATE desktop. It works on local and remote file systems.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -1026,8 +1013,7 @@ of various aspects of your desktop.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -1077,8 +1063,7 @@ for use with MATE or as a standalone window manager.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -1117,8 +1102,7 @@ sessions, panels, menus, file management, and preferences.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -1149,8 +1133,7 @@ sessions, panels, menus, file management, and preferences.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -1172,8 +1155,7 @@ can be used as backgrounds in the MATE Desktop environment.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -1214,8 +1196,7 @@ Re-decorates windows on un-maximise. (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -1286,8 +1267,7 @@ can be used as backgrounds in the MATE Desktop environment.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -1339,8 +1319,7 @@ can be used as backgrounds in the MATE Desktop environment.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -1390,8 +1369,7 @@ can be used as backgrounds in the MATE Desktop environment.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -1444,8 +1422,7 @@ can be used as backgrounds in the MATE Desktop environment.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -1495,8 +1472,7 @@ can be used as backgrounds in the MATE Desktop environment.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 @@ -1536,8 +1512,7 @@ MATE Desktop to monitor your system resources and usage.") (source (origin (method url-fetch) - (uri (string-append "https://pub.mate-desktop.org/releases/" - (version-major+minor version) "/" + (uri (string-append "mirror://mate/" (version-major+minor version) "/" name "-" version ".tar.xz")) (sha256 (base32 -- cgit v1.3 From 71bd55cb2a946ae403ed19f2fe0656d1123f915b Mon Sep 17 00:00:00 2001 From: Stefan Stefanović Date: Sat, 20 Apr 2019 15:37:13 +0200 Subject: gnu: Add x86-energy-perf-policy. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/linux.scm (x86-energy-perf-policy): New variable. Signed-off-by: Ludovic Courtès --- gnu/packages/linux.scm | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 9cf423291..a801e5039 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -34,6 +34,7 @@ ;;; Copyright © 2018 Vasile Dumitrascu ;;; Copyright © 2019 Tim Gesthuizen ;;; Copyright © 2019 Maxim Cournoyer +;;; Copyright © 2019 Stefan Stefanović ;;; ;;; This file is part of GNU Guix. ;;; @@ -4039,6 +4040,39 @@ Linux kernel to retrieve and control processor features related to power saving, such as frequency and voltage scaling.") (license license:gpl2))) +(define-public x86-energy-perf-policy + (package + (name "x86-energy-perf-policy") + (version (package-version linux-libre)) + (source (package-source linux-libre)) + (build-system gnu-build-system) + (arguments + '(#:tests? #f + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'enter-subdirectory + (lambda _ + (chdir "tools/power/x86/x86_energy_perf_policy") + #t)) + (delete 'configure) + (add-before 'build 'fix-makefile + (lambda _ + (substitute* "Makefile" (("/usr") "")) + #t))) + #:make-flags + (let ((out (assoc-ref %outputs "out"))) + (list (string-append "DESTDIR=" out) + (string-append "LDFLAGS=-Wl,-rpath=" out "/lib"))))) + (supported-systems '("i686-linux" "x86_64-linux")) + (home-page (package-home-page linux-libre)) + (synopsis "Display and update Intel-CPU energy-performance policy") + (description + "@command{x86_energy_perf_policy} displays and updates energy-performance +policy settings specific to Intel Architecture Processors. Settings are +accessed via Model Specific Register (MSR) updates, no matter if the Linux +cpufreq sub-system is enabled or not.") + (license license:gpl2))) + (define-public haveged (package (name "haveged") -- cgit v1.3 From cf342a859820c76ab749db3ac5e630ba09a9ad26 Mon Sep 17 00:00:00 2001 From: Stefan Stefanović Date: Sat, 20 Apr 2019 16:13:37 +0200 Subject: gnu: tlp: Add required x86-energy-perf-policy input dependency. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/linux.scm (tlp) [inputs]: Add system specific x86-energy-perf-policy dependency. [arguments]<#:phases>['wrap]: Adjust bin-directory procedure to return #f on missing input, a guard against system specific input dependencies. Filter only strings in the path list. Reformat for-each block. Add x86-energy-perf-policy in bin-directory input-name list. Co-authored-by: Ludovic Courtès --- gnu/packages/linux.scm | 53 +++++++++++++++++++++++++++++++------------------- 1 file changed, 33 insertions(+), 20 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index a801e5039..67085f30f 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -4601,10 +4601,19 @@ interface in sysfs, which can be accomplished with the included udev rules.") ("sed" ,sed) ("usbutils" ,usbutils) ("util-linux" ,util-linux) - ("wireless-tools" ,wireless-tools))) + ("wireless-tools" ,wireless-tools) + ,@(if (let ((system (or (%current-target-system) + (%current-system)))) + (or (string-prefix? "i686-" system) + (string-prefix? "x86_64-" system))) + `(("x86-energy-perf-policy" ,x86-energy-perf-policy)) + '()))) (build-system gnu-build-system) (arguments - `(#:phases + `(#:modules ((guix build gnu-build-system) + (guix build utils) + (srfi srfi-1)) + #:phases (modify-phases %standard-phases (delete 'configure) ; no configure script (add-before 'build 'setenv @@ -4642,30 +4651,34 @@ interface in sysfs, which can be accomplished with the included udev rules.") (let* ((bin (string-append (assoc-ref outputs "out") "/bin")) (bin-files (find-files bin ".*"))) (define (bin-directory input-name) - (string-append (assoc-ref inputs input-name) "/bin")) + (let ((p (assoc-ref inputs input-name))) + (and p (string-append p "/bin")))) (define (sbin-directory input-name) (string-append (assoc-ref inputs input-name) "/sbin")) (for-each (lambda (program) (wrap-program program `("PATH" ":" prefix ,(append - (map bin-directory '("bash" - "coreutils" - "dbus" - "eudev" - "grep" - "inetutils" - "kmod" - "perl" - "sed" - "usbutils" - "util-linux")) - (map sbin-directory '("ethtool" - "hdparm" - "iw" - "pciutils" - "rfkill" - "wireless-tools")))))) + (filter-map bin-directory + '("bash" + "coreutils" + "dbus" + "eudev" + "grep" + "inetutils" + "kmod" + "perl" + "sed" + "usbutils" + "util-linux" + "x86-energy-perf-policy")) + (filter-map sbin-directory + '("ethtool" + "hdparm" + "iw" + "pciutils" + "rfkill" + "wireless-tools")))))) bin-files) #t)))))) (home-page "http://linrunner.de/en/tlp/tlp.html") -- cgit v1.3 From f644f6365505eaad79ffca7046e18907b5d7a5b6 Mon Sep 17 00:00:00 2001 From: "Jakob L. Kreuze" Date: Thu, 23 May 2019 10:39:52 -0400 Subject: doc: Update default value of terminal-outputs. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * doc/guix.texi: (terminal-outputs) Update default value. Signed-off-by: Ludovic Courtès --- doc/guix.texi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/guix.texi b/doc/guix.texi index d60f453b2..98c5d1e91 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -24132,7 +24132,7 @@ The bootloader theme object describing the theme to use. If no theme is provided, some bootloaders might use a default theme, that's true for GRUB. -@item @code{terminal-outputs} (default: @code{'gfxterm}) +@item @code{terminal-outputs} (default: @code{'(gfxterm)}) The output terminals used for the bootloader boot menu, as a list of symbols. GRUB accepts the values: @code{console}, @code{serial}, @code{serial_@{0-3@}}, @code{gfxterm}, @code{vga_text}, -- cgit v1.3 From 8d1647b2286337d8c94f127ff2a0258a1550fd4d Mon Sep 17 00:00:00 2001 From: Danny Milosavljevic Date: Mon, 27 May 2019 18:16:25 +0200 Subject: gnu: python-alembic: Update to 1.0.10. * gnu/packages/databases.scm (python-alembic): Update to 1.0.10. --- gnu/packages/databases.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index 8a6e3ab00..ad4698f24 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -2415,14 +2415,14 @@ You might also want to install the following optional dependencies: (define-public python-alembic (package (name "python-alembic") - (version "1.0.2") + (version "1.0.10") (source (origin (method url-fetch) (uri (pypi-uri "alembic" version)) (sha256 (base32 - "0asqz9mwc4w8bsar1icv3ik9jslxrj3gv3yxgmhc6nc6r9qbkg04")))) + "1dwl0264r6ri2jyrjr68am04x538ab26xwy4crqjnnhm4alwm3c2")))) (build-system python-build-system) (native-inputs `(("python-mock" ,python-mock) -- cgit v1.3 From 521d736ae97ef34f4e6136c7175a99c680c5ac95 Mon Sep 17 00:00:00 2001 From: Alex Griffin Date: Sat, 20 Apr 2019 14:01:17 -0500 Subject: gnu: go@1.4: Update to 1.4-bootstrap-20171003. * gnu/packages/golang.scm (go-1.4): Use the bootstrap branch that is still supported upstream. [version]: Update to 1.4-bootstrap-20171003. [arguments]: Remove obsolete fix for timezone test which is now included upstream. Don't manually disable cgo because it is disabled by default. Manually enable test suite because future releases will disable tests by default. Signed-off-by: Leo Famulari --- gnu/packages/golang.scm | 20 +++++++------------- 1 file changed, 7 insertions(+), 13 deletions(-) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index ed0a78c6b..611c848bd 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -14,6 +14,7 @@ ;;; Copyright © 2018 Pierre Neidhardt ;;; Copyright @ 2018, 2019 Katherine Cox-Buday ;;; Copyright @ 2019 Giovanni Biscuolo +;;; Copyright @ 2019 Alex Griffin ;;; ;;; This file is part of GNU Guix. ;;; @@ -61,14 +62,16 @@ (define-public go-1.4 (package (name "go") - (version "1.4.3") + ;; The C-langauge bootstrap of Go: + ;; https://golang.org/doc/install/source#go14 + (version "1.4-bootstrap-20171003") (source (origin (method url-fetch) (uri (string-append "https://storage.googleapis.com/golang/" - name version ".src.tar.gz")) + name version ".tar.gz")) (sha256 (base32 - "0na9yqilzpvq0bjndbibfp07wr796gf252y471cip10bbdqgqiwr")))) + "0liybk5z00hizsb5ypkbhqcawnwwa6mkwgvjjg4y3jm3ndg5pzzl")))) (build-system gnu-build-system) (outputs '("out" "doc" @@ -135,13 +138,6 @@ ("os/os_test.go" "(.+)(TestHostname.+)") ("time/format_test.go" "(.+)(TestParseInSydney.+)") - ;; Tzdata 2016g changed the name of the time zone used in this - ;; test, and the patch for Go 1.7 does not work for 1.4.3: - ;; https://github.com/golang/go/issues/17545 - ;; https://github.com/golang/go/issues/17276 - ("time/time_test.go" "(.+)(TestLoadFixed.+)") - ("time/format_test.go" "(.+)(TestParseInLocation.+)") - ("os/exec/exec_test.go" "(.+)(TestEcho.+)") ("os/exec/exec_test.go" "(.+)(TestCommandRelativeName.+)") ("os/exec/exec_test.go" "(.+)(TestCatStdin.+)") @@ -168,9 +164,7 @@ (setenv "GOOS" "linux") (setenv "GOROOT" (dirname (getcwd))) (setenv "GOROOT_FINAL" output) - ;; Go 1.4's cgo will not work with binutils >= 2.27: - ;; https://github.com/golang/go/issues/16906 - (setenv "CGO_ENABLED" "0") + (setenv "GO14TESTS" "1") (invoke "sh" "all.bash")))) (replace 'install -- cgit v1.3 From ed72a133dbba02cd1d49a19e0a6391ce9384840e Mon Sep 17 00:00:00 2001 From: Guillaume LE VAILLANT Date: Mon, 27 May 2019 17:05:16 +0200 Subject: gnu: Add osmctools * gnu/packages/geo.scm (osmctools): New variable. Signed-off-by: Leo Famulari --- gnu/packages/geo.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/geo.scm b/gnu/packages/geo.scm index 94f2cf0cf..ec5ace351 100644 --- a/gnu/packages/geo.scm +++ b/gnu/packages/geo.scm @@ -7,6 +7,7 @@ ;;; Copyright © 2018 Arun Isaac ;;; Copyright © 2018 Joshua Sierles, Nextjournal ;;; Copyright © 2018 Julien Lepiller +;;; Copyright © 2019 Guillaume Le Vaillant ;;; ;;; This file is part of GNU Guix. ;;; @@ -36,6 +37,7 @@ #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (guix utils) + #:use-module (gnu packages autotools) #:use-module (gnu packages boost) #:use-module (gnu packages check) #:use-module (gnu packages compression) @@ -840,3 +842,30 @@ map, geocoding with Nominatim, or general analysis.") the texture and density of features is visible at every zoom level, instead of dropping features at lower levels.") (license license:bsd-2))) + +(define-public osmctools + (package + (name "osmctools") + (version "0.9") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://gitlab.com/osm-c-tools/osmctools") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1m8d3r1q1v05pkr8k9czrmb4xjszw6hvgsf3kn9pf0v14gpn4r8f")))) + (build-system gnu-build-system) + (native-inputs + `(("autoconf" ,autoconf) + ("automake" ,automake))) + (inputs + `(("zlib" ,zlib))) + (home-page "https://gitlab.com/osm-c-tools/osmctools") + (synopsis "Tools to convert, filter and update OpenStreetMap data files") + (description "This project contains a few tools which are used in the +OpenStreetMap project. They can be used to convert, filter and update +OpenStreetMap data files.") + (license license:agpl3))) -- cgit v1.3 From 8916034a347dd9a11b89678c9112c10ed8681e9b Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Mon, 27 May 2019 22:07:57 +0200 Subject: gnu: r-shiny: Fix JavaScript minification. Fixes . * gnu/packages/cran.scm (r-shiny)[native-inputs]: Add uglify-js. --- gnu/packages/cran.scm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 199dfbdbe..c5fc3be4a 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -738,6 +738,8 @@ and vice-versa.") ("js-strftime" ,js-strftime) ("js-highlight" ,js-highlight) ("js-es5-shim" ,js-es5-shim))) + (native-inputs + `(("uglify-js" ,uglify-js))) (home-page "http://shiny.rstudio.com") (synopsis "Easy interactive web applications with R") (description -- cgit v1.3 From e13354a7ca5a0d5e28e02c4cfce6fecb1ab770e4 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Mon, 27 May 2019 22:27:02 +0200 Subject: lzlib: Adjust 'lz-compress-read' docstring. * guix/lzlib.scm (lz-compress-read): The integer return can be zero; adjust docstring accordingly. --- guix/lzlib.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/guix/lzlib.scm b/guix/lzlib.scm index a6dac4604..deb900f35 100644 --- a/guix/lzlib.scm +++ b/guix/lzlib.scm @@ -168,7 +168,7 @@ so use it only when needed. " (let ((proc (lzlib-procedure int "LZ_compress_read" (list '* '* int)))) (lambda* (encoder lzfile-bv #:optional (start 0) (count (bytevector-length lzfile-bv))) "Read up to COUNT bytes from the encoder stream, storing the results in LZFILE-BV. -Return the number of uncompressed bytes written, a strictly positive integer." +Return the number of uncompressed bytes written, a positive integer." (let ((ret (proc (lz-encoder->pointer encoder) (bytevector->pointer lzfile-bv start) count))) -- cgit v1.3 From 2a991f3ae4823730395c7970d83159e93d5f5fe2 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Thu, 23 May 2019 21:35:47 +0200 Subject: lzlib: Add 'make-lzip-input-port/compressed'. * guix/lzlib.scm (lzwrite!, make-lzip-input-port/compressed): New procedures. * tests/lzlib.scm ("make-lzip-input-port/compressed"): New test. * guix/tests.scm (%seed): Export. --- guix/lzlib.scm | 71 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ guix/tests.scm | 1 + tests/lzlib.scm | 10 ++++++++ 3 files changed, 82 insertions(+) diff --git a/guix/lzlib.scm b/guix/lzlib.scm index deb900f35..a484315c0 100644 --- a/guix/lzlib.scm +++ b/guix/lzlib.scm @@ -1,5 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2019 Pierre Neidhardt +;;; Copyright © 2019 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -23,9 +24,11 @@ #:use-module (ice-9 match) #:use-module (system foreign) #:use-module (guix config) + #:use-module (srfi srfi-11) #:export (lzlib-available? make-lzip-input-port make-lzip-output-port + make-lzip-input-port/compressed call-with-lzip-input-port call-with-lzip-output-port %default-member-length-limit @@ -515,6 +518,24 @@ the end-of-stream has been reached." (loop rd))) read)) +(define (lzwrite! encoder source source-offset source-count + target target-offset target-count) + "Write up to SOURCE-COUNT bytes from SOURCE to ENCODER, and read up to +TARGET-COUNT bytes into TARGET at TARGET-OFFSET. Return two values: the +number of bytes read from SOURCE, and the number of bytes written to TARGET, +possibly zero." + (define read + (if (> (lz-compress-write-size encoder) 0) + (match (lz-compress-write encoder source source-offset source-count) + (0 (lz-compress-finish encoder) 0) + (n n)) + 0)) + + (define written + (lz-compress-read encoder target target-offset target-count)) + + (values read written)) + (define* (lzwrite encoder bv lz-port #:optional (start 0) (count (bytevector-length bv))) "Write up to COUNT bytes from BV at offset START into LZ-PORT. Return @@ -597,6 +618,56 @@ port is closed." (lz-compress-close encoder) (close-port port)))) +(define* (make-lzip-input-port/compressed port + #:key + (level %default-compression-level)) + "Return an input port that compresses data read from PORT, with the given LEVEL. +PORT is automatically closed when the resulting port is closed." + (define encoder (apply lz-compress-open + (car (assoc-ref %compression-levels level)))) + + (define input-buffer (make-bytevector 8192)) + (define input-len 0) + (define input-offset 0) + + (define input-eof? #f) + + (define (read! bv start count) + (cond + (input-eof? + (match (lz-compress-read encoder bv start count) + (0 (if (lz-compress-finished? encoder) + 0 + (read! bv start count))) + (n n))) + ((= input-offset input-len) + (match (get-bytevector-n! port input-buffer 0 + (bytevector-length input-buffer)) + ((? eof-object?) + (set! input-eof? #t) + (lz-compress-finish encoder)) + (count + (set! input-offset 0) + (set! input-len count))) + (read! bv start count)) + (else + (let-values (((read written) + (lzwrite! encoder + input-buffer input-offset + (- input-len input-offset) + bv start count))) + (set! input-offset (+ input-offset read)) + + ;; Make sure we don't return zero except on EOF. + (if (= 0 written) + (read! bv start count) + written))))) + + (make-custom-binary-input-port "lzip-input/compressed" + read! #f #f + (lambda () + (close-port port)))) + (define* (call-with-lzip-input-port port proc) "Call PROC with a port that wraps PORT and decompresses data read from it. PORT is closed upon completion." diff --git a/guix/tests.scm b/guix/tests.scm index 35ebf8464..66d60e964 100644 --- a/guix/tests.scm +++ b/guix/tests.scm @@ -33,6 +33,7 @@ #:use-module (web uri) #:export (open-connection-for-tests with-external-store + %seed random-text random-bytevector file=? diff --git a/tests/lzlib.scm b/tests/lzlib.scm index cf53a9417..543622bb4 100644 --- a/tests/lzlib.scm +++ b/tests/lzlib.scm @@ -108,4 +108,14 @@ (test-assert* "Bytevector of size relative to Lzip internal buffers (1MiB+1)" (compress-and-decompress (random-bytevector (1+ (* 1024 1024))))) +(test-assert "make-lzip-input-port/compressed" + (let* ((len (pk 'len (+ 10 (random 4000 %seed)))) + (data (random-bytevector len)) + (compressed (make-lzip-input-port/compressed + (open-bytevector-input-port data))) + (result (call-with-lzip-input-port compressed + get-bytevector-all))) + (pk (bytevector-length result) (bytevector-length data)) + (bytevector=? result data))) + (test-end) -- cgit v1.3 From 4c7ebe318f6b3c4ddadcea8d08c9fb67ac46ec1e Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Thu, 23 May 2019 22:11:33 +0200 Subject: utils: Test 'compressed-port' and 'decompressed-port' for both gzip and xz. * tests/utils.scm (test-compression/decompression): New procedure. : Call it for both 'xz and 'gzip. --- tests/utils.scm | 67 ++++++++++++++++++++++++++++++++++++--------------------- 1 file changed, 42 insertions(+), 25 deletions(-) diff --git a/tests/utils.scm b/tests/utils.scm index 3015b21b2..a5141592a 100644 --- a/tests/utils.scm +++ b/tests/utils.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018 Ludovic Courtès +;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019 Ludovic Courtès ;;; Copyright © 2014 Eric Bavier ;;; Copyright © 2016 Mathieu Lirzin ;;; @@ -174,30 +174,47 @@ (any (compose (negate zero?) cdr waitpid) pids)))) -(test-assert "compressed-port, decompressed-port, non-file" - (let ((data (call-with-input-file (search-path %load-path "guix.scm") - get-bytevector-all))) - (let*-values (((compressed pids1) - (compressed-port 'xz (open-bytevector-input-port data))) - ((decompressed pids2) - (decompressed-port 'xz compressed))) - (and (every (compose zero? cdr waitpid) - (append pids1 pids2)) - (equal? (get-bytevector-all decompressed) data))))) - -(false-if-exception (delete-file temp-file)) -(test-assert "compressed-output-port + decompressed-port" - (let* ((file (search-path %load-path "guix/derivations.scm")) - (data (call-with-input-file file get-bytevector-all)) - (port (open-file temp-file "w0b"))) - (call-with-compressed-output-port 'xz port - (lambda (compressed) - (put-bytevector compressed data))) - (close-port port) - - (bytevector=? data - (call-with-decompressed-port 'xz (open-file temp-file "r0b") - get-bytevector-all)))) +(define (test-compression/decompression method run?) + "Test METHOD, a symbol such as 'gzip. Call RUN? to determine whether to +skip these tests." + (unless (run?) (test-skip 1)) + (test-assert (format #f "compressed-port, decompressed-port, non-file [~a]" + method) + (let ((data (call-with-input-file (search-path %load-path "guix.scm") + get-bytevector-all))) + (let*-values (((compressed pids1) + (compressed-port method (open-bytevector-input-port data))) + ((decompressed pids2) + (decompressed-port method compressed))) + (and (every (compose zero? cdr waitpid) + (pk 'pids method (append pids1 pids2))) + (let ((result (get-bytevector-all decompressed))) + (pk 'len method + (if (bytevector? result) + (bytevector-length result) + result) + (bytevector-length data)) + (equal? result data)))))) + + (false-if-exception (delete-file temp-file)) + (unless (run?) (test-skip 1)) + (test-assert (format #f "compressed-output-port + decompressed-port [~a]" + method) + (let* ((file (search-path %load-path "guix/derivations.scm")) + (data (call-with-input-file file get-bytevector-all)) + (port (open-file temp-file "w0b"))) + (call-with-compressed-output-port method port + (lambda (compressed) + (put-bytevector compressed data))) + (close-port port) + + (bytevector=? data + (call-with-decompressed-port method (open-file temp-file "r0b") + get-bytevector-all))))) + +(for-each test-compression/decompression + '(gzip xz lzip) + (list (const #t) (const #t))) ;; This is actually in (guix store). (test-equal "store-path-package-name" -- cgit v1.3 From 4e48923e7523c863996bb616c6abb7e4cb78a3b5 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Thu, 23 May 2019 22:14:53 +0200 Subject: utils: Support compression and decompression with lzip. * guix/utils.scm (lzip-port): New procedure. (decompressed-port, compressed-port, compressed-output-port): Add 'lzip case. * tests/utils.scm : Call 'test-compression/decompression' for 'lzip as well. --- guix/utils.scm | 27 ++++++++++++++++++++++----- tests/utils.scm | 3 ++- 2 files changed, 24 insertions(+), 6 deletions(-) diff --git a/guix/utils.scm b/guix/utils.scm index ed1a418cc..709cdf935 100644 --- a/guix/utils.scm +++ b/guix/utils.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018 Ludovic Courtès +;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019 Ludovic Courtès ;;; Copyright © 2013, 2014, 2015 Mark H Weaver ;;; Copyright © 2014 Eric Bavier ;;; Copyright © 2014 Ian Denhardt @@ -169,6 +169,17 @@ buffered data is lost." (close-port out) (loop in (cons child pids))))))))) +(define (lzip-port proc port . args) + "Return the lzip port produced by calling PROC (a symbol) on PORT and ARGS. +Raise an error if lzlib support is missing." + (let* ((lzlib (false-if-exception (resolve-interface '(guix lzlib)))) + (supported? (and lzlib + ((module-ref lzlib 'lzlib-available?))))) + (if supported? + (let ((make-port (module-ref lzlib proc))) + (values (make-port port) '())) + (error "lzip compression not supported" lzlib)))) + (define (decompressed-port compression input) "Return an input port where INPUT is decompressed according to COMPRESSION, a symbol such as 'xz." @@ -177,17 +188,21 @@ a symbol such as 'xz." ('bzip2 (filtered-port `(,%bzip2 "-dc") input)) ('xz (filtered-port `(,%xz "-dc") input)) ('gzip (filtered-port `(,%gzip "-dc") input)) - (else (error "unsupported compression scheme" compression)))) + ('lzip (values (lzip-port 'make-lzip-input-port input) + '())) + (_ (error "unsupported compression scheme" compression)))) (define (compressed-port compression input) - "Return an input port where INPUT is decompressed according to COMPRESSION, + "Return an input port where INPUT is compressed according to COMPRESSION, a symbol such as 'xz." (match compression ((or #f 'none) (values input '())) ('bzip2 (filtered-port `(,%bzip2 "-c") input)) ('xz (filtered-port `(,%xz "-c") input)) ('gzip (filtered-port `(,%gzip "-c") input)) - (else (error "unsupported compression scheme" compression)))) + ('lzip (values (lzip-port 'make-lzip-input-port/compressed input) + '())) + (_ (error "unsupported compression scheme" compression)))) (define (call-with-decompressed-port compression port proc) "Call PROC with a wrapper around PORT, a file port, that decompresses data @@ -244,7 +259,9 @@ program--e.g., '(\"--fast\")." ('bzip2 (filtered-output-port `(,%bzip2 "-c" ,@options) output)) ('xz (filtered-output-port `(,%xz "-c" ,@options) output)) ('gzip (filtered-output-port `(,%gzip "-c" ,@options) output)) - (else (error "unsupported compression scheme" compression)))) + ('lzip (values (lzip-port 'make-lzip-output-port output) + '())) + (_ (error "unsupported compression scheme" compression)))) (define* (call-with-compressed-output-port compression port proc #:key (options '())) diff --git a/tests/utils.scm b/tests/utils.scm index a5141592a..44861384a 100644 --- a/tests/utils.scm +++ b/tests/utils.scm @@ -23,6 +23,7 @@ #:use-module (guix utils) #:use-module ((guix store) #:select (%store-prefix store-path-package-name)) #:use-module ((guix search-paths) #:select (string-tokenize*)) + #:use-module ((guix lzlib) #:select (lzlib-available?)) #:use-module (srfi srfi-1) #:use-module (srfi srfi-11) #:use-module (srfi srfi-64) @@ -214,7 +215,7 @@ skip these tests." (for-each test-compression/decompression '(gzip xz lzip) - (list (const #t) (const #t))) + (list (const #t) (const #t) lzlib-available?)) ;; This is actually in (guix store). (test-equal "store-path-package-name" -- cgit v1.3 From 66229b04ae0ee05779b93d77900a062b8e0e8770 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Fri, 24 May 2019 08:26:38 +0200 Subject: publish: Add support for lzip. * guix/scripts/publish.scm (show-help, %options): Support '-C METHOD' and '-C METHOD:LEVEL'. (default-compression): New procedure. (bake-narinfo+nar): Add lzip. (nar-response-port): Likewise. (string->compression-type): New procedure. (make-request-handler): Generalize /nar/gzip handler to handle /nar/lzip as well. * tests/publish.scm ("/nar/lzip/*"): New test. ("/*.narinfo with lzip compression"): New test. * doc/guix.texi (Invoking guix publish): Document it. (Requirements): Mention lzlib. --- .dir-locals.el | 2 ++ doc/guix.texi | 25 ++++++++++---- guix/scripts/publish.scm | 84 +++++++++++++++++++++++++++++++++++------------- tests/publish.scm | 36 +++++++++++++++++++++ 4 files changed, 119 insertions(+), 28 deletions(-) diff --git a/.dir-locals.el b/.dir-locals.el index 550e06ef0..f1196fd78 100644 --- a/.dir-locals.el +++ b/.dir-locals.el @@ -53,6 +53,8 @@ (eval . (put 'call-with-decompressed-port 'scheme-indent-function 2)) (eval . (put 'call-with-gzip-input-port 'scheme-indent-function 1)) (eval . (put 'call-with-gzip-output-port 'scheme-indent-function 1)) + (eval . (put 'call-with-lzip-input-port 'scheme-indent-function 1)) + (eval . (put 'call-with-lzip-output-port 'scheme-indent-function 1)) (eval . (put 'signature-case 'scheme-indent-function 1)) (eval . (put 'emacs-batch-eval 'scheme-indent-function 0)) (eval . (put 'emacs-batch-edit-file 'scheme-indent-function 1)) diff --git a/doc/guix.texi b/doc/guix.texi index 98c5d1e91..340b80696 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -757,6 +757,11 @@ Support for build offloading (@pxref{Daemon Offload Setup}) and @uref{https://github.com/artyom-poptsov/guile-ssh, Guile-SSH}, version 0.10.2 or later. +@item +When @url{https://www.nongnu.org/lzip/lzlib.html, lzlib} is available, lzlib +substitutes can be used and @command{guix publish} can compress substitutes +with lzlib. + @item When @url{http://www.bzip.org, libbz2} is available, @command{guix-daemon} can use it to compress build logs. @@ -9656,12 +9661,20 @@ accept connections from any interface. Change privileges to @var{user} as soon as possible---i.e., once the server socket is open and the signing key has been read. -@item --compression[=@var{level}] -@itemx -C [@var{level}] -Compress data using the given @var{level}. When @var{level} is zero, -disable compression. The range 1 to 9 corresponds to different gzip -compression levels: 1 is the fastest, and 9 is the best (CPU-intensive). -The default is 3. +@item --compression[=@var{method}[:@var{level}]] +@itemx -C [@var{method}[:@var{level}]] +Compress data using the given @var{method} and @var{level}. @var{method} is +one of @code{lzip} and @code{gzip}; when @var{method} is omitted, @code{gzip} +is used. + +When @var{level} is zero, disable compression. The range 1 to 9 corresponds +to different compression levels: 1 is the fastest, and 9 is the best +(CPU-intensive). The default is 3. + +Usually, @code{lzip} compresses noticeably better than @code{gzip} for a small +increase in CPU usage; see +@uref{https://nongnu.org/lzip/lzip_benchmark.html,benchmarks on the lzip Web +page}. Unless @option{--cache} is used, compression occurs on the fly and the compressed streams are not diff --git a/guix/scripts/publish.scm b/guix/scripts/publish.scm index db64d6483..11e7e985d 100644 --- a/guix/scripts/publish.scm +++ b/guix/scripts/publish.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2015 David Thompson -;;; Copyright © 2015, 2016, 2017, 2018 Ludovic Courtès +;;; Copyright © 2015, 2016, 2017, 2018, 2019 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -51,6 +51,7 @@ #:use-module (guix store) #:use-module ((guix serialization) #:select (write-file)) #:use-module (guix zlib) + #:autoload (guix lzlib) (lzlib-available?) #:use-module (guix cache) #:use-module (guix ui) #:use-module (guix scripts) @@ -74,8 +75,8 @@ Publish ~a over HTTP.\n") %store-directory) (display (G_ " -u, --user=USER change privileges to USER as soon as possible")) (display (G_ " - -C, --compression[=LEVEL] - compress archives at LEVEL")) + -C, --compression[=METHOD:LEVEL] + compress archives with METHOD at LEVEL")) (display (G_ " -c, --cache=DIRECTORY cache published items to DIRECTORY")) (display (G_ " @@ -121,6 +122,9 @@ Publish ~a over HTTP.\n") %store-directory) ;; Since we compress on the fly, default to fast compression. (compression 'gzip 3)) +(define (default-compression type) + (compression type 3)) + (define (actual-compression item requested) "Return the actual compression used for ITEM, which may be %NO-COMPRESSION if ITEM is already compressed." @@ -153,18 +157,28 @@ if ITEM is already compressed." name))))) (option '(#\C "compression") #f #t (lambda (opt name arg result) - (match (if arg (string->number* arg) 3) - (0 - (alist-cons 'compression %no-compression result)) - (level - (if (zlib-available?) - (alist-cons 'compression - (compression 'gzip level) - result) - (begin - (warning (G_ "zlib support is missing; \ -compression disabled~%")) - result)))))) + (let* ((colon (string-index arg #\:)) + (type (cond + (colon (string-take arg colon)) + ((string->number arg) "gzip") + (else arg))) + (level (if colon + (string->number* + (string-drop arg (+ 1 colon))) + (or (string->number arg) 3)))) + (match level + (0 + (alist-cons 'compression %no-compression result)) + (level + (match (string->compression-type type) + ((? symbol? type) + (alist-cons 'compression + (compression type level) + result)) + (_ + (warning (G_ "~a: unsupported compression type~%") + type) + result))))))) (option '(#\c "cache") #t #f (lambda (opt name arg result) (alist-cons 'cache arg result))) @@ -511,6 +525,13 @@ requested using POOL." #:level (compression-level compression) #:buffer-size (* 128 1024)) (rename-file (string-append nar ".tmp") nar)) + ('lzip + ;; Note: the file port gets closed along with the lzip port. + (call-with-lzip-output-port (open-output-file (string-append nar ".tmp")) + (lambda (port) + (write-file item port)) + #:level (compression-level compression)) + (rename-file (string-append nar ".tmp") nar)) ('none ;; Cache nars even when compression is disabled so that we can ;; guarantee the TTL (see .) @@ -715,6 +736,9 @@ example: \"/foo/bar\" yields '(\"foo\" \"bar\")." (make-gzip-output-port (response-port response) #:level level #:buffer-size (* 64 1024))) + (($ 'lzip level) + (make-lzip-output-port (response-port response) + #:level level)) (($ 'none) (response-port response)) (#f @@ -789,12 +813,23 @@ blocking." http-write (@@ (web server http) http-close)) +(define (string->compression-type string) + "Return a symbol denoting the compression method expressed by STRING; return +#f if STRING doesn't match any supported method." + (match string + ("gzip" (and (zlib-available?) 'gzip)) + ("lzip" (and (lzlib-available?) 'lzip)) + (_ #f))) + (define* (make-request-handler store #:key cache pool narinfo-ttl (nar-path "nar") (compression %no-compression)) + (define compression-type? + string->compression-type) + (define nar-path? (let ((expected (split-and-decode-uri-path nar-path))) (cut equal? expected <>))) @@ -843,13 +878,18 @@ blocking." ;; is restarted with different compression parameters. ;; /nar/gzip/ - ((components ... "gzip" store-item) - (if (and (nar-path? components) (zlib-available?)) - (let ((compression (match compression - (($ 'gzip) - compression) - (_ - %default-gzip-compression)))) + ((components ... (? compression-type? type) store-item) + (if (nar-path? components) + (let* ((compression-type (string->compression-type type)) + (compression (match compression + (($ type) + (if (eq? type compression-type) + compression + (default-compression + compression-type))) + (_ + (default-compression + compression-type))))) (if cache (render-nar/cached store cache request store-item #:ttl narinfo-ttl diff --git a/tests/publish.scm b/tests/publish.scm index 7f44bc700..80e0977cd 100644 --- a/tests/publish.scm +++ b/tests/publish.scm @@ -36,6 +36,7 @@ #:use-module (gcrypt pk-crypto) #:use-module ((guix pki) #:select (%public-key-file %private-key-file)) #:use-module (guix zlib) + #:use-module (guix lzlib) #:use-module (web uri) #:use-module (web client) #:use-module (web response) @@ -229,6 +230,19 @@ FileSize: ~a~%" (string-append "/nar/gzip/" (basename %item)))))) (get-bytevector-n nar (bytevector-length %gzip-magic-bytes)))) +(unless (lzlib-available?) + (test-skip 1)) +(test-equal "/nar/lzip/*" + "bar" + (call-with-temporary-output-file + (lambda (temp port) + (let ((nar (http-get-port + (publish-uri + (string-append "/nar/lzip/" (basename %item)))))) + (call-with-lzip-input-port nar + (cut restore-file <> temp))) + (call-with-input-file temp read-string)))) + (unless (zlib-available?) (test-skip 1)) (test-equal "/*.narinfo with compression" @@ -251,6 +265,28 @@ FileSize: ~a~%" (_ #f))) (recutils->alist body))))) +(unless (lzlib-available?) + (test-skip 1)) +(test-equal "/*.narinfo with lzip compression" + `(("StorePath" . ,%item) + ("URL" . ,(string-append "nar/lzip/" (basename %item))) + ("Compression" . "lzip")) + (let ((thread (with-separate-output-ports + (call-with-new-thread + (lambda () + (guix-publish "--port=6790" "-Clzip")))))) + (wait-until-ready 6790) + (let* ((url (string-append "http://localhost:6790/" + (store-path-hash-part %item) ".narinfo")) + (body (http-get-port url))) + (filter (lambda (item) + (match item + (("Compression" . _) #t) + (("StorePath" . _) #t) + (("URL" . _) #t) + (_ #f))) + (recutils->alist body))))) + (unless (zlib-available?) (test-skip 1)) (test-equal "/*.narinfo for a compressed file" -- cgit v1.3 From 73ac9098b17e515ab1215c3ada2b3b0c9fb5b28c Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Fri, 24 May 2019 10:28:34 +0200 Subject: self: Add dependency on lzlib. * guix/self.scm (compiled-guix): Pass #:lzlib to 'make-config.scm'. (make-config.scm): Add #:lzlib and honor it. (specification->package): Add "lzlib". --- guix/self.scm | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/guix/self.scm b/guix/self.scm index 8cc82de64..b7d8f4ee9 100644 --- a/guix/self.scm +++ b/guix/self.scm @@ -57,6 +57,7 @@ ("guile-gcrypt" (ref '(gnu packages gnupg) 'guile-gcrypt)) ("gnutls" (ref '(gnu packages tls) 'gnutls)) ("zlib" (ref '(gnu packages compression) 'zlib)) + ("lzlib" (ref '(gnu packages compression) 'lzlib)) ("gzip" (ref '(gnu packages compression) 'gzip)) ("bzip2" (ref '(gnu packages compression) 'bzip2)) ("xz" (ref '(gnu packages compression) 'xz)) @@ -660,6 +661,7 @@ Info manual." (guile-version (effective-version)) (guile-for-build (default-guile)) (zlib (specification->package "zlib")) + (lzlib (specification->package "lzlib")) (gzip (specification->package "gzip")) (bzip2 (specification->package "bzip2")) (xz (specification->package "xz")) @@ -814,6 +816,7 @@ Info manual." #:extra-modules `(((guix config) => ,(make-config.scm #:zlib zlib + #:lzlib lzlib #:gzip gzip #:bzip2 bzip2 #:xz xz @@ -911,7 +914,7 @@ Info manual." (variables rest ...)))))) (variables %localstatedir %storedir %sysconfdir))) -(define* (make-config.scm #:key zlib gzip xz bzip2 +(define* (make-config.scm #:key zlib lzlib gzip xz bzip2 (package-name "GNU Guix") (package-version "0") (bug-report-address "bug-guix@gnu.org") @@ -933,7 +936,7 @@ Info manual." %store-database-directory %config-directory %libz - ;; TODO: %liblz + %liblz %gzip %bzip2 %xz)) @@ -980,7 +983,11 @@ Info manual." (define %libz #+(and zlib - (file-append zlib "/lib/libz")))) + (file-append zlib "/lib/libz"))) + + (define %liblz + #+(and lzlib + (file-append lzlib "/lib/liblz")))) ;; Guile 2.0 *requires* the 'define-module' to be at the ;; top-level or the 'toplevel-ref' in the resulting .go file are -- cgit v1.3 From 2e5c71b2a21ec5f89f8bc38ca01480405b9767a1 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Fri, 24 May 2019 10:29:39 +0200 Subject: gnu: guix: Add dependency on lzlib. * gnu/packages/package-management.scm (guix)[inputs]: Add LZLIB. --- gnu/packages/package-management.scm | 1 + 1 file changed, 1 insertion(+) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index a356a6dab..985fa801b 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -272,6 +272,7 @@ `(("bzip2" ,bzip2) ("gzip" ,gzip) ("zlib" ,zlib) ;for 'guix publish' + ("lzlib" ,lzlib) ;for 'guix publish' and 'guix substitute' ("sqlite" ,sqlite) ("libgcrypt" ,libgcrypt) -- cgit v1.3 From c131bea2762ea0dd9e75e9340525dc54cd938647 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Fri, 24 May 2019 15:20:46 +0200 Subject: lzlib: 'lzread!' never returns more than it was asked for. Fixes a bug whereby 'lzread!' could return more than COUNT. * guix/lzlib.scm (lzread!): Rewrite in a semi-functional style. --- guix/lzlib.scm | 39 +++++++++++++++++++-------------------- 1 file changed, 19 insertions(+), 20 deletions(-) diff --git a/guix/lzlib.scm b/guix/lzlib.scm index a484315c0..31d84971c 100644 --- a/guix/lzlib.scm +++ b/guix/lzlib.scm @@ -494,29 +494,28 @@ perhaps not yet read." ;; High level functions. -(define* (lzread! decoder file-port bv + +(define* (lzread! decoder port bv #:optional (start 0) (count (bytevector-length bv))) - "Read up to COUNT bytes from FILE-PORT into BV at offset START. Return the + "Read up to COUNT bytes from PORT into BV at offset START. Return the number of uncompressed bytes actually read; it is zero if COUNT is zero or if the end-of-stream has been reached." - ;; WARNING: Because we don't alternate between lz-reads and lz-writes, we can't - ;; process more than lz-decompress-write-size from the file-port. - (when (> count (lz-decompress-write-size decoder)) - (set! count (lz-decompress-write-size decoder))) - (let ((file-bv (get-bytevector-n file-port count))) - (unless (eof-object? file-bv) - (lz-decompress-write decoder file-bv 0 (bytevector-length file-bv)))) - (let ((read 0)) - (let loop ((rd 0)) - (if (< start (bytevector-length bv)) - (begin - (set! rd (lz-decompress-read decoder bv start (- (bytevector-length bv) start))) - (set! start (+ start rd)) - (set! read (+ read rd))) - (set! rd 0)) - (unless (= rd 0) - (loop rd))) - read)) + (define (feed-decoder! decoder) + ;; Feed DECODER with data read from PORT. + (match (get-bytevector-n port (lz-decompress-write-size decoder)) + ((? eof-object? eof) eof) + (bv (lz-decompress-write decoder bv)))) + + (let loop ((read 0) + (start start)) + (cond ((< read count) + (match (lz-decompress-read decoder bv start (- count read)) + (0 (if (eof-object? (feed-decoder! decoder)) + read + (loop read start))) + (n (loop (+ read n) (+ start n))))) + (else + read)))) (define (lzwrite! encoder source source-offset source-count target target-offset target-count) -- cgit v1.3 From 35d1354fe87003dbe19b1b97aa64db1f7d989701 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Mon, 27 May 2019 22:38:15 +0200 Subject: publish: Display the compression method and level in use. * guix/scripts/publish.scm (guix-publish): Use 'info' instead of 'format' for the initial message. When COMPRESSION is true, display the method and level in use. --- guix/scripts/publish.scm | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/guix/scripts/publish.scm b/guix/scripts/publish.scm index 11e7e985d..889dbef86 100644 --- a/guix/scripts/publish.scm +++ b/guix/scripts/publish.scm @@ -987,10 +987,15 @@ consider using the '--user' option!~%"))) (parameterize ((%public-key public-key) (%private-key private-key)) - (format #t (G_ "publishing ~a on ~a, port ~d~%") - %store-directory - (inet-ntop (sockaddr:fam address) (sockaddr:addr address)) - (sockaddr:port address)) + (info (G_ "publishing ~a on ~a, port ~d~%") + %store-directory + (inet-ntop (sockaddr:fam address) (sockaddr:addr address)) + (sockaddr:port address)) + + (when compression + (info (G_ "using '~a' compression method, level ~a~%") + (compression-type compression) (compression-level compression))) + (when repl-port (repl:spawn-server (repl:make-tcp-server-socket #:port repl-port))) -- cgit v1.3 From d8d896c5b5d2aab42b3549b1cdcc4be340775f51 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 27 May 2019 23:22:19 +0200 Subject: gnu: emacs-xr: Update to 1.12. * gnu/packages/emacs-xyz.scm (emacs-xr): Update to 1.12. --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 9199b45e4..a27719695 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -777,7 +777,7 @@ in certain cases. It also enables recursion for anonymous functions.") (define-public emacs-xr (package (name "emacs-xr") - (version "1.11") + (version "1.12") (source (origin (method url-fetch) @@ -785,7 +785,7 @@ in certain cases. It also enables recursion for anonymous functions.") "https://elpa.gnu.org/packages/xr-" version ".tar")) (sha256 (base32 - "0xwfs2mkmgf63sfp5jwmw0ybc8pa0rlxh5aqwb348ddgmclv322f")))) + "1vv87h0h8ldc1mbsn45w5z1m6jq8j2js4xz23a9ixdby06g60y3g")))) (build-system emacs-build-system) (home-page "http://elpa.gnu.org/packages/xr.html") (synopsis "Convert string regexp to rx notation") -- cgit v1.3 From 70fa77d8815bf09760b7523d2559c9f6708ff279 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Mon, 27 May 2019 23:22:34 +0200 Subject: gnu: emacs-relint: Update to 1.8. * gnu/packages/emacs-xyz.scm (emacs-relint): Update to 1.8. --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index a27719695..6f74a2fc4 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -807,7 +807,7 @@ skip set strings, which are arguments to @code{skip-chars-forward} and (define-public emacs-relint (package (name "emacs-relint") - (version "1.7") + (version "1.8") (source (origin (method url-fetch) @@ -815,7 +815,7 @@ skip set strings, which are arguments to @code{skip-chars-forward} and "https://elpa.gnu.org/packages/relint-" version ".el")) (sha256 (base32 - "0h9nc84yv5lmbaa8any6i3bqcn6xn1gy6cv6kqaywn0nnqrm17i1")))) + "1bl6m2h7131acbmr0kqfnjjpv2syiv2mxfnm61g874ynnvkmmkm3")))) (build-system emacs-build-system) (propagated-inputs `(("emacs-xr" ,emacs-xr))) (home-page "https://github.com/mattiase/relint") -- cgit v1.3 From e7f078c337c98e8bb14e9f419cbc4f632d495384 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Tue, 28 May 2019 09:33:05 +0200 Subject: gnu: guix: Update to 35d1354. * gnu/packages/package-management.scm (guix): Update to 35d1354. --- gnu/packages/package-management.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index 985fa801b..2113e4956 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -111,8 +111,8 @@ ;; Note: the 'update-guix-package.scm' script expects this definition to ;; start precisely like this. (let ((version "1.0.1") - (commit "820429517f9cc8333704a839b4346ac4b02468c4") - (revision 1)) + (commit "35d1354fe87003dbe19b1b97aa64db1f7d989701") + (revision 2)) (package (name "guix") @@ -128,7 +128,7 @@ (commit commit))) (sha256 (base32 - "1vfp7ps1k1cwn8p0gsgarlxcy982hzyvb7zqnj66jqd258a1qfgh")) + "1fd7g31fgdn7pzfxki7pkn1335ffmbklygha8d16771widqbpla5")) (file-name (string-append "guix-" version "-checkout")))) (build-system gnu-build-system) (arguments -- cgit v1.3 From 458e92215f7a6083b155b020575ae2c9e03ab7cf Mon Sep 17 00:00:00 2001 From: Pierre Neidhardt Date: Tue, 28 May 2019 14:49:29 +0200 Subject: gnu: d-feet: Fix missing input and update to 0.3.14. * gnu/packages/gnome.scm (d-feet): Update to 0.3.14. [inputs]: Add hicolor-icon-theme since d-feet won't list anything without it. --- gnu/packages/gnome.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 6a2a683f5..14e63280e 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -4444,7 +4444,7 @@ principles are simplicity and standards compliance.") (define-public d-feet (package (name "d-feet") - (version "0.3.11") + (version "0.3.14") (source (origin (method url-fetch) (uri (string-append "mirror://gnome/sources/" name "/" @@ -4452,7 +4452,7 @@ principles are simplicity and standards compliance.") name "-" version ".tar.xz")) (sha256 (base32 - "1hmrijm4d9vwzx2r8qzzsy8ccpj79l1y6cc569n9jjzqcq699p53")))) + "1m8lwiwl5jhi0x7y6x5zmd3hjplgvdjrb8a8jg74rvkygslj1p7f")))) (build-system glib-or-gtk-build-system) (arguments '(#:out-of-source? #f ; tests need to run in the source directory. @@ -4491,6 +4491,7 @@ principles are simplicity and standards compliance.") `(("gobject-introspection" ,gobject-introspection) ("gtk+" ,gtk+) ("python" ,python-wrapper) + ("hicolor-icon-theme" ,hicolor-icon-theme) ("python-pygobject" ,python-pygobject))) (home-page "https://wiki.gnome.org/Apps/DFeet") (synopsis "D-Bus debugger") -- cgit v1.3 From 205eb40e5b2895fecbf97bcb69d06b7b27c195a4 Mon Sep 17 00:00:00 2001 From: "h.nasajpour" Date: Tue, 28 May 2019 15:26:43 +0430 Subject: gnu: python-flask: Update to 1.0.3. * gnu/packages/python-web.scm (python-flask): Update to 1.0.3. Signed-off-by: Danny Milosavljevic --- gnu/packages/python-web.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index 5d37e171e..aa0af3912 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -1647,13 +1647,13 @@ minimum of WSGI.") (define-public python-flask (package (name "python-flask") - (version "1.0.2") + (version "1.0.3") (source (origin (method url-fetch) - (uri (pypi-uri "flask" version)) + (uri (pypi-uri "Flask" version)) (sha256 (base32 - "0j6f4a9rpfh25k1gp7azqhnni4mb4fgy50jammgjgddw1l3w0w92")))) + "1wxnhjlxwwjhjxmghykjhllpahv5pkdc5hln4ab6nab43s26sz5d")))) (build-system python-build-system) (arguments '(#:phases -- cgit v1.3 From 67458e209d34f4782616c46c096287297a4274df Mon Sep 17 00:00:00 2001 From: "h.nasajpour" Date: Tue, 28 May 2019 16:36:01 +0430 Subject: gnu: python-attrs: Update to 19.1.0. * gnu/packages/python-xyz.scm (python-attrs): Update to 19.1.0. Signed-off-by: Danny Milosavljevic --- gnu/packages/python-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index a58b788ca..0e479d45e 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -11474,13 +11474,13 @@ and bit flag values.") (define-public python-attrs (package (name "python-attrs") - (version "18.2.0") + (version "19.1.0") (source (origin (method url-fetch) (uri (pypi-uri "attrs" version)) (sha256 (base32 - "0s9ydh058wmmf5v391pym877x4ahxg45dw6a0w4c7s5wgpigdjqh")))) + "16g33zr5f449lqc5wgvzpknxryfzrfsxcr6kpgxwn7l5fkv71f7h")))) (build-system python-build-system) (arguments `(#:modules ((guix build utils) -- cgit v1.3 From fa866548244e3a8ad65a19c40cb0d6f2c669cc6b Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:21:27 +0200 Subject: self: Fix unquoting. This is a follow-up to commit dfc69e4b6d4bbc41a4d37b3cc6ea12adb34aaafa. * guix/self.scm (whole-package): Unquote %storedir in the daemon wrapper. --- guix/self.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/guix/self.scm b/guix/self.scm index b7d8f4ee9..69e2381a8 100644 --- a/guix/self.scm +++ b/guix/self.scm @@ -617,7 +617,7 @@ Info manual." (setenv "GUIX_CONFIGURATION_DIRECTORY" #$(string-append %sysconfdir "/guix"))) (unless (getenv "NIX_STORE_DIR") - (setenv "NIX_STORE_DIR" %storedir)) + (setenv "NIX_STORE_DIR" #$%storedir)) (apply execl #$(file-append daemon "/bin/guix-daemon") "guix-daemon" (cdr (command-line)))))) -- cgit v1.3 From 923c6ac139821490fdbf44669d1808f2d86e7217 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:53:02 +0200 Subject: gnu: r-evaluate: Update to 0.14. * gnu/packages/statistics.scm (r-evaluate): Update to 0.14. --- gnu/packages/statistics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index 06f0aa1e7..98859a75c 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -1327,13 +1327,13 @@ for template use among CRAN packages.") (define-public r-evaluate (package (name "r-evaluate") - (version "0.13") + (version "0.14") (source (origin (method url-fetch) (uri (cran-uri "evaluate" version)) (sha256 (base32 - "0igvc27rsqxcswjb9slnpi5d509rffxn1y5d82hgqvv970nl3p2q")))) + "0a2y7j534gbgixkwj9r1z76l2vssw4g1hznzbpclc076wkdqpj58")))) (build-system r-build-system) (home-page "https://github.com/hadley/evaluate") (synopsis "Parsing and evaluation tools for R") -- cgit v1.3 From 3fca3fa1bccd69b750032944e0024914529f0873 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:53:15 +0200 Subject: gnu: r-rmarkdown: Update to 1.13. * gnu/packages/statistics.scm (r-rmarkdown): Update to 1.13. [propagated-inputs]: Add r-xfun. --- gnu/packages/statistics.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index 98859a75c..af3e4882d 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -2695,14 +2695,14 @@ certain criterion, e.g., it contains a certain regular file.") (define-public r-rmarkdown (package (name "r-rmarkdown") - (version "1.12") + (version "1.13") (source (origin (method url-fetch) (uri (cran-uri "rmarkdown" version)) (sha256 (base32 - "0milpdaf4nd36kq6sci9wc5dhwswl4w9c9fychfbppgjsgfp6kfv")))) + "1vv3b8nlw8ra19492rjg3na42lwh3xr5a2jy2ia81fvvs846pywn")))) (properties `((upstream-name . "rmarkdown"))) (build-system r-build-system) (propagated-inputs @@ -2714,6 +2714,7 @@ certain criterion, e.g., it contains a certain regular file.") ("r-mime" ,r-mime) ("r-stringr" ,r-stringr) ("r-tinytex" ,r-tinytex) + ("r-xfun" ,r-xfun) ("r-yaml" ,r-yaml) ("ghc-pandoc" ,ghc-pandoc))) (home-page "http://rmarkdown.rstudio.com") -- cgit v1.3 From 1498b5a2a4b2d139910cd776b27580c00d09dfa8 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:53:28 +0200 Subject: gnu: r-zoo: Update to 1.8-6. * gnu/packages/statistics.scm (r-zoo): Update to 1.8-6. --- gnu/packages/statistics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index af3e4882d..e8f27d018 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -4315,13 +4315,13 @@ mechanism.") (define-public r-zoo (package (name "r-zoo") - (version "1.8-5") + (version "1.8-6") (source (origin (method url-fetch) (uri (cran-uri "zoo" version)) (sha256 (base32 - "09p8gmd5ifz80ahnhiianarsr5xx3nz76jzp90d7v3fjffcrcww7")))) + "1k1pmzr9nfwbxq1xf0jzn3nawv4sgnkxkgzxnm1i887jcbrs85r2")))) (build-system r-build-system) (propagated-inputs `(("r-lattice" ,r-lattice))) -- cgit v1.3 From f95690ceae3909a8d56abf1aa18da49ed2019fa6 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:53:33 +0200 Subject: gnu: r-prabclus: Update to 2.2-7.1. * gnu/packages/statistics.scm (r-prabclus): Update to 2.2-7.1. --- gnu/packages/statistics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index e8f27d018..8c8f84ddf 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -4772,14 +4772,14 @@ and resampling-based inference.") (define-public r-prabclus (package (name "r-prabclus") - (version "2.2-7") + (version "2.2-7.1") (source (origin (method url-fetch) (uri (cran-uri "prabclus" version)) (sha256 (base32 - "0h2nml8ri27mhfs2p6ngb6kfd6lyq30sc6813yybpskkrb6gs1pb")))) + "0x998nidd7abq5nqynyr8q79z056qbli23mvad6f09fjn2xz6nrc")))) (build-system r-build-system) (propagated-inputs `(("r-mass" ,r-mass) -- cgit v1.3 From 341643c6e1dd7b85429d4b235c406e2a501c948c Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:53:43 +0200 Subject: gnu: r-fpc: Update to 2.2-1. * gnu/packages/statistics.scm (r-fpc): Update to 2.2-1. [propagated-inputs]: Remove r-trimcluster. --- gnu/packages/statistics.scm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index 8c8f84ddf..6dffa1f41 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -4968,14 +4968,14 @@ of the points.") (define-public r-fpc (package (name "r-fpc") - (version "2.1-11.2") + (version "2.2-1") (source (origin (method url-fetch) (uri (cran-uri "fpc" version)) (sha256 (base32 - "0wjjp9xn283acfg6cm1wa6fsi7pf0z97227hrnlpmprks3mbj8kr")))) + "183awn9fbigsy3rwmg5l39zpfg2zpbb94hkx7k99v2dir8dpdy85")))) (build-system r-build-system) (propagated-inputs `(("r-class" ,r-class) @@ -4987,8 +4987,7 @@ of the points.") ("r-mclust" ,r-mclust) ("r-mvtnorm" ,r-mvtnorm) ("r-prabclus" ,r-prabclus) - ("r-robustbase" ,r-robustbase) - ("r-trimcluster" ,r-trimcluster))) + ("r-robustbase" ,r-robustbase))) (home-page "https://cran.r-project.org/web/packages/fpc") (synopsis "Flexible procedures for clustering") (description -- cgit v1.3 From 14532452b8863049e8f43f0a2dc51551738a5c71 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:54:00 +0200 Subject: gnu: r-car: Update to 3.0-3. * gnu/packages/statistics.scm (r-car): Update to 3.0-3. --- gnu/packages/statistics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index 6dffa1f41..6263f0a1b 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -5270,14 +5270,14 @@ Companion to Applied Regression, Third Edition, Sage.") (define-public r-car (package (name "r-car") - (version "3.0-2") + (version "3.0-3") (source (origin (method url-fetch) (uri (cran-uri "car" version)) (sha256 (base32 - "0l3wyc9ia0ypcbap2p39slazfpbl84mjzydqvpsywrzdiyxajnfz")))) + "0vy3g3bjljd2al8xb9qr45f98is7yppc9jilqn7b6zvf5yqpr07s")))) (build-system r-build-system) (propagated-inputs `(("r-abind" ,r-abind) -- cgit v1.3 From 6edf0fb3dbd5592b05a706b737577ada9398e68b Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:54:07 +0200 Subject: gnu: r-lpsolve: Update to 5.6.13.1. * gnu/packages/cran.scm (r-lpsolve): Update to 5.6.13.1. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index c5fc3be4a..da37c26be 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -2068,14 +2068,14 @@ topics for ecologists (ISBN 978-0-691-12522-0).") (define-public r-lpsolve (package (name "r-lpsolve") - (version "5.6.13") + (version "5.6.13.1") (source (origin (method url-fetch) (uri (cran-uri "lpSolve" version)) (sha256 (base32 - "13a9ry8xf5j1f2j6imqrxdgxqz3nqp9sj9b4ivyx9sid459irm6m")))) + "1f10ywlaaldgjj84vs108ly0nsbkrdgbn5d6qj7nk93j1x1xrn3a")))) (properties `((upstream-name . "lpSolve"))) (build-system r-build-system) (home-page "https://cran.r-project.org/web/packages/lpSolve") -- cgit v1.3 From beb82eb9d08046fd4e59d8dde809e55bb5f5c8fe Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:54:12 +0200 Subject: gnu: r-ksamples: Update to 1.2-9. * gnu/packages/cran.scm (r-ksamples): Update to 1.2-9. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index da37c26be..c48cd0f8b 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -2206,14 +2206,14 @@ George Marsaglia are included.") (define-public r-ksamples (package (name "r-ksamples") - (version "1.2-8") + (version "1.2-9") (source (origin (method url-fetch) (uri (cran-uri "kSamples" version)) (sha256 (base32 - "15d5q5vpp4wx5rk5kjxjdxpwc8mkq5sbdz8gi07iscrvhzb5rzfr")))) + "1zs22p68d6320kcylisnk0b5wmpapxkyz15py09czxzw7npw8gms")))) (properties `((upstream-name . "kSamples"))) (build-system r-build-system) (propagated-inputs -- cgit v1.3 From 6d3cfb88eadf8ce32c32c6e8d239c83adc4b3c2e Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:54:18 +0200 Subject: gnu: r-jomo: Update to 2.6-8. * gnu/packages/cran.scm (r-jomo): Update to 2.6-8. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index c48cd0f8b..c2e5fd853 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -2894,14 +2894,14 @@ Laplace approximation and adaptive Gauss-Hermite quadrature.") (define-public r-jomo (package (name "r-jomo") - (version "2.6-7") + (version "2.6-8") (source (origin (method url-fetch) (uri (cran-uri "jomo" version)) (sha256 (base32 - "0lyvi32aikkvwdj0y2hc13kmmi0cw1icg8z9lcw10l8326sxm0vf")))) + "097zfdcqc3a45ay8xxbraqh8xsfyivskkdmc2b4ca4n979lx8vyb")))) (build-system r-build-system) (propagated-inputs `(("r-lme4" ,r-lme4) -- cgit v1.3 From 130314d8fa505829651aa612b4057917bbe42612 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:54:26 +0200 Subject: gnu: r-tsp: Update to 1.1-7. * gnu/packages/cran.scm (r-tsp): Update to 1.1-7. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index c2e5fd853..07ff1e3b3 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -3496,14 +3496,14 @@ timeout. It can also poll several processes at once.") (define-public r-tsp (package (name "r-tsp") - (version "1.1-6") + (version "1.1-7") (source (origin (method url-fetch) (uri (cran-uri "TSP" version)) (sha256 (base32 - "1ym97xl2icjpfkrici0wig29w06bb704hp51v7h5liygjlwpkhlc")))) + "0rxxhvqi55869dg2p82hzg5kvgcqf9h60cjcg00k3pv9aw4x07kb")))) (properties `((upstream-name . "TSP"))) (build-system r-build-system) (propagated-inputs `(("r-foreach" ,r-foreach))) -- cgit v1.3 From d328379d6297aaca75db574150207129ff4b6baf Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:54:32 +0200 Subject: gnu: r-pillar: Update to 1.4.1. * gnu/packages/cran.scm (r-pillar): Update to 1.4.1. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 07ff1e3b3..853d8e13d 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -3715,14 +3715,14 @@ to variables on the left-hand side of the assignment.") (define-public r-pillar (package (name "r-pillar") - (version "1.4.0") + (version "1.4.1") (source (origin (method url-fetch) (uri (cran-uri "pillar" version)) (sha256 (base32 - "1c8rwwh677vc92f4k6qj4mxl3acran1iqdv5dj6r1dyv7fvmcvfx")))) + "0mcc09caxm69pghhz6b8vawj9ni63aijv5qba53pg4ph7rxclwgm")))) (build-system r-build-system) (propagated-inputs `(("r-cli" ,r-cli) -- cgit v1.3 From 9dd351233ba84e4a118b53ca163dc460d1367343 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:54:36 +0200 Subject: gnu: r-openxlsx: Update to 4.1.0.1. * gnu/packages/cran.scm (r-openxlsx): Update to 4.1.0.1. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 853d8e13d..fa673ce57 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -4997,14 +4997,14 @@ additional external tools on any platform.") (define-public r-openxlsx (package (name "r-openxlsx") - (version "4.1.0") + (version "4.1.0.1") (source (origin (method url-fetch) (uri (cran-uri "openxlsx" version)) (sha256 (base32 - "1n7z22pm78xa77fvn77kdn68az6xzxk36y11sqf0w6h6adri4yxb")))) + "1lflygpi1z4rlb1c6g6wsmi334maiiy7jhpg6ph4sw8lpvg12w4b")))) (build-system r-build-system) (propagated-inputs `(("r-rcpp" ,r-rcpp) -- cgit v1.3 From 794c9e7d96084fc50be9e7098b6248e37b02f949 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:54:40 +0200 Subject: gnu: r-snakecase: Update to 0.11.0. * gnu/packages/cran.scm (r-snakecase): Update to 0.11.0. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index fa673ce57..627e29b45 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -5861,14 +5861,14 @@ intervals.") (define-public r-snakecase (package (name "r-snakecase") - (version "0.10.0") + (version "0.11.0") (source (origin (method url-fetch) (uri (cran-uri "snakecase" version)) (sha256 (base32 - "0325zkpyqa15lx7biq2cbimr2773332bp4jvcvnl00bjx41ia2fm")))) + "1ky1x2cp5rd0ffd9m1fji9sq4z4jsrpxzg30brw8bb4ihfjj114r")))) (build-system r-build-system) (propagated-inputs `(("r-stringi" ,r-stringi) -- cgit v1.3 From 27abdb11ae4dd4b92641a763bfc3bbc2062141c1 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:54:46 +0200 Subject: gnu: r-refgenome: Update to 1.7.7. * gnu/packages/cran.scm (r-refgenome): Update to 1.7.7. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 627e29b45..0680c0d96 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -6292,14 +6292,14 @@ Group (Non-)Overlap considerations.") (define-public r-refgenome (package (name "r-refgenome") - (version "1.7.3.1") + (version "1.7.7") (source (origin (method url-fetch) (uri (cran-uri "refGenome" version)) (sha256 (base32 - "1s4lxv5pqk6d0f0a9iclgv88yl346fwvzgraxh0gwpbym1yhh787")))) + "1za89bn3am1zgvm641qi1ab6kaqpll4rb9p9f1sjwvcgqq6065g5")))) (properties `((upstream-name . "refGenome"))) (build-system r-build-system) (propagated-inputs -- cgit v1.3 From 1d7bde781f58001155739a49c387c8bad2dca77e Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:54:53 +0200 Subject: gnu: r-bayesplot: Update to 1.7.0. * gnu/packages/cran.scm (r-bayesplot): Update to 1.7.0. [propagated-inputs]: Add r-glue, r-tibble, and r-tidyselect. --- gnu/packages/cran.scm | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 0680c0d96..8fb659cb6 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -7788,14 +7788,14 @@ correlation, censored, ordered and multivariate problems.") (define-public r-bayesplot (package (name "r-bayesplot") - (version "1.6.0") + (version "1.7.0") (source (origin (method url-fetch) (uri (cran-uri "bayesplot" version)) (sha256 (base32 - "0in9cq2ybpa7njrwqx4l6nc8i01cjswsvzwlyiw465pi74aapr57")))) + "0h23sbfny2hcipvvfhq5aiwdh1vanizn7f8lpb9kffypxhcd7v7w")))) (build-system r-build-system) (inputs `(("pandoc" ,ghc-pandoc) @@ -7804,8 +7804,11 @@ correlation, censored, ordered and multivariate problems.") `(("r-dplyr" ,r-dplyr) ("r-ggplot2" ,r-ggplot2) ("r-ggridges" ,r-ggridges) + ("r-glue" ,r-glue) ("r-reshape2" ,r-reshape2) - ("r-rlang" ,r-rlang))) + ("r-rlang" ,r-rlang) + ("r-tibble" ,r-tibble) + ("r-tidyselect" ,r-tidyselect))) (home-page "http://mc-stan.org/bayesplot") (synopsis "Plotting for Bayesian models") (description -- cgit v1.3 From fa10f0d330476fb6a5a4f0940e922af5fb759598 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:55:14 +0200 Subject: gnu: r-ks: Update to 1.11.5. * gnu/packages/cran.scm (r-ks): Update to 1.11.5. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 8fb659cb6..b44e5ba56 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -8802,14 +8802,14 @@ isosurfaces.") (define-public r-ks (package (name "r-ks") - (version "1.11.4") + (version "1.11.5") (source (origin (method url-fetch) (uri (cran-uri "ks" version)) (sha256 (base32 - "0d5i8458s8ri9pcx2jm003z1ajk7ha3pmw1sr6lgn6a8d7wgmvqb")))) + "06ymx244yknmpl6935l4pafqbm4gcbpnhqg7rinql6rrfr9mcrag")))) (build-system r-build-system) (propagated-inputs `(("r-fnn" ,r-fnn) -- cgit v1.3 From 10dbc3fc54fdd1c380e4aa74243c2768a065442d Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:55:21 +0200 Subject: gnu: r-cmprsk: Update to 2.2-8. * gnu/packages/cran.scm (r-cmprsk): Update to 2.2-8. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index b44e5ba56..05776eb6f 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -10729,14 +10729,14 @@ But it can also be used to do data analysis for small scale data sets.") (define-public r-cmprsk (package (name "r-cmprsk") - (version "2.2-7") + (version "2.2-8") (source (origin (method url-fetch) (uri (cran-uri "cmprsk" version)) (sha256 (base32 - "1imr3wpnj4g57n2x4ryahl4lk8lvq9y2r7319zv3k82mznha8bcm")))) + "1nacbzx950ygaqgnj0949skhwpzar5i3xlscd44jsimk2gsppx6z")))) (build-system r-build-system) (propagated-inputs `(("r-survival" ,r-survival))) -- cgit v1.3 From 9a749cad1916bfdd950b59c21a0a5afa1795ef4e Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:55:27 +0200 Subject: gnu: r-etm: Update to 1.0.5. * gnu/packages/cran.scm (r-etm): Update to 1.0.5. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 05776eb6f..a6e3241a6 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -10756,14 +10756,14 @@ JASA, 94:496-509.") (define-public r-etm (package (name "r-etm") - (version "1.0.4") + (version "1.0.5") (source (origin (method url-fetch) (uri (cran-uri "etm" version)) (sha256 (base32 - "0ws103b3pmli0z4xbyfxkly2wnnnxnnwc0r66qjjqjrlvm7pffl1")))) + "1yivbq8y0ijcl1m4nir4q9hp4pi6iphwxgjprygsdf7vp98wq677")))) (build-system r-build-system) (propagated-inputs `(("r-data-table" ,r-data-table) -- cgit v1.3 From 41059f63df133c03017ae1db5ef8c42683df90ca Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:55:33 +0200 Subject: gnu: r-epi: Update to 2.37. * gnu/packages/cran.scm (r-epi): Update to 2.37. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index a6e3241a6..d363f1fdd 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -10782,14 +10782,14 @@ model with finite state space using the Aalen-Johansen estimator.") (define-public r-epi (package (name "r-epi") - (version "2.35") + (version "2.37") (source (origin (method url-fetch) (uri (cran-uri "Epi" version)) (sha256 (base32 - "1z3959761ryv54y6vsrxxvhrwzz50xrxn55pqh5y7lrxh91zdsvl")))) + "1lanr9x0c6w22406p56j7cwk6wck8njq6pscb4gzc613d68zj1lk")))) (properties `((upstream-name . "Epi"))) (build-system r-build-system) (propagated-inputs -- cgit v1.3 From 20656a02024b99f087b6e6d4d36e78b171d47a31 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:55:38 +0200 Subject: gnu: r-upsetr: Update to 1.4.0. * gnu/packages/cran.scm (r-upsetr): Update to 1.4.0. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index d363f1fdd..a5f8ee2c0 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -11160,14 +11160,14 @@ algorithms) can be computed and partitioned matrices can be plotted.") (define-public r-upsetr (package (name "r-upsetr") - (version "1.3.3") + (version "1.4.0") (source (origin (method url-fetch) (uri (cran-uri "UpSetR" version)) (sha256 (base32 - "08vj7l92b8fpqyqwxshll2mhk3yhgyr74axvr2lf29z78bapymhz")))) + "007i0njnjjy7vbrxabwav7a1kk2n0hn2mkvqsdzzfk10ckp5y7im")))) (properties `((upstream-name . "UpSetR"))) (build-system r-build-system) (propagated-inputs -- cgit v1.3 From 650e8defa0341315ed91f6141e226e815f103289 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:55:44 +0200 Subject: gnu: r-bookdown: Update to 0.11. * gnu/packages/cran.scm (r-bookdown): Update to 0.11. [propagated-inputs]: Add ghc-pandoc; remove r-yaml. --- gnu/packages/cran.scm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index a5f8ee2c0..627415e5d 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -12900,21 +12900,21 @@ SELECT or UPDATE queries to an end-point.") (define-public r-bookdown (package (name "r-bookdown") - (version "0.10") + (version "0.11") (source (origin (method url-fetch) (uri (cran-uri "bookdown" version)) (sha256 (base32 - "0xk57p9iyj7rqrwb89q3pm8p29ca615fj1h9blf5yb3zhga4bjk3")))) + "0w4fkv5fqiaqgkx44p0s161imf29zir9742126xkz1pl1j25jn1r")))) (build-system r-build-system) (propagated-inputs `(("r-htmltools" ,r-htmltools) ("r-knitr" ,r-knitr) ("r-rmarkdown" ,r-rmarkdown) ("r-tinytex" ,r-tinytex) - ("r-yaml" ,r-yaml) - ("r-xfun" ,r-xfun))) + ("r-xfun" ,r-xfun) + ("pandoc" ,ghc-pandoc))) (home-page "https://github.com/rstudio/bookdown") (synopsis "Authoring books and technical documents with R markdown") (description "This package provides output formats and utilities for -- cgit v1.3 From 7a8577717fa83ffa1115a7c019c7e86d1c5ff21c Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:56:04 +0200 Subject: gnu: r-wgcna: Update to 1.68. * gnu/packages/cran.scm (r-wgcna): Update to 1.68. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 627415e5d..2fb923f00 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -12946,14 +12946,14 @@ that accept short and long options.") (define-public r-wgcna (package (name "r-wgcna") - (version "1.67") + (version "1.68") (source (origin (method url-fetch) (uri (cran-uri "WGCNA" version)) (sha256 (base32 - "09387w85lxvwr8ax2i2h602b4dgfv4wbvsl9aj1q0b1vfs4rkk69")))) + "1s7gy5vd7x67hpgli8r7ba2z99w3psiyv5hqmrh94zw141dg210a")))) (properties `((upstream-name . "WGCNA"))) (build-system r-build-system) (propagated-inputs -- cgit v1.3 From 0fe52daa59ab16f71d64f78711538f2e640aef7f Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:56:08 +0200 Subject: gnu: r-ggfortify: Update to 0.4.7. * gnu/packages/cran.scm (r-ggfortify): Update to 0.4.7. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 2fb923f00..35582bffb 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -14403,14 +14403,14 @@ includes data sets from oceanography.") (define-public r-ggfortify (package (name "r-ggfortify") - (version "0.4.6") + (version "0.4.7") (source (origin (method url-fetch) (uri (cran-uri "ggfortify" version)) (sha256 (base32 - "1clyha9f9ygma64xbgi78lxsp1203f2ashqhhdpm71nr6w91bm88")))) + "1wk9j0xg5hj9i1vf62qjiphv8cbsgq7y6baay3pfl3wyb2dwgci0")))) (build-system r-build-system) (propagated-inputs `(("r-dplyr" ,r-dplyr) -- cgit v1.3 From f43ec9e96a560d06de980566da0761f8277c173c Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:56:15 +0200 Subject: gnu: r-geosphere: Update to 1.5-10. * gnu/packages/cran.scm (r-geosphere): Update to 1.5-10. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 35582bffb..398cdd18a 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -985,14 +985,14 @@ coordinates.") (define-public r-geosphere (package (name "r-geosphere") - (version "1.5-7") + (version "1.5-10") (source (origin (method url-fetch) (uri (cran-uri "geosphere" version)) (sha256 (base32 - "186qdm5niq7v3d4w4rngx71znsgi44hnam7698bsx9ar5mg5b6wx")))) + "15xlgsmn0vwky1l13n6acdz6jn2b2na3gf6x367y3qh1f5w4zkan")))) (build-system r-build-system) (propagated-inputs `(("r-sp" ,r-sp))) (home-page "https://cran.r-project.org/web/packages/geosphere") -- cgit v1.3 From 85d0bd53403fae0c893339a784ac26e945f28656 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:56:27 +0200 Subject: gnu: r-chippeakanno: Update to 3.18.1. * gnu/packages/bioconductor.scm (r-chippeakanno): Update to 3.18.1. --- gnu/packages/bioconductor.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioconductor.scm b/gnu/packages/bioconductor.scm index 3810749f8..2febfcd9a 100644 --- a/gnu/packages/bioconductor.scm +++ b/gnu/packages/bioconductor.scm @@ -1153,14 +1153,14 @@ determining dependencies between variables, code improvement suggestions.") (define-public r-chippeakanno (package (name "r-chippeakanno") - (version "3.18.0") + (version "3.18.1") (source (origin (method url-fetch) (uri (bioconductor-uri "ChIPpeakAnno" version)) (sha256 (base32 - "089v16mm5m0rlyyyd0d6rz8gwb852zf3bcdrrw70wanlfjn258q7")))) + "1mwi5s600c3jxy8f1azfrndc3g06qvhbmrp9wqac9nwjbfx1kfji")))) (properties `((upstream-name . "ChIPpeakAnno"))) (build-system r-build-system) (propagated-inputs -- cgit v1.3 From 13b49976b79858e99efaf65281fd3d9e3304022e Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:56:31 +0200 Subject: gnu: r-icobra: Update to 1.12.1. * gnu/packages/bioconductor.scm (r-icobra): Update to 1.12.1. --- gnu/packages/bioconductor.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioconductor.scm b/gnu/packages/bioconductor.scm index 2febfcd9a..b13744ead 100644 --- a/gnu/packages/bioconductor.scm +++ b/gnu/packages/bioconductor.scm @@ -2086,14 +2086,14 @@ independent of the p-value under the null hypothesis.") (define-public r-icobra (package (name "r-icobra") - (version "1.12.0") + (version "1.12.1") (source (origin (method url-fetch) (uri (bioconductor-uri "iCOBRA" version)) (sha256 (base32 - "1w9frnczgypzc2czbwrvlizqcqhbp6cdpyws7vkmnn9k0ggzxvfc")))) + "1wj0vqyb6h4rddmn4va3182yap9bv4m1r1jlzyjfyrqxhl2sqb1q")))) (properties `((upstream-name . "iCOBRA"))) (build-system r-build-system) (propagated-inputs -- cgit v1.3 From e4519ee73dfc08e72977d0788807d6150bff66c6 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:56:36 +0200 Subject: gnu: r-atacseqqc: Update to 1.8.1. * gnu/packages/bioconductor.scm (r-atacseqqc): Update to 1.8.1. --- gnu/packages/bioconductor.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioconductor.scm b/gnu/packages/bioconductor.scm index b13744ead..e60f8cac0 100644 --- a/gnu/packages/bioconductor.scm +++ b/gnu/packages/bioconductor.scm @@ -3408,14 +3408,14 @@ position-specific scores within R and Bioconductor.") (define-public r-atacseqqc (package (name "r-atacseqqc") - (version "1.8.0") + (version "1.8.1") (source (origin (method url-fetch) (uri (bioconductor-uri "ATACseqQC" version)) (sha256 (base32 - "03f130vcd6hd3fv2pg60id0ddd6qkwsyx73gm907xaayf42ar2pj")))) + "0h5j3724hnd86w22vy3whqx6gkf0nf2dxd2clgzdvjzblbcd5s69")))) (properties `((upstream-name . "ATACseqQC"))) (build-system r-build-system) (propagated-inputs -- cgit v1.3 From 531940d388b08318edbf243e3e5008288b1eb60e Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 28 May 2019 23:56:59 +0200 Subject: import: cran: Ignore invalid packages from the system requirements. * guix/import/cran.scm (description->package): Filter invalid packages from the list of system requirements. --- guix/import/cran.scm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/guix/import/cran.scm b/guix/import/cran.scm index 4763fccd3..324009444 100644 --- a/guix/import/cran.scm +++ b/guix/import/cran.scm @@ -313,7 +313,9 @@ from the alist META, which was derived from the R package's DESCRIPTION file." (tarball (download source-url)) (sysdepends (append (if (needs-zlib? tarball) '("zlib") '()) - (map string-downcase (listify meta "SystemRequirements")))) + (filter (lambda (name) + (not (member name invalid-packages))) + (map string-downcase (listify meta "SystemRequirements"))))) (propagate (filter (lambda (name) (not (member name (append default-r-packages invalid-packages)))) -- cgit v1.3 From 4929a30f690b05ac2d76433514f08ec0c088cbdd Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 29 May 2019 00:02:10 +0200 Subject: gnu: r-variantannotation: Update to 1.30.1. * gnu/packages/bioinformatics.scm (r-variantannotation): Update to 1.30.1. --- gnu/packages/bioinformatics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index 352b7ab72..c0db2177f 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -7480,13 +7480,13 @@ CAGE.") (define-public r-variantannotation (package (name "r-variantannotation") - (version "1.30.0") + (version "1.30.1") (source (origin (method url-fetch) (uri (bioconductor-uri "VariantAnnotation" version)) (sha256 (base32 - "1sd01yv1hnwc16412ilncrrph4gxsr9ds0nqg1czl69fqaixjn1i")))) + "144x3d3b9a3q5jy4aqrk1nf2yavwjhwlf71s7qyr4x3ms3wmvf8i")))) (properties `((upstream-name . "VariantAnnotation"))) (inputs -- cgit v1.3 From 4eea449aaa231e059459cb9e71bcf950766a0d9d Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 29 May 2019 00:02:17 +0200 Subject: gnu: r-edger: Update to 3.26.4. * gnu/packages/bioinformatics.scm (r-edger): Update to 3.26.4. --- gnu/packages/bioinformatics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index c0db2177f..291894922 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -7452,13 +7452,13 @@ names in their natural, rather than lexicographic, order.") (define-public r-edger (package (name "r-edger") - (version "3.26.3") + (version "3.26.4") (source (origin (method url-fetch) (uri (bioconductor-uri "edgeR" version)) (sha256 (base32 - "12889lwcray2cw0skzy1xp1y3siiz6n5cwx8ni86m7r671p6zmb2")))) + "013glavk6a1wpyq3q35k343bdp6rf27w30q59i4kf47rp3i37g15")))) (properties `((upstream-name . "edgeR"))) (build-system r-build-system) (propagated-inputs -- cgit v1.3 From 24f46e6e9ebf7c6a3b56126d31d2f79ca4c9779e Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 29 May 2019 00:02:25 +0200 Subject: gnu: r-genomicfeatures: Update to 1.36.1. * gnu/packages/bioinformatics.scm (r-genomicfeatures): Update to 1.36.1. --- gnu/packages/bioinformatics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index 291894922..520b78c0b 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -7924,13 +7924,13 @@ as well as query and modify the browser state, such as the current viewport.") (define-public r-genomicfeatures (package (name "r-genomicfeatures") - (version "1.36.0") + (version "1.36.1") (source (origin (method url-fetch) (uri (bioconductor-uri "GenomicFeatures" version)) (sha256 (base32 - "17jy7lrpdaafd8g5v6j70xsypi0lqljdqmhv9f2r1xpyg3yjd84p")))) + "02psq3jfgghdydwbydb1j792lvfg44l5npb44mx8d54ckr8658dd")))) (properties `((upstream-name . "GenomicFeatures"))) (build-system r-build-system) -- cgit v1.3 From 102cf9a1ca394d1ab89e27476feb764e9d62eb70 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 29 May 2019 00:02:31 +0200 Subject: gnu: r-sva: Update to 3.32.1. * gnu/packages/bioinformatics.scm (r-sva): Update to 3.32.1. --- gnu/packages/bioinformatics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index 520b78c0b..b5c9c1551 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -9040,14 +9040,14 @@ TAB-Seq.") (define-public r-sva (package (name "r-sva") - (version "3.32.0") + (version "3.32.1") (source (origin (method url-fetch) (uri (bioconductor-uri "sva" version)) (sha256 (base32 - "100jwi43y4xdqb5lldx1ld58jg9icdjgz6c7ylx95gspipnkbgjp")))) + "0jj6klfha5v5qmx2sjblf1an6s2zqd7mmgsp7sfmh4k2jpqi3jm9")))) (build-system r-build-system) (propagated-inputs `(("r-genefilter" ,r-genefilter) -- cgit v1.3 From 55cd48508e93e0fba170d872465ff1f578858283 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 29 May 2019 00:02:37 +0200 Subject: gnu: r-scater: Update to 1.12.2. * gnu/packages/bioinformatics.scm (r-scater): Update to 1.12.2. --- gnu/packages/bioinformatics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index b5c9c1551..0c8f2d9ea 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -10568,13 +10568,13 @@ libraries.") (define-public r-scater (package (name "r-scater") - (version "1.12.1") + (version "1.12.2") (source (origin (method url-fetch) (uri (bioconductor-uri "scater" version)) (sha256 (base32 - "0k4jc0xc2n49saylcjrg7laxq4mchg4nv06nrbc6cp4vzpf33jh5")))) + "16a17161xlhh6qpna9qxph3anlc7ydgyrczmy4alfiw8si7pzmxa")))) (build-system r-build-system) (propagated-inputs `(("r-beachmat" ,r-beachmat) -- cgit v1.3 From d37ba98409f2a5d7f5e7bdfe79d6b0466845474a Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 29 May 2019 00:02:42 +0200 Subject: gnu: r-scran: Update to 1.12.1. * gnu/packages/bioinformatics.scm (r-scran): Update to 1.12.1. --- gnu/packages/bioinformatics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index 0c8f2d9ea..8f31d4e22 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -10603,14 +10603,14 @@ quality control.") (define-public r-scran (package (name "r-scran") - (version "1.12.0") + (version "1.12.1") (source (origin (method url-fetch) (uri (bioconductor-uri "scran" version)) (sha256 (base32 - "19cyjjzgmhswni6js4bhbj5djp976sl9n648kk7viazgkspql884")))) + "17mknpkvs7mgnlbf2hv9k7rwbx2vlg60yrwfyb8nn3nxsb6vm7yn")))) (build-system r-build-system) (propagated-inputs `(("r-beachmat" ,r-beachmat) -- cgit v1.3 From 4b92dac20fbca636201a38916d65bf825d69cd7f Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 29 May 2019 10:56:28 +0200 Subject: gnu: awscli: Add missing input. Fixes . * gnu/packages/python-web.scm (awscli)[arguments]: Add build phase "fix-reference-to-groff". [inputs]: Add groff. --- gnu/packages/python-web.scm | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index aa0af3912..042484c6a 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -57,6 +57,7 @@ #:use-module (gnu packages curl) #:use-module (gnu packages databases) #:use-module (gnu packages django) + #:use-module (gnu packages groff) #:use-module (gnu packages libffi) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) @@ -1541,6 +1542,19 @@ supports url redirection and retries, and also gzip and deflate decoding.") (base32 "0sispclx263lybbk19zp1n9yhg8xxx4jddypzgi24vpjaqnsbwlc")))) (build-system python-build-system) + (arguments + ;; FIXME: The 'pypi' release does not contain tests. + '(#:tests? #f + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'fix-reference-to-groff + (lambda _ + (substitute* "awscli/help.py" + (("if not self._exists_on_path\\('groff'\\):") "") + (("raise ExecutableNotFoundError\\('groff'\\)") "") + (("cmdline = \\['groff'") + (string-append "cmdline = ['" (which "groff") "'"))) + #t))))) (propagated-inputs `(("python-colorama" ,python-colorama) ("python-botocore" ,python-botocore) @@ -1548,9 +1562,8 @@ supports url redirection and retries, and also gzip and deflate decoding.") ("python-docutils" ,python-docutils) ("python-pyyaml" ,python-pyyaml) ("python-rsa" ,python-rsa))) - (arguments - ;; FIXME: The 'pypi' release does not contain tests. - '(#:tests? #f)) + (inputs + `(("groff" ,groff))) (home-page "https://aws.amazon.com/cli/") (synopsis "Command line client for AWS") (description "AWS CLI provides a unified command line interface to the -- cgit v1.3 From 694cb8dc62f59fb67799ad4908a6b12cf7cb49a3 Mon Sep 17 00:00:00 2001 From: Mathieu Othacehe Date: Wed, 29 May 2019 09:44:44 +0200 Subject: installer: Fix wifi menu crash with hidden SSIDs. This fixes https://issues.guix.gnu.org/issue/35622. * gnu/installer/connman.scm (): Mention that name may be false. * gnu/installer/newt/wifi.scm (wifi-services): Filter out wifi services without name. Co-authored by: Pierre Neidhardt --- gnu/installer/connman.scm | 2 +- gnu/installer/newt/wifi.scm | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/gnu/installer/connman.scm b/gnu/installer/connman.scm index ef8cca395..7f47b9af7 100644 --- a/gnu/installer/connman.scm +++ b/gnu/installer/connman.scm @@ -108,7 +108,7 @@ (define-record-type* service make-service service? - (name service-name) ; string + (name service-name) ; string or #f (type service-type) ; string (path service-path) ; string (strength service-strength) ; integer diff --git a/gnu/installer/newt/wifi.scm b/gnu/installer/newt/wifi.scm index da2f0b56d..1cb2ef2df 100644 --- a/gnu/installer/newt/wifi.scm +++ b/gnu/installer/newt/wifi.scm @@ -144,6 +144,7 @@ of records present in LISTBOX." (let ((services (connman-services))) (filter (lambda (service) (and (string=? (service-type service) "wifi") + (service-name service) (not (string-null? (service-name service))))) services))) -- cgit v1.3 From 4f963be052d8753d1c3d882dd7dc4392285cc96a Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 14 May 2019 22:11:08 +0200 Subject: gnu: Add childsplay. * gnu/packages/education.scm (childsplay): New variable. --- gnu/packages/education.scm | 107 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 107 insertions(+) diff --git a/gnu/packages/education.scm b/gnu/packages/education.scm index 869789552..98aaad7e6 100644 --- a/gnu/packages/education.scm +++ b/gnu/packages/education.scm @@ -27,7 +27,10 @@ #:use-module (gnu packages base) #:use-module (gnu packages bash) #:use-module (gnu packages compression) + #:use-module (gnu packages databases) + #:use-module (gnu packages fonts) #:use-module (gnu packages freedesktop) + #:use-module (gnu packages game-development) #:use-module (gnu packages gettext) #:use-module (gnu packages glib) #:use-module (gnu packages gnome) @@ -373,3 +376,107 @@ keyboard is also available if the child does not have any other specialized device.") (home-page "https://bipede.fr/contrib/") (license license:gpl3))) + +(define-public childsplay + (package + (name "childsplay") + (version "3.4") + (source (origin + (method url-fetch) + (uri (string-append + "mirror://sourceforge/schoolsplay/" + "childsplay-" version ".tgz")) + (sha256 + (base32 + "0z7yp2swjnbz51vn2zyfnjn40jq38l5mbh15yafmx1z3vn2z1m77")))) + (build-system python-build-system) + (arguments + `(#:python ,python-2 + #:tests? #f + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'unbundle-dejavu-font + (lambda* (#:key inputs #:allow-other-keys) + (let* ((dejavu-dir + (string-append (assoc-ref inputs "font-dejavu") + "/share/fonts/truetype")) + (dejavu-font + (string-append dejavu-dir + "/DejaVuSansCondensed-Bold.ttf"))) + (substitute* "SPConstants.py" + (("^(TTF(BOLD)? = ).*" _ prefix) + (string-append prefix "'" dejavu-font "'\n"))) + (for-each (lambda (f) (delete-file f)) + (find-files "lib/SPData" "DejaVu")) + #t))) + (delete 'build) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (pixmaps (string-append out "/share/pixmaps")) + (share (string-append out "/share/childsplay")) + (doc (string-append out "/share/doc/" ,name "-",version))) + ;; Install icon. + (install-file "lib/SPData/themes/childsplay/logo_cp.svg" pixmaps) + ;; Install data. + (mkdir-p share) + (for-each (lambda (f) + (copy-recursively f (string-append share "/" f))) + '("alphabet-sounds" "lib" "locale" "SPWidgets")) + (for-each (lambda (f) (install-file f share)) + (find-files "." "\\.(py|dev|db)$")) + ;; Install documentation. + (mkdir-p doc) + (copy-recursively "docs" doc) + #t))) + (add-after 'install 'create-executable + (lambda* (#:key outputs inputs #:allow-other-keys) + (let* ((python (string-append (assoc-ref inputs "python") + "/bin/python")) + (out (assoc-ref outputs "out")) + (bin (string-append out "/bin")) + (executable (string-append bin "/childsplay"))) + (mkdir-p bin) + (call-with-output-file executable + (lambda (file) + (format file + "~a ~a" + python + (string-append out "/share/childsplay/childsplay.py")))) + (chmod executable #o555) + #t))) + (add-after 'install 'create-desktop-file + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (applications (string-append out "/share/applications"))) + (mkdir-p applications) + (call-with-output-file + (string-append applications "/childsplay.desktop") + (lambda (file) + (format file + "[Desktop Entry]~@ + Name=Childsplay~@ + Comment=Suite of educational games for young children~@ + Comment[ca]=Conjunt de jocs educatius per a xiquets~@ + Comment[es]=Conjunto de juegos educativos para niños~@ + Comment[de]=Sammlung mit lehrreichen Spielen für kleine Kinder~@ + Exec=~a/bin/childsplay.py~@ + Terminal=false~@ + Icon=logo_cp.svg~@ + Type=Application~@ + Categories=Application;Game;Education;KidsGame;~@ + Keywords=suite;children;games;young;educational;~%" + out))) + #t)))))) + (inputs + `(("font-dejavu" ,font-dejavu) + ("pygame" ,python2-pygame) + ("sqlalchemy" ,python2-sqlalchemy))) + (synopsis "Suite of educational games for young children") + (description "Childsplay is a collection of educational activities +for young children. Childsplay can be used at home, kindergartens and +pre-schools. Childsplay is a fun and safe way to let young children +use the computer and at the same time teach them a little math, +letters of the alphabet, spelling, eye-hand coordination, etc.") + (home-page "http://www.schoolsplay.org") + (license license:gpl3+))) -- cgit v1.3 From 7180dd671697e0215b140ebc0d36047b4b8375f2 Mon Sep 17 00:00:00 2001 From: Carl Dong Date: Tue, 28 May 2019 17:31:32 +0000 Subject: gnu: Add basic support for riscv64-linux-gnu targets. * gnu/packages/bootstrap.scm (glibc-dynamic-linker): Add "riscv64-linux". * gnu/packages/linux.scm (system->linux-architecture): Add "riscv" prefix. Signed-off-by: Danny Milosavljevic --- gnu/packages/bootstrap.scm | 1 + gnu/packages/linux.scm | 1 + 2 files changed, 2 insertions(+) diff --git a/gnu/packages/bootstrap.scm b/gnu/packages/bootstrap.scm index a3ecbeb07..e8b212055 100644 --- a/gnu/packages/bootstrap.scm +++ b/gnu/packages/bootstrap.scm @@ -177,6 +177,7 @@ return value is ignored." ((string=? system "powerpc64le-linux") "/lib/ld64.so.2") ((string=? system "alpha-linux") "/lib/ld-linux.so.2") ((string=? system "s390x-linux") "/lib/ld64.so.1") + ((string=? system "riscv64-linux") "/lib/ld-linux-riscv64-lp64d.so.1") ;; XXX: This one is used bare-bones, without a libc, so add a case ;; here just so we can keep going. diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 67085f30f..bc519409c 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -144,6 +144,7 @@ ((string-prefix? "alpha" arch) "alpha") ((string-prefix? "powerpc" arch) "powerpc") ;including "powerpc64le" ((string-prefix? "s390" arch) "s390") + ((string-prefix? "riscv" arch) "riscv") (else arch)))) (define-public (system->defconfig system) -- cgit v1.3 From 2ea77d48a739eb289f2472d2c30c37a30bbcb571 Mon Sep 17 00:00:00 2001 From: Carl Dong Date: Tue, 28 May 2019 15:57:41 +0000 Subject: gnu: cross-base: Allow non-default linux-headers. * gnu/packages/cross-base.scm (cross-kernel-headers): Add LINUX-HEADERS optional argument. Signed-off-by: Danny Milosavljevic --- gnu/packages/cross-base.scm | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/gnu/packages/cross-base.scm b/gnu/packages/cross-base.scm index b3b90a649..a0341ebc5 100644 --- a/gnu/packages/cross-base.scm +++ b/gnu/packages/cross-base.scm @@ -39,7 +39,8 @@ #:export (cross-binutils cross-libc cross-gcc - cross-newlib?)) + cross-newlib? + cross-kernel-headers)) (define-syntax %xgcc ;; GCC package used as the basis for cross-compilation. It doesn't have to @@ -276,18 +277,19 @@ target that libc." (define* (cross-kernel-headers target #:optional + (linux-headers linux-libre-headers) (xgcc (cross-gcc target)) (xbinutils (cross-binutils target))) "Return headers depending on TARGET." (define xlinux-headers - (package (inherit linux-libre-headers) - (name (string-append (package-name linux-libre-headers) + (package (inherit linux-headers) + (name (string-append (package-name linux-headers) "-cross-" target)) (arguments (substitute-keyword-arguments `(#:implicit-cross-inputs? #f - ,@(package-arguments linux-libre-headers)) + ,@(package-arguments linux-headers)) ((#:phases phases) `(alist-replace 'build @@ -300,7 +302,7 @@ target that libc." ,phases)))) (native-inputs `(("cross-gcc" ,xgcc) ("cross-binutils" ,xbinutils) - ,@(package-native-inputs linux-libre-headers))))) + ,@(package-native-inputs linux-headers))))) (define xgnumach-headers (package (inherit gnumach-headers) -- cgit v1.3 From a15cee50cebddc665a16b455f44e22dcfb87d57f Mon Sep 17 00:00:00 2001 From: Carl Dong Date: Wed, 29 May 2019 18:04:43 +0200 Subject: gnu: Use make-linux-libre-headers. * gnu/packages/linux.scm (make-linux-libre-headers): New variable. (linux-libre): Rename to... (linux-libre-5.1): ...this. (linux-libre-headers): Rename to... (linux-libre-headers-4.14.67): ...this. (linux-libre-5.1, linux-libre-headers-4.14.67): Use make-linux-libre-headers. (linux-libre-5.1, linux-libre-headers-5.1, linux-libre-headers-4.19, %linux-libre-4.15-version, %linux-libre-4.15-hash, linux-libre-4.15, linux-libre-headers-4.15, linux-libre-headers-4.14): New variables. Signed-off-by: Danny Milosavljevic --- gnu/packages/linux.scm | 49 ++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 42 insertions(+), 7 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index bc519409c..ac26b024a 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -171,18 +171,20 @@ defconfig. Return the appropriate make target if applicable, otherwise return "mirror://gnu/linux-libre/" version "-gnu/linux-libre-" version "-gnu.tar.xz"))) -(define-public linux-libre-headers +(define (make-linux-libre-headers version hash) (package (name "linux-libre-headers") - (version "4.14.67") + (version version) (source (origin (method url-fetch) (uri (linux-libre-urls version)) - (sha256 - (base32 - "050zvdxjy6sc64q75pr1gxsmh49chwav2pwxz8xlif39bvahnrpg")))) + (sha256 (base32 hash)))) (build-system gnu-build-system) - (native-inputs `(("perl" ,perl))) + (native-inputs `(("perl" ,perl) + ,@(if (version>=? version "4.16") + `(("flex" ,flex) + ("bison" ,bison)) + '()))) (arguments `(#:modules ((guix build gnu-build-system) (guix build utils) @@ -435,13 +437,17 @@ It has been modified to remove all non-free binary blobs.") (list %boot-logo-patch %linux-libre-arm-export-__sync_icache_dcache-patch)) -(define-public linux-libre +(define-public linux-libre-5.1 (make-linux-libre %linux-libre-version %linux-libre-hash '("x86_64-linux" "i686-linux" "armhf-linux" "aarch64-linux") #:patches %linux-libre-5.1-patches #:configuration-file kernel-config)) +(define-public linux-libre-headers-5.1 + (make-linux-libre-headers %linux-libre-version + %linux-libre-hash)) + (define %linux-libre-4.19-version "4.19.46") (define %linux-libre-4.19-hash "17yy3h064kr7zck07wdrw3fmmmnfk15m17xvkpkc4yv5vxxi76vh") @@ -456,6 +462,24 @@ It has been modified to remove all non-free binary blobs.") #:patches %linux-libre-4.19-patches #:configuration-file kernel-config)) +(define-public linux-libre-headers-4.19 + (make-linux-libre-headers %linux-libre-4.19-version + %linux-libre-4.19-hash)) + +(define %linux-libre-4.15-version "4.15.18") +(define %linux-libre-4.15-hash "0f0s4drx888ydlwjcm9qcxqian4850yiv2vamyw9bbjf83frwxyw") + +(define-public linux-libre-4.15 + (make-linux-libre %linux-libre-4.15-version + %linux-libre-4.15-hash + '("x86_64-linux" "i686-linux" "armhf-linux") + #:configuration-file kernel-config)) + +(define-public linux-libre-headers-4.15 + (make-linux-libre-headers %linux-libre-4.15-version + %linux-libre-4.15-hash)) + + (define %linux-libre-4.14-version "4.14.122") (define %linux-libre-4.14-hash "0923m61b3gwm69w6m9zhb8az57lrwn7igdysf8wb7ld9z4hzpag8") @@ -465,6 +489,10 @@ It has been modified to remove all non-free binary blobs.") '("x86_64-linux" "i686-linux" "armhf-linux") #:configuration-file kernel-config)) +(define-public linux-libre-headers-4.14 + (make-linux-libre-headers %linux-libre-4.14-version + %linux-libre-4.14-hash)) + (define-public linux-libre-4.9 (make-linux-libre "4.9.179" "0nc9a7b7g5a18fdc8dswm3la7srn5sgz8adavp8r9h3ya9zh3wim" @@ -491,6 +519,13 @@ It has been modified to remove all non-free binary blobs.") #:configuration-file kernel-config-veyron #:extra-version "arm-veyron")) +(define-public linux-libre-headers-4.14.67 + (make-linux-libre-headers "4.14.67" + "050zvdxjy6sc64q75pr1gxsmh49chwav2pwxz8xlif39bvahnrpg")) + +(define-public linux-libre-headers linux-libre-headers-4.14.67) +(define-public linux-libre linux-libre-5.1) + (define-public linux-libre-arm-generic (make-linux-libre %linux-libre-version %linux-libre-hash -- cgit v1.3 From a1ac29f80dc902a5bce1e45094aaaacf33aa5e9f Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 29 May 2019 20:39:20 +0200 Subject: gnu: r-bayestestr: Update to 0.2.0. * gnu/packages/cran.scm (r-bayestestr): Update to 0.2.0. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 398cdd18a..8abf9ba13 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -7923,14 +7923,14 @@ differentiation.") (define-public r-bayestestr (package (name "r-bayestestr") - (version "0.1.0") + (version "0.2.0") (source (origin (method url-fetch) (uri (cran-uri "bayestestR" version)) (sha256 (base32 - "1m6gj55z3shm3m3mgqj8nk73wij67y617sl04rbj400wz9qrhfva")))) + "0729j4fdxkkvmh99nmny38dywidzgmipdjqbi2ljxygsn4jg7ysy")))) (properties `((upstream-name . "bayestestR"))) (build-system r-build-system) (propagated-inputs -- cgit v1.3 From 765d327c8580fd3900adda04abd5f8e88f6a03c5 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 29 May 2019 20:39:28 +0200 Subject: gnu: r-fields: Update to 9.8-3. * gnu/packages/cran.scm (r-fields): Update to 9.8-3. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 8abf9ba13..52297c736 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -10486,14 +10486,14 @@ Differences with other sparse matrix packages are: (define-public r-fields (package (name "r-fields") - (version "9.8-1") + (version "9.8-3") (source (origin (method url-fetch) (uri (cran-uri "fields" version)) (sha256 (base32 - "1zb44bm9mwbnld2q915nxxji3hqa025cmlaar7da35lyqlrjl30v")))) + "1q9x68dczjym56v7x90x4x5br59vj3dww6w8v42zd3yl17h7c1h1")))) (build-system r-build-system) (propagated-inputs `(("r-maps" ,r-maps) -- cgit v1.3 From 4c8603e808f73bfd4a65a04184285ae5e218e8b3 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Wed, 29 May 2019 20:39:36 +0200 Subject: gnu: r-statmod: Update to 1.4.32. * gnu/packages/statistics.scm (r-statmod): Update to 1.4.32. --- gnu/packages/statistics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index 6263f0a1b..12fcb7570 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -4471,13 +4471,13 @@ Wall Street Journal, among others. This package also provides (define-public r-statmod (package (name "r-statmod") - (version "1.4.30") + (version "1.4.32") (source (origin (method url-fetch) (uri (cran-uri "statmod" version)) (sha256 (base32 - "07v4x8af60alcw6vbiwf5fp25bhra61kvxz9kqx64lszm0i1fb4x")))) + "083yyp84xj85zg4bhz7i90bqzl3p6155ch4abwsfc9k1lv7s2rrg")))) (build-system r-build-system) (home-page "https://cran.r-project.org/web/packages/statmod") (native-inputs -- cgit v1.3 From e84e0369435add8e839fec78d4be7b2e71f6d4a8 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Wed, 29 May 2019 11:35:15 +0200 Subject: publish: Remove outdated comment. * guix/scripts/publish.scm (make-request-handler): Remove outdated TODO. --- guix/scripts/publish.scm | 2 -- 1 file changed, 2 deletions(-) diff --git a/guix/scripts/publish.scm b/guix/scripts/publish.scm index 889dbef86..287590475 100644 --- a/guix/scripts/publish.scm +++ b/guix/scripts/publish.scm @@ -848,8 +848,6 @@ blocking." (render-home-page request)) ;; /.narinfo (((= extract-narinfo-hash (? string? hash))) - ;; TODO: Register roots for HASH that will somehow remain for - ;; NARINFO-TTL. (if cache (render-narinfo/cached store request hash #:cache cache -- cgit v1.3 From 73bddab54504c6380a896b7263ab6c3dd8558ef7 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Wed, 29 May 2019 11:38:17 +0200 Subject: publish: Factorize 'compress-nar'. * guix/scripts/publish.scm (compress-nar): New procedure. (bake-narinfo+nar): Use it. --- guix/scripts/publish.scm | 54 +++++++++++++++++++++++++++--------------------- 1 file changed, 30 insertions(+), 24 deletions(-) diff --git a/guix/scripts/publish.scm b/guix/scripts/publish.scm index 287590475..c55873db7 100644 --- a/guix/scripts/publish.scm +++ b/guix/scripts/publish.scm @@ -505,6 +505,35 @@ requested using POOL." (else (not-found request #:phrase ""))))) +(define (compress-nar cache item compression) + "Save in directory CACHE the nar for ITEM compressed with COMPRESSION." + (define nar + (nar-cache-file cache item #:compression compression)) + + (mkdir-p (dirname nar)) + (match (compression-type compression) + ('gzip + ;; Note: the file port gets closed along with the gzip port. + (call-with-gzip-output-port (open-output-file (string-append nar ".tmp")) + (lambda (port) + (write-file item port)) + #:level (compression-level compression) + #:buffer-size (* 128 1024)) + (rename-file (string-append nar ".tmp") nar)) + ('lzip + ;; Note: the file port gets closed along with the lzip port. + (call-with-lzip-output-port (open-output-file (string-append nar ".tmp")) + (lambda (port) + (write-file item port)) + #:level (compression-level compression)) + (rename-file (string-append nar ".tmp") nar)) + ('none + ;; Cache nars even when compression is disabled so that we can + ;; guarantee the TTL (see .) + (with-atomic-file-output nar + (lambda (port) + (write-file item port)))))) + (define* (bake-narinfo+nar cache item #:key ttl (compression %no-compression) (nar-path "/nar")) @@ -514,30 +543,7 @@ requested using POOL." #:compression compression)) (narinfo (narinfo-cache-file cache item #:compression compression))) - - (mkdir-p (dirname nar)) - (match (compression-type compression) - ('gzip - ;; Note: the file port gets closed along with the gzip port. - (call-with-gzip-output-port (open-output-file (string-append nar ".tmp")) - (lambda (port) - (write-file item port)) - #:level (compression-level compression) - #:buffer-size (* 128 1024)) - (rename-file (string-append nar ".tmp") nar)) - ('lzip - ;; Note: the file port gets closed along with the lzip port. - (call-with-lzip-output-port (open-output-file (string-append nar ".tmp")) - (lambda (port) - (write-file item port)) - #:level (compression-level compression)) - (rename-file (string-append nar ".tmp") nar)) - ('none - ;; Cache nars even when compression is disabled so that we can - ;; guarantee the TTL (see .) - (with-atomic-file-output nar - (lambda (port) - (write-file item port))))) + (compress-nar cache item compression) (mkdir-p (dirname narinfo)) (with-atomic-file-output narinfo -- cgit v1.3 From dc37301330af38c7f3b7d6d10d1a3557335c0642 Mon Sep 17 00:00:00 2001 From: Reza Alizadeh Majd Date: Sat, 25 May 2019 17:39:14 +0430 Subject: gnu: sddm: Add QtQuick-related dependencies to sddm. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/display-managers.scm (sddm): add QtQuick related dependencies to sddm package in order to `sddm-greeter` application to load user defined themes which are based on QtQuick. Signed-off-by: Ludovic Courtès --- gnu/packages/display-managers.scm | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/gnu/packages/display-managers.scm b/gnu/packages/display-managers.scm index 29d8ae4eb..0b8f742c3 100644 --- a/gnu/packages/display-managers.scm +++ b/gnu/packages/display-managers.scm @@ -75,6 +75,15 @@ ("linux-pam" ,linux-pam) ("qtbase" ,qtbase) ("qtdeclarative" ,qtdeclarative) + + ;; Some user-defined themes use QtQuick components internally. Adding + ;; QtQuick & co. here; they end up in QML2_IMPORT_PATH thanks to + ;; 'wrap-qt-program'. + ("qtgraphicaleffects" ,qtgraphicaleffects) + ("qtquickcontrols" ,qtquickcontrols) + ("qtquickcontrols2" ,qtquickcontrols2) + ("qtsvg" ,qtsvg) + ("shadow" ,shadow) ("wayland" ,wayland))) (arguments -- cgit v1.3 From 169d63f53307f16743166c25f709d37fcbc47262 Mon Sep 17 00:00:00 2001 From: Andy Tai Date: Thu, 30 May 2019 00:02:38 -0700 Subject: gnu: Add gthumb. * gnu/packages/gnome.scm (gthumb): New variable. Signed-off-by: Ricardo Wurmus Co-authored-by: Ricardo Wurmus --- gnu/packages/gnome.scm | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 14e63280e..60141fce9 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -7974,3 +7974,50 @@ functionality.") (license (list license:lgpl2.1 license:lgpl3 ; either one of these license:openldap2.8 ; addressbook/gui/component/openldap-extract.h license:lgpl2.1+)))) ; smime/lib/* + +(define-public gthumb + (package + (name "gthumb") + (version "3.8.0") + (source (origin + (method url-fetch) + (uri (string-append "mirror://gnome/sources/gthumb/" + (version-major+minor version) "/" + "gthumb-" version ".tar.xz")) + (sha256 + (base32 + "1l2s1facq1r6yvqjqc34aqfzlvb3nhkhn79xisxbbdlgrrxdq52f")))) + (build-system meson-build-system) + (arguments + `(#:glib-or-gtk? #t + #:configure-flags + ;; Ensure the RUNPATH contains all installed library locations. + (list (string-append "-Dc_link_args=-Wl,-rpath=" + (assoc-ref %outputs "out") + "/lib/gthumb/extensions") + (string-append "-Dcpp_link_args=-Wl,-rpath=" + (assoc-ref %outputs "out") + "/lib/gthumb/extensions")))) + (native-inputs + `(("pkg-config" ,pkg-config) + ("glib:bin" ,glib "bin") ; for glib-compile-resources + ("gtk+:bin" ,gtk+ "bin") ; for gtk-update-icon-cache + ("desktop-file-utils" ,desktop-file-utils) ; for update-desktop-database + ("intltool" ,intltool) + ("itstool" ,itstool))) + (inputs + `(("exiv2" ,exiv2) + ("gtk" ,gtk+) + ("gsettings-desktop-schemas" ,gsettings-desktop-schemas) + ("gstreamer" ,gstreamer) + ("clutter" ,clutter) + ("clutter-gst" ,clutter-gst) + ("clutter-gtk" ,clutter-gtk) + ("libjpeg" ,libjpeg) + ("libtiff" ,libtiff) + ("libraw" ,libraw))) + (home-page "https://wiki.gnome.org/Apps/Gthumb") + (synopsis "GNOME image viewer and browser") + (description "GThumb is an image viewer, browser, organizer, editor and +advanced image management tool") + (license license:gpl2+))) -- cgit v1.3 From d1ee1540d4963e49861c60241596c5529c4d91a4 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 30 May 2019 13:40:48 +0200 Subject: gnu: r-dose: Update to 3.10.1. * gnu/packages/bioconductor.scm (r-dose): Update to 3.10.1. --- gnu/packages/bioconductor.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioconductor.scm b/gnu/packages/bioconductor.scm index e60f8cac0..1e38d796a 100644 --- a/gnu/packages/bioconductor.scm +++ b/gnu/packages/bioconductor.scm @@ -2886,14 +2886,14 @@ to multiple hypothesis correction.") (define-public r-dose (package (name "r-dose") - (version "3.10.0") + (version "3.10.1") (source (origin (method url-fetch) (uri (bioconductor-uri "DOSE" version)) (sha256 (base32 - "0dvhnfhzhhzcxm8zhdwrkif7sak4p888sjqfd3a0p77h0hs6g8pv")))) + "0ab7mgj42fg6608qkciyqivr1n8s8r5ibvp0z3jfclrnyx6cl0w1")))) (properties `((upstream-name . "DOSE"))) (build-system r-build-system) (propagated-inputs -- cgit v1.3 From 782a7f4655e376e08df75e328de689096e77f39e Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 30 May 2019 13:41:04 +0200 Subject: gnu: r-tibble: Update to 2.1.2. * gnu/packages/statistics.scm (r-tibble): Update to 2.1.2. --- gnu/packages/statistics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index 12fcb7570..27d1c29e2 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -1670,14 +1670,14 @@ like tidy evaluation.") (define-public r-tibble (package (name "r-tibble") - (version "2.1.1") + (version "2.1.2") (source (origin (method url-fetch) (uri (cran-uri "tibble" version)) (sha256 (base32 - "111jl0hdjhh7hkydxvsr5l19gb0ylxq7xrkc28awnc9pzglpgis5")))) + "1sb5j6k8hp7yf7grjjhn45hhc163fcndiw9zw976zc74f1856kpj")))) (build-system r-build-system) (propagated-inputs `(("r-cli" ,r-cli) -- cgit v1.3 From add5ecfd68784e2e9596402a2bb0533d2fab6458 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 30 May 2019 13:41:10 +0200 Subject: gnu: r-biocviews: Update to 1.52.1. * gnu/packages/bioinformatics.scm (r-biocviews): Update to 1.52.1. --- gnu/packages/bioinformatics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index 8f31d4e22..45c147f26 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -7245,13 +7245,13 @@ Bioconductor, CRAN, and Github.") (define-public r-biocviews (package (name "r-biocviews") - (version "1.52.0") + (version "1.52.1") (source (origin (method url-fetch) (uri (bioconductor-uri "biocViews" version)) (sha256 (base32 - "1wc7a953n6qrlh9azzg1q68rk99h3xkbs82wq0yk6h2vb2c5r3zk")))) + "1685gdcvsmdjp1g5hm882jyyjdgqq77zh9xl2japhj285s8bm12y")))) (properties `((upstream-name . "biocViews"))) (build-system r-build-system) -- cgit v1.3 From ff793da66918ace85048f90dc069415ef067ba06 Mon Sep 17 00:00:00 2001 From: Vagrant Cascadian Date: Thu, 30 May 2019 15:36:20 -0700 Subject: gnu: diffoscope: Update to version 115-1.7f3416f. * gnu/packages/package-management (diffoscope): [package] Update to version 115-1.7f3416f. [source] Switch to using git-fetch. [inputs] Move python-pytest and python-chardet ... [native-inputs] ... to here. [arguments] Move comment to fit line length. --- gnu/packages/package-management.scm | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index 2113e4956..9e0bfb697 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -548,13 +548,16 @@ transactions from C or Python.") (define-public diffoscope (package (name "diffoscope") - (version "114") + (version (git-version "115" "1" "7f3416ffd12572b42c814e43ac15cee44ef48155")) (source (origin - (method url-fetch) - (uri (pypi-uri name version)) + (method git-fetch) + (uri (git-reference + (url "https://salsa.debian.org/reproducible-builds/diffoscope.git") + (commit "7f3416ffd12572b42c814e43ac15cee44ef48155"))) + (file-name (git-file-name name version)) (sha256 (base32 - "07sma4izcqxdv0zi1s5fnsybvkc47c3vbpm372sg83q8l7rhizzp")))) + "1pn2rwlz5shdx7s63798wx2v7029bl5if6dlq3i2r6zsnpp0laki")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases @@ -590,7 +593,8 @@ transactions from C or Python.") #t)) (add-before 'check 'delete-failing-test (lambda _ - (delete-file "tests/test_tools.py") ;this requires /sbin to be on the path + ;; this requires /sbin to be on the path + (delete-file "tests/test_tools.py") #t))))) (inputs `(("rpm" ,rpm) ;for rpm-python ("python-file" ,python-file) @@ -599,11 +603,10 @@ transactions from C or Python.") ("python-tlsh" ,python-tlsh) ("acl" ,acl) ;for getfacl ("colordiff" ,colordiff) - ("xxd" ,xxd) - - ;; Below are modules used for tests. - ("python-pytest" ,python-pytest) - ("python-chardet" ,python-chardet))) + ("xxd" ,xxd))) + ;; Below are modules used for tests. + (native-inputs `(("python-pytest" ,python-pytest) + ("python-chardet" ,python-chardet))) (home-page "https://diffoscope.org/") (synopsis "Compare files, archives, and directories in depth") (description -- cgit v1.3 From e6377445470e24a86649d393619148368105d036 Mon Sep 17 00:00:00 2001 From: Rutger Helling Date: Fri, 31 May 2019 08:32:06 +0200 Subject: gnu: kitty: Update to 0.14.1. * gnu/packages/terminals.scm (kitty): Update to 0.14.1. --- gnu/packages/terminals.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm index 2eb273097..0ef9b0079 100644 --- a/gnu/packages/terminals.scm +++ b/gnu/packages/terminals.scm @@ -924,7 +924,7 @@ tmux.") (define-public kitty (package (name "kitty") - (version "0.14.0") + (version "0.14.1") (home-page "https://sw.kovidgoyal.net/kitty/") (source (origin @@ -935,7 +935,7 @@ tmux.") (file-name (git-file-name name version)) (sha256 (base32 - "122573l7xirs9dsi5p8gra47qpgxb3vahqp2r0c043pgz4i22v5z")) + "0nm8l8ki0csdapf5mj3vg605ki5hjsx7h7i3m01x1a4vjzjmk8bv")) (modules '((guix build utils))) (snippet '(begin -- cgit v1.3 From b0eaead510da14c66f7d3b81e6eeae6c5a8445db Mon Sep 17 00:00:00 2001 From: Joseph LaFreniere Date: Fri, 31 May 2019 09:56:17 +0200 Subject: gnu: Add emacs-ivy-pass. * gnu/packages/emacs-xyz.scm (emacs-ivy-pass): New variable. Signed-off-by: Ricardo Wurmus --- gnu/packages/emacs-xyz.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 6f74a2fc4..6467507d1 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -4403,6 +4403,33 @@ splitting the input text by spaces and re-building it into a regular expression.") (license license:gpl3+))) +(define-public emacs-ivy-pass + (let ((commit "5b523de1151f2109fdd6a8114d0af12eef83d3c5") + (revision "1")) + (package + (name "emacs-ivy-pass") + (version (git-version "0.1" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/ecraven/ivy-pass.git") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "18crb4zh2pjf0cmv3b913m9vfng27girjwfqc3mk7vqd1r5a49yk")))) + (build-system emacs-build-system) + (propagated-inputs + `(("emacs-ivy" ,emacs-ivy) + ("emacs-password-store" ,emacs-password-store) + ("password-store" ,password-store))) + (home-page "https://github.com/ecraven/ivy-pass") + (synopsis "Ivy interface for password store (pass)") + (description "This package provides an Ivy interface for working with +the password store @code{pass}.") + (license license:gpl3)))) + (define-public emacs-ivy-yasnippet (let ((commit "32580b4fd23ebf9ca7dde96704f7d53df6e253cd") (revision "2")) -- cgit v1.3 From 8ae48674ce3493fddfdc0d2acead285396ed1da0 Mon Sep 17 00:00:00 2001 From: "LaFreniere, Joseph" Date: Thu, 30 May 2019 15:17:53 -0500 Subject: gnu: Add emacs-reformatter. * gnu/packages/emacs-xyz.scm (emacs-reformatter): New variable. Signed-off-by: Ricardo Wurmus --- gnu/packages/emacs-xyz.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 6467507d1..1b0e623bb 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -804,6 +804,29 @@ skip set strings, which are arguments to @code{skip-chars-forward} and @code{skip-chars-backward}.") (license license:gpl3+))) +(define-public emacs-reformatter + (package + (name "emacs-reformatter") + (version "0.4") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/purcell/reformatter.el.git") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0hhy6x1bkwlhdlarsgm06g3am4yh02yqv8qs34szpzgy53x84qah")))) + (build-system emacs-build-system) + (home-page "https://github.com/purcell/reformatter.el") + (synopsis "Define commands which run reformatters on the current buffer") + (description + "This library lets elisp authors easily define an idiomatic command to +reformat the current buffer using a command-line program, together with an +optional minor mode which can apply this command automatically on save.") + (license license:gpl3+))) + (define-public emacs-relint (package (name "emacs-relint") -- cgit v1.3 From 265ee14650d0207299a8dac0b857b6412f86e0c7 Mon Sep 17 00:00:00 2001 From: Brian Leung Date: Mon, 27 May 2019 21:06:46 +0200 Subject: gnu: emacs-exec-path-from-shell: Update to 1.12. * gnu/packages/emacs-xyz.scm (emacs-exec-path-from-shell): Update to 1.12. [source]: Use git-fetch. Signed-off-by: Ricardo Wurmus --- gnu/packages/emacs-xyz.scm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 1b0e623bb..2c56a7cbf 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -9277,16 +9277,16 @@ functionality is inherited from @code{hcl-mode}.") (define-public emacs-exec-path-from-shell (package (name "emacs-exec-path-from-shell") - (version "1.11") + (version "1.12") (source (origin - (method url-fetch) - (uri (string-append - "https://stable.melpa.org/packages/exec-path-from-shell-" - version ".el")) + (method git-fetch) + (uri (git-reference + (url "https://github.com/purcell/exec-path-from-shell") + (commit version))) (sha256 (base32 - "03qjgb81cq1l3j54lvlf98r75vmmgd06mj6qh5wa6mz4xzp4w26r")))) + "1ga8bpxngd3ph2hdiik92c612ki71qxw818i6rgx6f6a5r0sbf3p")))) (build-system emacs-build-system) (home-page "https://github.com/purcell/exec-path-from-shell") (synopsis "Get environment variables such as @var{PATH} from the shell") -- cgit v1.3 From ea82e3b266e7bbea8065d171d44996c84d021e22 Mon Sep 17 00:00:00 2001 From: Brian Leung Date: Mon, 27 May 2019 21:06:56 +0200 Subject: gnu: emacs-editorconfig: Update to 0.8.0. * gnu/packages/emacs-xyz.scm (emacs-editorconfig): Update to 0.8.0. Signed-off-by: Ricardo Wurmus --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 2c56a7cbf..941d3469d 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -13459,7 +13459,7 @@ backends, including the @command{wordnet} offline backend.") (define-public emacs-editorconfig (package (name "emacs-editorconfig") - (version "0.7.14") + (version "0.8.0") (source (origin (method git-fetch) @@ -13469,7 +13469,7 @@ backends, including the @command{wordnet} offline backend.") (file-name (git-file-name name version)) (sha256 (base32 - "19j2428ij7sqvrqs7rqg1mcnv9109y6drqba40dkv3vrkk5d2yia")))) + "1b2cpqz75pivl323bs60j5rszwi787x6vy68csycikqz9mhpmjn9")))) (build-system emacs-build-system) (home-page "https://github.com/editorconfig/editorconfig-emacs") (synopsis "Define and maintain consistent coding styles between different -- cgit v1.3 From f42399b5e593f10900c381fbf9c41788b0eae6ab Mon Sep 17 00:00:00 2001 From: Brian Leung Date: Tue, 28 May 2019 05:44:04 +0200 Subject: gnu: emacs-counsel-tramp: Update to 0.6.3. * gnu/packages/emacs-xyz.scm (emacs-counsel-tramp): Update to 0.6.3. Signed-off-by: Ricardo Wurmus --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 941d3469d..3273679d0 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -15400,7 +15400,7 @@ well as an option for visually flashing evaluated s-expressions.") (define-public emacs-counsel-tramp (package (name "emacs-counsel-tramp") - (version "0.6.2") + (version "0.6.3") (source (origin (method git-fetch) @@ -15410,7 +15410,7 @@ well as an option for visually flashing evaluated s-expressions.") (file-name (git-file-name name version)) (sha256 (base32 - "0nz0733x2b9b5nkwivvhv5c8747dng451na1sdfbkx5x9fjs5gc7")))) + "1qy9lf7cyv6hp9mmpwh92cpdcffbxzyzchx6878d5pmk9qh6xy92")))) (build-system emacs-build-system) (propagated-inputs `(("emacs-ivy" ,emacs-ivy))) -- cgit v1.3 From 66712cc0ed69b1e7c6487d555c1a9d3486c16f98 Mon Sep 17 00:00:00 2001 From: Brian Leung Date: Wed, 29 May 2019 03:16:49 +0200 Subject: gnu: emacs-helm: Update to 3.2. * gnu/packages/emacs-xyz.scm (emacs-helm): Update to 3.2. Signed-off-by: Ricardo Wurmus --- gnu/packages/emacs-xyz.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 3273679d0..42fb57ab8 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -5608,7 +5608,7 @@ ack, ag, helm and pt.") (define-public emacs-helm (package (name "emacs-helm") - (version "3.1") + (version "3.2") (source (origin (method git-fetch) @@ -5617,7 +5617,7 @@ ack, ag, helm and pt.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "1x3nv8zvp8vvl30bm2d83hd7zxb0ca64pc8kwb81ml9al6r3mm01")))) + (base32 "12yyprpgh2by2pd41i4z9gz55fxg0f90x03bfrsf791xwbhf6931")))) (build-system emacs-build-system) (propagated-inputs `(("emacs-async" ,emacs-async) -- cgit v1.3 From 2e62ba46e2dc6f27398a65eb157b4ce711ff0e6b Mon Sep 17 00:00:00 2001 From: Brian Leung Date: Wed, 29 May 2019 03:17:00 +0200 Subject: gnu: emacs-diff-hl: Update to 1.8.6. * gnu/packages/emacs-xyz.scm (emacs-diff-hl): Update to 1.8.6. [source]: Fetch from git. Signed-off-by: Ricardo Wurmus --- gnu/packages/emacs-xyz.scm | 35 ++++++++++++++++++----------------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 42fb57ab8..c2d515ed9 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -7073,26 +7073,27 @@ actually changing the buffer's text.") (license license:gpl3+))) (define-public emacs-diff-hl - (package - (name "emacs-diff-hl") - (version "1.8.5") - (source - (origin - (method url-fetch) - (uri (string-append "https://elpa.gnu.org/packages/diff-hl-" - version ".tar")) - (sha256 + (package + (name "emacs-diff-hl") + (version "1.8.6") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/dgutov/diff-hl") + (commit version))) + (sha256 (base32 - "1vxc7z7c2qs0mx7l5sa4sybi5qbzv0s79flj74p1ynw8dl3qxg3d")))) - (build-system emacs-build-system) - (home-page "https://github.com/dgutov/diff-hl") - (synopsis - "Highlight uncommitted changes using VC") - (description - "@code{diff-hl-mode} highlights uncommitted changes on the side of the + "1xlsg728mz3cwhrsqvisa0aidic67nymd9g7h4c1h3q63j39yb2s")))) + (build-system emacs-build-system) + (home-page "https://github.com/dgutov/diff-hl") + (synopsis + "Highlight uncommitted changes using VC") + (description + "@code{diff-hl-mode} highlights uncommitted changes on the side of the window (using the fringe, by default), allows you to jump between the hunks and revert them selectively.") - (license license:gpl3+))) + (license license:gpl3+))) (define-public emacs-diminish (package -- cgit v1.3 From 95bf71c307cbc9c4d1380d5b82448db55be5afe1 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Fri, 31 May 2019 14:29:32 +0200 Subject: gnu: r-seriation: Update to 1.2-5. * gnu/packages/cran.scm (r-seriation): Update to 1.2-5. --- gnu/packages/cran.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/cran.scm b/gnu/packages/cran.scm index 52297c736..005016b98 100644 --- a/gnu/packages/cran.scm +++ b/gnu/packages/cran.scm @@ -3583,14 +3583,14 @@ Markdown documents.") (define-public r-seriation (package (name "r-seriation") - (version "1.2-3") + (version "1.2-5") (source (origin (method url-fetch) (uri (cran-uri "seriation" version)) (sha256 (base32 - "1q6hw4hjw224b4y0dc0j630v2pgj6sn455nwkilb70w8k31hpk92")))) + "0sk4wfwxxhz3nwbcsfshb93gra4c9p5pvpsz00d7f9nkkmhs97ws")))) (build-system r-build-system) (propagated-inputs `(("r-cluster" ,r-cluster) -- cgit v1.3 From 81e3de01ae2ac0e9cedc5625d25fd9b3d31e07fa Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Fri, 31 May 2019 14:40:20 +0200 Subject: gnu: Add r-birewire. * gnu/packages/bioconductor.scm (r-birewire): New variable. --- gnu/packages/bioconductor.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/bioconductor.scm b/gnu/packages/bioconductor.scm index 1e38d796a..10a4079fe 100644 --- a/gnu/packages/bioconductor.scm +++ b/gnu/packages/bioconductor.scm @@ -4548,3 +4548,32 @@ high-throughput sequencing data. It performs parallel processing of entire files and produces a report which contains a set of high-resolution graphics.") (license license:gpl2+))) + +(define-public r-birewire + (package + (name "r-birewire") + (version "3.16.0") + (source + (origin + (method url-fetch) + (uri (bioconductor-uri "BiRewire" version)) + (sha256 + (base32 + "1gjb18l3gq3w8zl6r5d49hw0r1kfh9f7ghv9hz6y86aniprvb518")))) + (properties `((upstream-name . "BiRewire"))) + (build-system r-build-system) + (propagated-inputs + `(("r-igraph" ,r-igraph) + ("r-matrix" ,r-matrix) + ("r-slam" ,r-slam) + ("r-tsne" ,r-tsne))) + (home-page "https://bioconductor.org/packages/release/bioc/html/BiRewire.html") + (synopsis "Tools for randomization of bipartite graphs") + (description + "This package provides functions for bipartite network rewiring through N +consecutive switching steps and for the computation of the minimal number of +switching steps to be performed in order to maximise the dissimilarity with +respect to the original network. It includes functions for the analysis of +the introduced randomness across the switching steps and several other +routines to analyse the resulting networks and their natural projections.") + (license license:gpl3))) -- cgit v1.3 From 1a24f855c8dcb61f34b1ec7390ca90e2540c53d9 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Fri, 31 May 2019 14:40:29 +0200 Subject: gnu: Add r-birta. * gnu/packages/bioconductor.scm (r-birta): New variable. --- gnu/packages/bioconductor.scm | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/gnu/packages/bioconductor.scm b/gnu/packages/bioconductor.scm index 10a4079fe..5ffb7c4e3 100644 --- a/gnu/packages/bioconductor.scm +++ b/gnu/packages/bioconductor.scm @@ -4577,3 +4577,32 @@ respect to the original network. It includes functions for the analysis of the introduced randomness across the switching steps and several other routines to analyse the resulting networks and their natural projections.") (license license:gpl3))) + +(define-public r-birta + (package + (name "r-birta") + (version "1.28.0") + (source + (origin + (method url-fetch) + (uri (bioconductor-uri "birta" version)) + (sha256 + (base32 + "12xjyvgmh4h0b7hi4qg50kcpb9003gnh2xyfgncb8l9mzvsbkxc2")))) + (build-system r-build-system) + (propagated-inputs + `(("r-biobase" ,r-biobase) + ("r-limma" ,r-limma) + ("r-mass" ,r-mass))) + (home-page "https://bioconductor.org/packages/birta") + (synopsis "Bayesian inference of regulation of transcriptional activity") + (description + "Expression levels of mRNA molecules are regulated by different +processes, comprising inhibition or activation by transcription factors and +post-transcriptional degradation by microRNAs. @dfn{birta} (Bayesian +Inference of Regulation of Transcriptional Activity) uses the regulatory +networks of transcription factors and miRNAs together with mRNA and miRNA +expression data to predict switches in regulatory activity between two +conditions. A Bayesian network is used to model the regulatory structure and +Markov-Chain-Monte-Carlo is applied to sample the activity states.") + (license license:gpl2+))) -- cgit v1.3 From 27489e7f73b812e13f52e4c9026b1175103ba7e7 Mon Sep 17 00:00:00 2001 From: Julien Lepiller Date: Fri, 31 May 2019 13:29:14 +0200 Subject: gnu: php: Update to 7.3.6. * gnu/packages/php.scm (php): Update to 7.3.6. --- gnu/packages/php.scm | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/gnu/packages/php.scm b/gnu/packages/php.scm index 68043051b..62444308d 100644 --- a/gnu/packages/php.scm +++ b/gnu/packages/php.scm @@ -58,7 +58,7 @@ (define-public php (package (name "php") - (version "7.3.5") + (version "7.3.6") (home-page "https://secure.php.net/") (source (origin (method url-fetch) @@ -66,7 +66,7 @@ name "-" version ".tar.xz")) (sha256 (base32 - "0wi4vd1c3ylsv7cs5b74pkspybb22qwk6fs5r2as3m3glhw1h0g1")) + "0r51aiff2abbr3d2swhvja0wm56sjxzqbciabcvvq3m3v9kqkz7y")) (modules '((guix build utils))) (snippet '(with-directory-excursion "ext" @@ -255,6 +255,10 @@ ;; but the bug report suggests the issue was in ;; the bundled gd, not upstream. "ext/gd/tests/bug77272.phpt" + ;; Expected invalid XBM but got EOF before image was + ;; complete. It's a warning in both cases and test + ;; result is the same. + "ext/gd/tests/bug77973.phpt" ;; XXX: These iconv tests have the expected outcome, ;; but with different error messages. -- cgit v1.3 From db6dd04c3dc0f893931f5cb823755eb792f2e9ee Mon Sep 17 00:00:00 2001 From: Julien Lepiller Date: Fri, 31 May 2019 14:37:16 +0200 Subject: gnu: gtksourceview-2: Fix finding default data. * gnu/packages/patches/gtksourceview-2-add-default-directory.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/gtk.scm (gtksourceview-2)[source]: Use it. --- gnu/local.mk | 1 + gnu/packages/gtk.scm | 5 +++- .../gtksourceview-2-add-default-directory.patch | 33 ++++++++++++++++++++++ 3 files changed, 38 insertions(+), 1 deletion(-) create mode 100644 gnu/packages/patches/gtksourceview-2-add-default-directory.patch diff --git a/gnu/local.mk b/gnu/local.mk index 3a199f82f..55fa90f92 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -897,6 +897,7 @@ dist_patch_DATA = \ %D%/packages/patches/gtk3-respect-GUIX_GTK3_PATH.patch \ %D%/packages/patches/gtk3-respect-GUIX_GTK3_IM_MODULE_FILE.patch \ %D%/packages/patches/gtkglext-disable-disable-deprecated.patch \ + %D%/packages/patches/gtksourceview-2-add-default-directory.patch \ %D%/packages/patches/gzdoom-search-in-installed-share.patch \ %D%/packages/patches/haskell-mode-unused-variables.patch \ %D%/packages/patches/haskell-mode-make-check.patch \ diff --git a/gnu/packages/gtk.scm b/gnu/packages/gtk.scm index 62b33a45b..b864225e3 100644 --- a/gnu/packages/gtk.scm +++ b/gnu/packages/gtk.scm @@ -348,7 +348,10 @@ diagrams.") name "-" version ".tar.bz2")) (sha256 (base32 - "07hrabhpl6n8ajz10s0d960jdwndxs87szxyn428mpxi8cvpg1f5")))) + "07hrabhpl6n8ajz10s0d960jdwndxs87szxyn428mpxi8cvpg1f5")) + (patches + (search-patches + "gtksourceview-2-add-default-directory.patch")))) (build-system gnu-build-system) (native-inputs `(("intltool" ,intltool) diff --git a/gnu/packages/patches/gtksourceview-2-add-default-directory.patch b/gnu/packages/patches/gtksourceview-2-add-default-directory.patch new file mode 100644 index 000000000..c4b5052b8 --- /dev/null +++ b/gnu/packages/patches/gtksourceview-2-add-default-directory.patch @@ -0,0 +1,33 @@ +From fc401acb15f15d487c942437b6fb429289dd3c67 Mon Sep 17 00:00:00 2001 +From: Julien Lepiller +Date: Fri, 31 May 2019 13:22:25 +0200 +Subject: [PATCH] Add installation directory as a default directory. + +In Guix, this library is installed in a separate directory in the store, +and it's typically not installed system-wide in a fixed directory. Add +the store path to the set of default directories so dependents can find +default langs and source highlighting scheme. +--- + gtksourceview/gtksourceview-utils.c | 6 ++++++ + 1 file changed, 6 insertions(+) + +diff --git a/gtksourceview/gtksourceview-utils.c b/gtksourceview/gtksourceview-utils.c +index 6f06bab..c3467d5 100644 +--- a/gtksourceview/gtksourceview-utils.c ++++ b/gtksourceview/gtksourceview-utils.c +@@ -66,6 +66,12 @@ _gtk_source_view_get_default_dirs (const char *basename, + basename, + NULL)); + ++ /* installed dir */ ++ g_ptr_array_add (dirs, g_build_filename (DATADIR, ++ SOURCEVIEW_DIR, ++ basename, ++ NULL)); ++ + g_ptr_array_add (dirs, NULL); + + return (gchar**) g_ptr_array_free (dirs, FALSE); +-- +2.21.0 + -- cgit v1.3 From 9bc1de31348858278067a45c5965328677ee74d8 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Fri, 31 May 2019 10:27:34 -0400 Subject: gnu: Go 1.4: Fix typo. * gnu/packages/golang.scm (go-1.4): Fix typo in comment. --- gnu/packages/golang.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 611c848bd..18013a445 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -62,7 +62,7 @@ (define-public go-1.4 (package (name "go") - ;; The C-langauge bootstrap of Go: + ;; The C-language bootstrap of Go: ;; https://golang.org/doc/install/source#go14 (version "1.4-bootstrap-20171003") (source (origin -- cgit v1.3 From f6b0e1f8ff6a6459d7d39238ced165f4caa988fe Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Thu, 4 Apr 2019 17:36:49 +0100 Subject: services: Add getmail. Getmail is a mail retriever written in Python, this commit adds a service-type to run getmail. I'm looking at this, as it's a convinient way of getting mailing list messages in to Patchwork. I initially tried putting this in the (gnu services mail) module, but due to also trying to use the define-configuration pattern, it conflicted with the dovecot service. * gnu/services/getmail.scm: New file. * gnu/local.mk: Add it. * gnu/tests/mail.scm (%getmail-os, %test-getmail): New variables. (run-getmail-test): New procedure. --- doc/guix.texi | 291 ++++++++++++++++++++++++++++++++++++ gnu/local.mk | 1 + gnu/services/getmail.scm | 380 +++++++++++++++++++++++++++++++++++++++++++++++ gnu/tests/mail.scm | 178 +++++++++++++++++++++- 4 files changed, 849 insertions(+), 1 deletion(-) create mode 100644 gnu/services/getmail.scm diff --git a/doc/guix.texi b/doc/guix.texi index 340b80696..d94b1f2b1 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -16716,6 +16716,297 @@ variables. @end table @end deftp +@subsubheading Getmail service + +@cindex IMAP +@cindex POP + +@deffn {Scheme Variable} getmail-service-type +This is the type of the @uref{http://pyropus.ca/software/getmail/, Getmail} +mail retriever, whose value should be an @code{getmail-configuration}. +@end deffn + +Available @code{getmail-configuration} fields are: + +@deftypevr {@code{getmail-configuration} parameter} symbol name +A symbol to identify the getmail service. + +Defaults to @samp{"unset"}. + +@end deftypevr + +@deftypevr {@code{getmail-configuration} parameter} package package +The getmail package to use. + +@end deftypevr + +@deftypevr {@code{getmail-configuration} parameter} string user +The user to run getmail as. + +Defaults to @samp{"getmail"}. + +@end deftypevr + +@deftypevr {@code{getmail-configuration} parameter} string group +The group to run getmail as. + +Defaults to @samp{"getmail"}. + +@end deftypevr + +@deftypevr {@code{getmail-configuration} parameter} string directory +The getmail directory to use. + +Defaults to @samp{"/var/lib/getmail/default"}. + +@end deftypevr + +@deftypevr {@code{getmail-configuration} parameter} getmail-configuration-file rcfile +The getmail configuration file to use. + +Available @code{getmail-configuration-file} fields are: + +@deftypevr {@code{getmail-configuration-file} parameter} getmail-retriever-configuration retriever +What mail account to retrieve mail from, and how to access that account. + +Available @code{getmail-retriever-configuration} fields are: + +@deftypevr {@code{getmail-retriever-configuration} parameter} string type +The type of mail retriever to use. Valid values include @samp{passwd} +and @samp{static}. + +Defaults to @samp{"SimpleIMAPSSLRetriever"}. + +@end deftypevr + +@deftypevr {@code{getmail-retriever-configuration} parameter} string server +Space separated list of arguments to the userdb driver. + +Defaults to @samp{unset}. + +@end deftypevr + +@deftypevr {@code{getmail-retriever-configuration} parameter} string username +Space separated list of arguments to the userdb driver. + +Defaults to @samp{unset}. + +@end deftypevr + +@deftypevr {@code{getmail-retriever-configuration} parameter} non-negative-integer port +Space separated list of arguments to the userdb driver. + +Defaults to @samp{#f}. + +@end deftypevr + +@deftypevr {@code{getmail-retriever-configuration} parameter} string password +Override fields from passwd. + +Defaults to @samp{""}. + +@end deftypevr + +@deftypevr {@code{getmail-retriever-configuration} parameter} list password-command +Override fields from passwd. + +Defaults to @samp{()}. + +@end deftypevr + +@deftypevr {@code{getmail-retriever-configuration} parameter} string keyfile +PEM-formatted key file to use for the TLS negotiation + +Defaults to @samp{""}. + +@end deftypevr + +@deftypevr {@code{getmail-retriever-configuration} parameter} string certfile +PEM-formatted certificate file to use for the TLS negotiation + +Defaults to @samp{""}. + +@end deftypevr + +@deftypevr {@code{getmail-retriever-configuration} parameter} string ca-certs +CA certificates to use + +Defaults to @samp{""}. + +@end deftypevr + +@deftypevr {@code{getmail-retriever-configuration} parameter} parameter-alist extra-parameters +Extra retriever parameters + +Defaults to @samp{()}. + +@end deftypevr + +@end deftypevr + +@deftypevr {@code{getmail-configuration-file} parameter} getmail-destination-configuration destination +What to do with retrieved messages. + +Available @code{getmail-destination-configuration} fields are: + +@deftypevr {@code{getmail-destination-configuration} parameter} string type +The type of mail destination. Valid values include @samp{Maildir}, +@samp{Mboxrd} and @samp{MDA_external}. + +Defaults to @samp{unset}. + +@end deftypevr + +@deftypevr {@code{getmail-destination-configuration} parameter} string-or-filelike path +The path option for the mail destination. The behaviour depends on the +chosen type. + +Defaults to @samp{""}. + +@end deftypevr + +@deftypevr {@code{getmail-destination-configuration} parameter} parameter-alist extra-parameters +Extra destination parameters + +Defaults to @samp{()}. + +@end deftypevr + +@end deftypevr + +@deftypevr {@code{getmail-configuration-file} parameter} getmail-options-configuration options +Configure getmail. + +Available @code{getmail-options-configuration} fields are: + +@deftypevr {@code{getmail-options-configuration} parameter} non-negative-integer verbose +If set to @samp{0}, getmail will only print warnings and errors. A +value of @samp{1} means that messages will be printed about retrieving +and deleting messages. If set to @samp{2}, getmail will print messages +about each of it's actions. + +Defaults to @samp{1}. + +@end deftypevr + +@deftypevr {@code{getmail-options-configuration} parameter} boolean read-all +If true, getmail will retrieve all available messages. Otherwise it +will only retrieve messages it hasn't seen previously. + +Defaults to @samp{#t}. + +@end deftypevr + +@deftypevr {@code{getmail-options-configuration} parameter} boolean delete +If set to true, messages will be deleted from the server after +retrieving and successfully delivering them. Otherwise, messages will +be left on the server. + +Defaults to @samp{#f}. + +@end deftypevr + +@deftypevr {@code{getmail-options-configuration} parameter} non-negative-integer delete-after +Getmail will delete messages this number of days after seeing them, if +they have not been delivered. This means messages will be left on the +server this number of days after delivering them. A value of @samp{0} +disabled this feature. + +Defaults to @samp{0}. + +@end deftypevr + +@deftypevr {@code{getmail-options-configuration} parameter} non-negative-integer delete-bigger-than +Delete messages larger than this of bytes after retrieving them, even if +the delete and delete-after options are disabled. A value of @samp{0} +disables this feature. + +Defaults to @samp{0}. + +@end deftypevr + +@deftypevr {@code{getmail-options-configuration} parameter} non-negative-integer max-bytes-per-session +Retrieve messages totalling up to this number of bytes before closing +the session with the server. A value of @samp{0} disables this feature. + +Defaults to @samp{0}. + +@end deftypevr + +@deftypevr {@code{getmail-options-configuration} parameter} non-negative-integer max-message-size +Don't retrieve messages larger than this number of bytes. A value of +@samp{0} disables this feature. + +Defaults to @samp{0}. + +@end deftypevr + +@deftypevr {@code{getmail-options-configuration} parameter} boolean delivered-to +If true, getmail will add a Delivered-To header to messages. + +Defaults to @samp{#t}. + +@end deftypevr + +@deftypevr {@code{getmail-options-configuration} parameter} boolean received +If set, getmail adds a Received header to the messages. + +Defaults to @samp{#t}. + +@end deftypevr + +@deftypevr {@code{getmail-options-configuration} parameter} string message-log +Getmail will record a log of its actions to the named file. A value of +@samp{""} disables this feature. + +Defaults to @samp{""}. + +@end deftypevr + +@deftypevr {@code{getmail-options-configuration} parameter} boolean message-log-syslog +If true, getmail will record a log of its actions using the system +logger. + +Defaults to @samp{#t}. + +@end deftypevr + +@deftypevr {@code{getmail-options-configuration} parameter} boolean message-log-verbose +If true, getmail will log information about messages not retrieved and +the reason for not retrieving them, as well as starting and ending +information lines. + +Defaults to @samp{#t}. + +@end deftypevr + +@deftypevr {@code{getmail-options-configuration} parameter} parameter-alist extra-parameters +Extra options to include. + +Defaults to @samp{()}. + +@end deftypevr + +@end deftypevr + +@end deftypevr + +@deftypevr {@code{getmail-configuration} parameter} list idle +A list of mailboxes that getmail should wait on the server for new mail +notifications. This depends on the server supporting the IDLE +extension. + +Defaults to @samp{()}. + +@end deftypevr + +@deftypevr {@code{getmail-configuration} parameter} list environment-variables +Environment variables to set for getmail. + +Defaults to @samp{()}. + +@end deftypevr + @subsubheading Mail Aliases Service @cindex email aliases diff --git a/gnu/local.mk b/gnu/local.mk index 55fa90f92..9b9c6e00e 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -516,6 +516,7 @@ GNU_SYSTEM_MODULES = \ %D%/services/docker.scm \ %D%/services/authentication.scm \ %D%/services/games.scm \ + %D%/services/getmail.scm \ %D%/services/kerberos.scm \ %D%/services/lirc.scm \ %D%/services/virtualization.scm \ diff --git a/gnu/services/getmail.scm b/gnu/services/getmail.scm new file mode 100644 index 000000000..b807bb3a5 --- /dev/null +++ b/gnu/services/getmail.scm @@ -0,0 +1,380 @@ +;;; GNU Guix --- Functional package management for GNU +;;; Copyright © 2019 Christopher Baines +;;; +;;; 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 . + +(define-module (gnu services getmail) + #:use-module (gnu services) + #:use-module (gnu services base) + #:use-module (gnu services configuration) + #:use-module (gnu services shepherd) + #:use-module (gnu system pam) + #:use-module (gnu system shadow) + #:use-module (gnu packages mail) + #:use-module (gnu packages admin) + #:use-module (gnu packages tls) + #:use-module (guix records) + #:use-module (guix store) + #:use-module (guix packages) + #:use-module (guix gexp) + #:use-module (ice-9 match) + #:use-module (ice-9 format) + #:use-module (srfi srfi-1) + #:export (getmail-retriever-configuration + getmail-retriever-configuration-extra-parameters + getmail-destination-configuration + getmail-options-configuration + getmail-configuration-file + getmail-configuration + getmail-service-type)) + +;;; Commentary: +;;; +;;; Service for the getmail mail retriever. +;;; +;;; Code: + +(define (uglify-field-name field-name) + (let ((str (symbol->string field-name))) + (string-join (string-split (if (string-suffix? "?" str) + (substring str 0 (1- (string-length str))) + str) + #\-) + "_"))) + +(define (serialize-field field-name val) + #~(let ((val '#$val)) + (format #f "~a = ~a\n" + #$(uglify-field-name field-name) + (cond + ((list? val) + (string-append + "(" + (string-concatenate + (map (lambda (list-val) + (format #f "\"~a\", " list-val)) + val)) + ")")) + (else + val))))) + +(define (serialize-string field-name val) + (if (string=? val "") + "" + (serialize-field field-name val))) + +(define (string-or-filelike? val) + (or (string? val) + (file-like? val))) +(define (serialize-string-or-filelike field-name val) + (if (equal? val "") + "" + (serialize-field field-name val))) + +(define (serialize-boolean field-name val) + (serialize-field field-name (if val "true" "false"))) + +(define (non-negative-integer? val) + (and (exact-integer? val) (not (negative? val)))) +(define (serialize-non-negative-integer field-name val) + (serialize-field field-name val)) + +(define serialize-list serialize-field) + +(define parameter-alist? list?) +(define (serialize-parameter-alist field-name val) + #~(string-append + #$@(map (match-lambda + ((key . value) + (serialize-field key value))) + val))) + +(define (serialize-getmail-retriever-configuration field-name val) + (serialize-configuration val getmail-retriever-configuration-fields)) + +(define-configuration getmail-retriever-configuration + (type + (string "SimpleIMAPSSLRetriever") + "The type of mail retriever to use. Valid values include +@samp{passwd} and @samp{static}.") + (server + (string 'unset) + "Space separated list of arguments to the userdb driver.") + (username + (string 'unset) + "Space separated list of arguments to the userdb driver.") + (port + (non-negative-integer #f) + "Space separated list of arguments to the userdb driver.") + (password + (string "") + "Override fields from passwd.") + (password-command + (list '()) + "Override fields from passwd.") + (keyfile + (string "") + "PEM-formatted key file to use for the TLS negotiation") + (certfile + (string "") + "PEM-formatted certificate file to use for the TLS negotiation") + (ca-certs + (string "") + "CA certificates to use") + (extra-parameters + (parameter-alist '()) + "Extra retriever parameters")) + +(define (serialize-getmail-destination-configuration field-name val) + (serialize-configuration val getmail-destination-configuration-fields)) + +(define-configuration getmail-destination-configuration + (type + (string 'unset) + "The type of mail destination. Valid values include @samp{Maildir}, +@samp{Mboxrd} and @samp{MDA_external}.") + (path + (string-or-filelike "") + "The path option for the mail destination. The behaviour depends on the +chosen type.") + (extra-parameters + (parameter-alist '()) + "Extra destination parameters")) + +(define (serialize-getmail-options-configuration field-name val) + (serialize-configuration val getmail-options-configuration-fields)) + +(define-configuration getmail-options-configuration + (verbose + (non-negative-integer 1) + "If set to @samp{0}, getmail will only print warnings and errors. A value +of @samp{1} means that messages will be printed about retrieving and deleting +messages. If set to @samp{2}, getmail will print messages about each of it's +actions.") + (read-all + (boolean #t) + "If true, getmail will retrieve all available messages. Otherwise it will +only retrieve messages it hasn't seen previously.") + (delete + (boolean #f) + "If set to true, messages will be deleted from the server after retrieving +and successfully delivering them. Otherwise, messages will be left on the +server.") + (delete-after + (non-negative-integer 0) + "Getmail will delete messages this number of days after seeing them, if +they have not been delivered. This means messages will be left on the server +this number of days after delivering them. A value of @samp{0} disabled this +feature.") + (delete-bigger-than + (non-negative-integer 0) + "Delete messages larger than this of bytes after retrieving them, even if +the delete and delete-after options are disabled. A value of @samp{0} +disables this feature.") + (max-bytes-per-session + (non-negative-integer 0) + "Retrieve messages totalling up to this number of bytes before closing the +session with the server. A value of @samp{0} disables this feature.") + (max-message-size + (non-negative-integer 0) + "Don't retrieve messages larger than this number of bytes. A value of +@samp{0} disables this feature.") + (delivered-to + (boolean #t) + "If true, getmail will add a Delivered-To header to messages.") + (received + (boolean #t) + "If set, getmail adds a Received header to the messages.") + (message-log + (string "") + "Getmail will record a log of its actions to the named file. A value of +@samp{\"\"} disables this feature.") + (message-log-syslog + (boolean #t) + "If true, getmail will record a log of its actions using the system +logger.") + (message-log-verbose + (boolean #t) + "If true, getmail will log information about messages not retrieved and the +reason for not retrieving them, as well as starting and ending information +lines.") + (extra-parameters + (parameter-alist '()) + "Extra options to include.")) + +(define (serialize-getmail-configuration-file field-name val) + (match val + (($ location + retriever destination options) + #~(string-append + "[retriever]\n" + #$(serialize-getmail-retriever-configuration #f retriever) + "\n[destination]\n" + #$(serialize-getmail-destination-configuration #f destination) + "\n[options]\n" + #$(serialize-getmail-options-configuration #f options))))) + +(define-configuration getmail-configuration-file + (retriever + (getmail-retriever-configuration (getmail-retriever-configuration)) + "What mail account to retrieve mail from, and how to access that account.") + (destination + (getmail-destination-configuration (getmail-destination-configuration)) + "What to do with retrieved messages.") + (options + (getmail-options-configuration (getmail-options-configuration)) + "Configure getmail.")) + +(define (serialize-symbol field-name val) "") +(define (serialize-getmail-configuration field-name val) "") + +(define-configuration getmail-configuration + (name + (symbol "unset") + "A symbol to identify the getmail service.") + (package + (package getmail) + "The getmail package to use.") + (user + (string "getmail") + "The user to run getmail as.") + (group + (string "getmail") + "The group to run getmail as.") + (directory + (string "/var/lib/getmail/default") + "The getmail directory to use.") + (rcfile + (getmail-configuration-file (getmail-configuration-file)) + "The getmail configuration file to use.") + (idle + (list '()) + "A list of mailboxes that getmail should wait on the server for new mail +notifications. This depends on the server supporting the IDLE extension.") + (environment-variables + (list '()) + "Environment variables to set for getmail.")) + +(define (generate-getmail-documentation) + (generate-documentation + `((getmail-configuration + ,getmail-configuration-fields + (rcfile getmail-configuration-file)) + (getmail-configuration-file + ,getmail-configuration-file-fields + (retriever getmail-retriever-configuration) + (destination getmail-destination-configuration) + (options getmail-options-configuration)) + (getmail-retriever-configuration ,getmail-retriever-configuration-fields) + (getmail-destination-configuration ,getmail-destination-configuration-fields) + (getmail-options-configuration ,getmail-options-configuration-fields)) + 'getmail-configuration)) + +(define-gexp-compiler (getmail-configuration-file-compiler + (rcfile ) system target) + (gexp->derivation + "getmailrc" + #~(call-with-output-file #$output + (lambda (port) + (display #$(serialize-getmail-configuration-file #f rcfile) + port))) + #:system system + #:target target)) + +(define (getmail-accounts configs) + (let ((users (delete-duplicates + (map getmail-configuration-user + configs))) + (groups (delete-duplicates + (map getmail-configuration-group + configs)))) + (append + (map (lambda (group) + (user-group + (name group) + (system? #t))) + groups) + (map (lambda (user) + (user-account + (name user) + (group (getmail-configuration-group + (find (lambda (config) + (and + (string=? user (getmail-configuration-user config)) + (getmail-configuration-group config))) + configs))) + (system? #t) + (comment "Getmail user") + (home-directory "/var/empty") + (shell (file-append shadow "/sbin/nologin")))) + users)))) + +(define (getmail-activation configs) + "Return the activation GEXP for CONFIGS." + (with-imported-modules '((guix build utils)) + #~(begin + (use-modules (guix build utils)) + #$@(map + (lambda (config) + #~(let* ((pw (getpw #$(getmail-configuration-user config))) + (uid (passwd:uid pw)) + (gid (passwd:gid pw)) + (getmaildir #$(getmail-configuration-directory config))) + (mkdir-p getmaildir) + (chown getmaildir uid gid))) + configs)))) + +(define (getmail-shepherd-services configs) + "Return a list of for CONFIGS." + (map (match-lambda + (($ location name package + user group directory rcfile idle + environment-variables) + (shepherd-service + (documentation "Run getmail.") + (provision (list (symbol-append 'getmail- name))) + (requirement '(networking)) + (start #~(make-forkexec-constructor + `(#$(file-append package "/bin/getmail") + ,(string-append "--getmaildir=" #$directory) + #$@(map (lambda (idle) + (string-append "--idle=" idle)) + idle) + ,(string-append "--rcfile=" #$rcfile)) + #:user #$user + #:group #$group + #:environment-variables + (list #$@environment-variables) + #:log-file + #$(string-append "/var/log/getmail-" + (symbol->string name))))))) + configs)) + +(define getmail-service-type + (service-type + (name 'getmail) + (extensions + (list (service-extension shepherd-root-service-type + getmail-shepherd-services) + (service-extension activation-service-type + getmail-activation) + (service-extension account-service-type + getmail-accounts))) + (description + "Run @command{getmail}, a mail retriever program.") + (default-value '()) + (compose concatenate) + (extend append))) diff --git a/gnu/tests/mail.scm b/gnu/tests/mail.scm index 33aa4d343..10e5be71d 100644 --- a/gnu/tests/mail.scm +++ b/gnu/tests/mail.scm @@ -4,6 +4,7 @@ ;;; Copyright © 2017 Ludovic Courtès ;;; Copyright © 2018 Oleg Pykhalov ;;; Copyright © 2018 Clément Lassieur +;;; Copyright © 2019 Christopher Baines ;;; ;;; This file is part of GNU Guix. ;;; @@ -25,6 +26,7 @@ #:use-module (gnu system) #:use-module (gnu system vm) #:use-module (gnu services) + #:use-module (gnu services getmail) #:use-module (gnu services mail) #:use-module (gnu services networking) #:use-module (guix gexp) @@ -32,7 +34,8 @@ #:use-module (ice-9 ftw) #:export (%test-opensmtpd %test-exim - %test-dovecot)) + %test-dovecot + %test-getmail)) (define %opensmtpd-os (simple-operating-system @@ -394,3 +397,176 @@ Subject: Hello Nice to meet you!") (name "dovecot") (description "Connect to a running Dovecot server.") (value (run-dovecot-test)))) + +(define %getmail-os + (simple-operating-system + (service dhcp-client-service-type) + (service dovecot-service-type + (dovecot-configuration + (disable-plaintext-auth? #f) + (ssl? "no") + (auth-mechanisms '("anonymous" "plain")) + (auth-anonymous-username "alice") + (mail-location + (string-append "maildir:~/Maildir" + ":INBOX=~/Maildir/INBOX" + ":LAYOUT=fs")))) + (service getmail-service-type + (list + (getmail-configuration + (name 'test) + (user "alice") + (directory "/var/lib/getmail/alice") + (idle '("TESTBOX")) + (rcfile + (getmail-configuration-file + (retriever + (getmail-retriever-configuration + (type "SimpleIMAPRetriever") + (server "localhost") + (username "alice") + (port 143) + (extra-parameters + '((password . "testpass") + (mailboxes . ("TESTBOX")))))) + (destination + (getmail-destination-configuration + (type "Maildir") + (path "/home/alice/TestMaildir/"))) + (options + (getmail-options-configuration + (read-all #f)))))))))) + +(define (run-getmail-test) + "Return a test of an OS running Getmail service." + (define vm + (virtual-machine + (operating-system (marionette-operating-system + %getmail-os + #:imported-modules '((gnu services herd)))) + (port-forwardings '((8143 . 143))))) + + (define test + (with-imported-modules '((gnu build marionette)) + #~(begin + (use-modules (gnu build marionette) + (ice-9 iconv) + (ice-9 rdelim) + (rnrs base) + (rnrs bytevectors) + (srfi srfi-64)) + + (define marionette + (make-marionette '(#$vm))) + + (define* (message-length message #:key (encoding "iso-8859-1")) + (bytevector-length (string->bytevector message encoding))) + + (define message "From: test@example.com\n\ +Subject: Hello Nice to meet you!") + + (mkdir #$output) + (chdir #$output) + + (test-begin "getmail") + + ;; Wait for dovecot to be up and running. + (test-assert "dovecot running" + (marionette-eval + '(begin + (use-modules (gnu services herd)) + (start-service 'dovecot)) + marionette)) + + (test-assert "set password for alice" + (marionette-eval + '(system "echo -e \"testpass\ntestpass\" | passwd alice") + marionette)) + + ;; Wait for getmail to be up and running. + (test-assert "getmail-test running" + (marionette-eval + '(let* ((pw (getpw "alice")) + (uid (passwd:uid pw)) + (gid (passwd:gid pw))) + (use-modules (gnu services herd)) + + (for-each + (lambda (dir) + (mkdir dir) + (chown dir uid gid)) + '("/home/alice/TestMaildir" + "/home/alice/TestMaildir/cur" + "/home/alice/TestMaildir/new" + "/home/alice/TestMaildir/tmp" + "/home/alice/TestMaildir/TESTBOX" + "/home/alice/TestMaildir/TESTBOX/cur" + "/home/alice/TestMaildir/TESTBOX/new" + "/home/alice/TestMaildir/TESTBOX/tmp")) + + (start-service 'getmail-test)) + marionette)) + + ;; Check Dovecot service's PID. + (test-assert "service process id" + (let ((pid + (number->string (wait-for-file "/var/run/dovecot/master.pid" + marionette)))) + (marionette-eval `(file-exists? (string-append "/proc/" ,pid)) + marionette))) + + (test-assert "accept an email" + (let ((imap (socket AF_INET SOCK_STREAM 0)) + (addr (make-socket-address AF_INET INADDR_LOOPBACK 8143))) + (connect imap addr) + ;; Be greeted. + (read-line imap) ;OK + ;; Authenticate + (write-line "a AUTHENTICATE ANONYMOUS" imap) + (read-line imap) ;+ + (write-line "c2lyaGM=" imap) + (read-line imap) ;OK + ;; Create a TESTBOX mailbox + (write-line "a CREATE TESTBOX" imap) + (read-line imap) ;OK + ;; Append a message to a TESTBOX mailbox + (write-line (format #f "a APPEND TESTBOX {~a}" + (number->string (message-length message))) + imap) + (read-line imap) ;+ + (write-line message imap) + (read-line imap) ;OK + ;; Logout + (write-line "a LOGOUT" imap) + (close imap) + #t)) + + (sleep 1) + + (test-assert "mail arrived" + (string-contains + (marionette-eval + '(begin + (use-modules (ice-9 ftw) + (ice-9 match)) + (let ((TESTBOX/new "/home/alice/TestMaildir/new/")) + (match (scandir TESTBOX/new) + (("." ".." message-file) + (call-with-input-file + (string-append TESTBOX/new message-file) + get-string-all))))) + marionette) + message)) + + (test-end) + (exit (= (test-runner-fail-count (test-runner-current)) 0))))) + + (gexp->derivation "getmail-test" test)) + +(define %test-getmail + (system-test + (name "getmail") + (description "Connect to a running Getmail server.") + (value (run-getmail-test)))) + +%getmail-os -- cgit v1.3 From 4764c6cc4671c06a2dd6be41b4b512fd80fa759a Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Fri, 3 May 2019 19:55:29 +0100 Subject: gnu: Add patchwork. * gnu/packages/patchutils.scm (patchwork): New variable. --- gnu/packages/patchutils.scm | 167 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 167 insertions(+) diff --git a/gnu/packages/patchutils.scm b/gnu/packages/patchutils.scm index f6197b98e..687864c00 100644 --- a/gnu/packages/patchutils.scm +++ b/gnu/packages/patchutils.scm @@ -2,6 +2,7 @@ ;;; Copyright © 2014, 2018 Eric Bavier ;;; Copyright © 2015, 2018 Leo Famulari ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice +;;; Copyright © 2019 Christopher Baines ;;; ;;; This file is part of GNU Guix. ;;; @@ -31,6 +32,8 @@ #:use-module (gnu packages base) #:use-module (gnu packages bash) #:use-module (gnu packages check) + #:use-module (gnu packages databases) + #:use-module (gnu packages django) #:use-module (gnu packages file) #:use-module (gnu packages gawk) #:use-module (gnu packages gettext) @@ -300,3 +303,167 @@ directories, and has support for many popular version control systems. Meld helps you review code changes and understand patches. It might even help you to figure out what is going on in that merge you keep avoiding.") (license gpl2))) + +(define-public patchwork + (package + (name "patchwork") + (version "2.1.2") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/getpatchwork/patchwork.git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "06ng5pv6744w98zkyfm0ldkmpdgnsql3gbbbh6awq61sr2ndr3qw")))) + (build-system python-build-system) + (arguments + `(;; TODO: Tests require a running database + #:tests? #f + #:phases + (modify-phases %standard-phases + (delete 'configure) + (delete 'build) + (add-after 'unpack 'replace-wsgi.py + (lambda* (#:key inputs outputs #:allow-other-keys) + (delete-file "patchwork/wsgi.py") + (call-with-output-file "patchwork/wsgi.py" + (lambda (port) + ;; Embed the PYTHONPATH containing the dependencies, as well + ;; as the python modules in this package in the wsgi.py file, + ;; as this will ensure they are available at runtime. + (define pythonpath + (string-append (getenv "PYTHONPATH") + ":" + (site-packages inputs outputs))) + (display + (string-append " +import os, sys + +sys.path.extend('" pythonpath "'.split(':')) + +from django.core.wsgi import get_wsgi_application + +# By default, assume that patchwork is running as a Guix service, which +# provides the settings as the 'guix.patchwork.settings' Python module. +# +# When using httpd, it's hard to set environment variables, so rely on the +# default set here. +os.environ['DJANGO_SETTINGS_MODULE'] = os.getenv( + 'DJANGO_SETTINGS_MODULE', + 'guix.patchwork.settings' # default +) + +application = get_wsgi_application()\n") port))))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (setenv "DJANGO_SETTINGS_MODULE" "patchwork.settings.dev") + (invoke "python" "-Wonce" "./manage.py" "test" "--noinput")) + #t)) + (replace 'install + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out")) + (out-site-packages (site-packages inputs outputs))) + (for-each (lambda (directory) + (copy-recursively + directory + (string-append out-site-packages directory))) + '(;; Contains the python code + "patchwork" + ;; Contains the templates for the generated HTML + "templates")) + (delete-file-recursively + (string-append out-site-packages "patchwork/tests")) + + ;; Install patchwork related tools + (for-each (lambda (file) + (install-file file (string-append out "/bin"))) + (list + (string-append out-site-packages + "patchwork/bin/pwclient") + (string-append out-site-packages + "patchwork/bin/parsemail.sh") + (string-append out-site-packages + "patchwork/bin/parsemail-batch.sh"))) + + ;; Delete the symlink to pwclient, and replace it with the + ;; actual file, as this can cause issues when serving the file + ;; from a webserver. + (let ((template-pwclient (string-append + out-site-packages + "patchwork/templates/patchwork/pwclient"))) + (delete-file template-pwclient) + (copy-file (string-append out-site-packages + "patchwork/bin/pwclient") + template-pwclient)) + + ;; Collect the static assets, this includes JavaScript, CSS and + ;; fonts. This is a standard Django process when running a + ;; Django application for regular use, and includes assets for + ;; dependencies like the admin site from Django. + ;; + ;; The intent here is that you can serve files from this + ;; directory through a webserver, which is recommended when + ;; running Django applications. + (let ((static-root + (string-append out "/share/patchwork/htdocs"))) + (mkdir-p static-root) + (copy-file "patchwork/settings/production.example.py" + "patchwork/settings/assets.py") + (setenv "DJANGO_SECRET_KEY" "dummyvalue") + (setenv "DJANGO_SETTINGS_MODULE" "patchwork.settings.assets") + (setenv "STATIC_ROOT" static-root) + (invoke "./manage.py" "collectstatic" "--no-input")) + + ;; The lib directory includes example configuration files that + ;; may be useful when deploying patchwork. + (copy-recursively "lib" + (string-append + out "/share/doc/" ,name "-" ,version))) + #t)) + ;; The hasher script is used from the post-receive.hook + (add-after 'install 'install-hasher + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (out-site-packages (site-packages inputs outputs)) + (out-hasher.py (string-append out-site-packages + "/patchwork/hasher.py"))) + (chmod out-hasher.py #o555) + (symlink out-hasher.py (string-append out "/bin/hasher"))) + #t)) + ;; Create a patchwork specific version of Django's command line admin + ;; utility. + (add-after 'install 'install-patchwork-admin + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out"))) + (mkdir-p (string-append out "/bin")) + (call-with-output-file (string-append out "/bin/patchwork-admin") + (lambda (port) + (simple-format port "#!~A +import os, sys + +if __name__ == \"__main__\": + from django.core.management import execute_from_command_line + + execute_from_command_line(sys.argv)" (which "python")))) + (chmod (string-append out "/bin/patchwork-admin") #o555)) + #t))))) + (inputs + `(("python-wrapper" ,python-wrapper))) + (propagated-inputs + `(("python-django" ,python-django) + ;; TODO: Make this configurable + ("python-psycopg2" ,python-psycopg2) + ("python-mysqlclient" ,python-mysqlclient) + ("python-django-filter" ,python-django-filter) + ("python-djangorestframework" ,python-djangorestframework) + ("python-django-debug-toolbar" ,python-django-debug-toolbar))) + (synopsis "Web based patch tracking system") + (description + "Patchwork is a patch tracking system. It takes in emails containing +patches, and displays the patches along with comments and state information. +Users can login allowing them to change the state of patches.") + (home-page "http://jk.ozlabs.org/projects/patchwork/") + (license gpl2+))) -- cgit v1.3 From 2177d9222f8c228fe5cd4e9c98d96f97e9601b86 Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Fri, 3 May 2019 19:55:35 +0100 Subject: services: Add patchwork. * gnu/service/web.scm ( , ): New record types. (patchwork-virtualhost): New procedure. (patchwork-service-type): New variable. * gnu/tests/web.scm (%test-patchwork): New variable. * doc/guix.text (Web Services): Document it. --- doc/guix.texi | 174 ++++++++++++++++++++++++ gnu/services/web.scm | 368 ++++++++++++++++++++++++++++++++++++++++++++++++++- gnu/tests/web.scm | 164 ++++++++++++++++++++++- 3 files changed, 702 insertions(+), 4 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index d94b1f2b1..786788bad 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -19389,6 +19389,180 @@ Additional arguments to pass to the @command{varnishd} process. @end table @end deftp +@subsubheading Patchwork +@cindex Patchwork +Patchwork is a patch tracking system. It can collect patches sent to a +mailing list, and display them in a web interface. + +@defvr {Scheme Variable} patchwork-service-type +Service type for Patchwork. +@end defvr + +The following example is an example of a minimal service for Patchwork, for +the @code{patchwork.example.com} domain. + +@example +(service patchwork-service-type + (patchwork-configuration + (domain "patchwork.example.com") + (settings-module + (patchwork-settings-module + (allowed-hosts (list domain)) + (default-from-email "patchwork@@patchwork.example.com"))) + (getmail-retriever-config + (getmail-retriever-configuration + (type "SimpleIMAPSSLRetriever") + (server "imap.example.com") + (port 993) + (username "patchwork") + (password-command + (list (file-append coreutils "/bin/cat") + "/etc/getmail-patchwork-imap-password")) + (extra-parameters + '((mailboxes . ("Patches")))))))) + +@end example + +There are three records for configuring the Patchwork service. The +@code{} relates to the configuration for Patchwork +within the HTTPD service. + +The @code{settings-module} field within the @code{} +record can be populated with the @code{} record, +which describes a settings module that is generated within the Guix store. + +For the @code{database-configuration} field within the +@code{}, the +@code{} must be used. + +@deftp {Data Type} patchwork-configuration +Data type representing the Patchwork service configuration. This type has the +following parameters: + +@table @asis +@item @code{patchwork} (default: @code{patchwork}) +The Patchwork package to use. + +@item @code{domain} +The domain to use for Patchwork, this is used in the HTTPD service virtual +host. + +@item @code{settings-module} +The settings module to use for Patchwork. As a Django application, Patchwork +is configured with a Python module containing the settings. This can either be +an instance of the @code{} record, any other record +that represents the settings in the store, or a directory outside of the +store. + +@item @code{static-path} (default: @code{"/static/"}) +The path under which the HTTPD service should serve the static files. + +@item @code{getmail-retriever-config} +The getmail-retriever-configuration record value to use with +Patchwork. Getmail will be configured with this value, the messages will be +delivered to Patchwork. + +@end table +@end deftp + +@deftp {Data Type} patchwork-settings-module +Data type representing a settings module for Patchwork. Some of these +settings relate directly to Patchwork, but others relate to Django, the web +framework used by Patchwork, or the Django Rest Framework library. This type +has the following parameters: + +@table @asis +@item @code{database-configuration} (default: @code{(patchwork-database-configuration)}) +The database connection settings used for Patchwork. See the +@code{} record type for more information. + +@item @code{secret-key-file} (default: @code{"/etc/patchwork/django-secret-key"}) +Patchwork, as a Django web application uses a secret key for cryptographically +signing values. This file should contain a unique unpredictable value. + +If this file does not exist, it will be created and populated with a random +value by the patchwork-setup shepherd service. + +This setting relates to Django. + +@item @code{allowed-hosts} +A list of valid hosts for this Patchwork service. This should at least include +the domain specified in the @code{} record. + +This is a Django setting. + +@item @code{default-from-email} +The email address from which Patchwork should send email by default. + +This is a Patchwork setting. + +@item @code{static-url} (default: @code{#f}) +The URL to use when serving static assets. It can be part of a URL, or a full +URL, but must end in a @code{/}. + +If the default value is used, the @code{static-path} value from the +@code{} record will be used. + +This is a Django setting. + +@item @code{admins} (default: @code{'()}) +Email addresses to send the details of errors that occur. Each value should +be a list containing two elements, the name and then the email address. + +This is a Django setting. + +@item @code{debug?} (default: @code{#f}) +Whether to run Patchwork in debug mode. If set to @code{#t}, detailed error +messages will be shown. + +This is a Django setting. + +@item @code{enable-rest-api?} (default: @code{#t}) +Whether to enable the Patchwork REST API. + +This is a Patchwork setting. + +@item @code{enable-xmlrpc?} (default: @code{#t}) +Whether to enable the XML RPC API. + +This is a Patchwork setting. + +@item @code{force-https-links?} (default: @code{#t}) +Whether to use HTTPS links on Patchwork pages. + +This is a Patchwork setting. + +@item @code{extra-settings} (default: @code{""}) +Extra code to place at the end of the Patchwork settings module. + +@end table +@end deftp + +@deftp {Data Type} patchwork-database-configuration +Data type representing the database configuration for Patchwork. + +@table @asis +@item @code{engine} (default: @code{"django.db.backends.postgresql_psycopg2"}) +The database engine to use. + +@item @code{name} (default: @code{"patchwork"}) +The name of the database to use. + +@item @code{user} (default: @code{"httpd"}) +The user to connect to the database as. + +@item @code{password} (default: @code{""}) +The password to use when connecting to the database. + +@item @code{host} (default: @code{""}) +The host to make the database connection to. + +@item @code{port} (default: @code{""}) +The port on which to connect to the database. + +@end table +@end deftp + @subsubheading FastCGI @cindex fastcgi @cindex fcgiwrap diff --git a/gnu/services/web.scm b/gnu/services/web.scm index 84294db53..35efddb0a 100644 --- a/gnu/services/web.scm +++ b/gnu/services/web.scm @@ -7,7 +7,7 @@ ;;; Copyright © 2017 nee ;;; Copyright © 2017, 2018 Clément Lassieur ;;; Copyright © 2018 Pierre-Antoine Rouby -;;; Copyright © 2017 Christopher Baines +;;; Copyright © 2017, 2018, 2019 Christopher Baines ;;; Copyright © 2018 Marius Bakke ;;; ;;; This file is part of GNU Guix. @@ -29,14 +29,23 @@ #:use-module (gnu services) #:use-module (gnu services shepherd) #:use-module (gnu services admin) + #:use-module (gnu services getmail) + #:use-module (gnu services mail) #:use-module (gnu system pam) #:use-module (gnu system shadow) #:use-module (gnu packages admin) + #:use-module (gnu packages databases) #:use-module (gnu packages web) + #:use-module (gnu packages patchutils) #:use-module (gnu packages php) + #:use-module (gnu packages python) + #:use-module (gnu packages gnupg) + #:use-module (gnu packages guile) #:use-module (gnu packages logging) + #:use-module (guix packages) #:use-module (guix records) #:use-module (guix modules) + #:use-module (guix utils) #:use-module (guix gexp) #:use-module ((guix store) #:select (text-file)) #:use-module ((guix utils) #:select (version-major)) @@ -210,7 +219,42 @@ varnish-configuration-parameters varnish-configuration-extra-options - varnish-service-type)) + varnish-service-type + + + patchwork-database-configuration + patchwork-database-configuration? + patchwork-database-configuration-engine + patchwork-database-configuration-name + patchwork-database-configuration-user + patchwork-database-configuration-password + patchwork-database-configuration-host + patchwork-database-configuration-port + + + patchwork-settings-module + patchwork-settings-module? + patchwork-settings-module-database-configuration + patchwork-settings-module-secret-key + patchwork-settings-module-allowed-hosts + patchwork-settings-module-default-from-email + patchwork-settings-module-static-url + patchwork-settings-module-admins + patchwork-settings-module-debug? + patchwork-settings-module-enable-rest-api? + patchwork-settings-module-enable-xmlrpc? + patchwork-settings-module-force-https-links? + patchwork-settings-module-extra-settings + + + patchwork-configuration + patchwork-configuration? + patchwork-configuration-patchwork + patchwork-configuration-settings-module + patchwork-configuration-domain + + patchwork-virtualhost + patchwork-service-type)) ;;; Commentary: ;;; @@ -1268,3 +1312,323 @@ files.") varnish-shepherd-service))) (default-value (varnish-configuration)))) + + +;;; +;;; Patchwork +;;; + +(define-record-type* + patchwork-database-configuration make-patchwork-database-configuration + patchwork-database-configuration? + (engine patchwork-database-configuration-engine + (default "django.db.backends.postgresql_psycopg2")) + (name patchwork-database-configuration-name + (default "patchwork")) + (user patchwork-database-configuration-user + (default "httpd")) + (password patchwork-database-configuration-password + (default "")) + (host patchwork-database-configuration-host + (default "")) + (port patchwork-database-configuration-port + (default ""))) + +(define-record-type* + patchwork-settings-module make-patchwork-settings-module + patchwork-settings-module? + (database-configuration patchwork-settings-module-database-configuration + (default (patchwork-database-configuration))) + (secret-key-file patchwork-settings-module-secret-key-file + (default "/etc/patchwork/django-secret-key")) + (allowed-hosts patchwork-settings-module-allowed-hosts) + (default-from-email patchwork-settings-module-default-from-email) + (static-url patchwork-settings-module-static-url + (default "/static/")) + (admins patchwork-settings-module-admins + (default '())) + (debug? patchwork-settings-module-debug? + (default #f)) + (enable-rest-api? patchwork-settings-module-enable-rest-api? + (default #t)) + (enable-xmlrpc? patchwork-settings-module-enable-xmlrpc? + (default #t)) + (force-https-links? patchwork-settings-module-force-https-links? + (default #t)) + (extra-settings patchwork-settings-module-extra-settings + (default ""))) + +(define-record-type* + patchwork-configuration make-patchwork-configuration + patchwork-configuration? + (patchwork patchwork-configuration-patchwork + (default patchwork)) + (domain patchwork-configuration-domain) + (settings-module patchwork-configuration-settings-module) + (static-path patchwork-configuration-static-url + (default "/static/")) + (getmail-retriever-config getmail-retriever-config)) + +;; Django uses a Python module for configuration, so this compiler generates a +;; Python module from the configuration record. +(define-gexp-compiler (patchwork-settings-module-compiler + (file ) system target) + (match file + (($ database-configuration secret-key-file + allowed-hosts default-from-email + static-url admins debug? enable-rest-api? + enable-xmlrpc? force-https-links? + extra-configuration) + (gexp->derivation + "patchwork-settings" + (with-imported-modules '((guix build utils)) + #~(let ((output #$output)) + (define (create-__init__.py filename) + (call-with-output-file filename + (lambda (port) (display "" port)))) + + (use-modules (guix build utils) + (srfi srfi-1)) + + (mkdir-p (string-append output "/guix/patchwork")) + (create-__init__.py + (string-append output "/guix/__init__.py")) + (create-__init__.py + (string-append output "/guix/patchwork/__init__.py")) + + (call-with-output-file + (string-append output "/guix/patchwork/settings.py") + (lambda (port) + (display + (string-append "from patchwork.settings.base import * + +# Configuration from Guix +with open('" #$secret-key-file "') as f: + SECRET_KEY = f.read().strip() + +ALLOWED_HOSTS = [ +" #$(string-concatenate + (map (lambda (allowed-host) + (string-append " '" allowed-host "'\n")) + allowed-hosts)) +"] + +ADMINS = [ +" #$(string-concatenate + (map (match-lambda + ((name email-address) + (string-append + "('" name "','" email-address "'),"))) + admins)) +"] + +DEBUG = " #$(if debug? "True" "False") " + +ENABLE_REST_API = " #$(if enable-xmlrpc? "True" "False") " +ENABLE_XMLRPC = " #$(if enable-xmlrpc? "True" "False") " + +FORCE_HTTPS_LINKS = " #$(if force-https-links? "True" "False") " + +DATABASES = { + 'default': { +" #$(match database-configuration + (($ + engine name user password host port) + (string-append + " 'ENGINE': '" engine "',\n" + " 'NAME': '" name "',\n" + " 'USER': '" user "',\n" + " 'PASSWORD': '" password "',\n" + " 'HOST': '" host "',\n" + " 'PORT': '" port "',\n"))) " + }, +} + +" #$(if debug? + #~(string-append "STATIC_ROOT = '" + #$(file-append patchwork "/share/patchwork/htdocs") + "'") + #~(string-append "STATIC_URL = '" #$static-url "'")) " + +STATICFILES_STORAGE = ( + 'django.contrib.staticfiles.storage.StaticFilesStorage' +) + +# Guix Extra Configuration +" #$extra-configuration " +") port))) + #t)) + #:local-build? #t)))) + +(define patchwork-virtualhost + (match-lambda + (($ patchwork domain + settings-module static-path + getmail-retriever-config) + (define wsgi.py + (file-append patchwork + (string-append + "/lib/python" + (version-major+minor + (package-version python)) + "/site-packages/patchwork/wsgi.py"))) + + (httpd-virtualhost + "*:8080" + `("ServerAdmin admin@example.com` +ServerName " ,domain " + +LogFormat \"%v %h %l %u %t \\\"%r\\\" %>s %b \\\"%{Referer}i\\\" \\\"%{User-Agent}i\\\"\" customformat +LogLevel info +CustomLog \"/var/log/httpd/" ,domain "-access_log\" customformat + +ErrorLog /var/log/httpd/error.log + +WSGIScriptAlias / " ,wsgi.py " +WSGIDaemonProcess " ,(package-name patchwork) " user=httpd group=httpd processes=1 threads=2 display-name=%{GROUP} lang='en_US.UTF-8' locale='en_US.UTF-8' python-path=" ,settings-module " +WSGIProcessGroup " ,(package-name patchwork) " +WSGIPassAuthorization On + + + Require all granted + + +" ,@(if static-path + `("Alias " ,static-path " " ,patchwork "/share/patchwork/htdocs/") + '()) +" + + AllowOverride None + Options MultiViews Indexes SymlinksIfOwnerMatch IncludesNoExec + Require method GET POST OPTIONS +"))))) + +(define (patchwork-httpd-configuration patchwork-configuration) + (list "WSGISocketPrefix /var/run/mod_wsgi" + (list "LoadModule wsgi_module " + (file-append mod-wsgi "/modules/mod_wsgi.so")) + (patchwork-virtualhost patchwork-configuration))) + +(define (patchwork-django-admin-gexp patchwork settings-module) + #~(lambda command + (let ((pid (primitive-fork)) + (user (getpwnam "httpd"))) + (if (eq? pid 0) + (dynamic-wind + (const #t) + (lambda () + (setgid (passwd:gid user)) + (setuid (passwd:uid user)) + + (setenv "DJANGO_SETTINGS_MODULE" "guix.patchwork.settings") + (setenv "PYTHONPATH" #$settings-module) + (primitive-exit + (if (zero? + (apply system* + #$(file-append patchwork "/bin/patchwork-admin") + command)) + 0 + 1))) + (lambda () + (primitive-exit 1))) + (zero? (cdr (waitpid pid))))))) + +(define (patchwork-django-admin-action patchwork settings-module) + (shepherd-action + (name 'django-admin) + (documentation + "Run a django admin command for patchwork") + (procedure (patchwork-django-admin-gexp patchwork settings-module)))) + +(define patchwork-shepherd-services + (match-lambda + (($ patchwork domain + settings-module static-path + getmail-retriever-config) + (define secret-key-file-creation-gexp + (if (patchwork-settings-module? settings-module) + (with-extensions (list guile-gcrypt) + #~(let ((secret-key-file + #$(patchwork-settings-module-secret-key-file + settings-module))) + (use-modules (guix build utils) + (gcrypt random)) + + (unless (file-exists? secret-key-file) + (mkdir-p (dirname secret-key-file)) + (call-with-output-file secret-key-file + (lambda (port) + (display (random-token 30 'very-strong) port))) + (let* ((pw (getpwnam "httpd")) + (uid (passwd:uid pw)) + (gid (passwd:gid pw))) + (chown secret-key-file uid gid) + (chmod secret-key-file #o400))))) + #~())) + + (list (shepherd-service + (requirement '(postgres)) + (provision (list (string->symbol + (string-append (package-name patchwork) + "-setup")))) + (start + #~(lambda () + (define run-django-admin-command + #$(patchwork-django-admin-gexp patchwork + settings-module)) + + #$secret-key-file-creation-gexp + + (run-django-admin-command "migrate"))) + (stop #~(const #f)) + (actions + (list (patchwork-django-admin-action patchwork + settings-module))) + (respawn? #f) + (documentation "Setup Patchwork.")))))) + +(define patchwork-getmail-configs + (match-lambda + (($ patchwork domain + settings-module static-path + getmail-retriever-config) + (list + (getmail-configuration + (name (string->symbol (package-name patchwork))) + (user "httpd") + (directory (string-append + "/var/lib/getmail/" (package-name patchwork))) + (rcfile + (getmail-configuration-file + (retriever getmail-retriever-config) + (destination + (getmail-destination-configuration + (type "MDA_external") + (path (file-append patchwork "/bin/patchwork-admin")) + (extra-parameters + '((arguments . ("parsemail")))))) + (options + (getmail-options-configuration + (read-all #f) + (delivered-to #f) + (received #f))))) + (idle (assq-ref + (getmail-retriever-configuration-extra-parameters + getmail-retriever-config) + 'mailboxes)) + (environment-variables + (list "DJANGO_SETTINGS_MODULE=guix.patchwork.settings" + #~(string-append "PYTHONPATH=" #$settings-module)))))))) + +(define patchwork-service-type + (service-type + (name 'patchwork-setup) + (extensions + (list (service-extension httpd-service-type + patchwork-httpd-configuration) + (service-extension shepherd-root-service-type + patchwork-shepherd-services) + (service-extension getmail-service-type + patchwork-getmail-configs))) + (description + "Patchwork patch tracking system."))) diff --git a/gnu/tests/web.scm b/gnu/tests/web.scm index 319655396..7c1c0aa51 100644 --- a/gnu/tests/web.scm +++ b/gnu/tests/web.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2017 Ludovic Courtès -;;; Copyright © 2017 Christopher Baines +;;; Copyright © 2017, 2019 Christopher Baines ;;; Copyright © 2017, 2018 Clément Lassieur ;;; Copyright © 2018 Pierre-Antoine Rouby ;;; Copyright © 2018 Marius Bakke @@ -28,15 +28,29 @@ #:use-module (gnu system vm) #:use-module (gnu services) #:use-module (gnu services web) + #:use-module (gnu services databases) + #:use-module (gnu services getmail) #:use-module (gnu services networking) + #:use-module (gnu services shepherd) + #:use-module (gnu services mail) + #:use-module (gnu packages databases) + #:use-module (gnu packages patchutils) + #:use-module (gnu packages python) + #:use-module (gnu packages web) + #:use-module (guix packages) + #:use-module (guix modules) + #:use-module (guix records) #:use-module (guix gexp) #:use-module (guix store) + #:use-module (guix utils) + #:use-module (ice-9 match) #:export (%test-httpd %test-nginx %test-varnish %test-php-fpm %test-hpcguix-web - %test-tailon)) + %test-tailon + %test-patchwork)) (define %index.html-contents ;; Contents of the /index.html file. @@ -498,3 +512,149 @@ HTTP-PORT." (name "tailon") (description "Connect to a running Tailon server.") (value (run-tailon-test)))) + + +;;; +;;; Patchwork +;;; + +(define patchwork-initial-database-setup-service + (match-lambda + (($ + engine name user password host port) + + (define start-gexp + #~(lambda () + (let ((pid (primitive-fork)) + (postgres (getpwnam "postgres"))) + (if (eq? pid 0) + (dynamic-wind + (const #t) + (lambda () + (setgid (passwd:gid postgres)) + (setuid (passwd:uid postgres)) + (primitive-exit + (if (and + (zero? + (system* #$(file-append postgresql "/bin/createuser") + #$user)) + (zero? + (system* #$(file-append postgresql "/bin/createdb") + "-O" #$user #$name))) + 0 + 1))) + (lambda () + (primitive-exit 1))) + (zero? (cdr (waitpid pid))))))) + + (shepherd-service + (requirement '(postgres)) + (provision '(patchwork-postgresql-user-and-database)) + (start start-gexp) + (stop #~(const #f)) + (respawn? #f) + (documentation "Setup patchwork database."))))) + +(define (patchwork-os patchwork) + (simple-operating-system + (service dhcp-client-service-type) + (service httpd-service-type + (httpd-configuration + (config + (httpd-config-file + (listen '("8080")))))) + (service postgresql-service-type) + (service patchwork-service-type + (patchwork-configuration + (patchwork patchwork) + (domain "localhost") + (settings-module + (patchwork-settings-module + (allowed-hosts (list domain)) + (default-from-email ""))) + (getmail-retriever-config + (getmail-retriever-configuration + (type "SimpleIMAPSSLRetriever") + (server "imap.example.com") + (port 993) + (username "username") + (password "password") + (extra-parameters + '((mailboxes . ("INBOX")))))))) + (simple-service 'patchwork-database-setup + shepherd-root-service-type + (list + (patchwork-initial-database-setup-service + (patchwork-database-configuration)))))) + +(define (run-patchwork-test patchwork) + "Run tests in %NGINX-OS, which has nginx running and listening on +HTTP-PORT." + (define os + (marionette-operating-system + (patchwork-os patchwork) + #:imported-modules '((gnu services herd) + (guix combinators)))) + + (define forwarded-port 8080) + + (define vm + (virtual-machine + (operating-system os) + (port-forwardings `((8080 . ,forwarded-port))))) + + (define test + (with-imported-modules '((gnu build marionette)) + #~(begin + (use-modules (srfi srfi-11) (srfi srfi-64) + (gnu build marionette) + (web uri) + (web client) + (web response)) + + (define marionette + (make-marionette (list #$vm))) + + (mkdir #$output) + (chdir #$output) + + (test-begin "patchwork") + + (test-assert "patchwork-postgresql-user-and-service started" + (marionette-eval + '(begin + (use-modules (gnu services herd)) + (match (start-service 'patchwork-postgresql-user-and-database) + (#f #f) + (('service response-parts ...) + (match (assq-ref response-parts 'running) + ((#t) #t) + ((pid) (number? pid)))))) + marionette)) + + (test-assert "httpd running" + (marionette-eval + '(begin + (use-modules (gnu services herd)) + (start-service 'httpd)) + marionette)) + + (test-equal "http-get" + 200 + (let-values + (((response text) + (http-get #$(simple-format + #f "http://localhost:~A/" forwarded-port) + #:decode-body? #t))) + (response-code response))) + + (test-end) + (exit (= (test-runner-fail-count (test-runner-current)) 0))))) + + (gexp->derivation "patchwork-test" test)) + +(define %test-patchwork + (system-test + (name "patchwork") + (description "Connect to a running Patchwork service.") + (value (run-patchwork-test patchwork)))) -- cgit v1.3 From 7293e3dba107abe416fde72c25dc351de3cfeef9 Mon Sep 17 00:00:00 2001 From: Guillaume LE VAILLANT Date: Wed, 29 May 2019 13:40:25 +0200 Subject: gnu: Add zbar. * gnu/packages/aidc.scm (zbar): New variable. Signed-off-by: Ricardo Wurmus --- gnu/packages/aidc.scm | 55 ++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 54 insertions(+), 1 deletion(-) diff --git a/gnu/packages/aidc.scm b/gnu/packages/aidc.scm index afcb33ad6..61d3331c9 100644 --- a/gnu/packages/aidc.scm +++ b/gnu/packages/aidc.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2016 Efraim Flashner ;;; Copyright © 2017 Hartmut Goebel ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice +;;; Copyright © 2019 Guillaume Le Vaillant ;;; ;;; This file is part of GNU Guix. ;;; @@ -26,8 +27,15 @@ #:use-module (guix download) #:use-module (guix git-download) #:use-module (gnu packages autotools) - #:use-module (gnu packages pkg-config) + #:use-module (gnu packages imagemagick) + #:use-module (gnu packages glib) + #:use-module (gnu packages gtk) #:use-module (gnu packages image) + #:use-module (gnu packages pkg-config) + #:use-module (gnu packages python) + #:use-module (gnu packages python-xyz) + #:use-module (gnu packages qt) + #:use-module (gnu packages video) #:use-module (guix build-system gnu)) @@ -102,3 +110,48 @@ characters, and is highly robust.") barcodes of the modern ECC200 variety. libdmtx is a shared library, allowing C/C++ programs to use its capabilities without restrictions or overhead.") (license license:bsd-3))) + +(define-public zbar + (package + (name "zbar") + (version "0.23") + (source + (origin + (method url-fetch) + (uri (string-append "https://linuxtv.org/downloads/zbar/zbar-" + version + ".tar.bz2")) + (sha256 + (base32 + "0bmd93a15qpgbsq9c9j33qms18rdrgz6gbc48zi6z9w5pvrvi7z9")))) + (build-system gnu-build-system) + (arguments + '(#:configure-flags (list "--with-gtk=auto" + "--with-python=auto" + (string-append "--with-dbusconfdir=" + (assoc-ref %outputs "out") + "/etc") + "CXXFLAGS=-std=c++11"))) + (native-inputs + `(("glib" ,glib "bin") + ("pkg-config" ,pkg-config))) + (inputs + `(("gobject-introspection" ,gobject-introspection) + ("gtk+" ,gtk+) + ("imagemagick" ,imagemagick) + ("libjpeg" ,libjpeg-turbo) + ("python" ,python) + ("qtbase" ,qtbase) + ("qtx11extras" ,qtx11extras) + ("v4l-utils" ,v4l-utils))) + (synopsis "Bar code reader") + (description + "ZBar can read barcodes from various sources, such as video streams, +image files, and raw intensity sensors. It supports EAN-13/UPC-A, UPC-E, +EAN-8, Code 128, Code 93, Code 39, Codabar, Interleaved 2 of 5, QR Code and SQ +Code. Included with the library are basic applications for decoding captured +bar code images and using a video device (e.g. webcam) as a bar code scanner. +For application developers, language bindings are included for C, C++ and +Python as well as GUI widgets for GTK and Qt.") + (home-page "https://github.com/mchehab/zbar") + (license license:lgpl2.1+))) -- cgit v1.3 From 5c48519204cf76b3770fd217680f93497612240a Mon Sep 17 00:00:00 2001 From: Kei Kebreau Date: Fri, 12 Apr 2019 19:41:57 -0400 Subject: gnu: Add mousepad. * gnu/packages/xfce.scm (mousepad): New variable. --- gnu/packages/xfce.scm | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/gnu/packages/xfce.scm b/gnu/packages/xfce.scm index c3ddf9f86..c51850836 100644 --- a/gnu/packages/xfce.scm +++ b/gnu/packages/xfce.scm @@ -1023,3 +1023,45 @@ the libburnia libraries. It can blank CD/DVD/BD(-RW)s, burn and create iso images, audio CDs, as well as burn personal compositions of data to either CD/DVD/BD.") (license gpl2+))) + +(define-public mousepad + (package + (name "mousepad") + (version "0.4.1") + (source (origin + (method url-fetch) + (uri (string-append "http://archive.xfce.org/src/apps/mousepad/" + (version-major+minor version) "/mousepad-" + version ".tar.bz2")) + (sha256 + (base32 + "12si6fvhp68wz4scr339c23jxqq5ywn5nf4w55jld5lxjadkg9rr")))) + (build-system gnu-build-system) + (arguments + '(#:configure-flags '("--enable-gtk3" + ;; Use the GSettings keyfile backend rather than + ;; DConf. + "--enable-keyfile-settings") + #:phases + (modify-phases %standard-phases + (add-after 'install 'wrap-program + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out")) + (gtksourceview (assoc-ref inputs "gtksourceview"))) + (wrap-program (string-append out "/bin/mousepad") + ;; For language-specs. + `("XDG_DATA_DIRS" ":" prefix (,(string-append gtksourceview + "/share"))))) + #t))))) + (native-inputs + `(("intltool" ,intltool) + ("glib" ,glib "bin") ; for glib-compile-schemas. + ("pkg-config" ,pkg-config))) + (inputs + `(("gtk+" ,gtk+) + ("gtksourceview" ,gtksourceview-3))) + (home-page "https://git.xfce.org/apps/mousepad/") + (synopsis "Simple text editor for Xfce") + (description + "Mousepad is a graphical text editor for Xfce based on Leafpad.") + (license gpl2+))) -- cgit v1.3 From e586c6faf3838daeadfe9aa97ae4d428f0613d67 Mon Sep 17 00:00:00 2001 From: Eric Bavier Date: Thu, 30 May 2019 23:27:46 -0500 Subject: gnu: petsc-complex-mpi: Setup MPI for tests. * gnu/packages/maths.scm (petsc-complex-mpi)[arguments]: Add 'mpi-setup phase. --- gnu/packages/maths.scm | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index f88f48b82..cd6f5780d 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -1845,7 +1845,11 @@ scientific applications modeled by partial differential equations.") ``("--with-mpiexec=mpirun" ,(string-append "--with-mpi-dir=" (assoc-ref %build-inputs "openmpi")) - ,@(delete "--with-mpi=0" ,cf))))) + ,@(delete "--with-mpi=0" ,cf))) + ((#:phases phases) + `(modify-phases ,phases + (add-before 'configure 'mpi-setup + ,%openmpi-setup))))) (synopsis "Library to solve PDEs (with complex scalars and MPI support)"))) (define-public python-petsc4py -- cgit v1.3 From 4f7a4a06c28934086a38f576dcc3f536e5be01fd Mon Sep 17 00:00:00 2001 From: Eric Bavier Date: Thu, 30 May 2019 23:28:46 -0500 Subject: gnu: petsc: Update to 3.11.2. * gnu/packages/maths.scm (petsc): Update to 3.11.2. --- gnu/packages/maths.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index cd6f5780d..3a5ee0ac6 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -1692,7 +1692,7 @@ September 2004}") (define-public petsc (package (name "petsc") - (version "3.10.4") + (version "3.11.2") (source (origin (method url-fetch) @@ -1700,7 +1700,7 @@ September 2004}") (uri (string-append "http://ftp.mcs.anl.gov/pub/petsc/release-snapshots/" "petsc-lite-" version ".tar.gz")) (sha256 - (base32 "0fk16944zh3473ra198kdkxdn08rq7b6ap838hxy1mh1i0hb488r")))) + (base32 "1645nwwcp9bcnfnxikk480mhbbacdvhsay2c401818hk97dqj5nx")))) (outputs '("out" ; libraries and headers "examples")) ; ~30MiB of examples (build-system gnu-build-system) -- cgit v1.3 From a13e0f3db48b8fde72cadfec30a94f4507c660f8 Mon Sep 17 00:00:00 2001 From: Eric Bavier Date: Thu, 30 May 2019 23:29:41 -0500 Subject: gnu: slepc: Update to 3.11.1. * gnu/packages/maths.scm (slepc): Update to 3.11.1. [native-inputs]: Add petsc:examples. [arguments]: Add PETSCCONFIGDIR to #:make-flags. --- gnu/packages/maths.scm | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index 3a5ee0ac6..99fa5b665 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -1914,7 +1914,7 @@ savings are consistently > 5x.") (define-public slepc (package (name "slepc") - (version "3.10.1") + (version "3.11.1") (source (origin (method url-fetch) @@ -1922,10 +1922,11 @@ savings are consistently > 5x.") version ".tar.gz")) (sha256 (base32 - "188j1a133q91h8pivpnzwcf78kz8dvz2nzf6ndnjygdbqb48fizn")))) + "1yq84q9wannc8xwapxpay4ypdd675picwi395hhsdvng9q6hf5j8")))) (build-system gnu-build-system) (native-inputs - `(("python" ,python-2))) + `(("python" ,python-2) + ("petsc:examples" ,petsc "examples"))) ;for gmakegen.py script (inputs `(("arpack" ,arpack-ng) ("gfortran" ,gfortran))) @@ -1937,7 +1938,10 @@ savings are consistently > 5x.") `(,(string-append "--with-arpack-dir=" (assoc-ref %build-inputs "arpack") "/lib")) #:make-flags ;honor (parallel-job-count) - `(,(format #f "MAKE_NP=~a" (parallel-job-count))) + `(,(format #f "MAKE_NP=~a" (parallel-job-count)) + ,(string-append "PETSCCONFIGDIR=" + (assoc-ref %build-inputs "petsc:examples") + "/share/petsc/examples/config")) #:phases (modify-phases %standard-phases (replace 'configure -- cgit v1.3 From 4d44bcad56c0a15c023aab08640e75b9896b0ab0 Mon Sep 17 00:00:00 2001 From: Eric Bavier Date: Fri, 31 May 2019 19:35:56 -0500 Subject: gnu: dealii-openmpi: Add hdf5-parallel-openmpi input. * gnu/packages/maths.scm (dealii-openmpi)[inputs]: Add hdf5-parallel-openmpi. --- gnu/packages/maths.scm | 1 + 1 file changed, 1 insertion(+) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index 99fa5b665..4741a0d5e 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -3561,6 +3561,7 @@ in finite element programs.") (inputs `(("mpi" ,openmpi) ;;Supported only with MPI: + ("hdf5" ,hdf5-parallel-openmpi) ;TODO: have petsc-openmpi propagate? ("p4est" ,p4est-openmpi) ("petsc" ,petsc-openmpi) ("slepc" ,slepc-openmpi) -- cgit v1.3 From d4cb92e707c5a8b727027f1593fd82db9acaaaf4 Mon Sep 17 00:00:00 2001 From: Vasile Dumitrascu Date: Thu, 30 May 2019 20:49:32 +0200 Subject: gnu: gnucash: Update to 3.5. * gnu/packages/gnucash.scm (gnucash): Update to 3.5. [source]: Remove unneeded patch. * gnu/packages/patches/gnucash-fix-test-transaction-failure.patch: Delete file. * gnu/local.mk (dist_patch_DATA): Remove patch. Signed-off-by: Kei Kebreau --- gnu/local.mk | 1 - gnu/packages/gnucash.scm | 5 +- .../gnucash-fix-test-transaction-failure.patch | 54 ---------------------- 3 files changed, 2 insertions(+), 58 deletions(-) delete mode 100644 gnu/packages/patches/gnucash-fix-test-transaction-failure.patch diff --git a/gnu/local.mk b/gnu/local.mk index 9b9c6e00e..d0c108049 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -866,7 +866,6 @@ dist_patch_DATA = \ %D%/packages/patches/gmp-faulty-test.patch \ %D%/packages/patches/gnome-shell-theme.patch \ %D%/packages/patches/gnome-tweaks-search-paths.patch \ - %D%/packages/patches/gnucash-fix-test-transaction-failure.patch \ %D%/packages/patches/gnutls-skip-trust-store-test.patch \ %D%/packages/patches/gobject-introspection-absolute-shlib-path.patch \ %D%/packages/patches/gobject-introspection-cc.patch \ diff --git a/gnu/packages/gnucash.scm b/gnu/packages/gnucash.scm index 5b4da97e5..e09a7cb0c 100644 --- a/gnu/packages/gnucash.scm +++ b/gnu/packages/gnucash.scm @@ -54,7 +54,7 @@ ;; directory. (package (name "gnucash") - (version "3.4") + (version "3.5") (source (origin (method url-fetch) @@ -62,8 +62,7 @@ version "/gnucash-" version ".tar.bz2")) (sha256 (base32 - "1ms2wg4sh5gq3rpjmmnp85rh5nc9ahca1imxkvhz4d3yiwy8hm52")) - (patches (search-patches "gnucash-fix-test-transaction-failure.patch")))) + "0ibp7g6aknvnkwkin97kv04ipksy3l18dsz9qysjb7h2nr8hnvbp")))) (build-system cmake-build-system) (inputs `(("guile" ,guile-2.2) diff --git a/gnu/packages/patches/gnucash-fix-test-transaction-failure.patch b/gnu/packages/patches/gnucash-fix-test-transaction-failure.patch deleted file mode 100644 index 7b1b29f06..000000000 --- a/gnu/packages/patches/gnucash-fix-test-transaction-failure.patch +++ /dev/null @@ -1,54 +0,0 @@ -# This patch was submitted upstream to: https://bugs.gnucash.org/show_bug.cgi?id=797008. -From c20d74bebca516d0e391724202aad511967fe109 Mon Sep 17 00:00:00 2001 -From: Maxim Cournoyer -Date: Wed, 2 Jan 2019 14:46:28 -0500 -Subject: [PATCH] tests: Fix a test failure in test-transaction.scm. - -With the New Year upon us, a test which was hard-coded to use 2018 now -failed. - -Fixes issue #797008 (see: -https://bugs.gnucash.org/show_bug.cgi?id=797008). - -* gnucash/report/standard-reports/test/test-transaction.scm: -(trep-tests): Use the current year in the test string instead of a -static one. ---- - gnucash/report/standard-reports/test/test-transaction.scm | 7 +++++-- - 1 file changed, 5 insertions(+), 2 deletions(-) - -diff --git a/gnucash/report/standard-reports/test/test-transaction.scm b/gnucash/report/standard-reports/test/test-transaction.scm -index 755aba298..ae3fbd5c1 100644 ---- a/gnucash/report/standard-reports/test/test-transaction.scm -+++ b/gnucash/report/standard-reports/test/test-transaction.scm -@@ -5,6 +5,7 @@ - (use-modules (gnucash report stylesheets)) - (use-modules (gnucash report report-system)) - (use-modules (gnucash report report-system test test-extras)) -+(use-modules (srfi srfi-19)) - (use-modules (srfi srfi-64)) - (use-modules (gnucash engine test srfi64-extras)) - (use-modules (sxml simple)) -@@ -643,7 +644,8 @@ - (set-option! options "General" "Show original currency amount" #t) - (set-option! options "Sorting" "Primary Key" 'date) - (set-option! options "Sorting" "Primary Subtotal for Date Key" 'none) -- (let* ((sxml (options->sxml options "dual columns"))) -+ (let* ((sxml (options->sxml options "dual columns")) -+ (current-year (date->string (current-date) "~y"))) - (test-equal "dual amount column, with original currency headers" - (list "Date" "Num" "Description" "Memo/Notes" "Account" - "Debit (USD)" "Credit (USD)" "Debit" "Credit") -@@ -652,7 +654,8 @@ - (list "Grand Total" "$2,280.00" "$2,280.00") - (get-row-col sxml -1 #f)) - (test-equal "dual amount column, first transaction correct" -- (list "01/03/18" "$103 income" "Root.Asset.Bank" "$103.00" "$103.00") -+ (list (string-append "01/03/" current-year) "$103 income" -+ "Root.Asset.Bank" "$103.00" "$103.00") - (get-row-col sxml 1 #f))) - ) - --- -2.19.0 - -- cgit v1.3 From 86d73d59c9d36008471e7615f4f38fc220f5ed13 Mon Sep 17 00:00:00 2001 From: Vasile Dumitrascu Date: Thu, 30 May 2019 20:49:33 +0200 Subject: gnu: gnucash-docs: Update to 3.5. * gnu/packages/gnucash.scm (gnucash-docs): Update to 3.5. Signed-off-by: Kei Kebreau --- gnu/packages/gnucash.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/gnucash.scm b/gnu/packages/gnucash.scm index e09a7cb0c..2196a8c50 100644 --- a/gnu/packages/gnucash.scm +++ b/gnu/packages/gnucash.scm @@ -196,7 +196,7 @@ installed as well as Yelp, the Gnome help browser.") ;; 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 - (let ((revision "a")) ;set to the empty string when no revision + (let ((revision "")) ;set to the empty string when no revision (package (name "gnucash-docs") (version (package-version gnucash)) @@ -207,7 +207,7 @@ installed as well as Yelp, the Gnome help browser.") version "/gnucash-docs-" version revision ".tar.gz")) (sha256 (base32 - "0bgjxpxgk7hy8ihn1kvd8p6vv191q5md2hz6jb9mqc4aykpvdlq7")))) + "0gjndyms413vilf5nqh39frs1691sxib8l7y9mbvcyirj1f8285k")))) (build-system gnu-build-system) ;; These are native-inputs because they are only required for building the ;; documentation. -- cgit v1.3 From 1cc12357a65e4479c2f4735e915941382ef82d94 Mon Sep 17 00:00:00 2001 From: Robert Vollmert Date: Sat, 25 May 2019 22:11:02 +0200 Subject: import: hackage: Update list of ghc-included packages. Update the list of excepted dependencies for current ghc-8.4, based on the release notes at https://downloads.haskell.org/~ghc/8.4.3/docs/html/users_guide/8.4.3-notes.html Particularly, this adds `text` to the list, which is a dependency of `parsec` which was already on the list before, causing build failures with updated versions of the `text` package. * guix/import/hackage.scm (ghc-standard-libraries): Update list. Signed-off-by: Ricardo Wurmus --- guix/import/hackage.scm | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/guix/import/hackage.scm b/guix/import/hackage.scm index bf7e99df1..366256b40 100644 --- a/guix/import/hackage.scm +++ b/guix/import/hackage.scm @@ -51,34 +51,35 @@ hackage-package?)) (define ghc-standard-libraries - ;; List of libraries distributed with ghc (7.10.2). We include GHC itself as - ;; some packages list it. - '("array" + ;; List of libraries distributed with ghc (8.4.3). + ;; https://downloads.haskell.org/~ghc/8.4.3/docs/html/users_guide/8.4.3-notes.html + '("ghc" + "cabal" ;; in the output of `ghc-pkg list` Cabal is uppercased, but + ;; hackage-name->package-name takes this into account. + "win32" ;; similarly uppercased + "array" "base" - "bin-package-db" "binary" "bytestring" - "cabal" ;; in the output of `ghc-pkg list` Cabal is uppercased, but - ;; hackage-name->package-name takes this into account. "containers" "deepseq" "directory" "filepath" - "ghc" + "ghc-boot" + "ghc-compact" "ghc-prim" + "ghci" "haskeline" - "hoopl" "hpc" "integer-gmp" - "pretty" + "mtl" + "parsec" "process" - "rts" "template-haskell" - "terminfo" + "text" "time" "transformers" "unix" - "win32" "xhtml")) (define package-name-prefix "ghc-") -- cgit v1.3 From 9d96994c6229319f5ca31dbe5c31539bf26d4031 Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Sat, 1 Jun 2019 01:37:28 -0400 Subject: gnu: linux-libre@4.9: Update to 4.9.180. * gnu/packages/linux.scm (linux-libre-4.9): Update to 4.9.180. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index ac26b024a..e8fad7556 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -494,8 +494,8 @@ It has been modified to remove all non-free binary blobs.") %linux-libre-4.14-hash)) (define-public linux-libre-4.9 - (make-linux-libre "4.9.179" - "0nc9a7b7g5a18fdc8dswm3la7srn5sgz8adavp8r9h3ya9zh3wim" + (make-linux-libre "4.9.180" + "062ybvc5ljpbn8llj62zsvvykl5rikn0jfzh62nrrdsnj7mvi77a" '("x86_64-linux" "i686-linux") #:configuration-file kernel-config)) -- cgit v1.3 From 83c067287784f3021fc6289d18289e28521b75cf Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Sat, 1 Jun 2019 01:39:06 -0400 Subject: gnu: linux-libre@4.14: Update to 4.14.123. * gnu/packages/linux.scm (%linux-libre-4.14-version): Update to 4.14.123. (%linux-libre-4.14-hash): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index e8fad7556..7a1670af5 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -480,8 +480,8 @@ It has been modified to remove all non-free binary blobs.") %linux-libre-4.15-hash)) -(define %linux-libre-4.14-version "4.14.122") -(define %linux-libre-4.14-hash "0923m61b3gwm69w6m9zhb8az57lrwn7igdysf8wb7ld9z4hzpag8") +(define %linux-libre-4.14-version "4.14.123") +(define %linux-libre-4.14-hash "185kf576rwhsaq7jqrnmg8r5fh2nh4k8lifxaxwi3amshnwbj2qg") (define-public linux-libre-4.14 (make-linux-libre %linux-libre-4.14-version -- cgit v1.3 From bc5d9ae7c944d79edaf71101b0937ec00e061a37 Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Sat, 1 Jun 2019 01:40:52 -0400 Subject: gnu: linux-libre@4.19: Update to 4.19.47. * gnu/packages/linux.scm (%linux-libre-4.19-version): Update to 4.19.47. (%linux-libre-4.19-hash): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 7a1670af5..bdf7ab94b 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -448,8 +448,8 @@ It has been modified to remove all non-free binary blobs.") (make-linux-libre-headers %linux-libre-version %linux-libre-hash)) -(define %linux-libre-4.19-version "4.19.46") -(define %linux-libre-4.19-hash "17yy3h064kr7zck07wdrw3fmmmnfk15m17xvkpkc4yv5vxxi76vh") +(define %linux-libre-4.19-version "4.19.47") +(define %linux-libre-4.19-hash "155rn6f555d2r1bqzi74zdif44ay7gk25xxjgw36s9n26dml8wf7") (define %linux-libre-4.19-patches (list %boot-logo-patch -- cgit v1.3 From b6cf7e54ea412ed24e6b3ca55a5b452a70ec957f Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Sat, 1 Jun 2019 01:43:11 -0400 Subject: gnu: linux-libre: Update to 5.1.6. * gnu/packages/linux.scm (%linux-libre-version): Update to 5.1.6. (%linux-libre-hash): Update hash. --- gnu/packages/linux.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index bdf7ab94b..ef4546528 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -430,8 +430,8 @@ for ARCH and optionally VARIANT, or #f if there is no such configuration." It has been modified to remove all non-free binary blobs.") (license license:gpl2))) -(define %linux-libre-version "5.1.5") -(define %linux-libre-hash "1zz0hlv509mf2vvrkvj8w19g3fhws6jk5j4ml47kzyr0lbs56iwa") +(define %linux-libre-version "5.1.6") +(define %linux-libre-hash "0m7yi23wlgrh16z5z9dxb7dd64i2irrkdwxi71i88mradn55iq42") (define %linux-libre-5.1-patches (list %boot-logo-patch -- cgit v1.3 From 87399dfc209fdec523947e7b45a1ad348afa4d46 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sat, 1 Jun 2019 11:38:33 +0200 Subject: lzlib: 'make-lzip-input-port' better handles end of decompression. Suggested by Pierre Neidhardt . * guix/lzlib.scm (lzread!): Call 'lz-decompress-finish' when 'feed-decoder!' returns EOF. Call 'lz-decompress-finished?' to determine end of compression. --- guix/lzlib.scm | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/guix/lzlib.scm b/guix/lzlib.scm index 31d84971c..24c7b4b44 100644 --- a/guix/lzlib.scm +++ b/guix/lzlib.scm @@ -510,9 +510,13 @@ the end-of-stream has been reached." (start start)) (cond ((< read count) (match (lz-decompress-read decoder bv start (- count read)) - (0 (if (eof-object? (feed-decoder! decoder)) - read - (loop read start))) + (0 (cond ((lz-decompress-finished? decoder) + read) + ((eof-object? (feed-decoder! decoder)) + (lz-decompress-finish decoder) + (loop read start)) + (else ;read again + (loop read start)))) (n (loop (+ read n) (+ start n))))) (else read)))) -- cgit v1.3 From 55c98f3261b6ced2c38e060566e1eb952bd3e42b Mon Sep 17 00:00:00 2001 From: Robert Vollmert Date: Fri, 31 May 2019 23:22:41 +0200 Subject: tests: hackage: Factor out package pattern. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * tests/hackage.scm: Import result pattern matching via helper. Signed-off-by: Ludovic Courtès --- tests/hackage.scm | 133 +++++++++++++++++++++++++++--------------------------- 1 file changed, 66 insertions(+), 67 deletions(-) diff --git a/tests/hackage.scm b/tests/hackage.scm index 0efad0638..41e3b2dcd 100644 --- a/tests/hackage.scm +++ b/tests/hackage.scm @@ -155,93 +155,92 @@ library (test-begin "hackage") -(define* (eval-test-with-cabal test-cabal #:key (cabal-environment '())) +(define-syntax-rule (define-package-matcher name pattern) + (define* (name obj) + (match obj + (pattern #t) + (x (pk 'fail x #f))))) + +(define-package-matcher match-ghc-foo + ('package + ('name "ghc-foo") + ('version "1.0.0") + ('source + ('origin + ('method 'url-fetch) + ('uri ('string-append + "https://hackage.haskell.org/package/foo/foo-" + 'version + ".tar.gz")) + ('sha256 + ('base32 + (? string? hash))))) + ('build-system 'haskell-build-system) + ('inputs + ('quasiquote + (("ghc-http" ('unquote 'ghc-http)) + ("ghc-mtl" ('unquote 'ghc-mtl))))) + ('home-page "http://test.org") + ('synopsis (? string?)) + ('description (? string?)) + ('license 'bsd-3))) + +(define* (eval-test-with-cabal test-cabal matcher #:key (cabal-environment '())) (mock ((guix import hackage) hackage-fetch (lambda (name-version) (call-with-input-string test-cabal read-cabal))) - (match (hackage->guix-package "foo" #:cabal-environment cabal-environment) - (('package - ('name "ghc-foo") - ('version "1.0.0") - ('source - ('origin - ('method 'url-fetch) - ('uri ('string-append - "https://hackage.haskell.org/package/foo/foo-" - 'version - ".tar.gz")) - ('sha256 - ('base32 - (? string? hash))))) - ('build-system 'haskell-build-system) - ('inputs - ('quasiquote - (("ghc-http" ('unquote 'ghc-http)) - ("ghc-mtl" ('unquote 'ghc-mtl))))) - ('home-page "http://test.org") - ('synopsis (? string?)) - ('description (? string?)) - ('license 'bsd-3)) - #t) - (x - (pk 'fail x #f))))) + (matcher (hackage->guix-package "foo" #:cabal-environment cabal-environment)))) (test-assert "hackage->guix-package test 1" - (eval-test-with-cabal test-cabal-1)) + (eval-test-with-cabal test-cabal-1 match-ghc-foo)) (test-assert "hackage->guix-package test 2" - (eval-test-with-cabal test-cabal-2)) + (eval-test-with-cabal test-cabal-2 match-ghc-foo)) (test-assert "hackage->guix-package test 3" - (eval-test-with-cabal test-cabal-3 + (eval-test-with-cabal test-cabal-3 match-ghc-foo #:cabal-environment '(("impl" . "ghc-7.8")))) (test-assert "hackage->guix-package test 4" - (eval-test-with-cabal test-cabal-4 + (eval-test-with-cabal test-cabal-4 match-ghc-foo #:cabal-environment '(("impl" . "ghc-7.8")))) (test-assert "hackage->guix-package test 5" - (eval-test-with-cabal test-cabal-5 + (eval-test-with-cabal test-cabal-5 match-ghc-foo #:cabal-environment '(("impl" . "ghc-7.8")))) +(define-package-matcher match-ghc-foo-6 + ('package + ('name "ghc-foo") + ('version "1.0.0") + ('source + ('origin + ('method 'url-fetch) + ('uri ('string-append + "https://hackage.haskell.org/package/foo/foo-" + 'version + ".tar.gz")) + ('sha256 + ('base32 + (? string? hash))))) + ('build-system 'haskell-build-system) + ('inputs + ('quasiquote + (("ghc-b" ('unquote 'ghc-b)) + ("ghc-http" ('unquote 'ghc-http)) + ("ghc-mtl" ('unquote 'ghc-mtl))))) + ('native-inputs + ('quasiquote + (("ghc-haskell-gi" ('unquote 'ghc-haskell-gi))))) + ('home-page "http://test.org") + ('synopsis (? string?)) + ('description (? string?)) + ('license 'bsd-3))) + (test-assert "hackage->guix-package test 6" - (mock - ((guix import hackage) hackage-fetch - (lambda (name-version) - (call-with-input-string test-cabal-6 - read-cabal))) - (match (hackage->guix-package "foo") - (('package - ('name "ghc-foo") - ('version "1.0.0") - ('source - ('origin - ('method 'url-fetch) - ('uri ('string-append - "https://hackage.haskell.org/package/foo/foo-" - 'version - ".tar.gz")) - ('sha256 - ('base32 - (? string? hash))))) - ('build-system 'haskell-build-system) - ('inputs - ('quasiquote - (("ghc-b" ('unquote 'ghc-b)) - ("ghc-http" ('unquote 'ghc-http)) - ("ghc-mtl" ('unquote 'ghc-mtl))))) - ('native-inputs - ('quasiquote - (("ghc-haskell-gi" ('unquote 'ghc-haskell-gi))))) - ('home-page "http://test.org") - ('synopsis (? string?)) - ('description (? string?)) - ('license 'bsd-3)) - #t) - (x - (pk 'fail x #f))))) + (eval-test-with-cabal test-cabal-6 match-ghc-foo-6)) (test-assert "read-cabal test 1" (match (call-with-input-string test-read-cabal-1 read-cabal) -- cgit v1.3 From 4110cde00560bd97cc8d83c34b80c52f37c680a2 Mon Sep 17 00:00:00 2001 From: Robert Vollmert Date: Fri, 31 May 2019 23:22:42 +0200 Subject: tests: hackage: Don't mock hackage-fetch. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * tests/hackage.scm: Pass a string input port to tests instead of mocking hackage download. Signed-off-by: Ludovic Courtès --- tests/hackage.scm | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/tests/hackage.scm b/tests/hackage.scm index 41e3b2dcd..1b4800164 100644 --- a/tests/hackage.scm +++ b/tests/hackage.scm @@ -186,12 +186,8 @@ library ('license 'bsd-3))) (define* (eval-test-with-cabal test-cabal matcher #:key (cabal-environment '())) - (mock - ((guix import hackage) hackage-fetch - (lambda (name-version) - (call-with-input-string test-cabal - read-cabal))) - (matcher (hackage->guix-package "foo" #:cabal-environment cabal-environment)))) + (define port (open-input-string test-cabal)) + (matcher (hackage->guix-package "foo" #:port port #:cabal-environment cabal-environment))) (test-assert "hackage->guix-package test 1" (eval-test-with-cabal test-cabal-1 match-ghc-foo)) -- cgit v1.3 From 0be465924c6f745618a73eea816aa15aba7c8d30 Mon Sep 17 00:00:00 2001 From: Robert Vollmert Date: Fri, 31 May 2019 23:22:43 +0200 Subject: tests: Indent hackage tests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * tests/hackage.scm: Reindent using etc/indent-code.el. Signed-off-by: Ludovic Courtès --- tests/hackage.scm | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/tests/hackage.scm b/tests/hackage.scm index 1b4800164..e5f3d6cae 100644 --- a/tests/hackage.scm +++ b/tests/hackage.scm @@ -242,19 +242,19 @@ library (match (call-with-input-string test-read-cabal-1 read-cabal) ((("name" ("test-me")) ('section 'library - (('if ('flag "base4point8") - (("build-depends" ("base >= 4.8 && < 5"))) - (('if ('flag "base4") - (("build-depends" ("base >= 4 && < 4.8"))) - (('if ('flag "base3") - (("build-depends" ("base >= 3 && < 4"))) - (("build-depends" ("base < 3")))))))) - ('if ('or ('flag "base4point8") - ('and ('flag "base4") ('flag "base3"))) - (("build-depends" ("random"))) - ()) - ("build-depends" ("containers")) - ("exposed-modules" ("Test.QuickCheck.Exception"))))) + (('if ('flag "base4point8") + (("build-depends" ("base >= 4.8 && < 5"))) + (('if ('flag "base4") + (("build-depends" ("base >= 4 && < 4.8"))) + (('if ('flag "base3") + (("build-depends" ("base >= 3 && < 4"))) + (("build-depends" ("base < 3")))))))) + ('if ('or ('flag "base4point8") + ('and ('flag "base4") ('flag "base3"))) + (("build-depends" ("random"))) + ()) + ("build-depends" ("containers")) + ("exposed-modules" ("Test.QuickCheck.Exception"))))) #t) (x (pk 'fail x #f)))) -- cgit v1.3 From a0c3a2e3a1a37884f795542d1cc8fb4b7bb227ac Mon Sep 17 00:00:00 2001 From: Guillaume LE VAILLANT Date: Tue, 28 May 2019 11:00:58 +0200 Subject: gnu: Add txr. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/lisp.scm (txr): New variable. * gnu/packages/patches/txr-shell.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. Signed-off-by: Ludovic Courtès --- gnu/local.mk | 1 + gnu/packages/lisp.scm | 48 +++++++++++++++++++++++++++++ gnu/packages/patches/txr-shell.patch | 59 ++++++++++++++++++++++++++++++++++++ 3 files changed, 108 insertions(+) create mode 100644 gnu/packages/patches/txr-shell.patch diff --git a/gnu/local.mk b/gnu/local.mk index d0c108049..55a8fcd36 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1318,6 +1318,7 @@ dist_patch_DATA = \ %D%/packages/patches/totem-meson-easy-codec.patch \ %D%/packages/patches/tuxpaint-stamps-path.patch \ %D%/packages/patches/twinkle-include-qregexpvalidator.patch \ + %D%/packages/patches/txr-shell.patch \ %D%/packages/patches/u-boot-fix-mkimage-header-verification.patch \ %D%/packages/patches/unzip-CVE-2014-8139.patch \ %D%/packages/patches/unzip-CVE-2014-8140.patch \ diff --git a/gnu/packages/lisp.scm b/gnu/packages/lisp.scm index 167c4433b..dfc58d469 100644 --- a/gnu/packages/lisp.scm +++ b/gnu/packages/lisp.scm @@ -14,6 +14,7 @@ ;;; Copyright © 2018 Pierre Langlois ;;; Copyright © 2019 Katherine Cox-Buday ;;; Copyright © 2019 Jesse Gildersleve +;;; Copyright © 2019 Guillaume Le Vaillant ;;; ;;; This file is part of GNU Guix. ;;; @@ -45,8 +46,10 @@ #:use-module (gnu packages admin) #:use-module (gnu packages base) #:use-module (gnu packages bdw-gc) + #:use-module (gnu packages bison) #:use-module (gnu packages compression) #:use-module (gnu packages ed) + #:use-module (gnu packages flex) #:use-module (gnu packages fontutils) #:use-module (gnu packages gcc) #:use-module (gnu packages gettext) @@ -5321,3 +5324,48 @@ port within a range.") (define-public ecl-find-port (sbcl-package->ecl-package sbcl-find-port)) + +(define-public txr + (package + (name "txr") + (version "216") + (source + (origin + (method url-fetch) + (uri (string-append "http://www.kylheku.com/cgit/txr/snapshot/txr-" + version + ".tar.bz2")) + (patches (search-patches "txr-shell.patch")) + (sha256 + (base32 + "07cxdpc9zsqd0c2668g00dqjpd6zc4mfdn74aarr6d2hpzdhh937")))) + (build-system gnu-build-system) + (arguments + '(#:configure-flags '("cc=gcc") + #:phases (modify-phases %standard-phases + (add-after 'configure 'fix-tests + (lambda _ + (substitute* "tests/017/realpath.tl" + (("/usr/bin") "/")) + (substitute* "tests/017/realpath.expected" + (("/usr/bin") "/")) + #t)) + (replace 'check + (lambda _ + (zero? (system* "make" "tests"))))))) + (native-inputs + `(("bison" ,bison) + ("flex" ,flex))) + (inputs + `(("libffi" ,libffi))) + (synopsis "General-purpose, multi-paradigm programming language") + (description + "TXR is a general-purpose, multi-paradigm programming language. It +comprises two languages integrated into a single tool: a text scanning and +extraction language referred to as the TXR Pattern Language (sometimes just +\"TXR\"), and a general-purpose dialect of Lisp called TXR Lisp. TXR can be +used for everything from \"one liner\" data transformation tasks at the +command line, to data scanning and extracting scripts, to full application +development in a wide-range of areas.") + (home-page "https://nongnu.org/txr/") + (license license:bsd-2))) diff --git a/gnu/packages/patches/txr-shell.patch b/gnu/packages/patches/txr-shell.patch new file mode 100644 index 000000000..a4abb73ea --- /dev/null +++ b/gnu/packages/patches/txr-shell.patch @@ -0,0 +1,59 @@ +Use the current shell instead of trying to find another one and +failing to do so. + +diff --git a/configure b/configure +index f1adb919..7891b4dc 100755 +--- a/configure ++++ b/configure +@@ -26,28 +26,6 @@ + # OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +-# +-# The #!/bin/sh might be some legacy piece of crap, +-# not even up to 1990 POSIX.2 spec. So the first step +-# is to look for a better shell in some known places +-# and re-execute ourselves with that interpreter. +-# +- +-if test x$txr_shell = x ; then +- for shell in /bin/bash /usr/bin/bash /usr/xpg4/bin/sh ; do +- if test -x $shell ; then +- txr_shell=$shell +- break +- fi +- done +- if test x$txr_shell = x ; then +- echo "No known POSIX shell found: falling back on /bin/sh, which may not work" +- txr_shell=/bin/sh +- fi +- export txr_shell +- exec $txr_shell $0 ${@+"$@"} +-fi +- + set -u + + # +@@ -190,13 +168,6 @@ while [ $# -gt 0 ] ; do + exit 1 + fi + +- eval "var_exists=\${$var+y}" +- +- if [ "$var_exists" != y ] ; then +- printf "$0: nonexistent option: '%s'\n" "$1" +- exit 1 +- fi +- + eval "$var='$val'" + + eval "var_given_exists=\${${var}_given+y}" +@@ -208,6 +179,8 @@ while [ $# -gt 0 ] ; do + shift + done + ++txr_shell=$CONFIG_SHELL ++ + # + # If --help was given (or --help= or help=) then + # print help and exit. The termination status is failed, to indicate -- cgit v1.3 From 2ccc9d692aed72dab614ab684341ca76466eafdf Mon Sep 17 00:00:00 2001 From: Timothy Sample Date: Sat, 1 Jun 2019 14:47:56 -0400 Subject: gnu: Add gash. * gnu/packages/shells.scm (gash): New variable. --- gnu/packages/shells.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/shells.scm b/gnu/packages/shells.scm index 9ed983db9..3512c5ac4 100644 --- a/gnu/packages/shells.scm +++ b/gnu/packages/shells.scm @@ -10,6 +10,7 @@ ;;; Copyright © 2017, 2018 Leo Famulari ;;; Copyright © 2017 Arun Isaac ;;; Copyright © 2019 Meiyo Peng +;;; Copyright © 2019 Timothy Sample ;;; ;;; This file is part of GNU Guix. ;;; @@ -34,6 +35,7 @@ #:use-module (gnu packages bison) #:use-module (gnu packages documentation) #:use-module (gnu packages groff) + #:use-module (gnu packages guile) #:use-module (gnu packages libbsd) #:use-module (gnu packages libedit) #:use-module (gnu packages ncurses) @@ -789,3 +791,27 @@ is commonly written.") (home-page "https://www.oilshell.org/") (license (list psfl ; The Oil sources include a patched Python 2 source tree asl2.0)))) + +(define-public gash + (package + (name "gash") + (version "0.1") + (source + (origin (method url-fetch) + (uri (string-append "mirror://savannah/gash/gash-" + version ".tar.gz")) + (sha256 + (base32 + "00m3lif64zyxd41cnk208kc81nl6qz659676qgiaqgwrw0brzrid")))) + (build-system gnu-build-system) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("guile" ,guile-2.2))) + (home-page "https://savannah.nongnu.org/projects/gash/") + (synopsis "POSIX-compatible shell written in Guile Scheme") + (description "Gash is a POSIX-compatible shell written in Guile +Scheme. It provides both the shell interface, as well as a Guile +library for parsing shell scripts. Gash is designed to bootstrap Bash +as part of the Guix bootstrap process.") + (license gpl3+))) -- cgit v1.3 From f53b4a6b77596d432739e08ff150ae51fcd2dd2b Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sat, 1 Jun 2019 23:03:11 +0200 Subject: gnu: r-biocviews: Update to 1.52.2. * gnu/packages/bioinformatics.scm (r-biocviews): Update to 1.52.2. [propagated-inputs]: Add r-biocmanager. --- gnu/packages/bioinformatics.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index 45c147f26..4b8e662a3 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -7245,18 +7245,19 @@ Bioconductor, CRAN, and Github.") (define-public r-biocviews (package (name "r-biocviews") - (version "1.52.1") + (version "1.52.2") (source (origin (method url-fetch) (uri (bioconductor-uri "biocViews" version)) (sha256 (base32 - "1685gdcvsmdjp1g5hm882jyyjdgqq77zh9xl2japhj285s8bm12y")))) + "0qwrsd9fcpkv7hhzy1scnj7ahdxi6cjary28kqk6b36gkzmnrw4r")))) (properties `((upstream-name . "biocViews"))) (build-system r-build-system) (propagated-inputs `(("r-biobase" ,r-biobase) + ("r-biocmanager" ,r-biocmanager) ("r-graph" ,r-graph) ("r-rbgl" ,r-rbgl) ("r-rcurl" ,r-rcurl) -- cgit v1.3 From 7d6efd2b6cde027d10570dbdbaa07cd91d717b44 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sat, 1 Jun 2019 23:03:34 +0200 Subject: gnu: r-openssl: Update to 1.4. * gnu/packages/statistics.scm (r-openssl): Update to 1.4. --- gnu/packages/statistics.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index 27d1c29e2..e845fc0bb 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -2333,14 +2333,14 @@ collation, and NAMESPACE files.") (define-public r-openssl (package (name "r-openssl") - (version "1.3") + (version "1.4") (source (origin (method url-fetch) (uri (cran-uri "openssl" version)) (sha256 (base32 - "1gx4mk7js1irzkql5rgk48ja9c6mm28ccxz483ngbhdd57az90qw")))) + "0mh4xwb9wnn5j2n1zzmjldqjqv2nn4wdidiixxciaqrqsi0l9834")))) (build-system r-build-system) (inputs `(("libressl" ,libressl))) -- cgit v1.3 From 36f5e67ab42867fa1a3e7287b093dfc09f766cb9 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 2 Jun 2019 01:23:40 +0200 Subject: gnu: grammalecte: Update to 1.1.1. * gnu/packages/dictionaries.scm (grammalecte): Update to 1.1.1. --- gnu/packages/dictionaries.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/dictionaries.scm b/gnu/packages/dictionaries.scm index 881ac9368..9f4dc59cc 100644 --- a/gnu/packages/dictionaries.scm +++ b/gnu/packages/dictionaries.scm @@ -218,7 +218,7 @@ It comes with a German-English dictionary with approximately 270,000 entries.") (define-public grammalecte (package (name "grammalecte") - (version "1.1") + (version "1.1.1") (source (origin (method url-fetch/zipbomb) @@ -226,7 +226,7 @@ It comes with a German-English dictionary with approximately 270,000 entries.") "Grammalecte-fr-v" version ".zip")) (sha256 (base32 - "031d6cn1wn7ps3j38vx6s8z2gjp9nqgiypqm3bfbhxqcammyhian")))) + "1al4c3976wgxijxghxqb1banarj82hwad51kln87xj2r5kwcfm05")))) (build-system python-build-system) (home-page "https://grammalecte.net") (synopsis "French spelling and grammar checker") -- cgit v1.3 From 8b3560501ff32ba09dafa053a4faed6ad56726e3 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 2 Jun 2019 01:31:52 +0200 Subject: gnu: keepassxc: Update to 2.4.2. * gnu/packages/password-utils.scm (keepassxc): Update to 2.4.2. --- gnu/packages/password-utils.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/password-utils.scm b/gnu/packages/password-utils.scm index 2b844c9a1..19595a2a6 100644 --- a/gnu/packages/password-utils.scm +++ b/gnu/packages/password-utils.scm @@ -108,7 +108,7 @@ human.") (define-public keepassxc (package (name "keepassxc") - (version "2.4.1") + (version "2.4.2") (source (origin (method url-fetch) @@ -117,7 +117,7 @@ human.") version "-src.tar.xz")) (sha256 (base32 - "1aw9airx9z846p0xc0qjgy5hg35b8cxp57rvlq39n6wx4z8ppa8d")))) + "0f31lmpbkw0wrhq0qa4yw5b51bjv7vqp3ikr355qcm905456vyhm")))) (build-system cmake-build-system) (arguments '(#:configure-flags '("-DWITH_XC_NETWORKING=YES" -- cgit v1.3 From 3eb261e2e54fe379071f47812bc52cc4b5b5e6c6 Mon Sep 17 00:00:00 2001 From: Robert Vollmert Date: Tue, 28 May 2019 21:10:24 +0200 Subject: gnu: ghc-happy: Skip memory-hungry tests. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Tests fail reliably for me on a system with 2GB of available RAM, in `issue93.a.hs` and `issue93.n.hs`. * gnu/packages/haskell.scm (ghc-happy): Skip test "issue93". Signed-off-by: Ludovic Courtès --- gnu/packages/haskell.scm | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/gnu/packages/haskell.scm b/gnu/packages/haskell.scm index 33c9c6484..822b0499b 100644 --- a/gnu/packages/haskell.scm +++ b/gnu/packages/haskell.scm @@ -1325,6 +1325,16 @@ postfix notation. For more information on stack based languages, see (base32 "138xpxdb7x62lpmgmb6b3v3vgdqqvqn4273jaap3mjmc2gla709y")))) (build-system haskell-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-after 'unpack 'skip-test-issue93 + (lambda _ + ;; Tests run out of memory on a system with 2GB of available RAM, + ;; in 'issue93.a.hs' and 'issue93.n.hs'. + (substitute* "tests/Makefile" + ((" issue93.y ") " ")) + #t))))) (home-page "https://hackage.haskell.org/package/happy") (synopsis "Parser generator for Haskell") (description "Happy is a parser generator for Haskell. Given a grammar -- cgit v1.3 From 08be02bea1f51855318f7c11d920ed9eea13b65b Mon Sep 17 00:00:00 2001 From: Andy Tai Date: Sat, 1 Jun 2019 10:41:16 -0700 Subject: gnu: Add terminator. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/gnome.scm (terminator): Add at 1.91 Signed-off-by: Ludovic Courtès --- gnu/packages/gnome.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 60141fce9..561936f16 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -162,6 +162,7 @@ #:use-module (guix build-system glib-or-gtk) #:use-module (guix build-system gnu) #:use-module (guix build-system meson) + #:use-module (guix build-system python) #:use-module (guix build-system trivial) #:use-module (guix download) #:use-module (guix git-download) @@ -8021,3 +8022,48 @@ functionality.") (description "GThumb is an image viewer, browser, organizer, editor and advanced image management tool") (license license:gpl2+))) + +(define-public terminator + (package + (name "terminator") + (version "1.91") + (source (origin + (method url-fetch) + (uri (string-append "https://launchpad.net/" name "/" + "gtk3/" version "/" "+download/" + name "-" version ".tar.gz")) + (sha256 + (base32 + "0sdyqwydmdnh7j6mn74vrywz35m416kqsbxbrqcnv5ak08y6xxwm")))) + (build-system python-build-system) + (native-inputs + `(("intltool" ,intltool) + ("glib:bin" ,glib "bin") ; for glib-compile-resources + ("gettext" ,gettext-minimal) + ("pkg-config" ,pkg-config))) + (inputs + `(("cairo" ,cairo) + ("gobject-introspection" ,gobject-introspection) + ("python2-pycairo" ,python2-pycairo) + ("python2-pygobject" ,python2-pygobject) + ("python2-psutil" ,python2-psutil) + ("vte" ,vte))) + (arguments + `(#:python ,python-2 ;Python 3 not supported + #:phases + (modify-phases %standard-phases + (add-after + 'install 'wrap-program + (lambda* (#:key outputs #:allow-other-keys) + (let ((prog (string-append (assoc-ref outputs "out") + "/bin/terminator"))) + (wrap-program prog + `("PYTHONPATH" = (,(getenv "PYTHONPATH"))) + `("GI_TYPELIB_PATH" = (,(getenv "GI_TYPELIB_PATH")))) + #t)))))) + (home-page "https://gnometerminator.blogspot.com/") + (synopsis "Store and run multiple GNOME terminals in one window") + (description + "Terminator allows you to run multiple GNOME terminals in a grid and ++tabs, and it supports drag and drop re-ordering of terminals.") + (license license:gpl2))) -- cgit v1.3 From 88bc3c89bf5145d24c2270d2192b7be547e0024f Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sun, 2 Jun 2019 01:29:38 +0200 Subject: progress: Provide the proper type for %PROGRESS-INTERVAL. The (srfi srfi-19) module of Guile 2.9.2 catches the wrong type. * guix/progress.scm (%progress-interval): Change type to TIME-DURATION. --- guix/progress.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/guix/progress.scm b/guix/progress.scm index 65080bcf2..f150b081d 100644 --- a/guix/progress.scm +++ b/guix/progress.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2017 Sou Bunnbu ;;; Copyright © 2015 Steve Sprang -;;; Copyright © 2017, 2018 Ludovic Courtès +;;; Copyright © 2017, 2018, 2019 Ludovic Courtès ;;; Copyright © 2018 Clément Lassieur ;;; ;;; This file is part of GNU Guix. @@ -229,7 +229,7 @@ throughput." (define %progress-interval ;; Default interval between subsequent outputs for rate-limited displays. - (make-time time-monotonic 200000000 0)) + (make-time time-duration 200000000 0)) (define* (progress-reporter/file file size #:optional (log-port (current-output-port)) -- cgit v1.3 From bb64b2e7c0ab14cf899c1d81892b59fa877d4d9c Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sun, 2 Jun 2019 01:30:42 +0200 Subject: herd: Use the Guile 2.2 'setvbuf' API. * gnu/services/herd.scm (open-connection): Use 'block for 'setvbuf'. --- gnu/services/herd.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/services/herd.scm b/gnu/services/herd.scm index 9fe757fb7..0008746fe 100644 --- a/gnu/services/herd.scm +++ b/gnu/services/herd.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2016, 2017, 2018 Ludovic Courtès +;;; Copyright © 2016, 2017, 2018, 2019 Ludovic Courtès ;;; Copyright © 2017 Mathieu Othacehe ;;; ;;; This file is part of GNU Guix. @@ -76,7 +76,7 @@ return the socket." (catch 'system-error (lambda () (connect sock address) - (setvbuf sock _IOFBF 1024) + (setvbuf sock 'block 1024) sock) (lambda args (close-port sock) -- cgit v1.3 From b2cddc6fb1df4bbde23149b3a36ac4cdfe1bd535 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sun, 2 Jun 2019 01:32:12 +0200 Subject: compile: Adjust for Guile 3. * guix/build/compile.scm (%default-optimizations): Adjust to the new names in Guile 2.9.2. --- guix/build/compile.scm | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/guix/build/compile.scm b/guix/build/compile.scm index 9e31be93f..794f12379 100644 --- a/guix/build/compile.scm +++ b/guix/build/compile.scm @@ -40,8 +40,12 @@ (define %default-optimizations ;; Default optimization options (equivalent to -O2 on Guile 2.2). - (append (tree-il-default-optimization-options) - (cps-default-optimization-options))) + (append (if (defined? 'tree-il-default-optimization-options) + (tree-il-default-optimization-options) ;Guile 2.2 + (tree-il-optimizations)) ;Guile 3 + (if (defined? 'cps-default-optimization-options) + (cps-default-optimization-options) ;Guile 2.2 + (cps-optimizations)))) ;Guile 3 (define %lightweight-optimizations ;; Lightweight optimizations (like -O0, but with partial evaluation). -- cgit v1.3 From 1a2fa342f0eac9aea5f16d0bb660fdf89bc9651e Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 2 Jun 2019 02:02:41 +0200 Subject: gnu: musescore: Update to 3.1. * gnu/packages/music.scm (musescore): Update to 3.1. --- gnu/packages/music.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index 9ee5206b3..8ca297b71 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -3727,7 +3727,7 @@ audio samples and various soft sythesizers. It can receive input from a MIDI ke (define-public musescore (package (name "musescore") - (version "3.0.5") + (version "3.1") (source (origin (method git-fetch) (uri (git-reference @@ -3736,7 +3736,7 @@ audio samples and various soft sythesizers. It can receive input from a MIDI ke (file-name (git-file-name name version)) (sha256 (base32 - "1inf6zdyh6yspjv1i7g6rw9wn90vki1s2qgilkp0j4aphayj4mic")) + "07xkn8gnnqzhj9cn1li5qpm2rfm86bmxbbfd76i1jx4v999icn0j")) (modules '((guix build utils))) (snippet ;; Un-bundle OpenSSL and remove unused libraries. -- cgit v1.3 From fd4d3939c41414297a11bcac09840b51c5070e16 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sun, 2 Jun 2019 02:21:15 +0200 Subject: gnu: giac: Update to 1.5.0-57. * gnu/packages/algebra.scm (giac): Update to 1.5.0-57. --- gnu/packages/algebra.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/algebra.scm b/gnu/packages/algebra.scm index 128d41a57..69163a43d 100644 --- a/gnu/packages/algebra.scm +++ b/gnu/packages/algebra.scm @@ -251,7 +251,7 @@ precision.") (define-public giac (package (name "giac") - (version "1.5.0-49") + (version "1.5.0-57") (source (origin (method url-fetch) ;; "~parisse/giac" is not used because the maintainer regularly @@ -263,7 +263,7 @@ precision.") "source/giac_" version ".tar.gz")) (sha256 (base32 - "0f4pkand9vmqfayw18jm5qxbhcwi1405qfd7ibzh9lwzz6amkm3l")))) + "08c93knsisbk9dkyyrignw0wvqbr1sa5czlvk5l307ahxbbmqncf")))) (build-system gnu-build-system) (arguments `(#:modules ((ice-9 ftw) -- cgit v1.3 From 76513c949b63c675c602bc634e0738efc4f5d9ab Mon Sep 17 00:00:00 2001 From: Vagrant Cascadian Date: Sat, 1 Jun 2019 17:31:46 -0700 Subject: gnu: debian-archive-keyring: Update to 2019.01. * gnu/packages/debian (debian-archive-keyring): Update to 2019.01. --- gnu/packages/debian.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/debian.scm b/gnu/packages/debian.scm index ba1954789..ce96159a0 100644 --- a/gnu/packages/debian.scm +++ b/gnu/packages/debian.scm @@ -32,7 +32,7 @@ (define-public debian-archive-keyring (package (name "debian-archive-keyring") - (version "2018.1") + (version "2019.1") (source (origin (method git-fetch) @@ -42,7 +42,7 @@ (file-name (git-file-name name version)) (sha256 (base32 - "136vr5dj7w0dz563qdghsndcfcqm2m8d4j1dyiq9dzx5vd0rcpcw")))) + "0bphwji3ywk1zi5bq8bhqk7l51fwjy1idwsw7zfqnxca8m5wvw1g")))) (build-system gnu-build-system) (arguments '(#:test-target "verify-results" -- cgit v1.3 From 54d14302462a68a9d96360f0d88236fdc39c17a0 Mon Sep 17 00:00:00 2001 From: Vagrant Cascadian Date: Sat, 1 Jun 2019 17:57:26 -0700 Subject: gnu: debootstrap: Update to 114. * gnu/packages/debian (debootstrap): Update to 114. --- gnu/packages/debian.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/debian.scm b/gnu/packages/debian.scm index ce96159a0..1b401bc94 100644 --- a/gnu/packages/debian.scm +++ b/gnu/packages/debian.scm @@ -117,7 +117,7 @@ contains the archive keys used for that.") (define-public debootstrap (package (name "debootstrap") - (version "1.0.111") + (version "1.0.114") (source (origin (method git-fetch) @@ -127,7 +127,7 @@ contains the archive keys used for that.") (file-name (git-file-name name version)) (sha256 (base32 - "1b8s00a2kvaajqhjlms3q2dk3gqv6g4yq9h843jal1pm66zsx19n")))) + "147308flz9y8g6f972izi3szmsywf5f8xm64z2smy1cayd340i63")))) (build-system gnu-build-system) (arguments `(#:phases -- cgit v1.3 From 08f48b7864b0a50c42c710bb5118213fb88f8a87 Mon Sep 17 00:00:00 2001 From: Rutger Helling Date: Sun, 2 Jun 2019 10:49:26 +0200 Subject: gnu: faudio: Update to 19.06. * gnu/packages/audio.scm (faudio): Update to 19.06. --- gnu/packages/audio.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm index c897e3045..592a1ba94 100644 --- a/gnu/packages/audio.scm +++ b/gnu/packages/audio.scm @@ -3701,7 +3701,7 @@ library.") (define-public faudio (package (name "faudio") - (version "19.05") + (version "19.06") (source (origin (method git-fetch) @@ -3710,7 +3710,7 @@ library.") (commit version))) (file-name (string-append name "-" version "-checkout")) (sha256 - (base32 "1dja2ykixk1ycqda116cg9fy4qg364dqj88amfln0r9pnsj2kbxk")))) + (base32 "1azjf972hik1cizsblbvfp38xz7dx368pbpw3pd6z1xk9mnrhi6s")))) (arguments '(#:tests? #f ; No tests. #:configure-flags '("-DFFMPEG=ON"))) -- cgit v1.3 From bdf2dd797e1e57dab1d504a6e1af783ec5802afd Mon Sep 17 00:00:00 2001 From: Jan Nieuwenhuizen Date: Fri, 31 May 2019 19:47:21 +0200 Subject: gnu: Add guile-gi. * gnu/packages/guile-xyz.scm (guile-gi): New variable. --- gnu/packages/guile-xyz.scm | 44 +++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 43 insertions(+), 1 deletion(-) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index 365f909c2..adf0bf6b6 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -9,7 +9,7 @@ ;;; Copyright © 2016, 2017 Alex Kost ;;; Copyright © 2016, 2017 Adonay "adfeno" Felipe Nogueira ;;; Copyright © 2016 Amirouche -;;; Copyright © 2016 Jan Nieuwenhuizen +;;; Copyright © 2016, 2019 Jan Nieuwenhuizen ;;; Copyright © 2017 Andy Wingo ;;; Copyright © 2017 David Thompson ;;; Copyright © 2017, 2018 Mathieu Othacehe @@ -53,8 +53,10 @@ #:use-module (gnu packages gawk) #:use-module (gnu packages gettext) #:use-module (gnu packages gl) + #:use-module (gnu packages glib) #:use-module (gnu packages gnome) #:use-module (gnu packages gperf) + #:use-module (gnu packages gtk) #:use-module (gnu packages guile) #:use-module (gnu packages hurd) #:use-module (gnu packages image) @@ -76,6 +78,7 @@ #:use-module (gnu packages texinfo) #:use-module (gnu packages tls) #:use-module (gnu packages version-control) + #:use-module (gnu packages webkit) #:use-module (gnu packages xdisorg) #:use-module (gnu packages xorg) #:use-module (guix packages) @@ -2232,3 +2235,42 @@ slashes are present and accounted for, resolving @code{.} and @code{..}, etc). Inevitably, you have to break the string up into chunks and operate on that list of components. This module takes care of that for you.") (license license:lgpl3+))) + +(define-public guile-gi + (let ((commit "91753258892c4a1fbf7ed43ff793a00ac0f77cf6") + (revision "0")) + (package + (name "guile-gi") + (version (string-append "0.0.1-" revision "." (string-take commit 7))) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://gitlab.com/janneke/guile-gi.git") + (commit commit))) + (file-name (string-append name "-" version)) + (sha256 + (base32 + "1i76jfs90p8pbx0bfrjd4sias9380pmjb9x387rx7hav4kvnsd1b")))) + (build-system gnu-build-system) + (native-inputs `(("autoconf" ,autoconf) + ("automake" ,automake) + ("gettext" ,gnu-gettext) + ("libtool" ,libtool) + ("pkg-config" ,pkg-config) + ("texinfo" ,texinfo))) + (propagated-inputs `(("glib" ,glib) + ("gobject-introspection" ,gobject-introspection) + ("gssettings-desktop-schemas" ,gsettings-desktop-schemas) + ("gtk+" ,gtk+) + ("guile-lib" ,guile-lib) + ("webkitgtk" ,webkitgtk))) + (inputs `(("guile" ,guile-2.2))) + (arguments + `(#:configure-flags '("--with-gnu-filesystem-hierarchy"))) + (home-page "https://github.com/spk121/guile-gi") + (synopsis "GObject bindings for Guile") + (description + "Guile-GI is a library for Guile that allows using GObject-based +libraries, such as GTK+3. Its README comes with the disclaimer: This is +pre-alpha code.") + (license license:gpl3+)))) -- cgit v1.3 From abeb54c00b320f8c3a220f54b6413837f6deac35 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sun, 2 Jun 2019 20:57:59 +0200 Subject: build-system/guile: Improve reporting of 'guild compile' failures. * guix/build/guile-build-system.scm (invoke-each)[processes]: New variable. [wait-for-one-process]: Check PROCESSES and update it. [fork-and-run-command]: Update PROCESSES. --- guix/build/guile-build-system.scm | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/guix/build/guile-build-system.scm b/guix/build/guile-build-system.scm index 31f0d3d6f..69819c87f 100644 --- a/guix/build/guile-build-system.scm +++ b/guix/build/guile-build-system.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2018 Ludovic Courtès +;;; Copyright © 2018, 2019 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -74,11 +74,19 @@ Raise an error if one of the processes exit with non-zero." (define total (length commands)) + (define processes + (make-hash-table)) + (define (wait-for-one-process) (match (waitpid WAIT_ANY) - ((_ . status) - (unless (zero? (status:exit-val status)) - (error "process failed" status))))) + ((pid . status) + (let ((command (hashv-ref processes pid))) + (hashv-remove! processes command) + (unless (zero? (status:exit-val status)) + (format (current-error-port) + "process '~{~a ~}' failed with status ~a~%" + command status) + (exit 1)))))) (define (fork-and-run-command command) (match (primitive-fork) @@ -90,6 +98,7 @@ Raise an error if one of the processes exit with non-zero." (lambda () (primitive-exit 127)))) (pid + (hashv-set! processes pid command) #t))) (let loop ((commands commands) -- cgit v1.3 From 30eb73836684ff8502063c43f3b315174e0d3a0b Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sun, 2 Jun 2019 20:59:34 +0200 Subject: build-system/guile: Add #:not-compiled-file-regexp. * guix/build/guile-build-system.scm (build): Add #:not-compiled-file-regexp and honor it. * guix/build-system/guile.scm (guile-build): Likewise. (guile-cross-build): Likewise. --- guix/build-system/guile.scm | 6 +++++- guix/build/guile-build-system.scm | 30 +++++++++++++++++++----------- 2 files changed, 24 insertions(+), 12 deletions(-) diff --git a/guix/build-system/guile.scm b/guix/build-system/guile.scm index 77a5f00b0..2c5cc968c 100644 --- a/guix/build-system/guile.scm +++ b/guix/build-system/guile.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2018 Ludovic Courtès +;;; Copyright © 2018, 2019 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -75,6 +75,7 @@ (search-paths '()) (system (%current-system)) (source-directory ".") + not-compiled-file-regexp (compile-flags %compile-flags) (imported-modules %guile-build-system-modules) (modules '((guix build guile-build-system) @@ -92,6 +93,7 @@ (source source)) #:source-directory ,source-directory + #:not-compiled-file-regexp ,not-compiled-file-regexp #:compile-flags ,compile-flags #:phases ,phases #:system ,system @@ -128,6 +130,7 @@ (phases '%standard-phases) (source-directory ".") + not-compiled-file-regexp (compile-flags %compile-flags) (imported-modules %guile-build-system-modules) (modules '((guix build guile-build-system) @@ -168,6 +171,7 @@ #:target ,target #:outputs %outputs #:source-directory ,source-directory + #:not-compiled-file-regexp ,not-compiled-file-regexp #:compile-flags ,compile-flags #:inputs %build-target-inputs #:native-inputs %build-host-inputs diff --git a/guix/build/guile-build-system.scm b/guix/build/guile-build-system.scm index 69819c87f..eb7a91840 100644 --- a/guix/build/guile-build-system.scm +++ b/guix/build/guile-build-system.scm @@ -19,10 +19,12 @@ (define-module (guix build guile-build-system) #:use-module ((guix build gnu-build-system) #:prefix gnu:) #:use-module (guix build utils) + #:use-module (srfi srfi-1) #:use-module (srfi srfi-26) #:use-module (ice-9 match) #:use-module (ice-9 popen) #:use-module (ice-9 rdelim) + #:use-module (ice-9 regex) #:use-module (guix build utils) #:export (target-guile-effective-version %standard-phases @@ -134,9 +136,12 @@ Raise an error if one of the processes exit with non-zero." (source-directory ".") (compile-flags '()) (scheme-file-regexp %scheme-file-regexp) + (not-compiled-file-regexp #f) target #:allow-other-keys) - "Build files in SOURCE-DIRECTORY that match SCHEME-FILE-REGEXP." + "Build files in SOURCE-DIRECTORY that match SCHEME-FILE-REGEXP. Files +matching NOT-COMPILED-FILE-REGEXP, if true, are not compiled but are +installed; this is useful for files that are meant to be included." (let* ((out (assoc-ref outputs "out")) (guile (assoc-ref (or native-inputs inputs) "guile")) (effective (target-guile-effective-version guile)) @@ -171,16 +176,19 @@ Raise an error if one of the processes exit with non-zero." (with-directory-excursion source-directory (find-files "." scheme-file-regexp)))) (invoke-each - (map (lambda (file) - (cons* guild - "guild" "compile" - "-L" source-directory - "-o" (string-append go-dir - (file-sans-extension file) - ".go") - (string-append source-directory "/" file) - flags)) - source-files) + (filter-map (lambda (file) + (and (or (not not-compiled-file-regexp) + (not (string-match not-compiled-file-regexp + file))) + (cons* guild + "guild" "compile" + "-L" source-directory + "-o" (string-append go-dir + (file-sans-extension file) + ".go") + (string-append source-directory "/" file) + flags))) + source-files) #:max-processes (parallel-job-count) #:report-progress report-build-progress) -- cgit v1.3 From e006f7493feb35044f4965181c9199d9fdde1843 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sun, 2 Jun 2019 21:07:24 +0200 Subject: build-system/guile: Display progress report as expected by (guix status). * guix/build/guile-build-system.scm (report-build-progress): Use a format string suitable for (guix status). --- guix/build/guile-build-system.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/guix/build/guile-build-system.scm b/guix/build/guile-build-system.scm index eb7a91840..32a431d34 100644 --- a/guix/build/guile-build-system.scm +++ b/guix/build/guile-build-system.scm @@ -25,6 +25,7 @@ #:use-module (ice-9 popen) #:use-module (ice-9 rdelim) #:use-module (ice-9 regex) + #:use-module (ice-9 format) #:use-module (guix build utils) #:export (target-guile-effective-version %standard-phases @@ -128,8 +129,8 @@ Raise an error if one of the processes exit with non-zero." (define* (report-build-progress total completed #:optional (log-port (current-error-port))) "Report that COMPLETED out of TOTAL files have been completed." - (format log-port "compiling...\t~5,1f% of ~d files~%" ;FIXME: i18n - (* 100. (/ completed total)) total) + (format log-port "[~2d/~2d] Compiling...~%" + completed total) (force-output log-port)) (define* (build #:key outputs inputs native-inputs -- cgit v1.3 From dec4b3aa18e24466841244c3e34b255201bbcc9e Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sun, 2 Jun 2019 21:45:08 +0200 Subject: gnu: Add guile-srfi-159. * gnu/packages/guile-xyz.scm (guile-srfi-159): New variable. --- gnu/packages/guile-xyz.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm index adf0bf6b6..43bdcab26 100644 --- a/gnu/packages/guile-xyz.scm +++ b/gnu/packages/guile-xyz.scm @@ -84,6 +84,7 @@ #:use-module (guix packages) #:use-module (guix download) #:use-module (guix git-download) + #:use-module (guix hg-download) #:use-module (guix build-system gnu) #:use-module (guix build-system guile) #:use-module (guix utils) @@ -2274,3 +2275,33 @@ list of components. This module takes care of that for you.") libraries, such as GTK+3. Its README comes with the disclaimer: This is pre-alpha code.") (license license:gpl3+)))) + +(define-public guile-srfi-159 + (let ((commit "1bd98abda2ae4ef8f36761a167903e55c6bda7bb") + (revision "0")) + (package + (name "guile-srfi-159") + (version (git-version "0" revision commit)) + (home-page "https://bitbucket.org/bjoli/guile-srfi-159") + (source (origin + (method hg-fetch) + (uri (hg-reference (changeset commit) + (url home-page))) + (sha256 + (base32 + "1zw6cmcy7xdbfiz3nz9arqnn7l2daidaps6ixkcrc9b6k51fdv3p")) + (file-name (git-file-name name version)))) + (build-system guile-build-system) + (arguments + ;; The *-impl.scm files are actually included from module files; they + ;; should not be compiled separately, but they must be installed. + '(#:not-compiled-file-regexp "-impl\\.scm$")) + (inputs + `(("guile" ,guile-2.2))) + (synopsis "Formatting combinators for Guile") + (description + "The @code{(srfi-159)} module and its sub-modules implement the +formatting combinators specified by +@uref{https://srfi.schemers.org/srfi-159/srfi-159.html, SRFI-159}. These are +more expressive and flexible than the traditional @code{format} procedure.") + (license license:bsd-3)))) -- cgit v1.3 From b8fa86adfc01205f1d942af8cb57515eb3726c52 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Thu, 30 May 2019 18:36:37 +0200 Subject: publish: '--compression' can be repeated. This allows 'guix publish' to compress and advertise multiple compression methods from which users can choose. * guix/scripts/publish.scm (actual-compression): Rename to... (actual-compressions): ... this. Expect REQUESTED to be a list, and always return a list. (%default-options): Remove 'compression. (store-item->recutils): New procedure. (narinfo-string): Change #:compression to #:compressions (plural). Adjust accordingly. (render-narinfo, render-narinfo/cached): Likewise. (bake-narinfo+nar): Change #:compression to #:compressions. [compressed-nar-size]: New procedure. Call 'compress-nar' for each item returned by 'actual-compressions'. Create a narinfo for each compression. (effective-compression): New procedure. (make-request-handler): Change #:compression to #:compressions. Use 'effective-compression' to determine the applicable compression. (guix-publish): Adjust handling of '--compression'. Print a message for each compression that is enabled. * tests/publish.scm ("/*.narinfo"): Adjust to new narinfo field ordering. ("/*.narinfo with properly encoded '+' sign"): Likewise. ("/*.narinfo with lzip + gzip"): New test. ("with cache, lzip + gzip"): New test. * doc/guix.texi (Invoking guix publish): Document it. --- doc/guix.texi | 5 ++ guix/scripts/publish.scm | 206 ++++++++++++++++++++++++++++------------------- tests/publish.scm | 89 ++++++++++++++++++-- 3 files changed, 211 insertions(+), 89 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index 786788bad..c01eb3a65 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -9685,6 +9685,11 @@ run @command{guix publish} behind a caching proxy, or to use allows @command{guix publish} to add @code{Content-Length} HTTP header to its responses. +This option can be repeated, in which case every substitute gets compressed +using all the selected methods, and all of them are advertised. This is +useful when users may not support all the compression methods: they can select +the one they support. + @item --cache=@var{directory} @itemx -c @var{directory} Cache archives and meta-data (@code{.narinfo} URLs) to @var{directory} diff --git a/guix/scripts/publish.scm b/guix/scripts/publish.scm index c55873db7..b4334b3f1 100644 --- a/guix/scripts/publish.scm +++ b/guix/scripts/publish.scm @@ -125,11 +125,11 @@ Publish ~a over HTTP.\n") %store-directory) (define (default-compression type) (compression type 3)) -(define (actual-compression item requested) - "Return the actual compression used for ITEM, which may be %NO-COMPRESSION +(define (actual-compressions item requested) + "Return the actual compressions used for ITEM, which may be %NO-COMPRESSION if ITEM is already compressed." (if (compressed-file? item) - %no-compression + (list %no-compression) requested)) (define %options @@ -217,11 +217,6 @@ if ITEM is already compressed." (public-key-file . ,%public-key-file) (private-key-file . ,%private-key-file) - ;; Default to fast & low compression. - (compression . ,(if (zlib-available?) - %default-gzip-compression - %no-compression)) - ;; Default number of workers when caching is enabled. (workers . ,(current-processor-count)) @@ -249,29 +244,40 @@ if ITEM is already compressed." (define base64-encode-string (compose base64-encode string->utf8)) +(define* (store-item->recutils store-item + #:key + (nar-path "nar") + (compression %no-compression) + file-size) + "Return the 'Compression' and 'URL' fields of the narinfo for STORE-ITEM, +with COMPRESSION, starting at NAR-PATH." + (let ((url (encode-and-join-uri-path + `(,@(split-and-decode-uri-path nar-path) + ,@(match compression + (($ 'none) + '()) + (($ type) + (list (symbol->string type)))) + ,(basename store-item))))) + (format #f "URL: ~a~%Compression: ~a~%~@[FileSize: ~a~%~]" + url (compression-type compression) file-size))) + (define* (narinfo-string store store-path key - #:key (compression %no-compression) - (nar-path "nar") file-size) + #:key (compressions (list %no-compression)) + (nar-path "nar") (file-sizes '())) "Generate a narinfo key/value string for STORE-PATH; an exception is raised if STORE-PATH is invalid. Produce a URL that corresponds to COMPRESSION. The narinfo is signed with KEY. NAR-PATH specifies the prefix for nar URLs. -Optionally, FILE-SIZE can specify the size in bytes of the compressed NAR; it -informs the client of how much needs to be downloaded." + +Optionally, FILE-SIZES is a list of compression/integer pairs, where the +integer is size in bytes of the compressed NAR; it informs the client of how +much needs to be downloaded." (let* ((path-info (query-path-info store store-path)) - (compression (actual-compression store-path compression)) - (url (encode-and-join-uri-path - `(,@(split-and-decode-uri-path nar-path) - ,@(match compression - (($ 'none) - '()) - (($ type) - (list (symbol->string type)))) - ,(basename store-path)))) + (compressions (actual-compressions store-path compressions)) (hash (bytevector->nix-base32-string (path-info-hash path-info))) (size (path-info-nar-size path-info)) - (file-size (or file-size - (and (eq? compression %no-compression) size))) + (file-sizes `((,%no-compression . ,size) ,@file-sizes)) (references (string-join (map basename (path-info-references path-info)) " ")) @@ -279,17 +285,21 @@ informs the client of how much needs to be downloaded." (base-info (format #f "\ StorePath: ~a -URL: ~a -Compression: ~a +~{~a~}\ NarHash: sha256:~a NarSize: ~d -References: ~a~%~a" - store-path url - (compression-type compression) - hash size references - (if file-size - (format #f "FileSize: ~a~%" file-size) - ""))) +References: ~a~%" + store-path + (map (lambda (compression) + (let ((size (assoc-ref file-sizes + compression))) + (store-item->recutils store-path + #:file-size size + #:nar-path nar-path + #:compression + compression))) + compressions) + hash size references)) ;; Do not render a "Deriver" or "System" line if we are rendering ;; info for a derivation. (info (if (not deriver) @@ -332,7 +342,7 @@ References: ~a~%~a" %nix-cache-info)))) (define* (render-narinfo store request hash - #:key ttl (compression %no-compression) + #:key ttl (compressions (list %no-compression)) (nar-path "nar")) "Render metadata for the store path corresponding to HASH. If TTL is true, advertise it as the maximum validity period (in seconds) via the @@ -348,7 +358,7 @@ appropriate duration. NAR-PATH specifies the prefix for nar URLs." (cut display (narinfo-string store store-path (%private-key) #:nar-path nar-path - #:compression compression) + #:compressions compressions) <>))))) (define* (nar-cache-file directory item @@ -442,7 +452,7 @@ vanished from the store in the meantime." (apply throw args)))))) (define* (render-narinfo/cached store request hash - #:key ttl (compression %no-compression) + #:key ttl (compressions (list %no-compression)) (nar-path "nar") cache pool) "Respond to the narinfo request for REQUEST. If the narinfo is available in @@ -460,11 +470,12 @@ requested using POOL." (delete-file* nar) (delete-file* mapping))) - (let* ((item (hash-part->path* store hash cache)) - (compression (actual-compression item compression)) - (cached (and (not (string-null? item)) - (narinfo-cache-file cache item - #:compression compression)))) + (let* ((item (hash-part->path* store hash cache)) + (compressions (actual-compressions item compressions)) + (cached (and (not (string-null? item)) + (narinfo-cache-file cache item + #:compression + (first compressions))))) (cond ((string-null? item) (not-found request)) ((file-exists? cached) @@ -488,7 +499,7 @@ requested using POOL." ;; (format #t "baking ~s~%" item) (bake-narinfo+nar cache item #:ttl ttl - #:compression compression + #:compressions compressions #:nar-path nar-path))) (when ttl @@ -535,30 +546,45 @@ requested using POOL." (write-file item port)))))) (define* (bake-narinfo+nar cache item - #:key ttl (compression %no-compression) + #:key ttl (compressions (list %no-compression)) (nar-path "/nar")) "Write the narinfo and nar for ITEM to CACHE." - (let* ((compression (actual-compression item compression)) - (nar (nar-cache-file cache item - #:compression compression)) - (narinfo (narinfo-cache-file cache item - #:compression compression))) - (compress-nar cache item compression) - - (mkdir-p (dirname narinfo)) - (with-atomic-file-output narinfo - (lambda (port) - ;; Open a new connection to the store. We cannot reuse the main - ;; thread's connection to the store since we would end up sending - ;; stuff concurrently on the same channel. - (with-store store - (display (narinfo-string store item - (%private-key) - #:nar-path nar-path - #:compression compression - #:file-size (and=> (stat nar #f) - stat:size)) - port)))))) + (define (compressed-nar-size compression) + (let* ((nar (nar-cache-file cache item #:compression compression)) + (stat (stat nar #f))) + (and stat + (cons compression (stat:size stat))))) + + (let ((compression (actual-compressions item compressions))) + + (for-each (cut compress-nar cache item <>) compressions) + + (match compressions + ((main others ...) + (let ((narinfo (narinfo-cache-file cache item + #:compression main))) + (with-atomic-file-output narinfo + (lambda (port) + ;; Open a new connection to the store. We cannot reuse the main + ;; thread's connection to the store since we would end up sending + ;; stuff concurrently on the same channel. + (with-store store + (let ((sizes (filter-map compressed-nar-size compression))) + (display (narinfo-string store item + (%private-key) + #:nar-path nar-path + #:compressions compressions + #:file-sizes sizes) + port))))) + + ;; Make narinfo files for OTHERS hard links to NARINFO such that the + ;; atime-based cache eviction considers either all the nars or none + ;; of them as candidates. + (for-each (lambda (other) + (let ((other (narinfo-cache-file cache item + #:compression other))) + (link narinfo other))) + others)))))) ;; XXX: Declare the 'X-Nar-Compression' HTTP header, which is in fact for ;; internal consumption: it allows us to pass the compression info to @@ -827,12 +853,22 @@ blocking." ("lzip" (and (lzlib-available?) 'lzip)) (_ #f))) +(define (effective-compression requested-type compressions) + "Given the REQUESTED-TYPE for compression and the set of chosen COMPRESSION +methods, return the applicable compression." + (or (find (match-lambda + (($ type) + (and (eq? type requested-type) + compression))) + compressions) + (default-compression requested-type))) + (define* (make-request-handler store #:key cache pool narinfo-ttl (nar-path "nar") - (compression %no-compression)) + (compressions (list %no-compression))) (define compression-type? string->compression-type) @@ -860,11 +896,11 @@ blocking." #:pool pool #:ttl narinfo-ttl #:nar-path nar-path - #:compression compression) + #:compressions compressions) (render-narinfo store request hash #:ttl narinfo-ttl #:nar-path nar-path - #:compression compression))) + #:compressions compressions))) ;; /nar/file/NAME/sha256/HASH (("file" name "sha256" hash) (guard (c ((invalid-base32-character? c) @@ -885,15 +921,8 @@ blocking." ((components ... (? compression-type? type) store-item) (if (nar-path? components) (let* ((compression-type (string->compression-type type)) - (compression (match compression - (($ type) - (if (eq? type compression-type) - compression - (default-compression - compression-type))) - (_ - (default-compression - compression-type))))) + (compression (effective-compression compression-type + compressions))) (if cache (render-nar/cached store cache request store-item #:ttl narinfo-ttl @@ -917,7 +946,8 @@ blocking." (not-found request)))) (define* (run-publish-server socket store - #:key (compression %no-compression) + #:key + (compressions (list %no-compression)) (nar-path "nar") narinfo-ttl cache pool) (run-server (make-request-handler store @@ -925,7 +955,7 @@ blocking." #:pool pool #:nar-path nar-path #:narinfo-ttl narinfo-ttl - #:compression compression) + #:compressions compressions) concurrent-http-server `(#:socket ,socket))) @@ -964,7 +994,17 @@ blocking." (user (assoc-ref opts 'user)) (port (assoc-ref opts 'port)) (ttl (assoc-ref opts 'narinfo-ttl)) - (compression (assoc-ref opts 'compression)) + (compressions (match (filter-map (match-lambda + (('compression . compression) + compression) + (_ #f)) + opts) + (() + ;; Default to fast & low compression. + (list (if (zlib-available?) + %default-gzip-compression + %no-compression))) + (lst (reverse lst)))) (address (let ((addr (assoc-ref opts 'address))) (make-socket-address (sockaddr:fam addr) (sockaddr:addr addr) @@ -996,9 +1036,11 @@ consider using the '--user' option!~%"))) (inet-ntop (sockaddr:fam address) (sockaddr:addr address)) (sockaddr:port address)) - (when compression - (info (G_ "using '~a' compression method, level ~a~%") - (compression-type compression) (compression-level compression))) + (for-each (lambda (compression) + (info (G_ "using '~a' compression method, level ~a~%") + (compression-type compression) + (compression-level compression))) + compressions) (when repl-port (repl:spawn-server (repl:make-tcp-server-socket #:port repl-port))) @@ -1013,7 +1055,7 @@ consider using the '--user' option!~%"))) #:thread-name "publish worker")) #:nar-path nar-path - #:compression compression + #:compressions compressions #:narinfo-ttl ttl)))))) ;;; Local Variables: diff --git a/tests/publish.scm b/tests/publish.scm index 80e0977cd..64a8ff3ca 100644 --- a/tests/publish.scm +++ b/tests/publish.scm @@ -138,17 +138,17 @@ "StorePath: ~a URL: nar/~a Compression: none +FileSize: ~a NarHash: sha256:~a NarSize: ~d -References: ~a -FileSize: ~a~%" +References: ~a~%" %item (basename %item) + (path-info-nar-size info) (bytevector->nix-base32-string (path-info-hash info)) (path-info-nar-size info) - (basename (first (path-info-references info))) - (path-info-nar-size info))) + (basename (first (path-info-references info))))) (signature (base64-encode (string->utf8 (canonical-sexp->string @@ -170,15 +170,15 @@ FileSize: ~a~%" "StorePath: ~a URL: nar/~a Compression: none +FileSize: ~a NarHash: sha256:~a NarSize: ~d -References: ~%\ -FileSize: ~a~%" +References: ~%" item (uri-encode (basename item)) + (path-info-nar-size info) (bytevector->nix-base32-string (path-info-hash info)) - (path-info-nar-size info) (path-info-nar-size info))) (signature (base64-encode (string->utf8 @@ -301,6 +301,35 @@ FileSize: ~a~%" (list (assoc-ref info "Compression") (dirname (assoc-ref info "URL"))))) +(unless (and (zlib-available?) (lzlib-available?)) + (test-skip 1)) +(test-equal "/*.narinfo with lzip + gzip" + `((("StorePath" . ,%item) + ("URL" . ,(string-append "nar/gzip/" (basename %item))) + ("Compression" . "gzip") + ("URL" . ,(string-append "nar/lzip/" (basename %item))) + ("Compression" . "lzip")) + 200 + 200) + (call-with-temporary-directory + (lambda (cache) + (let ((thread (with-separate-output-ports + (call-with-new-thread + (lambda () + (guix-publish "--port=6793" "-Cgzip:2" "-Clzip:2")))))) + (wait-until-ready 6793) + (let* ((base "http://localhost:6793/") + (part (store-path-hash-part %item)) + (url (string-append base part ".narinfo")) + (body (http-get-port url))) + (list (take (recutils->alist body) 5) + (response-code + (http-get (string-append base "nar/gzip/" + (basename %item)))) + (response-code + (http-get (string-append base "nar/lzip/" + (basename %item)))))))))) + (test-equal "custom nar path" ;; Serve nars at /foo/bar/chbouib instead of /nar. (list `(("StorePath" . ,%item) @@ -441,6 +470,52 @@ FileSize: ~a~%" (stat:size (stat nar))) (response-code uncompressed))))))))) +(unless (and (zlib-available?) (lzlib-available?)) + (test-skip 1)) +(test-equal "with cache, lzip + gzip" + '(200 200 404) + (call-with-temporary-directory + (lambda (cache) + (let ((thread (with-separate-output-ports + (call-with-new-thread + (lambda () + (guix-publish "--port=6794" "-Cgzip:2" "-Clzip:2" + (string-append "--cache=" cache))))))) + (wait-until-ready 6794) + (let* ((base "http://localhost:6794/") + (part (store-path-hash-part %item)) + (url (string-append base part ".narinfo")) + (nar-url (cute string-append "nar/" <> "/" + (basename %item))) + (cached (cute string-append cache "/" <> "/" + (basename %item) ".narinfo")) + (nar (cute string-append cache "/" <> "/" + (basename %item) ".nar")) + (response (http-get url))) + (wait-for-file (cached "gzip")) + (let* ((body (http-get-port url)) + (narinfo (recutils->alist body)) + (uncompressed (string-append base "nar/" + (basename %item)))) + (and (file-exists? (nar "gzip")) + (file-exists? (nar "lzip")) + (equal? (take (pk 'narinfo/gzip+lzip narinfo) 7) + `(("StorePath" . ,%item) + ("URL" . ,(nar-url "gzip")) + ("Compression" . "gzip") + ("FileSize" . ,(number->string + (stat:size (stat (nar "gzip"))))) + ("URL" . ,(nar-url "lzip")) + ("Compression" . "lzip") + ("FileSize" . ,(number->string + (stat:size (stat (nar "lzip"))))))) + (list (response-code + (http-get (string-append base (nar-url "gzip")))) + (response-code + (http-get (string-append base (nar-url "lzip")))) + (response-code + (http-get uncompressed)))))))))) + (unless (zlib-available?) (test-skip 1)) (let ((item (add-text-to-store %store "fake-compressed-thing.tar.gz" -- cgit v1.3 From b90ae065b5a5fab4ed475bf2faa3a84476389a02 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Fri, 31 May 2019 16:26:08 +0200 Subject: substitute: Select the best compression methods. When a server publishes several URLs with different compression methods, 'guix substitute' can now choose the best one among the compression methods that it supports. * guix/scripts/substitute.scm ()[uri]: Replace with... [uris]: ... this. [compression]: Replace with... [compressions]: ... this. [file-size]: Replace with... [file-sizes]: ... this. [file-hash]: Replace with... [file-hashes]: ... this. (narinfo-maker): Adjust accordingly. Ensure 'file-sizes' and 'file-hashes' have the right length. (assert-valid-signature, valid-narinfo?): Use the first element of 'narinfo-uris' in error messages. (read-narinfo): Expect "URL", "Compression", "FileSize", and "FileHash" to occur multiple times. (display-narinfo-data): Call 'select-uri' to determine the file size. (%compression-methods): New variable. (supported-compression?, compresses-better?, select-uri): New procedures. (process-substitution): Call 'select-uri' to select the URI and compression. * guix/scripts/weather.scm (report-server-coverage): Account for all the values returned by 'narinfo-file-sizes'. * tests/substitute.scm ("substitute, narinfo with several URLs"): New test. --- guix/scripts/challenge.scm | 4 +- guix/scripts/substitute.scm | 141 ++++++++++++++++++++++++++++++++------------ guix/scripts/weather.scm | 5 +- tests/substitute.scm | 51 +++++++++++++++- 4 files changed, 160 insertions(+), 41 deletions(-) diff --git a/guix/scripts/challenge.scm b/guix/scripts/challenge.scm index 65de42053..17e87f029 100644 --- a/guix/scripts/challenge.scm +++ b/guix/scripts/challenge.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2015, 2016, 2017 Ludovic Courtès +;;; Copyright © 2015, 2016, 2017, 2019 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -192,7 +192,7 @@ inconclusive reports." (report (G_ " no local build for '~a'~%") item)) (for-each (lambda (narinfo) (report (G_ " ~50a: ~a~%") - (uri->string (narinfo-uri narinfo)) + (uri->string (first (narinfo-uris narinfo))) (hash->string (narinfo-hash->sha256 (narinfo-hash narinfo))))) narinfos)) diff --git a/guix/scripts/substitute.scm b/guix/scripts/substitute.scm index 135398ba4..dba08edf5 100755 --- a/guix/scripts/substitute.scm +++ b/guix/scripts/substitute.scm @@ -42,6 +42,7 @@ #:use-module (guix progress) #:use-module ((guix build syscalls) #:select (set-thread-name)) + #:autoload (guix lzlib) (lzlib-available?) #:use-module (ice-9 rdelim) #:use-module (ice-9 regex) #:use-module (ice-9 match) @@ -66,11 +67,11 @@ narinfo? narinfo-path - narinfo-uri + narinfo-uris narinfo-uri-base - narinfo-compression - narinfo-file-hash - narinfo-file-size + narinfo-compressions + narinfo-file-hashes + narinfo-file-sizes narinfo-hash narinfo-size narinfo-references @@ -280,15 +281,16 @@ failure, return #f and #f." (define-record-type - (%make-narinfo path uri uri-base compression file-hash file-size nar-hash nar-size - references deriver system signature contents) + (%make-narinfo path uri-base uris compressions file-sizes file-hashes + nar-hash nar-size references deriver system + signature contents) narinfo? (path narinfo-path) - (uri narinfo-uri) - (uri-base narinfo-uri-base) ; URI of the cache it originates from - (compression narinfo-compression) - (file-hash narinfo-file-hash) - (file-size narinfo-file-size) + (uri-base narinfo-uri-base) ;URI of the cache it originates from + (uris narinfo-uris) ;list of strings + (compressions narinfo-compressions) ;list of strings + (file-sizes narinfo-file-sizes) ;list of (integers | #f) + (file-hashes narinfo-file-hashes) (nar-hash narinfo-hash) (nar-size narinfo-size) (references narinfo-references) @@ -334,17 +336,25 @@ s-expression: ~s~%") (define (narinfo-maker str cache-url) "Return a narinfo constructor for narinfos originating from CACHE-URL. STR must contain the original contents of a narinfo file." - (lambda (path url compression file-hash file-size nar-hash nar-size - references deriver system signature) + (lambda (path urls compressions file-hashes file-sizes + nar-hash nar-size references deriver system + signature) "Return a new object." - (%make-narinfo path + (define len (length urls)) + (%make-narinfo path cache-url ;; Handle the case where URL is a relative URL. - (or (string->uri url) - (string->uri (string-append cache-url "/" url))) - cache-url - - compression file-hash - (and=> file-size string->number) + (map (lambda (url) + (or (string->uri url) + (string->uri + (string-append cache-url "/" url)))) + urls) + compressions + (match file-sizes + (() (make-list len #f)) + ((lst ...) (map string->number lst))) + (match file-hashes + (() (make-list len #f)) + ((lst ...) (map string->number lst))) nar-hash (and=> nar-size string->number) (string-tokenize references) @@ -360,7 +370,7 @@ must contain the original contents of a narinfo file." #:optional (acl (current-acl))) "Bail out if SIGNATURE, a canonical sexp representing the signature of NARINFO, doesn't match HASH, a bytevector containing the hash of NARINFO." - (let ((uri (uri->string (narinfo-uri narinfo)))) + (let ((uri (uri->string (first (narinfo-uris narinfo))))) (signature-case (signature hash acl) (valid-signature #t) (invalid-signature @@ -387,7 +397,8 @@ No authentication and authorization checks are performed here!" '("StorePath" "URL" "Compression" "FileHash" "FileSize" "NarHash" "NarSize" "References" "Deriver" "System" - "Signature")))) + "Signature") + '("URL" "Compression" "FileSize" "FileHash")))) (define (narinfo-sha256 narinfo) "Return the sha256 hash of NARINFO as a bytevector, or #f if NARINFO lacks a @@ -414,7 +425,7 @@ No authentication and authorization checks are performed here!" (or %allow-unauthenticated-substitutes? (let ((hash (narinfo-sha256 narinfo)) (signature (narinfo-signature narinfo)) - (uri (uri->string (narinfo-uri narinfo)))) + (uri (uri->string (first (narinfo-uris narinfo))))) (and hash signature (signature-case (signature hash acl) (valid-signature #t) @@ -919,9 +930,11 @@ expected by the daemon." (length (narinfo-references narinfo))) (for-each (cute format #t "~a/~a~%" (%store-prefix) <>) (narinfo-references narinfo)) - (format #t "~a\n~a\n" - (or (narinfo-file-size narinfo) 0) - (or (narinfo-size narinfo) 0))) + + (let-values (((uri compression file-size) (select-uri narinfo))) + (format #t "~a\n~a\n" + (or file-size 0) + (or (narinfo-size narinfo) 0)))) (define* (process-query command #:key cache-urls acl) @@ -947,17 +960,73 @@ authorized substitutes." (wtf (error "unknown `--query' command" wtf)))) +(define %compression-methods + ;; Known compression methods and a thunk to determine whether they're + ;; supported. See 'decompressed-port' in (guix utils). + `(("gzip" . ,(const #t)) + ("lzip" . ,lzlib-available?) + ("xz" . ,(const #t)) + ("bzip2" . ,(const #t)) + ("none" . ,(const #t)))) + +(define (supported-compression? compression) + "Return true if COMPRESSION, a string, denotes a supported compression +method." + (match (assoc-ref %compression-methods compression) + (#f #f) + (supported? (supported?)))) + +(define (compresses-better? compression1 compression2) + "Return true if COMPRESSION1 generally compresses better than COMPRESSION2; +this is a rough approximation." + (match compression1 + ("none" #f) + ("gzip" (string=? compression2 "none")) + (_ (or (string=? compression2 "none") + (string=? compression2 "gzip"))))) + +(define (select-uri narinfo) + "Select the \"best\" URI to download NARINFO's nar, and return three values: +the URI, its compression method (a string), and the compressed file size." + (define choices + (filter (match-lambda + ((uri compression file-size) + (supported-compression? compression))) + (zip (narinfo-uris narinfo) + (narinfo-compressions narinfo) + (narinfo-file-sizes narinfo)))) + + (define (file-size acl))) - (uri (and=> narinfo narinfo-uri))) - (unless uri - (leave (G_ "no valid substitute for '~a'~%") - store-item)) + (define narinfo + (lookup-narinfo cache-urls store-item + (cut valid-narinfo? <> acl))) + + (unless narinfo + (leave (G_ "no valid substitute for '~a'~%") + store-item)) + (let-values (((uri compression file-size) + (select-uri narinfo))) ;; Tell the daemon what the expected hash of the Nar itself is. (format #t "~a~%" (narinfo-hash narinfo)) @@ -971,9 +1040,8 @@ DESTINATION as a nar file. Verify the substitute against ACL." ;; DOWNLOAD-SIZE is #f in practice. (fetch uri #:buffered? #f #:timeout? #f)) ((progress) - (let* ((comp (narinfo-compression narinfo)) - (dl-size (or download-size - (and (equal? comp "none") + (let* ((dl-size (or download-size + (and (equal? compression "none") (narinfo-size narinfo)))) (reporter (if print-build-trace? (progress-reporter/trace @@ -989,8 +1057,7 @@ DESTINATION as a nar file. Verify the substitute against ACL." ;; NOTE: This 'progress' port of current process will be ;; closed here, while the child process doing the ;; reporting will close it upon exit. - (decompressed-port (and=> (narinfo-compression narinfo) - string->symbol) + (decompressed-port (string->symbol compression) progress))) ;; Unpack the Nar at INPUT into DESTINATION. (restore-file input destination) diff --git a/guix/scripts/weather.scm b/guix/scripts/weather.scm index 78b8674e0..1701772bc 100644 --- a/guix/scripts/weather.scm +++ b/guix/scripts/weather.scm @@ -175,7 +175,10 @@ about the derivations queued, as is the case with Hydra." (requested (length items)) (missing (lset-difference string=? items (map narinfo-path narinfos))) - (sizes (filter-map narinfo-file-size narinfos)) + (sizes (append-map (lambda (narinfo) + (filter integer? + (narinfo-file-sizes narinfo))) + narinfos)) (time (+ (time-second time) (/ (time-nanosecond time) 1e9)))) (format #t (G_ " ~2,1f% substitutes available (~h out of ~h)~%") diff --git a/tests/substitute.scm b/tests/substitute.scm index f4f2e9512..ff2be662b 100644 --- a/tests/substitute.scm +++ b/tests/substitute.scm @@ -28,8 +28,10 @@ #:use-module (guix base32) #:use-module ((guix store) #:select (%store-prefix)) #:use-module ((guix ui) #:select (guix-warning-port)) + #:use-module ((guix utils) #:select (call-with-compressed-output-port)) + #:use-module ((guix lzlib) #:select (lzlib-available?)) #:use-module ((guix build utils) - #:select (mkdir-p delete-file-recursively)) + #:select (mkdir-p delete-file-recursively dump-port)) #:use-module (guix tests http) #:use-module (rnrs bytevectors) #:use-module (rnrs io ports) @@ -475,6 +477,53 @@ System: mips64el-linux\n") "/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa-foo") "substitute-retrieved")))) +(test-equal "substitute, narinfo with several URLs" + "Substitutable data." + (let ((narinfo (string-append "StorePath: " (%store-prefix) + "/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa-foo +URL: example.nar.gz +Compression: gzip +URL: example.nar.lz +Compression: lzip +URL: example.nar +Compression: none +NarHash: sha256:" (bytevector->nix-base32-string + (sha256 (string->utf8 "Substitutable data."))) " +NarSize: 42 +References: bar baz +Deriver: " (%store-prefix) "/foo.drv +System: mips64el-linux\n"))) + (with-narinfo (string-append narinfo "Signature: " + (signature-field narinfo)) + (dynamic-wind + (const #t) + (lambda () + (define (compress input output compression) + (call-with-output-file output + (lambda (port) + (call-with-compressed-output-port compression port + (lambda (port) + (call-with-input-file input + (lambda (input) + (dump-port input port)))))))) + + (let ((nar (string-append %main-substitute-directory + "/example.nar"))) + (compress nar (string-append nar ".gz") 'gzip) + (when (lzlib-available?) + (compress nar (string-append nar ".lz") 'lzip))) + + (parameterize ((substitute-urls + (list (string-append "file://" + %main-substitute-directory)))) + (guix-substitute "--substitute" + (string-append (%store-prefix) + "/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa-foo") + "substitute-retrieved")) + (call-with-input-file "substitute-retrieved" get-string-all)) + (lambda () + (false-if-exception (delete-file "substitute-retrieved"))))))) + (test-end "substitute") ;;; Local Variables: -- cgit v1.3 From ea35f5c599a2fe4d6ab2925b1030f64e8b21e195 Mon Sep 17 00:00:00 2001 From: Robert Vollmert Date: Sun, 2 Jun 2019 00:16:02 +0200 Subject: tests: Fix hackage tests. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is a followup to 1cc12357a65e4479c2f4735e915941382ef82d94. * tests/hackage.scm: ghc-mtl is no longer added as an input. Signed-off-by: Ludovic Courtès --- tests/hackage.scm | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/tests/hackage.scm b/tests/hackage.scm index e5f3d6cae..269c1e1f9 100644 --- a/tests/hackage.scm +++ b/tests/hackage.scm @@ -178,8 +178,7 @@ library ('build-system 'haskell-build-system) ('inputs ('quasiquote - (("ghc-http" ('unquote 'ghc-http)) - ("ghc-mtl" ('unquote 'ghc-mtl))))) + (("ghc-http" ('unquote 'ghc-http))))) ('home-page "http://test.org") ('synopsis (? string?)) ('description (? string?)) @@ -225,8 +224,7 @@ library ('inputs ('quasiquote (("ghc-b" ('unquote 'ghc-b)) - ("ghc-http" ('unquote 'ghc-http)) - ("ghc-mtl" ('unquote 'ghc-mtl))))) + ("ghc-http" ('unquote 'ghc-http))))) ('native-inputs ('quasiquote (("ghc-haskell-gi" ('unquote 'ghc-haskell-gi))))) -- cgit v1.3 From 64d31813577b7471f819652e3ec81abb285bb77c Mon Sep 17 00:00:00 2001 From: Robert Vollmert Date: Sun, 2 Jun 2019 00:27:49 +0200 Subject: tests: hackage: Test multiline cabal description. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * tests/hackage.scm (test-cabal-multiline-desc): New variable. ("hackage->guix-package test multiline desc"): New test. Signed-off-by: Ludovic Courtès --- tests/hackage.scm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/tests/hackage.scm b/tests/hackage.scm index 269c1e1f9..2f45194fa 100644 --- a/tests/hackage.scm +++ b/tests/hackage.scm @@ -236,6 +236,25 @@ library (test-assert "hackage->guix-package test 6" (eval-test-with-cabal test-cabal-6 match-ghc-foo-6)) +;; Check multi-line layouted description +(define test-cabal-multiline-desc + "name: foo +version: 1.0.0 +homepage: http://test.org +synopsis: synopsis +description: first line + second line +license: BSD3 +executable cabal + build-depends: + HTTP >= 4000.2.5 && < 4000.3, + mtl >= 2.0 && < 3 +") + +(test-assert "hackage->guix-package test multiline desc" + (eval-test-with-cabal test-cabal-multiline-desc match-ghc-foo)) + + (test-assert "read-cabal test 1" (match (call-with-input-string test-read-cabal-1 read-cabal) ((("name" ("test-me")) -- cgit v1.3 From 959c9d159da2c53b87ae0af1421aecac98b20f46 Mon Sep 17 00:00:00 2001 From: Robert Vollmert Date: Sun, 2 Jun 2019 00:27:50 +0200 Subject: import: hackage: Parse braced properties. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This adds partial support for Cabal properties that use curly braces instead of the layout rule. See for example https://hackage.haskell.org/package/cassava/ * guix/import/cabal.scm (read-braced-value): New procedure. (is-property): Remove. (is-layout-property, is-braced-property): New variables. (lex-property): Rename to... (lex-layout-property): ... this. (lex-braced-property, lex-property): New procedures. (lex-token): Add call to 'lex-property'. * guix/tests/hackage.scm: Test braced description import. * tests/hackage.scm (test-cabal-multiline-desc): Rename to... (test-cabal-multiline-layout): ... this. ("hackage->guix-package test multiline desc"): Rename to... ("hackage->guix-package test multiline desc (layout)"): ... this. (test-cabal-multiline-braced): New variable. ("hackage->guix-package test multiline desc (braced)"): New test. Signed-off-by: Ludovic Courtès --- guix/import/cabal.scm | 35 ++++++++++++++++++++++++++++------- tests/hackage.scm | 25 ++++++++++++++++++++++--- 2 files changed, 50 insertions(+), 10 deletions(-) diff --git a/guix/import/cabal.scm b/guix/import/cabal.scm index 13c2f3f48..1a87be0b0 100644 --- a/guix/import/cabal.scm +++ b/guix/import/cabal.scm @@ -270,6 +270,10 @@ following lines with indentation larger than MIN-INDENT." (peek-next-line-indent port))) val))) +(define* (read-braced-value port) + "Read up to a closing brace." + (string-trim-both (read-delimited "}" port 'trim))) + (define (lex-white-space port bol) "Consume white spaces and comment lines on PORT. If a new line is started return #t, otherwise return BOL (beginning-of-line)." @@ -343,8 +347,11 @@ matching a string against the created regexp." (make-regexp pat)))) (cut regexp-exec rx <>))) -(define is-property (make-rx-matcher "([a-z0-9-]+)[ \t]*:[ \t]*(\\w?.*)$" - regexp/icase)) +(define is-layout-property (make-rx-matcher "([a-z0-9-]+)[ \t]*:[ \t]*(\\w?[^{}]*)$" + regexp/icase)) + +(define is-braced-property (make-rx-matcher "([a-z0-9-]+)[ \t]*:[ \t]*\\{[ \t]*$" + regexp/icase)) (define is-flag (make-rx-matcher "^flag +([a-z0-9_-]+)" regexp/icase)) @@ -435,13 +442,19 @@ string with the read characters." (begin (unread-char c) (list->string res))))) (else (list->string res))))) -(define (lex-property k-v-rx-res loc port) +(define (lex-layout-property k-v-rx-res loc port) (let ((key (string-downcase (match:substring k-v-rx-res 1))) (value (match:substring k-v-rx-res 2))) (make-lexical-token 'PROPERTY loc (list key `(,(read-value port value (current-indentation))))))) +(define (lex-braced-property k-rx-res loc port) + (let ((key (string-downcase (match:substring k-rx-res 1)))) + (make-lexical-token + 'PROPERTY loc + (list key `(,(read-braced-value port)))))) + (define (lex-rx-res rx-res token loc) (let ((name (string-downcase (match:substring rx-res 1)))) (make-lexical-token token loc name))) @@ -552,7 +565,6 @@ LOC is the current port location." the current port location." (let* ((s (read-delimited "\n{}" port 'peek))) (cond - ((is-property s) => (cut lex-property <> loc port)) ((is-flag s) => (cut lex-flag <> loc)) ((is-src-repo s) => (cut lex-src-repo <> loc)) ((is-exec s) => (cut lex-exec <> loc)) @@ -561,13 +573,22 @@ the current port location." ((is-benchmark s) => (cut lex-benchmark <> loc)) ((is-lib s) (lex-lib loc)) ((is-else s) (lex-else loc)) - (else - #f)))) + (else (unread-string s port) #f)))) + +(define (lex-property port loc) + (let* ((s (read-delimited "\n" port 'peek))) + (cond + ((is-braced-property s) => (cut lex-braced-property <> loc port)) + ((is-layout-property s) => (cut lex-layout-property <> loc port)) + (else #f)))) (define (lex-token port) (let* ((loc (make-source-location (cabal-file-name) (port-line port) (port-column port) -1 -1))) - (or (lex-single-char port loc) (lex-word port loc) (lex-line port loc)))) + (or (lex-single-char port loc) + (lex-word port loc) + (lex-line port loc) + (lex-property port loc)))) ;; Lexer- and error-function generators diff --git a/tests/hackage.scm b/tests/hackage.scm index 2f45194fa..38a5825af 100644 --- a/tests/hackage.scm +++ b/tests/hackage.scm @@ -237,7 +237,7 @@ library (eval-test-with-cabal test-cabal-6 match-ghc-foo-6)) ;; Check multi-line layouted description -(define test-cabal-multiline-desc +(define test-cabal-multiline-layout "name: foo version: 1.0.0 homepage: http://test.org @@ -251,9 +251,28 @@ executable cabal mtl >= 2.0 && < 3 ") -(test-assert "hackage->guix-package test multiline desc" - (eval-test-with-cabal test-cabal-multiline-desc match-ghc-foo)) +(test-assert "hackage->guix-package test multiline desc (layout)" + (eval-test-with-cabal test-cabal-multiline-layout match-ghc-foo)) +;; Check multi-line braced description +(define test-cabal-multiline-braced + "name: foo +version: 1.0.0 +homepage: http://test.org +synopsis: synopsis +description: { +first line +second line +} +license: BSD3 +executable cabal + build-depends: + HTTP >= 4000.2.5 && < 4000.3, + mtl >= 2.0 && < 3 +") + +(test-assert "hackage->guix-package test multiline desc (braced)" + (eval-test-with-cabal test-cabal-multiline-braced match-ghc-foo)) (test-assert "read-cabal test 1" (match (call-with-input-string test-read-cabal-1 read-cabal) -- cgit v1.3 From 4a54ed774913480c0f8dad3caf0cd627e4fa8ebf Mon Sep 17 00:00:00 2001 From: Mathieu Lirzin Date: Sun, 2 Jun 2019 15:20:08 +0200 Subject: gnu: emacs-google-translate: Update to 0.11.17. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gnu/packages/emacs-xyz.scm (emacs-google-translate): Update to 0.11.17. [source]: Use 'git-fetch' method instead of 'url-fetch'. Signed-off-by: Ludovic Courtès --- gnu/packages/emacs-xyz.scm | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index c2d515ed9..c2b3bfddc 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -33,7 +33,7 @@ ;;; Copyright © 2017 Mike Gerwitz ;;; Copyright © 2017, 2018, 2019 Maxim Cournoyer ;;; Copyright © 2018 Sohom Bhattacharjee -;;; Copyright © 2018 Mathieu Lirzin +;;; Copyright © 2018, 2019 Mathieu Lirzin ;;; Copyright © 2018, 2019 Pierre Neidhardt ;;; Copyright © 2018, 2019 Tim Gesthuizen ;;; Copyright © 2018, 2019 Jack Hill @@ -12522,16 +12522,17 @@ the GIF result.") (define-public emacs-google-translate (package (name "emacs-google-translate") - (version "0.11.16") + (version "0.11.17") (source (origin - (method url-fetch) - (uri (string-append "https://github.com/atykhonov/google-translate/" - "archive/v" version ".tar.gz")) - (file-name (string-append name "-" version ".tar.gz")) + (method git-fetch) + (uri (git-reference + (url "https://github.com/atykhonov/google-translate/") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) (sha256 (base32 - "01n9spj1d0gjfj39x526rl3m9c28wnx9afipmf5s8y77cx3mfwhl")))) + "05ljjw7kbnszygw3w085kv57swfiiqxri2b5xvsf5dw3pc3g7j3c")))) (build-system emacs-build-system) (home-page "https://github.com/atykhonov/google-translate") (synopsis "Emacs interface to Google Translate") -- cgit v1.3 From 78d1497dcc1380cb8b857ce84ba0c16e2fc6c786 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Sun, 2 Jun 2019 16:28:15 -0400 Subject: gnu: WireGuard: Update to 0.0.20190601. * gnu/packages/vpn.scm (wireguard): Update to 0.0.20190601. --- gnu/packages/vpn.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gnu/packages/vpn.scm b/gnu/packages/vpn.scm index 0c607e60c..fdcd4521e 100644 --- a/gnu/packages/vpn.scm +++ b/gnu/packages/vpn.scm @@ -456,14 +456,14 @@ The peer-to-peer VPN implements a Layer 2 (Ethernet) network between the peers (define-public wireguard (package (name "wireguard") - (version "0.0.20190406") + (version "0.0.20190601") (source (origin (method url-fetch) (uri (string-append "https://git.zx2c4.com/WireGuard/snapshot/" "WireGuard-" version ".tar.xz")) (sha256 (base32 - "0ns1s31mfkj7nmapsnx126rj7xlydv7jv8infx5fg58byynz61ig")))) + "0s2mys78whsr0yw045a132iqx6nfy3c6hppiskbln5x04hc4ca3m")))) (build-system gnu-build-system) (outputs '("out" ; The WireGuard userspace tools "kernel-patch")) ; A patch to build Linux with WireGuard support -- cgit v1.3 From 3092f1b835d79655eecb2f8a79dda20ad9ba6bd6 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Sun, 2 Jun 2019 23:30:17 +0200 Subject: gnu: guix: Update to 4a54ed7. * gnu/packages/package-management.scm (guix): Update to 4a54ed7. --- gnu/packages/package-management.scm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index 9e0bfb697..e1e7d6a5a 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -111,8 +111,8 @@ ;; Note: the 'update-guix-package.scm' script expects this definition to ;; start precisely like this. (let ((version "1.0.1") - (commit "35d1354fe87003dbe19b1b97aa64db1f7d989701") - (revision 2)) + (commit "4a54ed774913480c0f8dad3caf0cd627e4fa8ebf") + (revision 3)) (package (name "guix") @@ -128,7 +128,7 @@ (commit commit))) (sha256 (base32 - "1fd7g31fgdn7pzfxki7pkn1335ffmbklygha8d16771widqbpla5")) + "14m4a4bn0d5hav6mrks5d7r223knx9dpswgbsc875wgr2921na2h")) (file-name (string-append "guix-" version "-checkout")))) (build-system gnu-build-system) (arguments -- cgit v1.3