diff options
| author | Nicolas Graves <ngraves@ngraves.fr> | 2025-10-12 18:03:35 +0200 |
|---|---|---|
| committer | Sharlatan Hellseher <sharlatanus@gmail.com> | 2025-10-13 12:00:49 +0100 |
| commit | 594f9970456126acaf0f66b045d5b832f6d51b06 (patch) | |
| tree | d69a5718204027e0b5f9dcc23131aa042298a986 /gnu/packages/python-xyz.scm | |
| parent | 2d41fcdc9cc6b203ab7e58d18e2320e5e2d5b6fa (diff) | |
gnu: python-numpysane: Switch to pyproject.
* gnu/packages/python-xyz.scm (python-numpysane):
[build-system]: Switch to pyproject-build-system.
[arguments]<#:phases>: Improve and rewrite phase 'patch.
[native-inputs]: Add python-setuptools.
[home-page]: Relocate field.
[description]: Improve style.
Change-Id: Ib4ecd4e68fad941b2afeaa09be6231cfe3cff8a5
Signed-off-by: Sharlatan Hellseher <sharlatanus@gmail.com>
Diffstat (limited to 'gnu/packages/python-xyz.scm')
| -rw-r--r-- | gnu/packages/python-xyz.scm | 64 |
1 files changed, 31 insertions, 33 deletions
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index d74e4254053..0f9203a255c 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -10636,40 +10636,39 @@ include_dirs = ~:*~a/include~%" #$(this-package-input "openblas")))))) (package (name "python-numpysane") (version "0.42") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/dkogan/numpysane.git") - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "0s38fm88bmq08j5qxfka1wyjs2r9s9arzd1c3c4ixa8k3pisnihr")))) - (build-system python-build-system) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/dkogan/numpysane.git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0s38fm88bmq08j5qxfka1wyjs2r9s9arzd1c3c4ixa8k3pisnihr")))) + (build-system pyproject-build-system) (arguments - (list #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'patch - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "Makefile.common.header" - ;; numpy 2.0 has this--but we don't use numpy 2.0. - (("pkg-config --cflags-only-I numpy") - (string-append "echo -I" - (assoc-ref inputs "python-numpy") - "/lib/python" - #$(version-major+minor - (package-version python)) - "/site-packages/numpy/core/include"))))) - (replace 'check - (lambda _ - (setenv "CC" #$(cc-for-target)) - (invoke "make" "check")))))) - (propagated-inputs - (list python-numpy)) - (native-inputs - (list perl pkg-config)) + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((numpy (assoc-ref inputs "python-numpy")) + (site (site-packages inputs `(("out" . ,numpy))))) + (substitute* "Makefile.common.header" + ;; numpy 2.0 has this--but we don't use numpy 2.0. + (("pkg-config --cflags-only-I numpy") + (format #f "echo -I~a/numpy/core/include" site)))))) + (replace 'check + (lambda _ + (setenv "CC" + #$(cc-for-target)) + (invoke "make" "check")))))) + (propagated-inputs (list python-numpy)) + (native-inputs (list perl pkg-config python-setuptools)) + (home-page "https://github.com/dkogan/numpysane") (synopsis "More-reasonable core functionality for numpy") - (description "This package provides more-reasonable core functionality for numpy. + (description + "This package provides more-reasonable core functionality for numpy. A lot of numpysane functionality is inspired by PDL (Perl Data Language). @@ -10685,7 +10684,6 @@ numpysane has: @item broadcast-aware matrix multiplication @end itemize ") - (home-page "https://github.com/dkogan/numpysane") (license license:lgpl2.0+))) (define-public python-numpy-documentation |
