Not sent upstream. From e23de62e28f64599148ff06e439fac116a391299 Mon Sep 17 00:00:00 2001 From: "Jan (janneke) Nieuwenhuizen" Date: Fri, 10 Apr 2020 07:24:48 +0200 Subject: [PATCH] guile: Cross build fix. To cross-build, both the host guile and the native guile-for-build must be available. If the native guile is not available, no snarfing is done and the guile cross build is skipped. During the cross-build gnutls.scm does not load when compliling extra.scm, becase of missing definitions from guile-gnutls-v-2. * guile/modules/gnutls.in (protocol/ssl-3 protocol/tls-1.0, protocol/tls-1.1, credentials/anonymous, cipher/rijndael-256-cbc, cipher/rijndael-128-cbc, cipher/rijndael-cbc, cipher/arcfour-128, certificate-verify/allow-any-x509-v1-ca-certificate, certificate-verify/allow-x509-v1-ca-certificate): Define to #f initially. When "GNUTLS_GUILE_CROSS_COMPILING" not set, set! to value from "guile-gnutls-v-2" load-extension C module. --- guile/modules/gnutls.in | 40 +++++++++++++++++++++++++++------------- 1 file changed, 27 insertions(+), 13 deletions(-) diff --git a/guile/modules/gnutls.in b/guile/modules/gnutls.in index 6461c404a..954e315de 100644 --- a/guile/modules/gnutls.in +++ b/guile/modules/gnutls.in @@ -564,22 +564,36 @@ This defines 'variable' as an alias for 'alias', and emits a warning when (identifier? #'id) #'alias)))))))))) - ;; Renaming. -(define protocol/ssl-3 protocol/ssl3) -(define protocol/tls-1.0 protocol/tls1-0) -(define protocol/tls-1.1 protocol/tls1-1) +(define protocol/ssl-3 #f) +(define protocol/tls-1.0 #f) +(define protocol/tls-1.1 #f) ;; Aliases. -(define credentials/anonymous credentials/anon) -(define cipher/rijndael-256-cbc cipher/aes-256-cbc) -(define cipher/rijndael-128-cbc cipher/aes-128-cbc) -(define cipher/rijndael-cbc cipher/aes-128-cbc) -(define cipher/arcfour-128 cipher/arcfour) -(define certificate-verify/allow-any-x509-v1-ca-certificate - certificate-verify/allow-any-x509-v1-ca-crt) -(define certificate-verify/allow-x509-v1-ca-certificate - certificate-verify/allow-x509-v1-ca-crt) +(define credentials/anonymous #f) +(define cipher/rijndael-256-cbc #f) +(define cipher/rijndael-128-cbc #f) +(define cipher/rijndael-cbc #f) +(define cipher/arcfour-128 #f) +(define certificate-verify/allow-any-x509-v1-ca-certificate #f) +(define certificate-verify/allow-x509-v1-ca-certificate #f) + +(unless (getenv "GNUTLS_GUILE_CROSS_COMPILING") + ;; Renaming. + (set! protocol/ssl-3 protocol/ssl3) + (set! protocol/tls-1.0 protocol/tls1-0) + (set! protocol/tls-1.1 protocol/tls1-1) + + ;; Aliases. + (set! credentials/anonymous credentials/anon) + (set! cipher/rijndael-256-cbc cipher/aes-256-cbc) + (set! cipher/rijndael-128-cbc cipher/aes-128-cbc) + (set! cipher/rijndael-cbc cipher/aes-128-cbc) + (set! cipher/arcfour-128 cipher/arcfour) + (set! certificate-verify/allow-any-x509-v1-ca-certificate + certificate-verify/allow-any-x509-v1-ca-crt) + (set! certificate-verify/allow-x509-v1-ca-certificate + certificate-verify/allow-x509-v1-ca-crt)) ;; Deprecated OpenPGP bindings. (define-deprecated certificate-type/openpgp) -- 2.26.0 pan>services: configuration: Use *unspecified* instead of 'disabled....Use *unspecified* as a marker for field values that have not been set. Rationale: 'disabled may easily clash with user values for boolean fields, is confusing (i.e. its meaning is *not* boolean false, but unspecified) and it also passes silently through the symbol? predicate of a field of type symbol. * gnu/services/configuration.scm (configuration-missing-default-value): Renamed from configuration-no-default-value. (define-maybe-helper): Use *unspecified* instead of 'disabled, and make the default value optional. * gnu/home/services/desktop.scm (home-redshift-configuration): Change (maybe-xyz 'disabled) to maybe-xyz. * gnu/services/authentication.scm (nslcd-configuration): Likewise. * gnu/services/cgit.scm (repository-cgit-configuration): Likewise. * gnu/services/file-sharing.scm (serialize-maybe-string) (serialize-maybe-file-object): Use 'unspecified?' instead of (eq? val 'disabled). * gnu/services/messaging.scm (raw-content?): Likewise. (ssl-configuration): Change (maybe-xyz 'disabled) to maybe-xyz. (prosody-configuration): Likewise. * gnu/services/file-sharing.scm (transmission-daemon-configuration): Likewise. * gnu/services/messaging.scm (define-all-configurations): Use *unspecified* instead of 'disabled'. * gnu/services/networking.scm (opendht-configuration): Likewise. * gnu/services/pm.scm (tlp-configuration): Likewise. * gnu/services/telephony.scm (jami-account): Likewise. (jami-configuration): Likewise. * gnu/services/vpn.scm (openvpn-client-configuration): Likewise. * tests/services/configuration.scm ("maybe type, no default") ("maybe type, with default"): New tests. Signed-off-by: Ludovic Courtès <ludo@gnu.org> Attila Lendvai 2021-11-30services: Accept <inferior-package>s in lieu of <package>s....* gnu/services/authentication.scm (fprintd-configuration) (nslcd-configuration): Substitute file-like objects for package ones. * gnu/services/cgit.scm (cgit-configuration, opaque-cgit-configuration): Likewise. * gnu/services/cups.scm (package-list?, cups-configuration): Likewise. * gnu/services/dns.scm (verify-knot-configuration) (ddclient-configuration): Likewise. * gnu/services/docker.scm (docker-configuration): Likewise. * gnu/services/file-sharing.scm (transmission-daemon-configuration): Likewise. * gnu/services/getmail.scm (getmail-configuration): Likewise. * gnu/services/mail.scm (dovecot-configuration) (opaque-dovecot-configuration): Likewise. * gnu/services/messaging.scm (prosody-configuration) (opaque-prosody-configuration): Likewise. * gnu/services/monitoring.scm (zabbix-server-configuration) (zabbix-agent-configuration): Likewise. * gnu/services/networking.scm (opendht-configuration): Likewise. * gnu/services/pm.scm (tlp-configuration): Likewise. * gnu/services/telephony.scm (jami-configuration): Likewise. * gnu/services/virtualization.scm (libvirt-configuration) (qemu-guest-agent-configuration): Likewise. * gnu/services/vpn.scm (openvpn-client-configuration): Likewise. Tobias Geerinckx-Rice