mirror of
https://codeberg.org/guix/guix.git
synced 2025-10-02 02:15:12 +00:00
gnu: python-pythran: Update to 0.17.0.
* gnu/packages/python-science.scm (python-pythran): Update to 0.17.0. [build-system]: Use pyproject-build-system. [source]: Remove obsolete snippet. [arguments]: Remove phase 'do-not-install-third-parties and custom 'check phase; use #:test-flags and add 'pre-check phase. [native-inputs]: Add python-setuptools and python-wheel. Change-Id: I49ebdd21cfb0668dd84f0d12c460a86ed694c7d6
This commit is contained in:
parent
f0739f3ae4
commit
aa0650d159
1 changed files with 29 additions and 34 deletions
|
@ -1666,49 +1666,44 @@ y, z)}.")
|
||||||
(define-public python-pythran
|
(define-public python-pythran
|
||||||
(package
|
(package
|
||||||
(name "python-pythran")
|
(name "python-pythran")
|
||||||
(version "0.11.0")
|
(version "0.17.0")
|
||||||
(home-page "https://github.com/serge-sans-paille/pythran")
|
(home-page "https://github.com/serge-sans-paille/pythran")
|
||||||
(source (origin
|
(source (origin
|
||||||
(method git-fetch)
|
(method git-fetch)
|
||||||
(uri (git-reference (url home-page) (commit version)))
|
(uri (git-reference (url home-page) (commit version)))
|
||||||
(file-name (git-file-name name version))
|
(file-name (git-file-name name version))
|
||||||
(sha256
|
(sha256
|
||||||
(base32 "0cm7wfcyvkp1wmq7n1lyf2d3sj6158jf63bagjpjmfnjwij19n0p"))
|
(base32 "1rm9lfbz5qvah1m0rr5gaaahkf1gzwlw1ysvym2l2yh0clglav94"))))
|
||||||
(modules '((guix build utils)))
|
(build-system pyproject-build-system)
|
||||||
(snippet
|
|
||||||
'(begin
|
|
||||||
;; Remove bundled Boost and xsimd.
|
|
||||||
(delete-file-recursively "third_party")))))
|
|
||||||
(build-system python-build-system)
|
|
||||||
(arguments
|
(arguments
|
||||||
(list #:phases
|
(list
|
||||||
#~(modify-phases %standard-phases
|
#:test-flags
|
||||||
(add-after 'unpack 'do-not-install-third-parties
|
'(list (string-append "--numprocesses=" (number->string
|
||||||
(lambda _
|
(parallel-job-count)))
|
||||||
(substitute* "setup.py"
|
;; XXX There are lots of tests of the format
|
||||||
(("third_parties = .*")
|
;; pythran/tests/test_*.py, but they cannot easily be selected.
|
||||||
"third_parties = []\n"))))
|
"pythran/tests/test_typing.py")
|
||||||
(replace 'check
|
#:phases
|
||||||
(lambda* (#:key tests? #:allow-other-keys)
|
#~(modify-phases %standard-phases
|
||||||
(when tests?
|
(add-before 'check 'pre-check
|
||||||
;; Remove compiler flag that trips newer GCC:
|
(lambda* (#:key tests? #:allow-other-keys)
|
||||||
;; https://github.com/serge-sans-paille/pythran/issues/908
|
(when tests?
|
||||||
(substitute* "pythran/tests/__init__.py"
|
;; Remove compiler flag that trips newer GCC:
|
||||||
(("'-Wno-absolute-value',")
|
;; https://github.com/serge-sans-paille/pythran/issues/908
|
||||||
""))
|
(substitute* "pythran/tests/__init__.py"
|
||||||
(setenv "HOME" (getcwd))
|
(("'-Wno-absolute-value',") ""))
|
||||||
;; This setup is modelled after the upstream CI system.
|
(setenv "HOME" (getcwd))
|
||||||
(call-with-output-file ".pythranrc"
|
;; This setup is modelled after the upstream CI system.
|
||||||
(lambda (port)
|
(call-with-output-file ".pythranrc"
|
||||||
(format port "[compiler]\nblas=openblas~%")))
|
(lambda (port)
|
||||||
(invoke "pytest" "-vv"
|
(format port "[compiler]\nblas=openblas~%")))))))))
|
||||||
(string-append "--numprocesses="
|
|
||||||
(number->string
|
|
||||||
(parallel-job-count)))
|
|
||||||
"pythran/tests/test_cases.py")))))))
|
|
||||||
(native-inputs
|
(native-inputs
|
||||||
;; For tests.
|
;; For tests.
|
||||||
(list openblas python-pytest python-pytest-xdist))
|
(list openblas
|
||||||
|
python-pytest
|
||||||
|
python-pytest-xdist
|
||||||
|
python-setuptools
|
||||||
|
python-wheel))
|
||||||
(propagated-inputs
|
(propagated-inputs
|
||||||
(list boost xsimd ;headers need to be available
|
(list boost xsimd ;headers need to be available
|
||||||
python-beniget python-gast python-numpy python-ply))
|
python-beniget python-gast python-numpy python-ply))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue