diff options
-rw-r--r-- | gnu/packages/nss.scm | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/gnu/packages/nss.scm b/gnu/packages/nss.scm index 13dffa4966..40adef194b 100644 --- a/gnu/packages/nss.scm +++ b/gnu/packages/nss.scm @@ -102,6 +102,14 @@ platform-neutral API for system level and libc-like functions. It is used in the Mozilla clients.") (license license:mpl2.0))) +(define (nss-uri version) + (let* ((components (string-split version #\.)) + (version-with-underscores (string-join components "_"))) + (string-append + "https://ftp.mozilla.org/pub/mozilla.org/security/nss/" + "releases/NSS_" version-with-underscores "_RTM/src/" + "nss-" version ".tar.gz"))) + ;; nss should track ESRs, but currently doesn't. 3.102.1 is the current ESR. (define-public nss @@ -113,12 +121,7 @@ in the Mozilla clients.") (version "3.101.4") (source (origin (method url-fetch) - (uri (let ((version-with-underscores - (string-join (string-split version #\.) "_"))) - (string-append - "https://ftp.mozilla.org/pub/mozilla.org/security/nss/" - "releases/NSS_" version-with-underscores "_RTM/src/" - "nss-" version ".tar.gz"))) + (uri (nss-uri version)) (sha256 (base32 "1sqvh49qi9vq55sbg42c5n0kz6w6ni383hgiyhaym6drsmbzb86a")) @@ -192,13 +195,12 @@ in the Mozilla clients.") (setenv "CCC" #$(cxx-for-target)) (setenv "NATIVE_CC" "gcc") ;; No VSX on powerpc-linux. - #$@(if (target-ppc32?) - #~((setenv "NSS_DISABLE_CRYPTO_VSX" "1")) - #~()) + (when #$(target-ppc32?) + (setenv "NSS_DISABLE_CRYPTO_VSX" "1")) + ;; Tells NSS to build for the 64-bit ABI if we are 64-bit system. - #$@(if (target-64bit?) - #~((setenv "USE_64" "1")) - #~()))) + (when #$(target-64bit?) + (setenv "USE_64" "1")))) (replace 'check (lambda* (#:key tests? #:allow-other-keys) (if tests? @@ -217,15 +219,13 @@ in the Mozilla clients.") (substitute* "nss/tests/dbtests/dbtests.sh" ((" -lt 5") " -lt 50")) - #$@(if (target-64bit?) - '() - ;; The script fails to determine the source - ;; directory when running under 'datefudge' (see - ;; <https://issues.guix.gnu.org/72239>). Help it. - #~((substitute* "nss/tests/gtests/gtests.sh" - (("SOURCE_DIR=.*") - (string-append "SOURCE_DIR=" (getcwd) "/nss\n"))))) - + (unless #$(target-64bit?) + ;; The script fails to determine the source + ;; directory when running under 'datefudge' (see + ;; <https://issues.guix.gnu.org/72239>). Help it. + ((substitute* "nss/tests/gtests/gtests.sh" + (("SOURCE_DIR=.*") + (string-append "SOURCE_DIR=" (getcwd) "/nss\n"))))) (let ((release-date (getenv "GUIX_NSS_RELEASE_DATE"))) (when (string=? "" release-date) |