summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2023-05-10 18:39:24 +0200
committerLudovic Courtès <ludo@gnu.org>2023-05-18 19:51:30 +0200
commit92a899ed985c60ffc199d8465ddbc03d285365ce (patch)
tree8b85b68311ae507898b963b255cce78ecb3953a8
parent5d84a90694a30d3d5c0a3058562938af448c829d (diff)
gnu: btrfs-progs: Make the python-sphinx input conditional.
* gnu/packages/linux.scm (btrfs-progs) [native-inputs]: Make the python-sphinx input conditional. [arguments]: Conditionally add --disable-documentation to configure flags. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
-rw-r--r--gnu/packages/linux.scm39
1 files changed, 27 insertions, 12 deletions
diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
index a0248106b6..38d7a041e0 100644
--- a/gnu/packages/linux.scm
+++ b/gnu/packages/linux.scm
@@ -5927,9 +5927,18 @@ and copy/paste text in the console and in xterm.")
(arguments
(list
#:configure-flags
- ;; The ‘Python support’ was never actually installed by previous
- ;; versions of this package, but did prevent cross-compilation.
- #~(list "--disable-python")
+ #~(append
+ ;; Without --disable-documentation, it complains about missing
+ ;; python-sphinx on systems where this package isn't available
+ ;; (because it requires Rust).
+ (if #$@(member (%current-system)
+ (package-transitive-supported-systems
+ python-sphinx))
+ '()
+ (list "--disable-documentation"))
+ ;; The ‘Python support’ was never actually installed by previous
+ ;; versions of this package, but did prevent cross-compilation.
+ (list "--disable-python"))
#:phases #~(modify-phases %standard-phases
(add-after 'unpack 'patch-makefile
(lambda* (#:key outputs #:allow-other-keys)
@@ -5968,15 +5977,21 @@ and copy/paste text in the console and in xterm.")
`(,zlib "static")
`(,zstd "lib")
`(,zstd "static")))
- (native-inputs (list pkg-config
- python-sphinx ;for building documentation
- acl ;for tests
- lvm2 ;for dmsetup
- grep ;need Perl regexp support
- libaio
- liburing
- util-linux ;for fallocate
- which))
+ (native-inputs
+ (append
+ ;; For building documentation. Since python-sphinx requires Rust, add
+ ;; it conditionally depending on such support.
+ (if (supported-package? python-sphinx)
+ (list python-sphinx)
+ '())
+ (list pkg-config
+ acl ;for tests
+ lvm2 ;for dmsetup
+ grep ;need Perl regexp support
+ libaio
+ liburing
+ util-linux ;for fallocate
+ which)))
(home-page "https://btrfs.wiki.kernel.org/index.php/Main_Page")
(synopsis "Create and manage btrfs copy-on-write file systems")
(description