mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-28 15:22:18 -05: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)
|
||||
(outputs '("out" "bin"))
|
||||
(arguments
|
||||
`(#:make-flags
|
||||
(let* ((out (assoc-ref %outputs "out"))
|
||||
(nspr (string-append (assoc-ref %build-inputs "nspr")))
|
||||
(rpath (string-append "-Wl,-rpath=" out "/lib/nss")))
|
||||
(list "-C" "nss" (string-append "PREFIX=" out)
|
||||
(list
|
||||
#:make-flags
|
||||
#~(let ((rpath (string-append "-Wl,-rpath=" #$output "/lib/nss")))
|
||||
(list "-C" "nss"
|
||||
(string-append "PREFIX=" #$output)
|
||||
"NSDISTMODE=copy"
|
||||
"NSS_USE_SYSTEM_SQLITE=1"
|
||||
;; The gtests fail to compile on riscv64.
|
||||
;; Skipping them doesn't affect the test suite.
|
||||
,@(if (target-riscv64?)
|
||||
`("NSS_DISABLE_GTESTS=1")
|
||||
'())
|
||||
(string-append "NSPR_INCLUDE_DIR=" nspr "/include/nspr")
|
||||
#$@(if (target-riscv64?)
|
||||
#~("NSS_DISABLE_GTESTS=1")
|
||||
#~())
|
||||
(string-append "NSPR_INCLUDE_DIR="
|
||||
(search-input-directory %build-inputs
|
||||
"include/nspr"))
|
||||
;; Add $out/lib/nss to RPATH.
|
||||
(string-append "RPATH=" rpath)
|
||||
(string-append "LDFLAGS=" rpath)))
|
||||
#:modules ((guix build gnu-build-system)
|
||||
#:modules '((guix build gnu-build-system)
|
||||
(guix build utils)
|
||||
(ice-9 ftw)
|
||||
(ice-9 match)
|
||||
(srfi srfi-26))
|
||||
#:tests? ,(not (or (%current-target-system)
|
||||
#:tests? (not (or (%current-target-system)
|
||||
;; Tests take more than 30 hours on riscv64-linux.
|
||||
(target-riscv64?)))
|
||||
#:phases
|
||||
(modify-phases %standard-phases
|
||||
#~(modify-phases %standard-phases
|
||||
(replace 'configure
|
||||
(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.
|
||||
,@(if (target-64bit?)
|
||||
`((setenv "USE_64" "1"))
|
||||
'())))
|
||||
#$@(if (target-64bit?)
|
||||
#~((setenv "USE_64" "1"))
|
||||
#~())))
|
||||
(replace 'check
|
||||
(lambda* (#:key tests? #:allow-other-keys)
|
||||
(if tests?
|
||||
|
|
Loading…
Reference in a new issue