Archived
1
0
Fork 0

gnu: slurm: Use gexps and remove input labels.

* gnu/packages/parallel.scm (slurm)[source]: Remove trailing #t.
[native-inputs]: Remove labels.
[arguments]: Rewrite as gexps.  Use 'this-package-input' instead of
'%build-inputs'.
(slurm-20.02)[arguments]: Adjust accordingly.
This commit is contained in:
Ludovic Courtès 2022-03-08 18:11:31 +01:00
parent d3a7cd7acf
commit d80c722034
No known key found for this signature in database
GPG key ID: 090B11993D9AEBB5

View file

@ -38,6 +38,7 @@
#:use-module ((guix utils) #:select (target-64bit?))
#:use-module (guix packages)
#:use-module (guix utils)
#:use-module (guix gexp)
#:use-module (gnu packages)
#:use-module (gnu packages admin)
#:use-module (gnu packages autotools)
@ -193,8 +194,7 @@ when jobs finish.")
(rename-file "contribs/pmi" "tmp-pmi")
(delete-file-recursively "contribs")
(mkdir "contribs")
(rename-file "tmp-pmi" "contribs/pmi")
#t))))
(rename-file "tmp-pmi" "contribs/pmi")))))
;; FIXME: More optional inputs could be added,
;; in particular mysql and gtk+.
(inputs (list freeipmi
@ -205,26 +205,22 @@ when jobs finish.")
numactl
readline))
(native-inputs
`(("autoconf" ,autoconf)
("expect" ,expect)
("perl" ,perl)
("pkg-config" ,pkg-config)
("python" ,python-wrapper)))
(list autoconf expect perl pkg-config python-wrapper))
(build-system gnu-build-system)
(arguments
`(#:configure-flags
(list "--enable-pam" "--sysconfdir=/etc/slurm"
(list #:configure-flags
#~(list "--enable-pam" "--sysconfdir=/etc/slurm"
"--disable-static"
(string-append "--with-freeipmi=" (assoc-ref %build-inputs "freeipmi"))
(string-append "--with-hwloc=" (assoc-ref %build-inputs "hwloc"))
(string-append "--with-json=" (assoc-ref %build-inputs "json-c"))
(string-append "--with-munge=" (assoc-ref %build-inputs "munge"))
(string-append "--with-freeipmi=" #$(this-package-input "freeipmi"))
(string-append "--with-hwloc=" #$(this-package-input "hwloc"))
(string-append "--with-json=" #$(this-package-input "json-c"))
(string-append "--with-munge=" #$(this-package-input "munge"))
;; 32-bit support is marked as deprecated and needs to be
;; explicitly enabled.
,@(if (target-64bit?) '() '("--enable-deprecated")))
#$@(if (target-64bit?) '() '("--enable-deprecated")))
#:phases
(modify-phases %standard-phases
#~(modify-phases %standard-phases
(add-after 'unpack 'patch-plugin-linker-flags
(lambda _
(substitute* (find-files "src/plugins/" "Makefile.in")
@ -275,8 +271,8 @@ by managing a queue of pending work.")
(arguments
(substitute-keyword-arguments (package-arguments slurm)
((#:configure-flags flags ''())
`(append '("CFLAGS=-O2 -g -fcommon" "LDFLAGS=-fcommon")
,flags))))))
#~(append '("CFLAGS=-O2 -g -fcommon" "LDFLAGS=-fcommon")
#$flags))))))
(define-public slurm-19.05
(package