From 0788e62d3e391d04e5a2fa6c399fcdfba5dcb579 Mon Sep 17 00:00:00 2001 From: Marius Bakke Date: Sun, 6 Jun 2021 18:46:48 +0200 Subject: gnu: nss: Fix test failure. * gnu/packages/sqlite.scm (sqlite-uri): New variable. (sqlite)[source](uri): Use it. (sqlite-3.33): New public variable. --- gnu/packages/nss.scm | 4 +++- gnu/packages/sqlite.scm | 38 ++++++++++++++++++++++++++------------ 2 files changed, 29 insertions(+), 13 deletions(-) (limited to 'gnu') diff --git a/gnu/packages/nss.scm b/gnu/packages/nss.scm index e054363e9f..854205f917 100644 --- a/gnu/packages/nss.scm +++ b/gnu/packages/nss.scm @@ -174,7 +174,9 @@ (define-public nss (copy-recursively (string-append obj "/bin") bin) (copy-recursively (string-append obj "/lib") lib))))))) (inputs - `(("sqlite" ,sqlite) + `(;; XXX: Build with SQLite 3.33 to work around + ;; https://bugzilla.mozilla.org/show_bug.cgi?id=1714874 + ("sqlite" ,sqlite-3.33) ("zlib" ,zlib))) (propagated-inputs `(("nspr" ,nspr))) ; required by nss.pc. (native-inputs `(("perl" ,perl) diff --git a/gnu/packages/sqlite.scm b/gnu/packages/sqlite.scm index c0ea2e670e..56e53eeae4 100644 --- a/gnu/packages/sqlite.scm +++ b/gnu/packages/sqlite.scm @@ -6,7 +6,7 @@ ;;; Copyright © 2016 Efraim Flashner ;;; Copyright © 2016 Ben Woodcroft ;;; Copyright © 2016 David Craven -;;; Copyright © 2016, 2017, 2018, 2019, 2020 Marius Bakke +;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Marius Bakke ;;; Copyright © 2017 Ricardo Wurmus ;;; Copyright © 2017 Jelle Licht ;;; Copyright © 2018 Tobias Geerinckx-Rice @@ -45,23 +45,26 @@ (define-module (gnu packages sqlite) ;;; This module has been separated from (gnu packages databases) to reduce the ;;; number of module references for core packages. +(define (sqlite-uri version year) + (let ((numeric-version + (match (string-split version #\.) + ((first-digit other-digits ...) + (string-append first-digit + (string-pad-right + (string-concatenate + (map (cut string-pad <> 2 #\0) + other-digits)) + 6 #\0)))))) + (string-append "https://sqlite.org/" (number->string year) + "/sqlite-autoconf-" numeric-version ".tar.gz"))) + (define-public sqlite (package (name "sqlite") (version "3.35.5") (source (origin (method url-fetch) - (uri (let ((numeric-version - (match (string-split version #\.) - ((first-digit other-digits ...) - (string-append first-digit - (string-pad-right - (string-concatenate - (map (cut string-pad <> 2 #\0) - other-digits)) - 6 #\0)))))) - (string-append "https://sqlite.org/2021/sqlite-autoconf-" - numeric-version ".tar.gz"))) + (uri (sqlite-uri version 2021)) (patches (search-patches "sqlite-hurd.patch")) (sha256 (base32 @@ -106,6 +109,17 @@ (define-public sqlite is in the public domain.") (license license:public-domain))) +(define-public sqlite-3.33 + (package + (inherit sqlite) + (version "3.33.0") + (source (origin + (method url-fetch) + (uri (sqlite-uri version 2020)) + (sha256 + (base32 + "05dvdfaxd552gj5p7k0i72sfam7lykaw1g2pfn52jnppqx42qshh")))))) + ;; Column metadata support was added to the regular 'sqlite' package with ;; commit fad5b1a6d8d9c36bea5785ae4fbc1beb37e644d7. (define-public sqlite-with-column-metadata -- cgit v1.2.3