From mboxrd@z Thu Jan 1 00:00:00 1970 Delivery-date: Mon, 27 Mar 2023 16:29:20 +0200 Received: from metis.ext.pengutronix.de ([2001:67c:670:201:290:27ff:fe1d:cc33]) by lore.white.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1pgnqZ-00GZQ6-Oc for lore@lore.pengutronix.de; Mon, 27 Mar 2023 16:29:20 +0200 Received: from localhost ([127.0.0.1] helo=metis.ext.pengutronix.de) by metis.ext.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1pgnqZ-0001Ig-Vt; Mon, 27 Mar 2023 16:29:19 +0200 Received: from mo4-p00-ob.smtp.rzone.de ([81.169.146.160]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pgnqD-0001IW-Gw for ptxdist@pengutronix.de; Mon, 27 Mar 2023 16:28:58 +0200 ARC-Seal: i=1; a=rsa-sha256; t=1679927336; cv=none; d=strato.com; s=strato-dkim-0002; b=VWmUc/aByPSG0DoIq3XkouppqJxZU14GmSOZtUsBpXYjmwIdBYEUnr5K82/e3yxrZk 65TYwn+5MG2MB7nweI7ZkiVgvlzc4PQ+MBhOEum+bZRJH4EbPOGRQOWw9jJyK3/ACi2K 75Pcl0jvwnSx5sYf/UM4B2j71XPkgZR7r87Xp/vp3Bcci3wfgXsl1M2iZNyhBBYg8NQh rh5Hs+QC8pnbSiMuLfetnRRQQD4xcBoRZRwXxlN2/cT998gESGPxo1kuV9JSN5uUaPwW XE2V75FwwNKY7jGxbCTEJLzzd7fzjIR/o9OxkwJldL4/4GkiJIMVcRK8gkN/jgJ+I6/d S+0Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; t=1679927336; s=strato-dkim-0002; d=strato.com; h=Subject:Message-ID:To:Date:In-Reply-To:From:Cc:Date:From:Subject: Sender; bh=trbNIG8Keld8ZlpEgcUKjlh8++4QL1RhJB41S2tMkYY=; b=ZpgmzYCe3AwFzVZTjIqPrd9xiLqI4C+5DSl3J/xJLRxSbV4LrnvcmUopbsbzg+9/dD MUvCVPDHzBqFz5R4N3GGaPKemxyGXvkp0WzvdtbjFUEmMu88Sm9dQTq40petkEOL8WlZ 8oW427QVzrm3Toqygai3PxGsoUy+KkGSrG1oblvOG4GpE4RqXquUoNZ4P5u3B0EoSqtq nIcy824UA5AsmaDAy4NXoQ049Jb6W5INnEoou1EL45QLDsecQRYiejv6vpmy6XByyJuH e7mJxoVN4iWKmVukbJmNJvlWKGhRgvQVmIWuCtJw/jhJrm3mgxi8nm3RpcW+t+h4zg9j w64w== ARC-Authentication-Results: i=1; strato.com; arc=none; dkim=none X-RZG-CLASS-ID: mo00 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1679927336; s=strato-dkim-0002; d=4wiebe.de; h=Subject:Message-ID:To:Date:In-Reply-To:From:Cc:Date:From:Subject: Sender; bh=trbNIG8Keld8ZlpEgcUKjlh8++4QL1RhJB41S2tMkYY=; b=GFX1E+w+pCIPmr/GXsv6YdtaM+erblzvpOCZ8LtX6+00VC6DKPTQAjeuD6jid3AlKH uao/heibiYMt4ox4+LCQ7jtI5rV4rF5DHhEdpK2tnKOjUIVSiBhQw/vXygBJxsgpjmtd NkmVtPL6CK35ZSPHGyWvR95soNqEjz6j/bSNajMQBevxch9ktQfw+eGqOd9Mz3uRgqW5 nCxVuWadljHUThJeYT7EwPWiJbz+vUdELF2rX27KWx/dB6MXuWlLkh+U4fWVKyW68qOc n7v/TCTI8FlgPwEd7ohIcWJmYz7xIA9etwEYAK/aOn/6UISxHNXNc/BbCFcd8IB00TXb hn4w== X-RZG-AUTH: ":Km0JfEyhft8wzIIhFLJpRLyPODuSc5X4exbBROmid4/wfXDMnRC7+FnMrvP0Z5i9Y6KONzWR" Received: from home by smtp.strato.de (RZmta 49.3.1 DYNA|AUTH) with ESMTPSA id 692debz2RESuXNU (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits)) (Client did not present a certificate) for ; Mon, 27 Mar 2023 16:28:56 +0200 (CEST) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by home (Postfix) with ESMTP id 358071A02B2 for ; Mon, 27 Mar 2023 16:28:56 +0200 (CEST) From: "Artur Wiebe" In-Reply-To: <20230327140915.3253285-3-artur@4wiebe.de> Content-Type: text/plain; charset="utf-8" X-Forward: ::1 Date: Mon, 27 Mar 2023 16:28:56 +0200 To: ptxdist@pengutronix.de MIME-Version: 1.0 Message-ID: <143ed7-6421a800-91-6821c100@118252765> User-Agent: SOGoMail 5.8.0 Content-Transfer-Encoding: quoted-printable X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on metis.ext.pengutronix.de X-Spam-Level: X-Spam-Status: No, score=-2.3 required=4.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_NONE autolearn=ham autolearn_force=no version=3.4.2 Subject: Re: [ptxdist] =?utf-8?q?=5BPATCH_3/3=5D_python3-cryptography=3A__Pyt?= =?utf-8?q?hon_package_that_wants_to_compile_with_rust_and_cargo=2E=2E=2E?= X-BeenThere: ptxdist@pengutronix.de X-Mailman-Version: 2.1.29 Precedence: list List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: ptxdist@pengutronix.de Sender: "ptxdist" X-SA-Exim-Connect-IP: 127.0.0.1 X-SA-Exim-Mail-From: ptxdist-bounces@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false Hi, cryptography is a python package that uses setuptools-rust to compile a= module with rust/cargo. This is the first one in PTXdist, but I think it will not be the last. It is needed by python3-asyncua (OPC/UA) that I am trying to add. While pure cargo packages already work well (I've tried few weeks ago),= the python-setuptools scenario is not covered yet. I am not that deep into PTXdist so I could send a patch. I hope someone= can help. My suggestion is to add a PKG=5FCARGO=5FLOCK variable that points to th= e Cargo.lock file. If it exists ptxdist cargosync should use it and also CARGO=5FHOME shou= ld be set in env.=20 PYTHON3=5FCRYPTOGRAPHY=5FCARGO=5FLOCK :=3D $(PYTHON3=5FCRYPTOGRAPHY=5FD= IR)/src/rust/Cargo.lock BR, Artur On Monday, 27 March, 2023 16:09 CEST, Artur Wiebe wro= te: > --- > rules/python3-cryptography.in | 10 ++++++ > rules/python3-cryptography.make | 56 +++++++++++++++++++++++++++++++= ++ > 2 files changed, 66 insertions(+) > create mode 100644 rules/python3-cryptography.in > create mode 100644 rules/python3-cryptography.make >=20 > diff --git a/rules/python3-cryptography.in b/rules/python3-cryptograp= hy.in > new file mode 100644 > index 000000000..97187de02 > --- /dev/null > +++ b/rules/python3-cryptography.in > @@ -0,0 +1,10 @@ > +## SECTION=3Dpython3 > + > +config PYTHON3=5FCRYPTOGRAPHY > + tristate > + select PYTHON3 > + select HOST=5FPYTHON3=5FSETUPTOOLS=5FRUST > + prompt "cryptography" > + help > + Cryptography is a package which provides cryptographic recipes an= d primitives to Python developers. > + Our goal is for it to be your =E2=80=9Ccryptographic standard lib= rary=E2=80=9D > diff --git a/rules/python3-cryptography.make b/rules/python3-cryptogr= aphy.make > new file mode 100644 > index 000000000..7c5ac9885 > --- /dev/null > +++ b/rules/python3-cryptography.make > @@ -0,0 +1,56 @@ > +# -*-makefile-*- > +# > +# Copyright (C) 2023 by Artur Wiebe > +# > +# For further information about the PTXdist project and license cond= itions > +# see the README file. > +# > + > +# > +# We provide this package > +# > +PACKAGES-$(PTXCONF=5FPYTHON3=5FCRYPTOGRAPHY) +=3D python3-cryptograp= hy > + > +# > +# Paths and names > +# > +PYTHON3=5FCRYPTOGRAPHY=5FVERSION :=3D 40.0.1 > +PYTHON3=5FCRYPTOGRAPHY=5FMD5 :=3D 24dec990fce1d4a614ad86076c8e347f > +PYTHON3=5FCRYPTOGRAPHY :=3D cryptography-$(PYTHON3=5FCRYPTOGRAPHY=5F= VERSION) > +PYTHON3=5FCRYPTOGRAPHY=5FSUFFIX :=3D tar.gz > +PYTHON3=5FCRYPTOGRAPHY=5FURL :=3D $(call ptx/mirror-pypi, cryptogra= phy, $(PYTHON3=5FCRYPTOGRAPHY).$(PYTHON3=5FCRYPTOGRAPHY=5FSUFFIX)) > +PYTHON3=5FCRYPTOGRAPHY=5FSOURCE :=3D $(SRCDIR)/$(PYTHON3=5FCRYPTOGR= APHY).$(PYTHON3=5FCRYPTOGRAPHY=5FSUFFIX) > +PYTHON3=5FCRYPTOGRAPHY=5FDIR :=3D $(BUILDDIR)/$(PYTHON3=5FCRYPTOGRA= PHY) > +PYTHON3=5FCRYPTOGRAPHY=5FLICENSE :=3D Apache-2.0 OR BSD-3-Clause > +PYTHON3=5FCRYPTOGRAPHY=5FLICENSE=5FFILES :=3D > + > +PYTHON3=5FCRYPTOGRAPHY=5FCARGO=5FLOCK :=3D $(PYTHON3=5FCRYPTOGRAPHY= =5FDIR)/src/rust/Cargo.lock > + > + > +# ------------------------------------------------------------------= ---------- > +# Prepare > +# ------------------------------------------------------------------= ---------- > + > +PYTHON3=5FCRYPTOGRAPHY=5FCONF=5FTOOL :=3D python3 > + > +# ------------------------------------------------------------------= ---------- > +# Target-Install > +# ------------------------------------------------------------------= ---------- > + > +$(STATEDIR)/python3-cryptography.targetinstall: > + @$(call targetinfo) > + > + @$(call install=5Finit, python3-cryptography) > + @$(call install=5Ffixup, python3-cryptography,PRIORITY,optional) > + @$(call install=5Ffixup, python3-cryptography,SECTION,base) > + @$(call install=5Ffixup, python3-cryptography,AUTHOR,"Artur Wiebe <= artur@4wiebe.de>") > + @$(call install=5Ffixup, python3-cryptography,DESCRIPTION,missing) > + > + @$(call install=5Fglob, python3-cryptography, 0, 0, -, \ > + $(PYTHON3=5FSITEPACKAGES),, *.py) > + > + @$(call install=5Ffinish, python3-cryptography) > + > + @$(call touch) > + > +# vim: syntax=3Dmake > --=20 > 2.39.2 >=20 >