summaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorSharlatan Hellseher <sharlatanus@gmail.com>2025-10-19 21:03:00 +0100
committerSharlatan Hellseher <sharlatanus@gmail.com>2025-10-19 21:09:44 +0100
commitac1fb33ffd75ea80d063a53b74b2d9d0c0959109 (patch)
tree94eefa6dc4d9d24af3b120036fd220032526252b /gnu
parent159931a9729659144fdc9db382ff9f8f1e96e999 (diff)
gnu: python-fs: Fix build on cross compilation.
* gnu/packages/python-xyz.scm (python-fs)[arguments] <test-flags>: Move option here instead of overwriting 'check phase. <phases>: Use default 'check; add 'pre-check. [native-inputs]: Keep python-setuptools away from condition. Fixes: guix/guix#3656 Change-Id: I247a70ea9d3fbc94a748973dd4a273341408fea9
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/python-xyz.scm48
1 files changed, 28 insertions, 20 deletions
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 9a8032049f..b2be63df07 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -17199,33 +17199,41 @@ It has a flexible system of @samp{authorizers} able to manage both
(source
(origin
(method git-fetch)
- (uri (git-reference (url
- "https://github.com/PyFilesystem/pyfilesystem2/")
- (commit (string-append "v" version))))
+ (uri (git-reference
+ (url "https://github.com/PyFilesystem/pyfilesystem2/")
+ (commit (string-append "v" version))))
(file-name (git-file-name name version))
- (sha256 (base32 "1wrkhsv57kv4jcadn7w330mgbjjsimgzfvicni8cka6y1a8chbjs"))))
+ (sha256
+ (base32 "1wrkhsv57kv4jcadn7w330mgbjjsimgzfvicni8cka6y1a8chbjs"))))
(build-system pyproject-build-system)
(arguments
(list
+ ;; tests: 1995 passed, 21 skipped, 411 deselected, 14 warnings
+ #:test-flags #~(list "-m" "not slow")
#:tests? (and (not (%current-target-system))
(->bool (this-package-native-input "python-pytest")))
- #:phases #~(modify-phases %standard-phases
- (replace 'check
- (lambda* (#:key tests? #:allow-other-keys)
- (when tests?
- (setenv "HOME" "/tmp")
- (invoke "pytest" "-m" "not slow")))))))
- (propagated-inputs
- (list python-appdirs python-pytz python-six))
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-before 'check 'pre-check
+ (lambda _
+ (setenv "HOME" "/tmp"))))))
(native-inputs
- ;; 'python-pyftpdlib' is needed for tests but it indirectly depends Rust,
- ;; which is currently unavailable on aarch64-linux. Remove all the test
- ;; dependencies in that case.
- (if (and (not (%current-target-system))
- (supported-package? python-pyftpdlib))
- (list python-mock python-parameterized python-pyftpdlib
- python-pytest python-setuptools)
- '()))
+ (append
+ (list python-setuptools)
+ ;; 'python-pyftpdlib' is needed for tests but it indirectly depends Rust,
+ ;; which is currently unavailable on aarch64-linux. Remove all the test
+ ;; dependencies in that case.
+ (if (and (not (%current-target-system))
+ (supported-package? python-pyftpdlib))
+ (list python-mock
+ python-parameterized
+ python-pyftpdlib
+ python-pytest)
+ '())))
+ (propagated-inputs
+ (list python-appdirs
+ python-pytz
+ python-six)) ;still hard itegrated
(home-page "https://github.com/PyFilesystem/pyfilesystem2/")
(synopsis "File system abstraction layer for Python")
(description