diff options
author | Maxim Cournoyer <maxim.cournoyer@gmail.com> | 2023-04-18 10:41:28 -0400 |
---|---|---|
committer | Maxim Cournoyer <maxim.cournoyer@gmail.com> | 2023-04-19 20:24:28 -0400 |
commit | 2d33e6d6e88110594d9b212a4c9ddc576fa238ed (patch) | |
tree | a78fb860ce995c691ed31280a59f4c475e3136c2 | |
parent | ed854ad8e621f62b5f918ddcb23b0bc7d55a21e6 (diff) | |
download | guix-patches-2d33e6d6e88110594d9b212a4c9ddc576fa238ed.tar guix-patches-2d33e6d6e88110594d9b212a4c9ddc576fa238ed.tar.gz |
gnu: samba: Make the python-cryptography input conditional.
* gnu/packages/samba.scm (samba/pinned) [arguments]: Conditionally enable self tests
in configure phase.
[native-inputs]: Conditionally add python-cryptography.
Reported-by: John Kehayias <john.kehayias@protonmail.com>
-rw-r--r-- | gnu/packages/samba.scm | 42 |
1 files changed, 27 insertions, 15 deletions
diff --git a/gnu/packages/samba.scm b/gnu/packages/samba.scm index 8c004a1aac..8b3e96e9c2 100644 --- a/gnu/packages/samba.scm +++ b/gnu/packages/samba.scm @@ -9,7 +9,7 @@ ;;; Copyright © 2018 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2019 Rutger Helling <rhelling@mykolab.com> ;;; Copyright © 2020 Pierre Langlois <pierre.langlois@gmx.com> -;;; Copyright © 2020, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2020, 2022, 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2022 Jean-Pierre De Jesus DIAZ <me@jeandudey.tech> ;;; Copyright © 2022 Guillaume Le Vaillant <glv@posteo.net> ;;; Copyright © 2022 Maxime Devos <maximedevos@telenet.be> @@ -210,7 +210,11 @@ external dependencies.") (lambda* (#:key inputs #:allow-other-keys) (let* ((libdir (string-append #$output "/lib"))) (invoke "./configure" - "--enable-selftest" + #$@(if (member (%current-system) + (package-transitive-supported-systems + python-cryptography)) + '("--enable-selftest") + '()) "--enable-fhs" (string-append "--prefix=" #$output) "--sysconfdir=/etc" @@ -255,19 +259,27 @@ external dependencies.") ;; In Requires or Requires.private of pkg-config files. (list ldb talloc tevent)) (native-inputs - (list perl-parse-yapp - pkg-config - python-cryptography ;for krb5 tests - python-dnspython - python-iso8601 - python-markdown - rpcsvc-proto ;for 'rpcgen' - python-pyasn1 ;for krb5 tests - ;; For generating man pages. - docbook-xml-4.2 - docbook-xsl - libxslt - libxml2)) ;for XML_CATALOG_FILES + (append + (list perl-parse-yapp + pkg-config) + ;; The python-cryptography dependency is needed for the krb5 tests. + ;; Since python-cryptography requires Rust, add it conditionally + ;; depending on such support. + (if (member (%current-system) + (package-transitive-supported-systems + python-cryptography)) + (list python-cryptography) + '()) + (list python-dnspython + python-iso8601 + python-markdown + rpcsvc-proto ;for 'rpcgen' + python-pyasn1 ;for krb5 tests + ;; For generating man pages. + docbook-xml-4.2 + docbook-xsl + libxslt + libxml2))) ;for XML_CATALOG_FILES (home-page "https://www.samba.org/") (synopsis "The standard Windows interoperability suite of programs for GNU and Unix") |