From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id oIJ+Dv5IsF7HaAAA0tVLHw (envelope-from ) for ; Mon, 04 May 2020 16:55:26 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id ILqxHghJsF4GDgAA1q6Kng (envelope-from ) for ; Mon, 04 May 2020 16:55:36 +0000 Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:470:142::17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 62CBC945834 for ; Mon, 4 May 2020 16:17:45 +0000 (UTC) Received: from localhost ([::1]:34614 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jVdmr-000685-Pn for larch@yhetil.org; Mon, 04 May 2020 12:17:45 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40182) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jVdhK-00060q-Ke for guix-patches@gnu.org; Mon, 04 May 2020 12:12:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:50475) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jVdhK-0003Es-Al for guix-patches@gnu.org; Mon, 04 May 2020 12:12:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jVdhK-000671-6W for guix-patches@gnu.org; Mon, 04 May 2020 12:12:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#40874] [PATCH v2 3/3] gnu: Add rust-nettle-7. Resent-From: Efraim Flashner Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 04 May 2020 16:12:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 40874 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Hartmut Goebel Cc: 40874@debbugs.gnu.org Received: via spool by 40874-submit@debbugs.gnu.org id=B40874.158860866623421 (code B ref 40874); Mon, 04 May 2020 16:12:02 +0000 Received: (at 40874) by debbugs.gnu.org; 4 May 2020 16:11:06 +0000 Received: from localhost ([127.0.0.1]:33788 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jVdgN-00065e-5D for submit@debbugs.gnu.org; Mon, 04 May 2020 12:11:06 -0400 Received: from flashner.co.il ([178.62.234.194]:52296) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jVdgI-000652-O5 for 40874@debbugs.gnu.org; Mon, 04 May 2020 12:11:01 -0400 Received: from localhost (unknown [188.120.128.132]) by flashner.co.il (Postfix) with ESMTPSA id 1974F4000F; Mon, 4 May 2020 16:10:51 +0000 (UTC) Date: Mon, 4 May 2020 19:10:14 +0300 From: Efraim Flashner Message-ID: <20200504161014.GE1920@E5400> References: <754dc70567f6058f506c6a75598c9d00685c82b8.1587919230.git.h.goebel@crazy-compilers.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="0QFb0wBpEddLcDHQ" Content-Disposition: inline In-Reply-To: X-PGP-Key-ID: 0x41AAE7DCCA3D8351 X-PGP-Key: https://flashner.co.il/~efraim/efraim_flashner.asc X-PGP-Fingerprint: A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 X-Spam-Score: -0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.0 (-) X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Scanner: scn0 X-Spam-Score: 0.69 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 2001:470:142::17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Scan-Result: default: False [0.69 / 13.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; GENERIC_REPUTATION(0.00)[-0.49491878683368]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(0.00)[+ip6:2001:470:142::/48:c]; IP_REPUTATION_HAM(0.00)[asn: 22989(0.13), country: US(-0.00), ip: 2001:470:142::17(-0.49)]; DWL_DNSWL_BLOCKED(0.00)[2001:470:142::17:from]; MX_GOOD(-0.50)[cached: eggs.gnu.org]; RCPT_COUNT_TWO(0.00)[2]; MAILLIST(-0.20)[mailman]; SIGNED_PGP(-2.00)[]; FORGED_RECIPIENTS_MAILLIST(0.00)[]; RECEIVED_SPAMHAUS_PBL(0.00)[188.120.128.132:received]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; ASN(0.00)[asn:22989, ipnet:2001:470:142::/48, country:US]; MIME_TRACE(0.00)[0:+,1:+,2:~]; TAGGED_FROM(0.00)[larch=yhetil.org]; ARC_NA(0.00)[]; RECEIVED_SPAMHAUS_XBL(3.00)[188.120.128.132:received]; FROM_NEQ_ENVFROM(0.00)[efraim@flashner.co.il,guix-patches-bounces@gnu.org]; FROM_HAS_DN(0.00)[]; URIBL_BLOCKED(0.00)[gitlab.com:url,build.rs:url,fifthhorseman.net:email,flashner.co.il:email]; MIME_GOOD(-0.20)[multipart/signed,text/plain]; DMARC_NA(0.00)[flashner.co.il]; HAS_LIST_UNSUB(-0.01)[]; DNSWL_BLOCKED(0.00)[2001:470:142::17:from]; BAD_REP_POLICIES(0.10)[]; MID_RHS_NOT_FQDN(0.50)[]; RCVD_COUNT_SEVEN(0.00)[8]; FORGED_SENDER_MAILLIST(0.00)[] X-TUID: 9Jrz612DrH9t --0QFb0wBpEddLcDHQ Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable I would personally do this one with a snippet since its one line but looks good. On Mon, May 04, 2020 at 05:11:19PM +0200, Hartmut Goebel wrote: > * gnu/packages/crates-io.scm (rust-nettle-7): New variable. > * gnu/packages/patches/rust-nettle-disable-vendor.patch: New file. > * gnu/local.mk: Add it. > --- > gnu/local.mk | 1 + > gnu/packages/crates-io.scm | 44 +++++++++++++++++++ > .../patches/rust-nettle-disable-vendor.patch | 13 ++++++ > 3 files changed, 58 insertions(+) > create mode 100644 gnu/packages/patches/rust-nettle-disable-vendor.patch >=20 > diff --git a/gnu/local.mk b/gnu/local.mk > index f7ffe75eb3..383f867426 100644 > --- a/gnu/local.mk > +++ b/gnu/local.mk > @@ -1425,6 +1425,7 @@ dist_patch_DATA =3D \ > %D%/packages/patches/rust-1.25-accept-more-detailed-gdb-lines.patch \ > %D%/packages/patches/rust-bootstrap-stage0-test.patch \ > %D%/packages/patches/rust-coresimd-doctest.patch \ > + %D%/packages/patches/rust-nettle-disable-vendor.patch \ > %D%/packages/patches/rust-nettle-sys-disable-vendor.patch \ > %D%/packages/patches/rust-reproducible-builds.patch \ > %D%/packages/patches/rust-openssl-sys-no-vendor.patch \ > diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm > index 16855a8bff..e1c971e76e 100644 > --- a/gnu/packages/crates-io.scm > +++ b/gnu/packages/crates-io.scm > @@ -37,6 +37,7 @@ > #:use-module (gnu packages gtk) > #:use-module (gnu packages jemalloc) > #:use-module (gnu packages llvm) > + #:use-module (gnu packages multiprecision) > #:use-module (gnu packages nettle) > #:use-module (gnu packages pcre) > #:use-module (gnu packages pkg-config) > @@ -11943,6 +11944,49 @@ types as proposed in RFC 1158.") > (license (list license:asl2.0 > license:expat)))) > =20 > +(define-public rust-nettle-7 > + (package > + (name "rust-nettle") > + (version "7.0.0") > + (source > + (origin > + (method url-fetch) > + (uri (crate-uri "nettle" version)) > + (file-name (string-append name "-" version ".tar.gz")) > + (sha256 > + (base32 "1n6dwy9zba8853bmxzhwaashd3np0wxpx0pj43brm0hb8n2sxbxi")) > + (patches (search-patches "rust-nettle-disable-vendor.patch")))) > + (build-system cargo-build-system) > + (native-inputs > + `(("pkg-config" ,pkg-config))) > + (inputs > + `(("clang" ,clang) > + ("gmp" ,gmp) > + ("nettle" ,nettle))) > + (arguments > + `(#:skip-build? #t ;; provides nothing, has no tests > + #:cargo-inputs > + (("rust-getrandom" ,rust-getrandom-0.1) > + ("rust-libc" ,rust-libc-0.2) > + ("rust-nettle-sys" ,rust-nettle-sys-2) > + ("rust-thiserror" ,rust-thiserror-1.0)) > + #:cargo-development-inputs > + (("rust-bindgen" ,rust-bindgen-0.51) > + ("rust-pkg-config" ,rust-pkg-config-0.3)) > + #:phases > + (modify-phases %standard-phases > + (add-after 'unpack 'set-missing-env-vars > + (lambda* (#:key inputs #:allow-other-keys) > + ;; FIXME: why do we need to set this? > + (setenv "LIBCLANG_PATH" > + (string-append (assoc-ref inputs "clang") "/lib")) > + #t))))) > + (home-page "https://gitlab.com/sequoia-pgp/nettle-rs") > + (synopsis "Rust bindings for the Nettle cryptographic library") > + (description "This package provides Rust bindings for the Nettle > +cryptographic library.") > + (license (list license:lgpl3 license:gpl2 license:gpl3)))) > + > (define-public rust-nettle-sys-2 > (package > (name "rust-nettle-sys") > diff --git a/gnu/packages/patches/rust-nettle-disable-vendor.patch b/gnu/= packages/patches/rust-nettle-disable-vendor.patch > new file mode 100644 > index 0000000000..5b52821cdb > --- /dev/null > +++ b/gnu/packages/patches/rust-nettle-disable-vendor.patch > @@ -0,0 +1,13 @@ > +Subject: nettle: clear out "vendored" feature cruft from build.rs > +From: Daniel Kahn Gillmor's avatarDaniel Kahn Gillmor > + > +https://salsa.debian.org/rust-team/debcargo-conf/-/commit/b608e6beaa1d38= c14fc16ad53780d94954a91900 > +https://sources.debian.org/src/rust-nettle/7.0.0-1/debian/patches/disabl= e-vendor.diff/ > +--- a/Cargo.toml 1969-12-31 19:00:00.000000000 -0500 > ++++ b/Cargo.toml 2019-10-23 19:12:01.076181971 -0400 > +@@ -35,4 +35,4 @@ > + version =3D "1" > +=20 > + [features] > +-vendored =3D ["nettle-sys/vendored"] > ++vendored =3D [] > --=20 > 2.21.3 >=20 --=20 Efraim Flashner =D7=90=D7=A4=D7=A8=D7=99=D7=9D = =D7=A4=D7=9C=D7=A9=D7=A0=D7=A8 GPG key =3D A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 Confidentiality cannot be guaranteed on emails sent or received unencrypted --0QFb0wBpEddLcDHQ Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEoov0DD5VE3JmLRT3Qarn3Mo9g1EFAl6wPmYACgkQQarn3Mo9 g1EM4BAAwECBxzNUXhshkZXwp4DhjtPMXq/Egx7+BY/CZePmDgATb9cghnkSYrPU 9obUJ2EKIWvZcqymtFYuiVrjQuglC1miSc9DSiEKB6ZaT6alGa0SycKOcGAn8una qUxt4AUMbqDrrDDsO7KmHQ4PVDzQbtpOfXWyNNIjGaaRwCWP/GfRtNRqidYjMezO 5KlFBvgzkDlqKDdOtbWIG+6aNDVZ7A0le1Td0FPudxUu6k/0i4I//6hBvRD78Mc/ OTE6bU1gQ2XZokCd7d3GpI0IhRaIYA3eHZ/6ycefdmoifxNyb0W3JDab/btajKN4 uXjKyWFj3uJcFdKw/tqQG97gtm65gHfOuP7908swxQT6gEhYQwLVrpz6W5CAWCl8 fXmQe46fpWyx+PMBNkH+Q8x9iDR5/8J2sgqNO9xwnEye9wHyqcQVH+HchFppksme xkBVYhaRS3fZyO9dVSfNcUW6gruhFjh/bXGlA4qvedLeGQy4MOsVQJyRwCLEhCGN RhjUhr2llzKli0VOun0Kli7onvXaxQNRgOVDtY4lwk8iIZuFC2z+y527P4e/E8/f w0BKutLWpD4ZIE+HhC4hdERpqkgf9dLM1CB4s3YfCKXM4/jgsnB4E1HNqFEPuX+/ kUDrtD2ZcuAhZWcTfKCW2TIE/HkQnh4X/MwJnSM+RP8kwfi2yS8= =N8DB -----END PGP SIGNATURE----- --0QFb0wBpEddLcDHQ--