All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 01/33] python3-setuptools-rust-native: from meta-python
@ 2022-03-14 22:48 Richard Purdie
  2022-03-14 22:48 ` [PATCH 02/33] python3-setuptools-rust-native: remove obsolete PIP_* Richard Purdie
                   ` (31 more replies)
  0 siblings, 32 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography 3.4.x+

Only native rustc is supported at this time in oe-core,
therefore it makes no sense to try to build for target.

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python3-setuptools-rust-native_1.1.2.bb   | 33 +++++++++++++++++++
 1 file changed, 33 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-setuptools-rust-native_1.1.2.bb

diff --git a/meta/recipes-devtools/python/python3-setuptools-rust-native_1.1.2.bb b/meta/recipes-devtools/python/python3-setuptools-rust-native_1.1.2.bb
new file mode 100644
index 00000000000..73dcbb26e67
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-setuptools-rust-native_1.1.2.bb
@@ -0,0 +1,33 @@
+SUMMARY = "Setuptools Rust extension plugin"
+DESCRIPTION = "setuptools-rust is a plugin for setuptools to build Rust \
+Python extensions implemented with PyO3 or rust-cpython.\
+\
+Compile and distribute Python extensions written in Rust as easily as if they were written in C."
+HOMEPAGE = "https://github.com/PyO3/setuptools-rust"
+BUGTRACKER = "https://github.com/PyO3/setuptools-rust/issues"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=011cd92e702dd9e6b1a26157b6fd53f5"
+
+SRC_URI = "https://files.pythonhosted.org/packages/67/08/e1aa2c582c62ac76e4d60f8e454bd3bba933781a06a88b4e38797445822a/setuptools-rust-${PV}.tar.gz"
+SRC_URI[sha256sum] = "a0adb9b503c0ffc4e8fe80b7c617898cefa78049983aaaea7f747e153a3e65d1"
+
+# While this has a pyproject.toml and declares that setuptools_build_meta should work
+# it results in a wheel named UNKNOWN-0.0.0-py3-none-any.whl so stay with setuptools3
+# until that can be resolved
+inherit cargo pypi setuptools3 native
+
+# For some reason the wheel is built in ${S} not ${B}
+PIP_INSTALL_DIST_PATH = "${S}/dist"
+PIP_INSTALL_PACKAGE = "setuptools_rust"
+
+DEPENDS += "python3-setuptools-scm-native python3-wheel-native"
+
+RDEPENDS:${PN}:class-native += " \
+    python3-semantic-version-native \
+    python3-setuptools-native \
+    python3-setuptools-scm-native \
+    python3-toml-native \
+    python3-typing-extensions-native \
+    python3-wheel-native \
+"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 02/33] python3-setuptools-rust-native: remove obsolete PIP_*
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 03/33] pyo3.bbclass: move from meta-python Richard Purdie
                   ` (30 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Ross Burton

From: Ross Burton <ross.burton@arm.com>

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 .../python/python3-setuptools-rust-native_1.1.2.bb            | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/meta/recipes-devtools/python/python3-setuptools-rust-native_1.1.2.bb b/meta/recipes-devtools/python/python3-setuptools-rust-native_1.1.2.bb
index 73dcbb26e67..2b929727005 100644
--- a/meta/recipes-devtools/python/python3-setuptools-rust-native_1.1.2.bb
+++ b/meta/recipes-devtools/python/python3-setuptools-rust-native_1.1.2.bb
@@ -17,10 +17,6 @@ SRC_URI[sha256sum] = "a0adb9b503c0ffc4e8fe80b7c617898cefa78049983aaaea7f747e153a
 # until that can be resolved
 inherit cargo pypi setuptools3 native
 
-# For some reason the wheel is built in ${S} not ${B}
-PIP_INSTALL_DIST_PATH = "${S}/dist"
-PIP_INSTALL_PACKAGE = "setuptools_rust"
-
 DEPENDS += "python3-setuptools-scm-native python3-wheel-native"
 
 RDEPENDS:${PN}:class-native += " \
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 03/33] pyo3.bbclass: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
  2022-03-14 22:48 ` [PATCH 02/33] python3-setuptools-rust-native: remove obsolete PIP_* Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 04/33] setuptools3_rust.bbclass: " Richard Purdie
                   ` (29 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

PyO3 provides Rust bindings for Python, including tools for creating native
Python extension modules. Running and interacting with Python code from a
Rust binary is also supported.

This class sets up the cross-compilation environment.

Export PYO3_CROSS, PYO3_CROSS_LIB_DIR, PYO3_CROSS_INCLUDE_DIR and CARGO_BUILD_TARGET
to inform tools like setuptools-rust we are cross-compiling.

Export RUSTFLAGS so cargo can find 'std' and 'core' for target

Dynamically generate PyO3 config file and export PYO3_CONFIG_FILE
absolute path. This is the trick that finally made pyo3 work.

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 meta/classes/pyo3.bbclass | 30 ++++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)
 create mode 100644 meta/classes/pyo3.bbclass

diff --git a/meta/classes/pyo3.bbclass b/meta/classes/pyo3.bbclass
new file mode 100644
index 00000000000..6ce21329c2e
--- /dev/null
+++ b/meta/classes/pyo3.bbclass
@@ -0,0 +1,30 @@
+#
+# This class helps make sure that Python extensions built with PyO3
+# and setuptools_rust properly set up the environment for cross compilation
+#
+
+inherit cargo python3-dir siteinfo
+
+export PYO3_CROSS="1"
+export PYO3_CROSS_PYTHON_VERSION="${PYTHON_BASEVERSION}"
+export PYO3_CROSS_LIB_DIR="${STAGING_LIBDIR}"
+export CARGO_BUILD_TARGET="${HOST_SYS}"
+export RUSTFLAGS
+export PYO3_PYTHON="${PYTHON}"
+export PYO3_CONFIG_FILE="${WORKDIR}/pyo3.config"
+
+pyo3_do_configure () {
+    cat > ${WORKDIR}/pyo3.config << EOF
+implementation=CPython
+version=${PYTHON_BASEVERSION}
+shared=true
+abi3=false
+lib_name=${PYTHON_DIR}
+lib_dir=${STAGING_LIBDIR}
+pointer_width=${SITEINFO_BITS}
+build_flags=WITH_THREAD
+suppress_build_script_link_lines=false
+EOF
+}
+
+EXPORT_FUNCTIONS do_configure
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 04/33] setuptools3_rust.bbclass: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
  2022-03-14 22:48 ` [PATCH 02/33] python3-setuptools-rust-native: remove obsolete PIP_* Richard Purdie
  2022-03-14 22:48 ` [PATCH 03/33] pyo3.bbclass: move from meta-python Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 05/33] python3-cryptography: " Richard Purdie
                   ` (28 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

setuptools-rust is a plugin for setuptools to build Rust Python extensions
implemented with PyO3 or rust-cpython.

Compile and distribute Python extensions written in Rust as easily as if
they were written in C.

This class inherits pyo3.bbclass (and therefore cargo.bbclass) and
setuptools3.bbclass to make it easier to build Python modules with Rust
extensions.

Need to call pyo3_do_configure to properly setup the PyO3 environment
for cross-compiling.

Need to call cargo_common_do_configure to setup cargo_home/config so
that the linker properly finds e.g. crti.o and crtbeginS.o

It is strongly recommended to provide crates needed for your recipe
using the crate:// fetcher. This can be helped with the cargo-bitbake
command [1].

If you choose not to use the crate fetcher, bitbake vendoring will not
work with setuptools-rust, as it errors out immediately because it cannot
find pyo3 or some other crate. The (strongly discouraged) workaround for
this is to set:

CARGO_DISABLE_BITBAKE_VENDORING = "1"

[1] https://crates.io/crates/cargo-bitbake

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 meta/classes/setuptools3_rust.bbclass | 11 +++++++++++
 1 file changed, 11 insertions(+)
 create mode 100644 meta/classes/setuptools3_rust.bbclass

diff --git a/meta/classes/setuptools3_rust.bbclass b/meta/classes/setuptools3_rust.bbclass
new file mode 100644
index 00000000000..fb11f08f89c
--- /dev/null
+++ b/meta/classes/setuptools3_rust.bbclass
@@ -0,0 +1,11 @@
+inherit pyo3 setuptools3
+
+DEPENDS += "python3-setuptools-rust-native"
+
+setuptools3_rust_do_configure() {
+    pyo3_do_configure
+    cargo_common_do_configure
+    setuptools3_do_configure
+}
+
+EXPORT_FUNCTIONS do_configure
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 05/33] python3-cryptography: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (2 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 04/33] setuptools3_rust.bbclass: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 06/33] python3-pytest-subtests: " Richard Purdie
                   ` (27 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

* inherit new setuptools_rust class (which inherits new pyo3 class, which
  inherits cargo and python3-dir).
* RDEPENDS on python3-pytest-subtests for ptest
* Copy pyproject.toml for ptest as it defines the pytest.marker(s) needed
* Use 'cargo bitbake' to generate the crate:// SRC_URIs
   - Needed some hacks to the Cargo.toml in src/rust/ to make this work (probably
     only package.repository was strictly required):

     [package]
     description = "cryptography includes both high level recipes and low level interfaces to common cryptographic algorithms such as symmetric ciphers, message digests, and key derivation functions."
     homepage = "https://github.com/pyca/cryptography"
     repository = "https://github.com/pyca/cryptography"

* Add patches to src/rust/Cargo.toml to fix cargo errors including  pem version
* Add check-memfree.py to ptest to check for sufficient free memory

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../0001-Cargo.toml-specify-pem-version.patch |  31 +++++
 .../0002-Cargo.toml-edition-2018-2021.patch   |  28 ++++
 .../python3-cryptography/check-memfree.py     |  10 ++
 .../python/python3-cryptography/run-ptest     |   4 +
 .../python/python3-cryptography_36.0.1.bb     | 123 ++++++++++++++++++
 5 files changed, 196 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-cryptography/0001-Cargo.toml-specify-pem-version.patch
 create mode 100644 meta/recipes-devtools/python/python3-cryptography/0002-Cargo.toml-edition-2018-2021.patch
 create mode 100755 meta/recipes-devtools/python/python3-cryptography/check-memfree.py
 create mode 100644 meta/recipes-devtools/python/python3-cryptography/run-ptest
 create mode 100644 meta/recipes-devtools/python/python3-cryptography_36.0.1.bb

diff --git a/meta/recipes-devtools/python/python3-cryptography/0001-Cargo.toml-specify-pem-version.patch b/meta/recipes-devtools/python/python3-cryptography/0001-Cargo.toml-specify-pem-version.patch
new file mode 100644
index 00000000000..d7ab757bb51
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-cryptography/0001-Cargo.toml-specify-pem-version.patch
@@ -0,0 +1,31 @@
+From ec8d3f3c61280c8140b34ed1479baef5e706f064 Mon Sep 17 00:00:00 2001
+From: Tim Orling <tim.orling@konsulko.com>
+Date: Fri, 14 Jan 2022 22:02:25 -0800
+Subject: [PATCH] Cargo.toml: specify pem version
+
+pem = "1.0" is not resolving, specify the current
+pem = { version: "1.0.2"}
+
+Upstream-Status: Pending
+
+Signed-off-by: Tim Orling <tim.orling@konsulko.com>
+---
+ src/rust/Cargo.toml | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/rust/Cargo.toml b/src/rust/Cargo.toml
+index 617167d0..174eaa80 100644
+--- a/src/rust/Cargo.toml
++++ b/src/rust/Cargo.toml
+@@ -9,7 +9,7 @@ publish = false
+ lazy_static = "1"
+ pyo3 = { version = "0.15.1" }
+ asn1 = { version = "0.8.7", default-features = false, features = ["derive"] }
+-pem = "1.0"
++pem = { version = "1.0.2" }
+ chrono = { version = "0.4", default-features = false, features = ["alloc", "clock"] }
+ ouroboros = "0.13"
+ 
+-- 
+2.30.2
+
diff --git a/meta/recipes-devtools/python/python3-cryptography/0002-Cargo.toml-edition-2018-2021.patch b/meta/recipes-devtools/python/python3-cryptography/0002-Cargo.toml-edition-2018-2021.patch
new file mode 100644
index 00000000000..366e3a4d39a
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-cryptography/0002-Cargo.toml-edition-2018-2021.patch
@@ -0,0 +1,28 @@
+From 4b73298b214a5b69ea6edf3c2e21dd82b2b29708 Mon Sep 17 00:00:00 2001
+From: Tim Orling <tim.orling@konsulko.com>
+Date: Fri, 14 Jan 2022 22:34:59 -0800
+Subject: [PATCH 2/2] Cargo.toml: edition 2018 -> 2021
+
+Upstream-Status: Pending
+
+Signed-off-by: Tim Orling <tim.orling@konsulko.com>
+---
+ src/rust/Cargo.toml | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/rust/Cargo.toml b/src/rust/Cargo.toml
+index 174eaa80..7ad053d9 100644
+--- a/src/rust/Cargo.toml
++++ b/src/rust/Cargo.toml
+@@ -2,7 +2,7 @@
+ name = "cryptography-rust"
+ version = "0.1.0"
+ authors = ["The cryptography developers <cryptography-dev@python.org>"]
+-edition = "2018"
++edition = "2021"
+ publish = false
+ 
+ [dependencies]
+-- 
+2.30.2
+
diff --git a/meta/recipes-devtools/python/python3-cryptography/check-memfree.py b/meta/recipes-devtools/python/python3-cryptography/check-memfree.py
new file mode 100755
index 00000000000..c111a9074c1
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-cryptography/check-memfree.py
@@ -0,0 +1,10 @@
+#!/usr/bin/env python3
+# https://stackoverflow.com/questions/22102999/get-total-physical-memory-in-python/28161352
+import sys
+meminfo = dict((i.split()[0].rstrip(':'),int(i.split()[1])) for i in open('/proc/meminfo').readlines())
+mem_free = meminfo['MemTotal']/1024./1024.
+if mem_free < 2.:
+    raise RuntimeError("Insufficient free memory({:.3f}): requires > 2 GB".format(mem_free))
+    sys.exit(1)
+else:
+    print("Free memory: {:.3f} GB".format(mem_free))
diff --git a/meta/recipes-devtools/python/python3-cryptography/run-ptest b/meta/recipes-devtools/python/python3-cryptography/run-ptest
new file mode 100644
index 00000000000..1e97dda63e7
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-cryptography/run-ptest
@@ -0,0 +1,4 @@
+#!/bin/sh
+if ./check-memfree.py; then
+    pytest -vvvv tests/
+fi
diff --git a/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb b/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
new file mode 100644
index 00000000000..00791dce2de
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
@@ -0,0 +1,123 @@
+SUMMARY = "Provides cryptographic recipes and primitives to python developers"
+HOMEPAGE = "https://cryptography.io/"
+SECTION = "devel/python"
+LICENSE = "( Apache-2.0 | BSD-3-Clause ) & PSF-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=bf405a8056a6647e7d077b0e7bc36aba \
+                    file://LICENSE.APACHE;md5=4e168cce331e5c827d4c2b68a6200e1b \
+                    file://LICENSE.BSD;md5=5ae30ba4123bc4f2fa49aa0b0dce887b \
+                    file://LICENSE.PSF;md5=43c37d21e1dbad10cddcd150ba2c0595 \
+                   "
+LDSHARED += "-pthread"
+
+SRC_URI[sha256sum] = "53e5c1dc3d7a953de055d77bef2ff607ceef7a2aac0353b5d630ab67f7423638"
+
+SRC_URI += " \
+    file://run-ptest \
+    file://check-memfree.py \
+    file://0001-Cargo.toml-specify-pem-version.patch \
+    file://0002-Cargo.toml-edition-2018-2021.patch \
+"
+
+inherit pypi setuptools3_rust
+
+PIP_INSTALL_DIST_PATH = "${S}/dist"
+
+DEPENDS += " \
+    ${PYTHON_PN}-asn1crypto-native \
+    ${PYTHON_PN}-cffi-native \
+    ${PYTHON_PN}-setuptools-rust-native \
+    ${PYTHON_PN}-six-native \
+"
+
+SRC_URI += " \
+    crate://crates.io/Inflector/0.11.4 \
+    crate://crates.io/aliasable/0.1.3 \
+    crate://crates.io/asn1/0.8.7 \
+    crate://crates.io/asn1_derive/0.8.7 \
+    crate://crates.io/autocfg/1.0.1 \
+    crate://crates.io/base64/0.13.0 \
+    crate://crates.io/bitflags/1.3.2 \
+    crate://crates.io/cfg-if/1.0.0 \
+    crate://crates.io/chrono/0.4.19 \
+    crate://crates.io/indoc-impl/0.3.6 \
+    crate://crates.io/indoc/0.3.6 \
+    crate://crates.io/instant/0.1.12 \
+    crate://crates.io/lazy_static/1.4.0 \
+    crate://crates.io/libc/0.2.112 \
+    crate://crates.io/lock_api/0.4.5 \
+    crate://crates.io/num-integer/0.1.44 \
+    crate://crates.io/num-traits/0.2.14 \
+    crate://crates.io/once_cell/1.9.0 \
+    crate://crates.io/ouroboros/0.13.0 \
+    crate://crates.io/ouroboros_macro/0.13.0 \
+    crate://crates.io/parking_lot/0.11.2 \
+    crate://crates.io/parking_lot_core/0.8.5 \
+    crate://crates.io/paste-impl/0.1.18 \
+    crate://crates.io/paste/0.1.18 \
+    crate://crates.io/pem/1.0.2 \
+    crate://crates.io/proc-macro-error-attr/1.0.4 \
+    crate://crates.io/proc-macro-error/1.0.4 \
+    crate://crates.io/proc-macro-hack/0.5.19 \
+    crate://crates.io/proc-macro2/1.0.36 \
+    crate://crates.io/pyo3-build-config/0.15.1 \
+    crate://crates.io/pyo3-macros-backend/0.15.1 \
+    crate://crates.io/pyo3-macros/0.15.1 \
+    crate://crates.io/pyo3/0.15.1 \
+    crate://crates.io/quote/1.0.14 \
+    crate://crates.io/redox_syscall/0.2.10 \
+    crate://crates.io/scopeguard/1.1.0 \
+    crate://crates.io/smallvec/1.7.0 \
+    crate://crates.io/stable_deref_trait/1.2.0 \
+    crate://crates.io/syn/1.0.85 \
+    crate://crates.io/unicode-xid/0.2.2 \
+    crate://crates.io/unindent/0.1.7 \
+    crate://crates.io/version_check/0.9.4 \
+    crate://crates.io/winapi-i686-pc-windows-gnu/0.4.0 \
+    crate://crates.io/winapi-x86_64-pc-windows-gnu/0.4.0 \
+    crate://crates.io/winapi/0.3.9 \
+"
+
+RDEPENDS:${PN} += " \
+    ${PYTHON_PN}-asn1crypto \
+    ${PYTHON_PN}-cffi \
+    ${PYTHON_PN}-idna \
+    ${PYTHON_PN}-setuptools \
+    ${PYTHON_PN}-six \
+"
+
+RDEPENDS:${PN}:append:class-target = " \
+    ${PYTHON_PN}-numbers \
+    ${PYTHON_PN}-threading \
+"
+
+RDEPENDS:${PN}-ptest += " \
+    ${PYTHON_PN}-bcrypt \
+    ${PYTHON_PN}-cryptography-vectors \
+    ${PYTHON_PN}-hypothesis \
+    ${PYTHON_PN}-iso8601 \
+    ${PYTHON_PN}-pretend \
+    ${PYTHON_PN}-psutil \
+    ${PYTHON_PN}-pytest \
+    ${PYTHON_PN}-pytest-subtests \
+    ${PYTHON_PN}-pytz \
+"
+
+inherit ptest
+
+do_install_ptest() {
+    install -D ${WORKDIR}/check-memfree.py ${D}${PTEST_PATH}/
+    install -d ${D}${PTEST_PATH}/tests
+    cp -rf ${S}/tests/* ${D}${PTEST_PATH}/tests/
+    install -d ${D}${PTEST_PATH}/tests/hazmat
+    cp -rf ${S}/tests/hazmat/* ${D}${PTEST_PATH}/tests/hazmat/
+    cp -r ${S}/pyproject.toml ${D}${PTEST_PATH}/
+}
+
+FILES:${PN}-ptest += " \
+    ${PTEST_PATH}/check-memfree.py \
+"
+FILES:${PN}-dbg += " \
+    ${PYTHON_SITEPACKAGES_DIR}/${SRCNAME}/hazmat/bindings/.debug \
+"
+
+BBCLASSEXTEND = "native nativesdk"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 06/33] python3-pytest-subtests: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (3 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 05/33] python3-cryptography: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 07/33] python3-cryptography-vectors: " Richard Purdie
                   ` (26 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography ptest.

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python/python3-pytest-subtests_0.6.0.bb   | 20 +++++++++++++++++++
 1 file changed, 20 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-pytest-subtests_0.6.0.bb

diff --git a/meta/recipes-devtools/python/python3-pytest-subtests_0.6.0.bb b/meta/recipes-devtools/python/python3-pytest-subtests_0.6.0.bb
new file mode 100644
index 00000000000..5e4847b8d94
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-pytest-subtests_0.6.0.bb
@@ -0,0 +1,20 @@
+SUMMARY = "unittest subTest() support and subtests fixture."
+DESCRIPTION = "Adds support for TestCase.subTest.\
+New subtests fixture, providing similar functionality for pure pytest tests."
+HOMEPAGE = "https://github.com/pytest-dev/pytest-subtests"
+BUGTRACKER = "https://github.com/pytest-dev/pytest-subtests/issues"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=242b4e17fa287dcf7aef372f6bc3dcb1"
+
+SRC_URI[sha256sum] = "3ebd306a8dcf75133f1742f288c82f36426ebcf8a132d4ee89782d20e84fc13a"
+
+inherit pypi setuptools3
+
+DEPENDS += "${PYTHON_PN}-setuptools-scm-native"
+
+RDEPENDS:${PN} += " \
+    ${PYTHON_PN}-pytest \
+"
+
+BBCLASSEXTEND = "native nativesdk"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 07/33] python3-cryptography-vectors: from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (4 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 06/33] python3-pytest-subtests: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 08/33] python3-asn1crypto: move " Richard Purdie
                   ` (25 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography ptest.

This recipe needs to be kept in lock-step with the version of
python3-cryptography.

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python3-cryptography-vectors_36.0.1.bb    | 24 +++++++++++++++++++
 1 file changed, 24 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-cryptography-vectors_36.0.1.bb

diff --git a/meta/recipes-devtools/python/python3-cryptography-vectors_36.0.1.bb b/meta/recipes-devtools/python/python3-cryptography-vectors_36.0.1.bb
new file mode 100644
index 00000000000..b9e6b811c37
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-cryptography-vectors_36.0.1.bb
@@ -0,0 +1,24 @@
+SUMMARY = "Test vectors for the cryptography package."
+HOMEPAGE = "https://cryptography.io/"
+SECTION = "devel/python"
+LICENSE = "Apache-2.0 | BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=8c3617db4fb6fae01f1d253ab91511e4 \
+                    file://LICENSE.APACHE;md5=4e168cce331e5c827d4c2b68a6200e1b \
+                    file://LICENSE.BSD;md5=5ae30ba4123bc4f2fa49aa0b0dce887b"
+
+# NOTE: Make sure to keep this recipe at the same version as python3-cryptography
+#       Upgrade both recipes at the same time
+
+SRC_URI[sha256sum] = "fc8490afd5424342b868215435bd174dcd76ab396b4ea9435498be5721dcd598"
+
+PYPI_PACKAGE = "cryptography_vectors"
+
+inherit pypi setuptools3
+
+DEPENDS += " \
+    ${PYTHON_PN}-cryptography \
+"
+
+BBCLASSEXTEND = "native nativesdk"
+
+UPSTREAM_CHECK_REGEX = ""
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 08/33] python3-asn1crypto: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (5 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 07/33] python3-cryptography-vectors: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 09/33] python3-cffi: " Richard Purdie
                   ` (24 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python/python3-asn1crypto_1.4.0.bb        | 25 +++++++++++++++++++
 1 file changed, 25 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-asn1crypto_1.4.0.bb

diff --git a/meta/recipes-devtools/python/python3-asn1crypto_1.4.0.bb b/meta/recipes-devtools/python/python3-asn1crypto_1.4.0.bb
new file mode 100644
index 00000000000..c052cb8c827
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-asn1crypto_1.4.0.bb
@@ -0,0 +1,25 @@
+DESCRIPTION = "A fast, pure Python library for parsing and serializing ASN.1 structures"
+HOMEPAGE = "https://github.com/wbond/asn1crypto"
+SECTION = "devel/python"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=7439e38f5e04ff62fae436184786b7ca"
+
+PYPI_PACKAGE = "asn1crypto"
+
+SRC_URI[md5sum] = "00bf5b72d37778e62cc73b1d8909ae27"
+SRC_URI[sha256sum] = "f4f6e119474e58e04a2b1af817eb585b4fd72bdd89b998624712b5c99be7641c"
+
+inherit pypi setuptools3
+
+RDEPENDS:${PN}:class-target += " \
+    ${PYTHON_PN}-codecs \
+    ${PYTHON_PN}-crypt \
+    ${PYTHON_PN}-ctypes \
+    ${PYTHON_PN}-datetime \
+    ${PYTHON_PN}-io \
+    ${PYTHON_PN}-netclient \
+    ${PYTHON_PN}-numbers \
+    ${PYTHON_PN}-shell \
+"
+
+BBCLASSEXTEND = "native nativesdk"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 09/33] python3-cffi: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (6 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 08/33] python3-asn1crypto: move " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 10/33] python3-pytz: " Richard Purdie
                   ` (23 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python/python3-cffi_1.15.0.bb              | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-cffi_1.15.0.bb

diff --git a/meta/recipes-devtools/python/python3-cffi_1.15.0.bb b/meta/recipes-devtools/python/python3-cffi_1.15.0.bb
new file mode 100644
index 00000000000..c36f23b3dde
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-cffi_1.15.0.bb
@@ -0,0 +1,18 @@
+SUMMARY = "Foreign Function Interface for Python calling C code"
+HOMEPAGE = "http://cffi.readthedocs.org/"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=5677e2fdbf7cdda61d6dd2b57df547bf"
+DEPENDS += "libffi ${PYTHON_PN}-pycparser"
+
+SRC_URI[sha256sum] = "920f0d66a896c2d99f0adbb391f990a84091179542c205fa53ce5787aff87954"
+
+inherit pypi setuptools3
+
+RDEPENDS:${PN}:class-target = " \
+    ${PYTHON_PN}-ctypes \
+    ${PYTHON_PN}-io \
+    ${PYTHON_PN}-pycparser \
+    ${PYTHON_PN}-shell \
+"
+
+BBCLASSEXTEND = "native nativesdk"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 10/33] python3-pytz: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (7 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 09/33] python3-cffi: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 11/33] python3-bcrypt: " Richard Purdie
                   ` (22 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python/python3-pytz/run-ptest             |  3 ++
 .../python/python3-pytz_2021.3.bb             | 35 +++++++++++++++++++
 2 files changed, 38 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-pytz/run-ptest
 create mode 100644 meta/recipes-devtools/python/python3-pytz_2021.3.bb

diff --git a/meta/recipes-devtools/python/python3-pytz/run-ptest b/meta/recipes-devtools/python/python3-pytz/run-ptest
new file mode 100644
index 00000000000..b63c4de0d9a
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-pytz/run-ptest
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+pytest -o log_cli=true -o log_cli_level=INFO | sed -e 's/\[...%\]//g'| sed -e 's/PASSED/PASS/g'| sed -e 's/FAILED/FAIL/g'|sed -e 's/SKIPPED/SKIP/g'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS"){printf "%s: %s\n", $NF, $0}else{print}}'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS") {$NF="";print $0}else{print}}'
diff --git a/meta/recipes-devtools/python/python3-pytz_2021.3.bb b/meta/recipes-devtools/python/python3-pytz_2021.3.bb
new file mode 100644
index 00000000000..119342a4bd7
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-pytz_2021.3.bb
@@ -0,0 +1,35 @@
+SUMMARY = "World timezone definitions, modern and historical"
+HOMEPAGE = "http://pythonhosted.org/pytz"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=1a67fc46c1b596cce5d21209bbe75999"
+
+inherit pypi setuptools3 ptest
+
+SRC_URI[sha256sum] = "acad2d8b20a1af07d4e4c9d2e9285c5ed9104354062f275f3fcd88dcef4f1326"
+
+RDEPENDS:${PN}:class-target += "\
+    ${PYTHON_PN}-datetime \
+    ${PYTHON_PN}-doctest \
+    ${PYTHON_PN}-io \
+    ${PYTHON_PN}-pickle \
+    ${PYTHON_PN}-pprint \
+    ${PYTHON_PN}-threading \
+"
+
+BBCLASSEXTEND = "native nativesdk"
+
+SRC_URI += " \
+	file://run-ptest \
+"
+
+RDEPENDS:${PN}-ptest += " \
+	${PYTHON_PN}-pytest \
+"
+
+do_install_ptest() {
+	install -d ${D}${PTEST_PATH}/pytz
+	install -d ${D}${PTEST_PATH}/pytz/tests
+	cp -rf ${S}/pytz/tests/* ${D}${PTEST_PATH}/pytz/tests/
+	cp -f ${S}/README.rst ${D}${PTEST_PATH}/
+
+}
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 11/33] python3-bcrypt: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (8 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 10/33] python3-pytz: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 12/33] python3-pretend: " Richard Purdie
                   ` (21 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python/python3-bcrypt/run-ptest           |  3 ++
 .../python/python3-bcrypt_3.2.0.bb            | 30 +++++++++++++++++++
 2 files changed, 33 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-bcrypt/run-ptest
 create mode 100644 meta/recipes-devtools/python/python3-bcrypt_3.2.0.bb

diff --git a/meta/recipes-devtools/python/python3-bcrypt/run-ptest b/meta/recipes-devtools/python/python3-bcrypt/run-ptest
new file mode 100644
index 00000000000..b63c4de0d9a
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-bcrypt/run-ptest
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+pytest -o log_cli=true -o log_cli_level=INFO | sed -e 's/\[...%\]//g'| sed -e 's/PASSED/PASS/g'| sed -e 's/FAILED/FAIL/g'|sed -e 's/SKIPPED/SKIP/g'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS"){printf "%s: %s\n", $NF, $0}else{print}}'| awk '{if ($NF=="PASS" || $NF=="FAIL" || $NF=="SKIP" || $NF=="XFAIL" || $NF=="XPASS") {$NF="";print $0}else{print}}'
diff --git a/meta/recipes-devtools/python/python3-bcrypt_3.2.0.bb b/meta/recipes-devtools/python/python3-bcrypt_3.2.0.bb
new file mode 100644
index 00000000000..92a6a0d8c5f
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-bcrypt_3.2.0.bb
@@ -0,0 +1,30 @@
+DESCRIPTION = "Modern password hashing for your software and your servers."
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=8f7bb094c7232b058c7e9f2e431f389c"
+
+DEPENDS += "${PYTHON_PN}-cffi-native"
+
+SRC_URI[md5sum] = "fe31390dab603728f756cd3d6830c80a"
+SRC_URI[sha256sum] = "5b93c1726e50a93a033c36e5ca7fdcd29a5c7395af50a6892f5d9e7c6cfbfb29"
+
+inherit pypi setuptools_build_meta ptest
+
+SRC_URI += " \
+	file://run-ptest \
+"
+
+RDEPENDS:${PN}-ptest += " \
+	${PYTHON_PN}-pytest \
+"
+
+do_install_ptest() {
+	install -d ${D}${PTEST_PATH}/tests
+	cp -rf ${S}/tests/* ${D}${PTEST_PATH}/tests/
+}
+
+RDEPENDS:${PN}:class-target += "\
+    ${PYTHON_PN}-cffi \
+    ${PYTHON_PN}-ctypes \
+    ${PYTHON_PN}-shell \
+    ${PYTHON_PN}-six \
+"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 12/33] python3-pretend: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (9 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 11/33] python3-bcrypt: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 13/33] python3-psutil: " Richard Purdie
                   ` (20 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 meta/recipes-devtools/python/python3-pretend_1.0.9.bb | 11 +++++++++++
 1 file changed, 11 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-pretend_1.0.9.bb

diff --git a/meta/recipes-devtools/python/python3-pretend_1.0.9.bb b/meta/recipes-devtools/python/python3-pretend_1.0.9.bb
new file mode 100644
index 00000000000..21d14a03b8d
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-pretend_1.0.9.bb
@@ -0,0 +1,11 @@
+SUMMARY = "A library for stubbing in Python"
+HOMEPAGE = "https://github.com/alex/pretend"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE.rst;md5=411780c0b7fa756753e94affeee5bc99"
+
+SRC_URI[md5sum] = "ad53883ede48aeac7ae584f0de0240e8"
+SRC_URI[sha256sum] = "c90eb810cde8ebb06dafcb8796f9a95228ce796531bc806e794c2f4649aa1b10"
+
+inherit pypi setuptools3
+
+BBCLASSEXTEND = "native nativesdk"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 13/33] python3-psutil: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (10 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 12/33] python3-pretend: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 14/33] poetry_core.bbclass: " Richard Purdie
                   ` (19 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../0001-fix-failure-test-cases.patch         | 197 ++++++++++++++++++
 .../python/python3-psutil_5.9.0.bb            |  28 +++
 2 files changed, 225 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-psutil/0001-fix-failure-test-cases.patch
 create mode 100644 meta/recipes-devtools/python/python3-psutil_5.9.0.bb

diff --git a/meta/recipes-devtools/python/python3-psutil/0001-fix-failure-test-cases.patch b/meta/recipes-devtools/python/python3-psutil/0001-fix-failure-test-cases.patch
new file mode 100644
index 00000000000..34ea03b27f3
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-psutil/0001-fix-failure-test-cases.patch
@@ -0,0 +1,197 @@
+From 8b4e38958ff8bdbb3ece4796bfa2d3b6f7536f71 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Wed, 23 Feb 2022 11:54:40 +0800
+Subject: [PATCH] fix failure test cases
+
+The test cases is not robust enough. skip some cases that is
+not suitable for all conditions.
+
+* test_io_counters failed when kernel config CONFIG_TASKSTATS
+  and CONFIG_TASK_IO_ACCOUNTING are not enable in OE 
+* test_setup_script failed since oe don't install setup.py
+* test_used failed since oe use git source for free, so the version
+  is 3.3.17-dirty
+* test_weird_environ failed since gcc not installed
+* test_debug failed since it is designed to run when PSUTIL_DEBUG is set
+* test_against_findmnt/test_comparisons/test_disk_partitions_mocked/
+  test_disk_partitions is not suitable for Linux nfs boot
+
+Upstream-Status: Pending
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ psutil/tests/test_contracts.py | 1 +
+ psutil/tests/test_linux.py     | 8 ++++++--
+ psutil/tests/test_misc.py      | 4 ++++
+ psutil/tests/test_process.py   | 5 +++++
+ psutil/tests/test_system.py    | 1 +
+ psutil/tests/test_unicode.py   | 4 +++-
+ 6 files changed, 20 insertions(+), 3 deletions(-)
+
+diff --git a/psutil/tests/test_contracts.py b/psutil/tests/test_contracts.py
+index 7401cc1..bf0fca0 100755
+--- a/psutil/tests/test_contracts.py
++++ b/psutil/tests/test_contracts.py
+@@ -172,6 +172,7 @@ class TestAvailProcessAPIs(PsutilTestCase):
+     def test_rlimit(self):
+         self.assertEqual(hasattr(psutil.Process, "rlimit"), LINUX or FREEBSD)
+ 
++    @unittest.skip("broken on OE since kernel config maye not be enabled")
+     def test_io_counters(self):
+         hasit = hasattr(psutil.Process, "io_counters")
+         self.assertEqual(hasit, False if MACOS or SUNOS else True)
+diff --git a/psutil/tests/test_linux.py b/psutil/tests/test_linux.py
+index 20e28d2..66b6dda 100755
+--- a/psutil/tests/test_linux.py
++++ b/psutil/tests/test_linux.py
+@@ -196,8 +196,9 @@ def get_free_version_info():
+     out = sh(["free", "-V"]).strip()
+     if 'UNKNOWN' in out:
+         raise unittest.SkipTest("can't determine free version")
+-    return tuple(map(int, out.split()[-1].split('.')))
+-
++    vlist = out.split()[-1].split('.')
++    vlist[:] = [n.split('-')[0] for n in vlist]
++    return tuple(map(int, vlist))
+ 
+ @contextlib.contextmanager
+ def mock_open_content(for_path, content):
+@@ -1289,6 +1290,7 @@ class TestRootFsDeviceFinder(PsutilTestCase):
+         finder.ask_sys_class_block()
+ 
+     @unittest.skipIf(GITHUB_ACTIONS, "unsupported on GITHUB_ACTIONS")
++    @unittest.skip("Broken for oe")
+     def test_comparisons(self):
+         finder = RootFsDeviceFinder()
+         self.assertIsNotNone(finder.find())
+@@ -1311,11 +1313,13 @@ class TestRootFsDeviceFinder(PsutilTestCase):
+ 
+     @unittest.skipIf(not which("findmnt"), "findmnt utility not available")
+     @unittest.skipIf(GITHUB_ACTIONS, "unsupported on GITHUB_ACTIONS")
++    @unittest.skip("Broken for oe")
+     def test_against_findmnt(self):
+         psutil_value = RootFsDeviceFinder().find()
+         findmnt_value = sh("findmnt -o SOURCE -rn /")
+         self.assertEqual(psutil_value, findmnt_value)
+ 
++    @unittest.skip("Broken for oe")
+     def test_disk_partitions_mocked(self):
+         with mock.patch(
+                 'psutil._pslinux.cext.disk_partitions',
+diff --git a/psutil/tests/test_misc.py b/psutil/tests/test_misc.py
+index d946eb6..121004a 100755
+--- a/psutil/tests/test_misc.py
++++ b/psutil/tests/test_misc.py
+@@ -54,6 +54,8 @@ from psutil.tests import unittest
+ # ===================================================================
+ 
+ 
++PSUTIL_DEBUG = bool(os.getenv('PSUTIL_DEBUG', 0))
++
+ class TestMisc(PsutilTestCase):
+ 
+     def test_process__repr__(self, func=repr):
+@@ -368,6 +370,7 @@ class TestMisc(PsutilTestCase):
+ 
+     # XXX: https://github.com/pypa/setuptools/pull/2896
+     @unittest.skipIf(APPVEYOR, "temporarily disabled due to setuptools bug")
++    @unittest.skip("OE run this test outof source tree")
+     def test_setup_script(self):
+         setup_py = os.path.join(ROOT_DIR, 'setup.py')
+         if CI_TESTING and not os.path.exists(setup_py):
+@@ -401,6 +404,7 @@ class TestMisc(PsutilTestCase):
+                 reload_module(psutil)
+             self.assertIn("version conflict", str(cm.exception).lower())
+ 
++    @unittest.skipIf(not PSUTIL_DEBUG, "env PSUTIL_DEBUG not set")
+     def test_debug(self):
+         if PY3:
+             from io import StringIO
+diff --git a/psutil/tests/test_process.py b/psutil/tests/test_process.py
+index c9059e3..a34ba3d 100755
+--- a/psutil/tests/test_process.py
++++ b/psutil/tests/test_process.py
+@@ -36,6 +36,7 @@ from psutil._compat import PY3
+ from psutil._compat import FileNotFoundError
+ from psutil._compat import long
+ from psutil._compat import super
++from psutil._compat import which
+ from psutil.tests import APPVEYOR
+ from psutil.tests import CI_TESTING
+ from psutil.tests import GITHUB_ACTIONS
+@@ -726,6 +727,7 @@ class TestProcess(PsutilTestCase):
+             self.assertEqual(' '.join(p.cmdline()), ' '.join(cmdline))
+ 
+     @unittest.skipIf(PYPY, "broken on PYPY")
++    @unittest.skipIf(not which("gcc"), "gcc not installed")
+     def test_long_cmdline(self):
+         testfn = self.get_testfn()
+         create_exe(testfn)
+@@ -740,6 +742,7 @@ class TestProcess(PsutilTestCase):
+         assert pyexe.startswith(name), (pyexe, name)
+ 
+     @unittest.skipIf(PYPY, "unreliable on PYPY")
++    @unittest.skipIf(not which("gcc"), "gcc not installed")
+     def test_long_name(self):
+         testfn = self.get_testfn(suffix="0123456789" * 2)
+         create_exe(testfn)
+@@ -750,6 +753,7 @@ class TestProcess(PsutilTestCase):
+     @unittest.skipIf(SUNOS, "broken on SUNOS")
+     @unittest.skipIf(AIX, "broken on AIX")
+     @unittest.skipIf(PYPY, "broken on PYPY")
++    @unittest.skipIf(not which("gcc"), "gcc not installed")
+     def test_prog_w_funky_name(self):
+         # Test that name(), exe() and cmdline() correctly handle programs
+         # with funky chars such as spaces and ")", see:
+@@ -1408,6 +1412,7 @@ class TestProcess(PsutilTestCase):
+ 
+     @unittest.skipIf(not HAS_ENVIRON, "not supported")
+     @unittest.skipIf(not POSIX, "POSIX only")
++    @unittest.skipIf(not which("gcc"), "gcc not installed")
+     def test_weird_environ(self):
+         # environment variables can contain values without an equals sign
+         code = textwrap.dedent("""
+diff --git a/psutil/tests/test_system.py b/psutil/tests/test_system.py
+index db2cb34..5ee519f 100755
+--- a/psutil/tests/test_system.py
++++ b/psutil/tests/test_system.py
+@@ -580,6 +580,7 @@ class TestDiskAPIs(PsutilTestCase):
+     def test_disk_usage_bytes(self):
+         psutil.disk_usage(b'.')
+ 
++    @unittest.skip("Broken for oe")
+     def test_disk_partitions(self):
+         def check_ntuple(nt):
+             self.assertIsInstance(nt.device, str)
+diff --git a/psutil/tests/test_unicode.py b/psutil/tests/test_unicode.py
+index e635726..7ba5b0f 100755
+--- a/psutil/tests/test_unicode.py
++++ b/psutil/tests/test_unicode.py
+@@ -86,6 +86,7 @@ from psutil import POSIX
+ from psutil import WINDOWS
+ from psutil._compat import PY3
+ from psutil._compat import u
++from psutil._compat import which
+ from psutil.tests import APPVEYOR
+ from psutil.tests import ASCII_FS
+ from psutil.tests import CI_TESTING
+@@ -156,7 +157,7 @@ def try_unicode(suffix):
+ # FS APIs
+ # ===================================================================
+ 
+-
++@unittest.skipIf(not which("gcc"), "gcc not installed")
+ class BaseUnicodeTest(PsutilTestCase):
+     funky_suffix = None
+ 
+@@ -169,6 +170,7 @@ class BaseUnicodeTest(PsutilTestCase):
+ @serialrun
+ @unittest.skipIf(ASCII_FS, "ASCII fs")
+ @unittest.skipIf(PYPY and not PY3, "too much trouble on PYPY2")
++@unittest.skipIf(not which("gcc"), "gcc not installed")
+ class TestFSAPIs(BaseUnicodeTest):
+     """Test FS APIs with a funky, valid, UTF8 path name."""
+ 
+-- 
+2.25.1
+
diff --git a/meta/recipes-devtools/python/python3-psutil_5.9.0.bb b/meta/recipes-devtools/python/python3-psutil_5.9.0.bb
new file mode 100644
index 00000000000..3df0e5d003e
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-psutil_5.9.0.bb
@@ -0,0 +1,28 @@
+SUMMARY = "A cross-platform process and system utilities module for Python"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=e35fd9f271d19d5f742f20a9d1f8bb8b"
+
+SRC_URI[sha256sum] = "869842dbd66bb80c3217158e629d6fceaecc3a3166d3d1faee515b05dd26ca25"
+
+inherit pypi setuptools3
+
+SRC_URI += "file://0001-fix-failure-test-cases.patch"
+
+PACKAGES =+ "${PN}-tests"
+
+FILES:${PN}-tests += " \
+    ${PYTHON_SITEPACKAGES_DIR}/psutil/test* \
+    ${PYTHON_SITEPACKAGES_DIR}/psutil/__pycache__/test* \
+"
+
+
+RDEPENDS:${PN} += " \
+    ${PYTHON_PN}-shell \
+    ${PYTHON_PN}-threading \
+    ${PYTHON_PN}-xml \
+    ${PYTHON_PN}-netclient \
+    ${PYTHON_PN}-ctypes \
+    ${PYTHON_PN}-resource \
+"
+
+BBCLASSEXTEND = "native nativesdk"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 14/33] poetry_core.bbclass: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (11 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 13/33] python3-psutil: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 15/33] python3-poetry-core: " Richard Purdie
                   ` (18 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

poetry.core.masonry.api is one of the common PEP-517 build backends.

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 meta/classes/poetry_core.bbclass | 15 +++++++++++++++
 1 file changed, 15 insertions(+)
 create mode 100644 meta/classes/poetry_core.bbclass

diff --git a/meta/classes/poetry_core.bbclass b/meta/classes/poetry_core.bbclass
new file mode 100644
index 00000000000..fb37c78c782
--- /dev/null
+++ b/meta/classes/poetry_core.bbclass
@@ -0,0 +1,15 @@
+inherit pip_install_wheel python3native setuptools3-base
+
+DEPENDS += "python3-poetry-core-native"
+
+poetry_core_do_configure () {
+    :
+}
+
+# TODO: ideally this uses pypa/build
+poetry_core_do_compile () {
+    nativepython3 -c "from poetry.core.masonry import api; api.build_wheel('${PIP_INSTALL_DIST_PATH}')"
+}
+do_compile[cleandirs] += "${PIP_INSTALL_DIST_PATH}"
+
+EXPORT_FUNCTIONS do_configure do_compile
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 15/33] python3-poetry-core: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (12 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 14/33] poetry_core.bbclass: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 16/33] python3-poetry-core: remove obsolete PIP_INSTALL_PACKAGE Richard Purdie
                   ` (17 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

A PEP 517 build backend implementation developed for Poetry. This project
is intended to be a light weight, fully compliant, self-contained package
allowing PEP 517 compatible build frontends to build Poetry managed projects.

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python/python3-poetry-core_1.0.8.bb       | 46 +++++++++++++++++++
 1 file changed, 46 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb

diff --git a/meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb b/meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb
new file mode 100644
index 00000000000..99ec763c4d5
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb
@@ -0,0 +1,46 @@
+SUMMARY = "Poetry PEP 517 Build Backend"
+DESCRIPTION = "Poetry PEP 517 Build Backend"
+HOMEPAGE = "https://github.com/python-poetry/poetry-core"
+BUGTRACKER = "https://github.com/python-poetry/poetry-core"
+CHANGELOG = "https://github.com/python-poetry/poetry-core/blob/master/CHANGELOG.md"
+
+LICENSE = "Apache-2.0 & BSD-2-Clause & MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=104d5c3c653aeededf4076773aa4c236 \
+                    file://poetry/core/_vendor/attrs.LICENSE;md5=75bb9823a2778b5a2bd9b793fac93ea2 \
+                    file://poetry/core/_vendor/jsonschema/COPYING;md5=6554d3a51d7cb0b611891317f3c69057 \
+                    file://poetry/core/_vendor/jsonschema/LICENSE;md5=2ecb81765361195731a6f72a89e449fd \
+                    file://poetry/core/_vendor/lark-parser.LICENSE;md5=b37b83a9cf129d92ee65aaa71c01ce72 \
+                    file://poetry/core/_vendor/packaging/LICENSE;md5=7a6e56c9d54ecd731ab31c52de7942f0 \
+                    file://poetry/core/_vendor/packaging/LICENSE.APACHE;md5=29256199be2a609aac596980ffc11996 \
+                    file://poetry/core/_vendor/packaging/LICENSE.BSD;md5=f405810d173a1618433827928768bcd2 \
+                    file://poetry/core/_vendor/pyparsing.LICENSE;md5=fb46329938e6bc829b256e37d5c1e31a \
+                    file://poetry/core/_vendor/pyrsistent/LICENSE.mit;md5=1211a1ac6eac40020d0f99c39b4e4270 \
+                    file://poetry/core/_vendor/six.LICENSE;md5=6a574656da93d9ef05431b45907e35b6 \
+                    file://poetry/core/_vendor/tomlkit/LICENSE;md5=be329e5ef9c9fe86738c9afe6ef3c11c \
+                    "
+
+SRC_URI[sha256sum] = "951fc7c1f8d710a94cb49019ee3742125039fc659675912ea614ac2aa405b118"
+
+inherit poetry_core pypi
+
+PIP_INSTALL_PACKAGE = "poetry_core"
+
+RDEPENDS:${PN}:append:class-target = "\
+    python3-compression \
+    python3-core \
+    python3-crypt \
+    python3-io \
+    python3-json \
+    python3-logging \
+    python3-netclient \
+    python3-pathlib2 \
+    python3-pprint \
+    python3-shell \
+"
+
+RDEPENDS:${PN} += "\
+    python3-pip \
+    python3-six \
+"
+
+BBCLASSEXTEND = "native nativesdk"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 16/33] python3-poetry-core: remove obsolete PIP_INSTALL_PACKAGE
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (13 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 15/33] python3-poetry-core: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 17/33] python3-iso8601: move from meta-python Richard Purdie
                   ` (16 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Ross Burton

From: Ross Burton <ross.burton@arm.com>

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb | 2 --
 1 file changed, 2 deletions(-)

diff --git a/meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb b/meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb
index 99ec763c4d5..22d7076d01b 100644
--- a/meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb
+++ b/meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb
@@ -23,8 +23,6 @@ SRC_URI[sha256sum] = "951fc7c1f8d710a94cb49019ee3742125039fc659675912ea614ac2aa4
 
 inherit poetry_core pypi
 
-PIP_INSTALL_PACKAGE = "poetry_core"
-
 RDEPENDS:${PN}:append:class-target = "\
     python3-compression \
     python3-core \
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 17/33] python3-iso8601: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (14 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 16/33] python3-poetry-core: remove obsolete PIP_INSTALL_PACKAGE Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 18/33] python3-typing-extensions: " Richard Purdie
                   ` (15 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python/python3-iso8601_1.0.2.bb               | 15 +++++++++++++++
 1 file changed, 15 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-iso8601_1.0.2.bb

diff --git a/meta/recipes-devtools/python/python3-iso8601_1.0.2.bb b/meta/recipes-devtools/python/python3-iso8601_1.0.2.bb
new file mode 100644
index 00000000000..aabc47d69b9
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-iso8601_1.0.2.bb
@@ -0,0 +1,15 @@
+SUMMARY = "Simple module to parse ISO 8601 dates"
+HOMEPAGE = "http://pyiso8601.readthedocs.org/"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=b05625f2336fa024e8d57e65c6595844"
+
+SRC_URI[sha256sum] = "27f503220e6845d9db954fb212b95b0362d8b7e6c1b2326a87061c3de93594b1"
+
+inherit pypi poetry_core
+
+RDEPENDS:${PN} += "\
+    ${PYTHON_PN}-datetime \
+    ${PYTHON_PN}-numbers \
+"
+
+BBCLASSEXTEND = "native nativesdk"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 18/33] python3-typing-extensions: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (15 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 17/33] python3-iso8601: move from meta-python Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 19/33] python3-semantic-version: " Richard Purdie
                   ` (14 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python/python3-typing-extensions_3.10.0.0.bb     | 12 ++++++++++++
 1 file changed, 12 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-typing-extensions_3.10.0.0.bb

diff --git a/meta/recipes-devtools/python/python3-typing-extensions_3.10.0.0.bb b/meta/recipes-devtools/python/python3-typing-extensions_3.10.0.0.bb
new file mode 100644
index 00000000000..a5f491c7700
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-typing-extensions_3.10.0.0.bb
@@ -0,0 +1,12 @@
+HOMEPAGE = "https://github.com/python/typing"
+LICENSE = "PSF-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=64fc2b30b67d0a8423c250e0386ed72f"
+
+# The name on PyPi is slightly different.
+PYPI_PACKAGE = "typing_extensions"
+
+SRC_URI[sha256sum] = "50b6f157849174217d0656f99dc82fe932884fb250826c18350e159ec6cdf342"
+
+inherit pypi setuptools3
+
+BBCLASSEXTEND = "native nativesdk"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 19/33] python3-semantic-version: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (16 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 18/33] python3-typing-extensions: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 20/33] python3-pycparser: " Richard Purdie
                   ` (13 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python/python3-semantic-version_2.9.0.bb         | 12 ++++++++++++
 1 file changed, 12 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-semantic-version_2.9.0.bb

diff --git a/meta/recipes-devtools/python/python3-semantic-version_2.9.0.bb b/meta/recipes-devtools/python/python3-semantic-version_2.9.0.bb
new file mode 100644
index 00000000000..ee635871bf5
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-semantic-version_2.9.0.bb
@@ -0,0 +1,12 @@
+SUMMARY  = "A library implementing the 'SemVer' scheme."
+DESCRIPTION = "Semantic version comparison for Python (see http://semver.org/)"
+HOMEPAGE = "https://github.com/rbarrois/python-semanticversion"
+LICENSE = "BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=4fb31e3c1c7eeb8b5e8c07657cdd54e2"
+
+SRC_URI[sha256sum] = "abf54873553e5e07a6fd4d5f653b781f5ae41297a493666b59dcf214006a12b2"
+
+PYPI_PACKAGE = "semantic_version"
+inherit pypi setuptools3
+
+BBCLASSEXTEND = "native nativesdk"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 20/33] python3-pycparser: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (17 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 19/33] python3-semantic-version: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 21/33] python3-ply: " Richard Purdie
                   ` (12 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python/python3-pycparser_2.21.bb          | 21 +++++++++++++++++++
 1 file changed, 21 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-pycparser_2.21.bb

diff --git a/meta/recipes-devtools/python/python3-pycparser_2.21.bb b/meta/recipes-devtools/python/python3-pycparser_2.21.bb
new file mode 100644
index 00000000000..53b7367903e
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-pycparser_2.21.bb
@@ -0,0 +1,21 @@
+SUMMARY = "Parser of the C language, written in pure Python"
+HOMEPAGE = "https://github.com/eliben/pycparser"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=2c28cdeabcb88f5843d934381b4b4fea"
+
+SRC_URI[sha256sum] = "e644fdec12f7872f86c58ff790da456218b10f863970249516d60a5eaca77206"
+
+inherit pypi setuptools3
+
+BBCLASSEXTEND = "native nativesdk"
+
+RDEPENDS:${PN}:class-target += "\
+    ${PYTHON_PN}-netclient \
+    ${PYTHON_PN}-ply \
+    ${PYTHON_PN}-pprint \
+    "
+
+RSUGGESTS:${PN}:class-target += "\
+    cpp \
+    cpp-symlinks \
+    "
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 21/33] python3-ply: move from meta-python
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (18 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 20/33] python3-pycparser: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 22/33] maintainers.inc: add python3-crypto and friends Richard Purdie
                   ` (11 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Dependency for python3-cryptography

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 .../python/python3-ply_3.11.bb                 | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-ply_3.11.bb

diff --git a/meta/recipes-devtools/python/python3-ply_3.11.bb b/meta/recipes-devtools/python/python3-ply_3.11.bb
new file mode 100644
index 00000000000..99c037bb734
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-ply_3.11.bb
@@ -0,0 +1,18 @@
+SUMMARY = "Python Lex and Yacc"
+DESCRIPTION = "Python ply: PLY is yet another implementation of lex and yacc for Python"
+HOMEPAGE = "https://pypi.python.org/pypi/ply"
+SECTION = "devel/python"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = "file://README.md;beginline=5;endline=32;md5=f5ee5c355c0e6719c787a71b8f0fa96c"
+
+SRC_URI[md5sum] = "6465f602e656455affcd7c5734c638f8"
+SRC_URI[sha256sum] = "00c7c1aaa88358b9c765b6d3000c6eec0ba42abca5351b095321aef446081da3"
+
+inherit pypi setuptools3
+
+RDEPENDS:${PN}:class-target += "\
+    ${PYTHON_PN}-netclient \
+    ${PYTHON_PN}-shell \
+"
+
+BBCLASSEXTEND = "native"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 22/33] maintainers.inc: add python3-crypto and friends
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (19 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 21/33] python3-ply: " Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 23/33] py3o: Rename to python_py3o Richard Purdie
                   ` (10 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 meta/conf/distro/include/maintainers.inc | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc
index 3fceb6701bb..f149db81cde 100644
--- a/meta/conf/distro/include/maintainers.inc
+++ b/meta/conf/distro/include/maintainers.inc
@@ -587,8 +587,13 @@ RECIPE_MAINTAINER:pn-pulseaudio-client-conf-sato = "Unassigned <unassigned@yocto
 RECIPE_MAINTAINER:pn-puzzles = "Anuj Mittal <anuj.mittal@intel.com>"
 RECIPE_MAINTAINER:pn-python3 = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
 RECIPE_MAINTAINER:pn-python3-async = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
+RECIPE_MAINTAINER:pn-python3-asn1crypto = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-atomicwrites = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-attrs = "Tim Orling <tim.orling@konsulko.com>"
+RECIPE_MAINTAINER:pn-python3-bcrypt = "Tim Orling <tim.orling@konsulko.com>"
+RECIPE_MAINTAINER:pn-python3-cffi = "Tim Orling <tim.orling@konsulko.com>"
+RECIPE_MAINTAINER:pn-python3-cryptography = "Tim Orling <tim.orling@konsulko.com>"
+RECIPE_MAINTAINER:pn-python3-cryptography-vectors = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-cython = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
 RECIPE_MAINTAINER:pn-python3-dbus = "Zang Ruochen <zangrc.fnst@fujitsu.com>"
 RECIPE_MAINTAINER:pn-python3-dbusmock = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
@@ -607,6 +612,7 @@ RECIPE_MAINTAINER:pn-python3-idna = "Bruce Ashfield <bruce.ashfield@gmail.com>"
 RECIPE_MAINTAINER:pn-python3-importlib-metadata = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-iniconfig = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-iniparse = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
+RECIPE_MAINTAINER:pn-python3-iso8601 = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-jinja2 = "Richard Purdie <richard.purdie@linuxfoundation.org>"
 RECIPE_MAINTAINER:pn-python3-jsonpointer = "Bruce Ashfield <bruce.ashfield@gmail.com>"
 RECIPE_MAINTAINER:pn-python3-jsonschema = "Bruce Ashfield <bruce.ashfield@gmail.com>"
@@ -622,20 +628,29 @@ RECIPE_MAINTAINER:pn-python3-pathlib2 = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-pbr = "Zang Ruochen <zangrc.fnst@fujitsu.com>"
 RECIPE_MAINTAINER:pn-python3-pip = "Zang Ruochen <zangrc.fnst@fujitsu.com>"
 RECIPE_MAINTAINER:pn-python3-pluggy = "Tim Orling <tim.orling@konsulko.com>"
+RECIPE_MAINTAINER:pn-python3-ply = "Tim Orling <tim.orling@konsulko.com>"
+RECIPE_MAINTAINER:pn-python3-poetry-core = "Tim Orling <tim.orling@konsulko.com>"
+RECIPE_MAINTAINER:pn-python3-pretend = "Tim Orling <tim.orling@konsulko.com>"
+RECIPE_MAINTAINER:pn-python3-psutil = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-py = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-pyyaml = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-pycairo = "Zang Ruochen <zangrc.fnst@fujitsu.com>"
+RECIPE_MAINTAINER:pn-python3-pycparser = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-pyelftools = "Joshua Watt <JPEWhacker@gmail.com>"
 RECIPE_MAINTAINER:pn-python3-pygments = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
 RECIPE_MAINTAINER:pn-python3-pygobject = "Zang Ruochen <zangrc.fnst@fujitsu.com>"
 RECIPE_MAINTAINER:pn-python3-pyparsing = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
 RECIPE_MAINTAINER:pn-python3-pytest = "Tim Orling <tim.orling@konsulko.com>"
+RECIPE_MAINTAINER:pn-python3-pytest-subtests = "Tim Orling <tim.orling@konsulko.com>"
+RECIPE_MAINTAINER:pn-python3-pytz = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-rfc3339-validator = "Bruce Ashfield <bruce.ashfield@gmail.com>"
 RECIPE_MAINTAINER:pn-python3-rfc3986-validator = "Bruce Ashfield <bruce.ashfield@gmail.com>"
 RECIPE_MAINTAINER:pn-python3-rfc3987 = "Bruce Ashfield <bruce.ashfield@gmail.com>"
 RECIPE_MAINTAINER:pn-python3-ruamel-yaml = "Bruce Ashfield <bruce.ashfield@gmail.com>"
 RECIPE_MAINTAINER:pn-python3-scons = "Tim Orling <tim.orling@konsulko.com>"
+RECIPE_MAINTAINER:pn-python3-semantic-version = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-setuptools = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
+RECIPE_MAINTAINER:pn-python3-setuptools-rust-native = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-setuptools-scm = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-six = "Zang Ruochen <zangrc.fnst@fujitsu.com>"
 RECIPE_MAINTAINER:pn-python3-smartypants = "Alexander Kanavin <alex.kanavin@gmail.com>"
@@ -646,6 +661,7 @@ RECIPE_MAINTAINER:pn-python3-subunit = "Oleksandr Kravchuk <open.source@oleksand
 RECIPE_MAINTAINER:pn-python3-testtools = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
 RECIPE_MAINTAINER:pn-python3-toml = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-tomli = "Tim Orling <tim.orling@konsulko.com>"
+RECIPE_MAINTAINER:pn-python3-typing-extensions = "Tim Orling <tim.orling@konsulko.com>"
 RECIPE_MAINTAINER:pn-python3-typogrify = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER:pn-python3-vcversioner = "Bruce Ashfield <bruce.ashfield@gmail.com>"
 RECIPE_MAINTAINER:pn-python3-wcwidth = "Tim Orling <tim.orling@konsulko.com>"
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 23/33] py3o: Rename to python_py3o
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (20 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 22/33] maintainers.inc: add python3-crypto and friends Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 24/33] setuptools3_rust: Rename to python_setuptools3_rust Richard Purdie
                   ` (9 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/classes/{pyo3.bbclass => python_pyo3.bbclass} | 2 +-
 meta/classes/setuptools3_rust.bbclass              | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
 rename meta/classes/{pyo3.bbclass => python_pyo3.bbclass} (96%)

diff --git a/meta/classes/pyo3.bbclass b/meta/classes/python_pyo3.bbclass
similarity index 96%
rename from meta/classes/pyo3.bbclass
rename to meta/classes/python_pyo3.bbclass
index 6ce21329c2e..10cc3a06457 100644
--- a/meta/classes/pyo3.bbclass
+++ b/meta/classes/python_pyo3.bbclass
@@ -13,7 +13,7 @@ export RUSTFLAGS
 export PYO3_PYTHON="${PYTHON}"
 export PYO3_CONFIG_FILE="${WORKDIR}/pyo3.config"
 
-pyo3_do_configure () {
+python_pyo3_do_configure () {
     cat > ${WORKDIR}/pyo3.config << EOF
 implementation=CPython
 version=${PYTHON_BASEVERSION}
diff --git a/meta/classes/setuptools3_rust.bbclass b/meta/classes/setuptools3_rust.bbclass
index fb11f08f89c..fa8508fbec6 100644
--- a/meta/classes/setuptools3_rust.bbclass
+++ b/meta/classes/setuptools3_rust.bbclass
@@ -1,4 +1,4 @@
-inherit pyo3 setuptools3
+inherit python_pyo3 setuptools3
 
 DEPENDS += "python3-setuptools-rust-native"
 
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 24/33] setuptools3_rust: Rename to python_setuptools3_rust
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (21 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 23/33] py3o: Rename to python_py3o Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 25/33] poetry_core: Rename to python_poetry_core Richard Purdie
                   ` (8 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 ...tuptools3_rust.bbclass => python_setuptools3_rust.bbclass} | 4 ++--
 meta/recipes-devtools/python/python3-cryptography_36.0.1.bb   | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
 rename meta/classes/{setuptools3_rust.bbclass => python_setuptools3_rust.bbclass} (70%)

diff --git a/meta/classes/setuptools3_rust.bbclass b/meta/classes/python_setuptools3_rust.bbclass
similarity index 70%
rename from meta/classes/setuptools3_rust.bbclass
rename to meta/classes/python_setuptools3_rust.bbclass
index fa8508fbec6..f12e5d0cbd2 100644
--- a/meta/classes/setuptools3_rust.bbclass
+++ b/meta/classes/python_setuptools3_rust.bbclass
@@ -2,8 +2,8 @@ inherit python_pyo3 setuptools3
 
 DEPENDS += "python3-setuptools-rust-native"
 
-setuptools3_rust_do_configure() {
-    pyo3_do_configure
+python_setuptools3_rust_do_configure() {
+    python_pyo3_do_configure
     cargo_common_do_configure
     setuptools3_do_configure
 }
diff --git a/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb b/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
index 00791dce2de..11466ecece6 100644
--- a/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
+++ b/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
@@ -18,7 +18,7 @@ SRC_URI += " \
     file://0002-Cargo.toml-edition-2018-2021.patch \
 "
 
-inherit pypi setuptools3_rust
+inherit pypi python_setuptools3_rust
 
 PIP_INSTALL_DIST_PATH = "${S}/dist"
 
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 25/33] poetry_core: Rename to python_poetry_core
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (22 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 24/33] setuptools3_rust: Rename to python_setuptools3_rust Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 26/33] poetry_core: update for renamed class pip_install_wheel to python_pep517 Richard Purdie
                   ` (7 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 .../{poetry_core.bbclass => python_poetry_core.bbclass}       | 4 ++--
 meta/recipes-devtools/python/python3-iso8601_1.0.2.bb         | 2 +-
 meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb     | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)
 rename meta/classes/{poetry_core.bbclass => python_poetry_core.bbclass} (82%)

diff --git a/meta/classes/poetry_core.bbclass b/meta/classes/python_poetry_core.bbclass
similarity index 82%
rename from meta/classes/poetry_core.bbclass
rename to meta/classes/python_poetry_core.bbclass
index fb37c78c782..a2086b11b6c 100644
--- a/meta/classes/poetry_core.bbclass
+++ b/meta/classes/python_poetry_core.bbclass
@@ -2,12 +2,12 @@ inherit pip_install_wheel python3native setuptools3-base
 
 DEPENDS += "python3-poetry-core-native"
 
-poetry_core_do_configure () {
+python_poetry_core_do_configure () {
     :
 }
 
 # TODO: ideally this uses pypa/build
-poetry_core_do_compile () {
+python_poetry_core_do_compile () {
     nativepython3 -c "from poetry.core.masonry import api; api.build_wheel('${PIP_INSTALL_DIST_PATH}')"
 }
 do_compile[cleandirs] += "${PIP_INSTALL_DIST_PATH}"
diff --git a/meta/recipes-devtools/python/python3-iso8601_1.0.2.bb b/meta/recipes-devtools/python/python3-iso8601_1.0.2.bb
index aabc47d69b9..93af233d296 100644
--- a/meta/recipes-devtools/python/python3-iso8601_1.0.2.bb
+++ b/meta/recipes-devtools/python/python3-iso8601_1.0.2.bb
@@ -5,7 +5,7 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=b05625f2336fa024e8d57e65c6595844"
 
 SRC_URI[sha256sum] = "27f503220e6845d9db954fb212b95b0362d8b7e6c1b2326a87061c3de93594b1"
 
-inherit pypi poetry_core
+inherit pypi python_poetry_core
 
 RDEPENDS:${PN} += "\
     ${PYTHON_PN}-datetime \
diff --git a/meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb b/meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb
index 22d7076d01b..f3e9b055218 100644
--- a/meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb
+++ b/meta/recipes-devtools/python/python3-poetry-core_1.0.8.bb
@@ -21,7 +21,7 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=104d5c3c653aeededf4076773aa4c236 \
 
 SRC_URI[sha256sum] = "951fc7c1f8d710a94cb49019ee3742125039fc659675912ea614ac2aa405b118"
 
-inherit poetry_core pypi
+inherit python_poetry_core pypi
 
 RDEPENDS:${PN}:append:class-target = "\
     python3-compression \
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 26/33] poetry_core: update for renamed class pip_install_wheel to python_pep517
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (23 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 25/33] poetry_core: Rename to python_poetry_core Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 27/33] ptest-packagelists.inc: add python3-cryptography Richard Purdie
                   ` (6 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Ross Burton, Ross Burton

From: Ross Burton <ross@burtonini.com>

Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/classes/python_poetry_core.bbclass | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/meta/classes/python_poetry_core.bbclass b/meta/classes/python_poetry_core.bbclass
index a2086b11b6c..47b2fe46d5f 100644
--- a/meta/classes/python_poetry_core.bbclass
+++ b/meta/classes/python_poetry_core.bbclass
@@ -1,4 +1,4 @@
-inherit pip_install_wheel python3native setuptools3-base
+inherit python_pep517 python3native setuptools3-base
 
 DEPENDS += "python3-poetry-core-native"
 
@@ -8,8 +8,8 @@ python_poetry_core_do_configure () {
 
 # TODO: ideally this uses pypa/build
 python_poetry_core_do_compile () {
-    nativepython3 -c "from poetry.core.masonry import api; api.build_wheel('${PIP_INSTALL_DIST_PATH}')"
+    nativepython3 -c "from poetry.core.masonry import api; api.build_wheel('${PEP517_WHEEL_PATH}')"
 }
-do_compile[cleandirs] += "${PIP_INSTALL_DIST_PATH}"
+do_compile[cleandirs] += "${PEP517_WHEEL_PATH}"
 
 EXPORT_FUNCTIONS do_configure do_compile
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 27/33] ptest-packagelists.inc: add python3-cryptography
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (24 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 26/33] poetry_core: update for renamed class pip_install_wheel to python_pep517 Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 28/33] ptest-packagelists: add python3-bcrypt and -pytz Richard Purdie
                   ` (5 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling

From: Tim Orling <tim.orling@konsulko.com>

The python3-cryptography recipe has a lot of tests and uses a large
amount of memory. It is slow (> 30 seconds).

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
---
 meta/conf/distro/include/ptest-packagelists.inc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/conf/distro/include/ptest-packagelists.inc b/meta/conf/distro/include/ptest-packagelists.inc
index c503a6a5949..af8a57bec4f 100644
--- a/meta/conf/distro/include/ptest-packagelists.inc
+++ b/meta/conf/distro/include/ptest-packagelists.inc
@@ -86,6 +86,7 @@ PTESTS_SLOW = "\
     openssh-ptest \
     openssl-ptest \
     perl-ptest \
+    python3-cryptography-ptest \
     python3-ptest \
     strace-ptest \
     tcl-ptest \
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 28/33] ptest-packagelists: add python3-bcrypt and -pytz
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (25 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 27/33] ptest-packagelists.inc: add python3-cryptography Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 29/33] python3-cryptography: mark test_create_certificate_with_extensions as expected to fail Richard Purdie
                   ` (4 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Tim Orling, Tim Orling

From: Tim Orling <ticotimo@gmail.com>

python3-bcrypt and python3-pytz both run in just a few seconds, so add
them to the fast list.

Signed-off-by: Tim Orling <tim.orling@konsulko.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/conf/distro/include/ptest-packagelists.inc | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/meta/conf/distro/include/ptest-packagelists.inc b/meta/conf/distro/include/ptest-packagelists.inc
index af8a57bec4f..715a8f6f70b 100644
--- a/meta/conf/distro/include/ptest-packagelists.inc
+++ b/meta/conf/distro/include/ptest-packagelists.inc
@@ -49,12 +49,14 @@ PTESTS_FAST = "\
     pango-ptest \
     parted-ptest \
     python3-atomicwrites-ptest \
+    python3-bcrypt-ptest \
     python3-hypothesis-ptest \
     python3-jinja2-ptest \
     python3-jsonpointer-ptest \
     python3-markupsafe-ptest \
     python3-more-itertools-ptest \
     python3-pluggy-ptest \
+    python3-pytz-ptest \
     python3-wcwidth-ptest \
     python3-webcolors-ptest \
     qemu-ptest \
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 29/33] python3-cryptography: mark test_create_certificate_with_extensions as expected to fail
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (26 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 28/33] ptest-packagelists: add python3-bcrypt and -pytz Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 30/33] python3-psutil/python3-bcrypt: Add missing HOMEPAGE Richard Purdie
                   ` (3 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Ross Burton

From: Ross Burton <ross.burton@arm.com>

This test causes OpenSSL to leak some memory. Until this is resolved in
OpenSSL, mark the test as expected-to-fail.

Signed-off-by: Ross Burton <ross.burton@arm.com>
---
 .../skip-leaky-test.patch                     | 19 +++++++++++++++++++
 .../python/python3-cryptography_36.0.1.bb     |  1 +
 2 files changed, 20 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3-cryptography/skip-leaky-test.patch

diff --git a/meta/recipes-devtools/python/python3-cryptography/skip-leaky-test.patch b/meta/recipes-devtools/python/python3-cryptography/skip-leaky-test.patch
new file mode 100644
index 00000000000..64248d57bd9
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-cryptography/skip-leaky-test.patch
@@ -0,0 +1,19 @@
+Mark as test as expected-failure, OpenSSL is leaking memory.
+
+xfail not skip so we can remove this when OpenSSL doesn't leak anymore.
+
+Upstream-Status: Inappropriate
+Signed-off-by: Ross Burton <ross.burton@arm.com>
+
+diff --git a/tests/hazmat/backends/test_openssl_memleak.py b/tests/hazmat/backends/test_openssl_memleak.py
+index 835c9256..639f6ba2 100644
+--- a/tests/hazmat/backends/test_openssl_memleak.py
++++ b/tests/hazmat/backends/test_openssl_memleak.py
+@@ -466,6 +466,7 @@ class TestOpenSSLMemoryLeaks:
+             )
+         )
+ 
++    @pytest.mark.xfail(reason="has memory leaks")
+     def test_create_certificate_with_extensions(self):
+         assert_no_memory_leaks(
+             textwrap.dedent(
diff --git a/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb b/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
index 11466ecece6..69eeeb1e968 100644
--- a/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
+++ b/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
@@ -16,6 +16,7 @@ SRC_URI += " \
     file://check-memfree.py \
     file://0001-Cargo.toml-specify-pem-version.patch \
     file://0002-Cargo.toml-edition-2018-2021.patch \
+    file://skip-leaky-test.patch \
 "
 
 inherit pypi python_setuptools3_rust
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 30/33] python3-psutil/python3-bcrypt: Add missing HOMEPAGE
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (27 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 29/33] python3-cryptography: mark test_create_certificate_with_extensions as expected to fail Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 31/33] python3-cryptography: Add missing ptest tomli dependency Richard Purdie
                   ` (2 subsequent siblings)
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core

Add missing HOMEPAGE entries to the two recipes imported from meta-oe to fix
selftest failures.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/recipes-devtools/python/python3-bcrypt_3.2.0.bb | 1 +
 meta/recipes-devtools/python/python3-psutil_5.9.0.bb | 1 +
 2 files changed, 2 insertions(+)

diff --git a/meta/recipes-devtools/python/python3-bcrypt_3.2.0.bb b/meta/recipes-devtools/python/python3-bcrypt_3.2.0.bb
index 92a6a0d8c5f..731aff299ba 100644
--- a/meta/recipes-devtools/python/python3-bcrypt_3.2.0.bb
+++ b/meta/recipes-devtools/python/python3-bcrypt_3.2.0.bb
@@ -1,6 +1,7 @@
 DESCRIPTION = "Modern password hashing for your software and your servers."
 LICENSE = "Apache-2.0"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=8f7bb094c7232b058c7e9f2e431f389c"
+HOMEPAGE = "https://pypi.org/project/bcrypt/"
 
 DEPENDS += "${PYTHON_PN}-cffi-native"
 
diff --git a/meta/recipes-devtools/python/python3-psutil_5.9.0.bb b/meta/recipes-devtools/python/python3-psutil_5.9.0.bb
index 3df0e5d003e..df304f01e69 100644
--- a/meta/recipes-devtools/python/python3-psutil_5.9.0.bb
+++ b/meta/recipes-devtools/python/python3-psutil_5.9.0.bb
@@ -1,6 +1,7 @@
 SUMMARY = "A cross-platform process and system utilities module for Python"
 LICENSE = "BSD-3-Clause"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=e35fd9f271d19d5f742f20a9d1f8bb8b"
+HOMEPAGE = "https://pypi.org/project/psutil/"
 
 SRC_URI[sha256sum] = "869842dbd66bb80c3217158e629d6fceaecc3a3166d3d1faee515b05dd26ca25"
 
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 31/33] python3-cryptography: Add missing ptest tomli dependency
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (28 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 30/33] python3-psutil/python3-bcrypt: Add missing HOMEPAGE Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 32/33] python3-cryptography: remove obsolete PIP_INSTALL_DIST_PATH Richard Purdie
  2022-03-14 22:48 ` [PATCH 33/33] python3-cryptography-vectors: Fix reproducibility Richard Purdie
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core

Add missing tomli runtime dependency to allow ptests to execute.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/recipes-devtools/python/python3-cryptography_36.0.1.bb | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb b/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
index 69eeeb1e968..09f940272a4 100644
--- a/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
+++ b/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
@@ -101,6 +101,7 @@ RDEPENDS:${PN}-ptest += " \
     ${PYTHON_PN}-pytest \
     ${PYTHON_PN}-pytest-subtests \
     ${PYTHON_PN}-pytz \
+    ${PYTHON_PN}-tomli \
 "
 
 inherit ptest
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 32/33] python3-cryptography: remove obsolete PIP_INSTALL_DIST_PATH
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (29 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 31/33] python3-cryptography: Add missing ptest tomli dependency Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  2022-03-14 22:48 ` [PATCH 33/33] python3-cryptography-vectors: Fix reproducibility Richard Purdie
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core; +Cc: Ross Burton

From: Ross Burton <ross.burton@arm.com>

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 meta/recipes-devtools/python/python3-cryptography_36.0.1.bb | 2 --
 1 file changed, 2 deletions(-)

diff --git a/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb b/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
index 09f940272a4..e33eaa50834 100644
--- a/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
+++ b/meta/recipes-devtools/python/python3-cryptography_36.0.1.bb
@@ -21,8 +21,6 @@ SRC_URI += " \
 
 inherit pypi python_setuptools3_rust
 
-PIP_INSTALL_DIST_PATH = "${S}/dist"
-
 DEPENDS += " \
     ${PYTHON_PN}-asn1crypto-native \
     ${PYTHON_PN}-cffi-native \
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

* [PATCH 33/33] python3-cryptography-vectors: Fix reproducibility
  2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
                   ` (30 preceding siblings ...)
  2022-03-14 22:48 ` [PATCH 32/33] python3-cryptography: remove obsolete PIP_INSTALL_DIST_PATH Richard Purdie
@ 2022-03-14 22:48 ` Richard Purdie
  31 siblings, 0 replies; 33+ messages in thread
From: Richard Purdie @ 2022-03-14 22:48 UTC (permalink / raw)
  To: openembedded-core

We regenerate the pycache files and the checksums in the manifest are incorrect.
Remove them to avoid this and ensure reproducibility.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
 .../python/python3-cryptography-vectors_36.0.1.bb            | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/meta/recipes-devtools/python/python3-cryptography-vectors_36.0.1.bb b/meta/recipes-devtools/python/python3-cryptography-vectors_36.0.1.bb
index b9e6b811c37..da6718fb90c 100644
--- a/meta/recipes-devtools/python/python3-cryptography-vectors_36.0.1.bb
+++ b/meta/recipes-devtools/python/python3-cryptography-vectors_36.0.1.bb
@@ -19,6 +19,11 @@ DEPENDS += " \
     ${PYTHON_PN}-cryptography \
 "
 
+do_install:append () {
+	# Remove the sha256 checksum lines for pycache files
+	sed ${D}${PYTHON_SITEPACKAGES_DIR}/cryptography_vectors-${PV}.dist-info/RECORD -e '/__pycache__/d' -i
+}
+
 BBCLASSEXTEND = "native nativesdk"
 
 UPSTREAM_CHECK_REGEX = ""
-- 
2.32.0



^ permalink raw reply related	[flat|nested] 33+ messages in thread

end of thread, other threads:[~2022-03-14 22:49 UTC | newest]

Thread overview: 33+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-14 22:48 [PATCH 01/33] python3-setuptools-rust-native: from meta-python Richard Purdie
2022-03-14 22:48 ` [PATCH 02/33] python3-setuptools-rust-native: remove obsolete PIP_* Richard Purdie
2022-03-14 22:48 ` [PATCH 03/33] pyo3.bbclass: move from meta-python Richard Purdie
2022-03-14 22:48 ` [PATCH 04/33] setuptools3_rust.bbclass: " Richard Purdie
2022-03-14 22:48 ` [PATCH 05/33] python3-cryptography: " Richard Purdie
2022-03-14 22:48 ` [PATCH 06/33] python3-pytest-subtests: " Richard Purdie
2022-03-14 22:48 ` [PATCH 07/33] python3-cryptography-vectors: " Richard Purdie
2022-03-14 22:48 ` [PATCH 08/33] python3-asn1crypto: move " Richard Purdie
2022-03-14 22:48 ` [PATCH 09/33] python3-cffi: " Richard Purdie
2022-03-14 22:48 ` [PATCH 10/33] python3-pytz: " Richard Purdie
2022-03-14 22:48 ` [PATCH 11/33] python3-bcrypt: " Richard Purdie
2022-03-14 22:48 ` [PATCH 12/33] python3-pretend: " Richard Purdie
2022-03-14 22:48 ` [PATCH 13/33] python3-psutil: " Richard Purdie
2022-03-14 22:48 ` [PATCH 14/33] poetry_core.bbclass: " Richard Purdie
2022-03-14 22:48 ` [PATCH 15/33] python3-poetry-core: " Richard Purdie
2022-03-14 22:48 ` [PATCH 16/33] python3-poetry-core: remove obsolete PIP_INSTALL_PACKAGE Richard Purdie
2022-03-14 22:48 ` [PATCH 17/33] python3-iso8601: move from meta-python Richard Purdie
2022-03-14 22:48 ` [PATCH 18/33] python3-typing-extensions: " Richard Purdie
2022-03-14 22:48 ` [PATCH 19/33] python3-semantic-version: " Richard Purdie
2022-03-14 22:48 ` [PATCH 20/33] python3-pycparser: " Richard Purdie
2022-03-14 22:48 ` [PATCH 21/33] python3-ply: " Richard Purdie
2022-03-14 22:48 ` [PATCH 22/33] maintainers.inc: add python3-crypto and friends Richard Purdie
2022-03-14 22:48 ` [PATCH 23/33] py3o: Rename to python_py3o Richard Purdie
2022-03-14 22:48 ` [PATCH 24/33] setuptools3_rust: Rename to python_setuptools3_rust Richard Purdie
2022-03-14 22:48 ` [PATCH 25/33] poetry_core: Rename to python_poetry_core Richard Purdie
2022-03-14 22:48 ` [PATCH 26/33] poetry_core: update for renamed class pip_install_wheel to python_pep517 Richard Purdie
2022-03-14 22:48 ` [PATCH 27/33] ptest-packagelists.inc: add python3-cryptography Richard Purdie
2022-03-14 22:48 ` [PATCH 28/33] ptest-packagelists: add python3-bcrypt and -pytz Richard Purdie
2022-03-14 22:48 ` [PATCH 29/33] python3-cryptography: mark test_create_certificate_with_extensions as expected to fail Richard Purdie
2022-03-14 22:48 ` [PATCH 30/33] python3-psutil/python3-bcrypt: Add missing HOMEPAGE Richard Purdie
2022-03-14 22:48 ` [PATCH 31/33] python3-cryptography: Add missing ptest tomli dependency Richard Purdie
2022-03-14 22:48 ` [PATCH 32/33] python3-cryptography: remove obsolete PIP_INSTALL_DIST_PATH Richard Purdie
2022-03-14 22:48 ` [PATCH 33/33] python3-cryptography-vectors: Fix reproducibility Richard Purdie

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.