mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-24 21:38:07 -05:00
gnu: scotch, pt-scotch: Use modify-phases.
* gnu/packages/maths.scm (scotch, pt-scotch)[arguments]: Use modify-phases.
This commit is contained in:
parent
6c7985408f
commit
d6602ee9d4
1 changed files with 31 additions and 39 deletions
|
@ -802,15 +802,16 @@ (define-public scotch
|
||||||
("bison" ,bison)))
|
("bison" ,bison)))
|
||||||
(arguments
|
(arguments
|
||||||
`(#:phases
|
`(#:phases
|
||||||
(alist-cons-after
|
(modify-phases %standard-phases
|
||||||
'unpack 'chdir-to-src
|
(add-after
|
||||||
(lambda _ (chdir "src"))
|
'unpack 'chdir-to-src
|
||||||
(alist-replace
|
(lambda _ (chdir "src")))
|
||||||
'configure
|
(replace
|
||||||
(lambda _
|
'configure
|
||||||
(call-with-output-file "Makefile.inc"
|
(lambda _
|
||||||
(lambda (port)
|
(call-with-output-file "Makefile.inc"
|
||||||
(format port "
|
(lambda (port)
|
||||||
|
(format port "
|
||||||
EXE =
|
EXE =
|
||||||
LIB = .a
|
LIB = .a
|
||||||
OBJ = .o
|
OBJ = .o
|
||||||
|
@ -831,22 +832,21 @@ (define-public scotch
|
||||||
RANLIB = ranlib
|
RANLIB = ranlib
|
||||||
YACC = bison -pscotchyy -y -b y
|
YACC = bison -pscotchyy -y -b y
|
||||||
"
|
"
|
||||||
'("COMMON_FILE_COMPRESS_GZ"
|
'("COMMON_FILE_COMPRESS_GZ"
|
||||||
"COMMON_PTHREAD"
|
"COMMON_PTHREAD"
|
||||||
"COMMON_RANDOM_FIXED_SEED"
|
"COMMON_RANDOM_FIXED_SEED"
|
||||||
;; XXX: Causes invalid frees in superlu-dist tests
|
;; XXX: Causes invalid frees in superlu-dist tests
|
||||||
;; "SCOTCH_PTHREAD"
|
;; "SCOTCH_PTHREAD"
|
||||||
;; "SCOTCH_PTHREAD_NUMBER=2"
|
;; "SCOTCH_PTHREAD_NUMBER=2"
|
||||||
"restrict=__restrict")))))
|
"restrict=__restrict"))))))
|
||||||
(alist-replace
|
(replace
|
||||||
'install
|
'install
|
||||||
(lambda* (#:key outputs #:allow-other-keys)
|
(lambda* (#:key outputs #:allow-other-keys)
|
||||||
(let ((out (assoc-ref outputs "out")))
|
(let ((out (assoc-ref outputs "out")))
|
||||||
(mkdir out)
|
(mkdir out)
|
||||||
(zero? (system* "make"
|
(zero? (system* "make"
|
||||||
(string-append "prefix=" out)
|
(string-append "prefix=" out)
|
||||||
"install"))))
|
"install"))))))))
|
||||||
%standard-phases)))))
|
|
||||||
(home-page "http://www.labri.fr/perso/pelegrin/scotch/")
|
(home-page "http://www.labri.fr/perso/pelegrin/scotch/")
|
||||||
(synopsis "Programs and libraries for graph algorithms")
|
(synopsis "Programs and libraries for graph algorithms")
|
||||||
(description "SCOTCH is a set of programs and libraries which implement
|
(description "SCOTCH is a set of programs and libraries which implement
|
||||||
|
@ -867,26 +867,18 @@ (define-public pt-scotch
|
||||||
(arguments
|
(arguments
|
||||||
(substitute-keyword-arguments (package-arguments scotch)
|
(substitute-keyword-arguments (package-arguments scotch)
|
||||||
((#:phases scotch-phases)
|
((#:phases scotch-phases)
|
||||||
`(alist-replace
|
`(modify-phases ,scotch-phases
|
||||||
'build
|
(replace
|
||||||
;; TODO: Would like to add parallelism here
|
'build
|
||||||
(lambda _
|
;; TODO: Would like to add parallelism here
|
||||||
(and
|
(lambda _
|
||||||
(zero? (system* "make" "ptscotch"))
|
(and
|
||||||
;; Install the serial metis compatibility library
|
(zero? (system* "make" "ptscotch"))
|
||||||
(zero? (system* "make" "-C" "libscotchmetis" "install"))))
|
;; Install the serial metis compatibility library
|
||||||
(alist-replace
|
(zero? (system* "make" "-C" "libscotchmetis" "install")))))
|
||||||
'check
|
(replace
|
||||||
(lambda _ (zero? (system* "make" "ptcheck")))
|
'check
|
||||||
(alist-replace
|
(lambda _ (zero? (system* "make" "ptcheck"))))))))
|
||||||
'install
|
|
||||||
(lambda* (#:key outputs #:allow-other-keys)
|
|
||||||
(let ((out (assoc-ref outputs "out")))
|
|
||||||
(mkdir out)
|
|
||||||
(zero? (system* "make"
|
|
||||||
(string-append "prefix=" out)
|
|
||||||
"install"))))
|
|
||||||
,scotch-phases))))))
|
|
||||||
(synopsis "Programs and libraries for graph algorithms (with MPI)")))
|
(synopsis "Programs and libraries for graph algorithms (with MPI)")))
|
||||||
|
|
||||||
(define-public gsegrafix
|
(define-public gsegrafix
|
||||||
|
|
Loading…
Reference in a new issue