[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug#72877] [PATCH 2/8] gnu: python-petsc4py: Update to 3.21.4.
From: |
Ludovic Courtès |
Subject: |
[bug#72877] [PATCH 2/8] gnu: python-petsc4py: Update to 3.21.4. |
Date: |
Thu, 29 Aug 2024 17:39:35 +0200 |
From: Ludovic Courtès <ludovic.courtes@inria.fr>
* gnu/packages/maths.scm (python-petsc4py): Update to 3.21.4.
[source](modules, snippet): Remove.
[arguments]: Switch to gexps. Rename ‘pre-build’ phase to
‘set-PETSC_DIR’. Replace ‘check’ phase.
[native-inputs]: Switch to ‘python-cython-3’.
[inputs]: Remove labels.
Change-Id: I2d8ef3519f6ffe93ff761ef99c4b8951b6107e1c
---
gnu/packages/maths.scm | 44 ++++++++++++++++--------------------------
1 file changed, 17 insertions(+), 27 deletions(-)
diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 4be9ad9d7e..c6a40a2652 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -3727,41 +3727,31 @@ (define-public petsc-complex-openmpi
(define-public python-petsc4py
(package
(name "python-petsc4py")
- (version "3.16.1")
+ (version "3.21.4")
(source
(origin
(method url-fetch)
(uri (pypi-uri "petsc4py" version))
(sha256
(base32
- "0pxr6qa7p0pmpq0av29lx8lzlrdcfdzj87ynixzr8dn42y13a662"))
- (modules '((guix build utils)))
- (snippet
- '(begin
- ;; Ensure source file is regenerated in the build phase.
- (delete-file "src/petsc4py.PETSc.c")
- ;; Remove legacy GC code. See
- ;; https://bitbucket.org/petsc/petsc4py/issues/125.
- (substitute* "src/PETSc/cyclicgc.pxi"
- ((".*gc_refs.*") "" )
- ((".*PyGC_Head.*") ""))
- #t))))
+ "1kffxhcwkx6283n2p83ymanz6m8j2xmz5kpa5s8qc4f9iiah59sb"))))
(build-system python-build-system)
(arguments
- `(#:phases
- (modify-phases %standard-phases
- (add-before 'build 'pre-build
- (lambda _
- ;; Define path to PETSc installation.
- (setenv "PETSC_DIR" (assoc-ref %build-inputs "petsc"))
- #t))
- (add-before 'check 'mpi-setup
- ,%openmpi-setup))))
- (native-inputs
- (list python-cython))
- (inputs
- `(("petsc" ,petsc-openmpi)
- ("python-numpy" ,python-numpy)))
+ (list #:phases
+ #~(modify-phases %standard-phases
+ (add-before 'build 'set-PETSC_DIR
+ (lambda* (#:key inputs #:allow-other-keys)
+ ;; Define path to PETSc installation.
+ (setenv "PETSC_DIR"
+ (assoc-ref inputs "petsc-openmpi"))))
+ (add-before 'check 'mpi-setup
+ #$%openmpi-setup)
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (invoke "python" "test/runtests.py")))))))
+ (native-inputs (list python-cython-3))
+ (inputs (list petsc-openmpi python-numpy))
(home-page "https://bitbucket.org/petsc/petsc4py/")
(synopsis "Python bindings for PETSc")
(description "PETSc, the Portable, Extensible Toolkit for
--
2.45.2
- [bug#72877] [PATCH 0/8] Upgrade PETSc, SLEPc, SUNDIALS, and DealII, Ludovic Courtès, 2024/08/29
- [bug#72877] [PATCH 2/8] gnu: python-petsc4py: Update to 3.21.4.,
Ludovic Courtès <=
- [bug#72877] [PATCH 3/8] gnu: slepc: Update to 3.21.1., Ludovic Courtès, 2024/08/29
- [bug#72877] [PATCH 1/8] gnu: petsc: Update to 3.21.4., Ludovic Courtès, 2024/08/29
- [bug#72877] [PATCH 4/8] gnu: python-slepc4py: Update to 3.21.1., Ludovic Courtès, 2024/08/29
- [bug#72877] [PATCH 7/8] gnu: sundials, sundials-openmpi: Use gexps., Ludovic Courtès, 2024/08/29
- [bug#72877] [PATCH 8/8] gnu: dealii: Update to 9.6.0., Ludovic Courtès, 2024/08/29
- [bug#72877] [PATCH 5/8] gnu: petsc: Make ‘petscvariables’ reproducible., Ludovic Courtès, 2024/08/29
- [bug#72877] [PATCH 6/8] gnu: sundials: Upgrade to 7.1.1., Ludovic Courtès, 2024/08/29