mirror of
https://git.savannah.gnu.org/git/guix.git
synced 2025-02-04 18:07:24 +01:00
gnu: nss: Use G-expressions.
* gnu/packages/nss.scm (nss)[arguments]: Use gexp and remove labels.
This commit is contained in:
parent
b316d8b751
commit
01d1b285b8
1 changed files with 69 additions and 67 deletions
|
@ -137,39 +137,41 @@ (define-public nss
|
||||||
(build-system gnu-build-system)
|
(build-system gnu-build-system)
|
||||||
(outputs '("out" "bin"))
|
(outputs '("out" "bin"))
|
||||||
(arguments
|
(arguments
|
||||||
`(#:make-flags
|
(list
|
||||||
(let* ((out (assoc-ref %outputs "out"))
|
#:make-flags
|
||||||
(nspr (string-append (assoc-ref %build-inputs "nspr")))
|
#~(let ((rpath (string-append "-Wl,-rpath=" #$output "/lib/nss")))
|
||||||
(rpath (string-append "-Wl,-rpath=" out "/lib/nss")))
|
(list "-C" "nss"
|
||||||
(list "-C" "nss" (string-append "PREFIX=" out)
|
(string-append "PREFIX=" #$output)
|
||||||
"NSDISTMODE=copy"
|
"NSDISTMODE=copy"
|
||||||
"NSS_USE_SYSTEM_SQLITE=1"
|
"NSS_USE_SYSTEM_SQLITE=1"
|
||||||
;; The gtests fail to compile on riscv64.
|
;; The gtests fail to compile on riscv64.
|
||||||
;; Skipping them doesn't affect the test suite.
|
;; Skipping them doesn't affect the test suite.
|
||||||
,@(if (target-riscv64?)
|
#$@(if (target-riscv64?)
|
||||||
`("NSS_DISABLE_GTESTS=1")
|
#~("NSS_DISABLE_GTESTS=1")
|
||||||
'())
|
#~())
|
||||||
(string-append "NSPR_INCLUDE_DIR=" nspr "/include/nspr")
|
(string-append "NSPR_INCLUDE_DIR="
|
||||||
|
(search-input-directory %build-inputs
|
||||||
|
"include/nspr"))
|
||||||
;; Add $out/lib/nss to RPATH.
|
;; Add $out/lib/nss to RPATH.
|
||||||
(string-append "RPATH=" rpath)
|
(string-append "RPATH=" rpath)
|
||||||
(string-append "LDFLAGS=" rpath)))
|
(string-append "LDFLAGS=" rpath)))
|
||||||
#:modules ((guix build gnu-build-system)
|
#:modules '((guix build gnu-build-system)
|
||||||
(guix build utils)
|
(guix build utils)
|
||||||
(ice-9 ftw)
|
(ice-9 ftw)
|
||||||
(ice-9 match)
|
(ice-9 match)
|
||||||
(srfi srfi-26))
|
(srfi srfi-26))
|
||||||
#:tests? ,(not (or (%current-target-system)
|
#:tests? (not (or (%current-target-system)
|
||||||
;; Tests take more than 30 hours on riscv64-linux.
|
;; Tests take more than 30 hours on riscv64-linux.
|
||||||
(target-riscv64?)))
|
(target-riscv64?)))
|
||||||
#:phases
|
#:phases
|
||||||
(modify-phases %standard-phases
|
#~(modify-phases %standard-phases
|
||||||
(replace 'configure
|
(replace 'configure
|
||||||
(lambda _
|
(lambda _
|
||||||
(setenv "CC" ,(cc-for-target))
|
(setenv "CC" #$(cc-for-target))
|
||||||
;; Tells NSS to build for the 64-bit ABI if we are 64-bit system.
|
;; Tells NSS to build for the 64-bit ABI if we are 64-bit system.
|
||||||
,@(if (target-64bit?)
|
#$@(if (target-64bit?)
|
||||||
`((setenv "USE_64" "1"))
|
#~((setenv "USE_64" "1"))
|
||||||
'())))
|
#~())))
|
||||||
(replace 'check
|
(replace 'check
|
||||||
(lambda* (#:key tests? #:allow-other-keys)
|
(lambda* (#:key tests? #:allow-other-keys)
|
||||||
(if tests?
|
(if tests?
|
||||||
|
|
Loading…
Reference in a new issue