diff options
author | Sharlatan Hellseher <[email protected]> | 2025-01-27 20:31:24 +0000 |
---|---|---|
committer | Sharlatan Hellseher <[email protected]> | 2025-01-27 21:22:32 +0000 |
commit | f2b3c36bee8c232b026a66de93db38e13fbd7076 (patch) | |
tree | e49ac071dad4e648e6dbd11166372e4cbcc99d3f /gnu/packages/simulation.scm | |
parent | a35e975e162d43fff34a643a98b1aa4f5b5bc639 (diff) |
gnu: python-fenics-dijitso: Fix build.
* gnu/packages/simulation.scm (python-fenics-dijitso): Improve style,
fix build, use G-Expressions.
[phases] {check}: Respect tests? flag.
[native-inputs]: Add python-pytest-cov.
Change-Id: I4032735228d36366a7014b48e9d21606628c56a6
Diffstat (limited to 'gnu/packages/simulation.scm')
-rw-r--r-- | gnu/packages/simulation.scm | 52 |
1 files changed, 27 insertions, 25 deletions
diff --git a/gnu/packages/simulation.scm b/gnu/packages/simulation.scm index 1fca88ddb1..3af29aeeaa 100644 --- a/gnu/packages/simulation.scm +++ b/gnu/packages/simulation.scm @@ -559,39 +559,41 @@ some support for generating and analysing traffic scenarios..") (name "python-fenics-dijitso") (version "2019.1.0") (source - (origin - (method url-fetch) - (uri (pypi-uri "fenics-dijitso" version)) - (sha256 - (base32 - "0lhqsq8ypdak0ahr2jnyvg07yrqp6wicjxi6k56zx24wp3qg60sc")))) + (origin + (method url-fetch) + (uri (pypi-uri "fenics-dijitso" version)) + (sha256 + (base32 "0lhqsq8ypdak0ahr2jnyvg07yrqp6wicjxi6k56zx24wp3qg60sc")))) (build-system pyproject-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'build 'mpi-setup + #$%openmpi-setup) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (setenv "HOME" "/tmp") + (with-directory-excursion "test" + ;; Disable parallel tests to avoid race condition. See + ;; https://github.com/pytest-dev/pytest-cov/issues/237. + (substitute* "runtests.sh" + (("for p in 1 4 8 16; do") "for p in 1; do")) + (invoke "./runtests.sh")))))))) + (native-inputs + (list python-pytest + python-pytest-cov + python-setuptools + python-wheel)) (inputs (list openmpi python-numpy)) - (native-inputs - (list python-pytest python-setuptools python-wheel)) (propagated-inputs (list python-mpi4py)) - (arguments - `(#:phases - (modify-phases %standard-phases - (add-after 'build 'mpi-setup - ,%openmpi-setup) - (replace 'check - (lambda* (#:key inputs #:allow-other-keys) - (setenv "HOME" "/tmp") - (with-guix-pytest-plugin inputs - (with-directory-excursion "test" - ;; Disable parallel tests to avoid race condition. See - ;; https://github.com/pytest-dev/pytest-cov/issues/237. - (substitute* "runtests.sh" - (("for p in 1 4 8 16; do") - "for p in 1; do")) - (invoke "./runtests.sh")))))))) (home-page "https://bitbucket.org/fenics-project/dijitso/") (synopsis "Distributed just-in-time building of shared libraries") (description - "Dijitso provides a core component of the @code{FEniCS} framework, + "Dijitso provides a core component of the @code{FEniCS} framework, namely the just-in-time compilation of C++ code that is generated from Python modules. It is called from within a C++ library, using ctypes to import the dynamic shared library directly. |