From 706d5aacd7ab7b37c00df1a1b210e4ced06119e1 Mon Sep 17 00:00:00 2001 From: Andrew Geissler Date: Fri, 12 Feb 2021 15:55:30 -0600 Subject: Reset poky to before our libpam hacks Things got a bit out of synch with openbmc-config due to the libpam issues and the migration from the meta-* layers. Revert the two previous commits and then put the latest poky in with the libpam revert and get openbmc-config right again. Revert "Revert "libpam: update 1.3.1 -> 1.5.1"" This reverts commit 87ddd3eab4df68e624b5350ccaab28b3b97547c0. Revert "poky: subtree update:796be0593a..10c69538c0" This reverts commit c723b72979bfac6362509cf1fe086900f6641f28. Change-Id: I3a1f405193aee6a21fe0cd24be9927c143a23d9a Signed-off-by: Andrew Geissler --- .../python/python3-hypothesis_5.41.4.bb | 14 + .../python/python3-hypothesis_5.43.3.bb | 14 - .../python/python3-importlib-metadata_3.1.0.bb | 18 + .../python/python3-importlib-metadata_3.3.0.bb | 20 -- .../python/python3-packaging_20.4.bb | 14 + .../python/python3-packaging_20.8.bb | 13 - .../recipes-devtools/python/python3-py_1.10.0.bb | 14 - .../recipes-devtools/python/python3-py_1.9.0.bb | 15 + .../python/python3-pygments_2.7.2.bb | 19 ++ .../python/python3-pygments_2.7.3.bb | 19 -- ...ove-the-setup_requires-for-setuptools-scm.patch | 17 +- .../python/python3-pytest_6.1.2.bb | 39 +++ .../python/python3-pytest_6.2.1.bb | 39 --- .../python/python3-setuptools-scm_4.1.2.bb | 23 ++ .../python/python3-setuptools-scm_5.0.1.bb | 24 -- .../python/python3-setuptools_50.3.2.bb | 65 ++++ .../python/python3-setuptools_51.0.0.bb | 65 ---- .../python/python3/CVE-2020-27619.patch | 69 ++++ poky/meta/recipes-devtools/python/python3_3.9.0.bb | 376 +++++++++++++++++++++ poky/meta/recipes-devtools/python/python3_3.9.1.bb | 374 -------------------- 20 files changed, 662 insertions(+), 589 deletions(-) create mode 100644 poky/meta/recipes-devtools/python/python3-hypothesis_5.41.4.bb delete mode 100644 poky/meta/recipes-devtools/python/python3-hypothesis_5.43.3.bb create mode 100644 poky/meta/recipes-devtools/python/python3-importlib-metadata_3.1.0.bb delete mode 100644 poky/meta/recipes-devtools/python/python3-importlib-metadata_3.3.0.bb create mode 100644 poky/meta/recipes-devtools/python/python3-packaging_20.4.bb delete mode 100644 poky/meta/recipes-devtools/python/python3-packaging_20.8.bb delete mode 100644 poky/meta/recipes-devtools/python/python3-py_1.10.0.bb create mode 100644 poky/meta/recipes-devtools/python/python3-py_1.9.0.bb create mode 100644 poky/meta/recipes-devtools/python/python3-pygments_2.7.2.bb delete mode 100644 poky/meta/recipes-devtools/python/python3-pygments_2.7.3.bb create mode 100644 poky/meta/recipes-devtools/python/python3-pytest_6.1.2.bb delete mode 100644 poky/meta/recipes-devtools/python/python3-pytest_6.2.1.bb create mode 100644 poky/meta/recipes-devtools/python/python3-setuptools-scm_4.1.2.bb delete mode 100644 poky/meta/recipes-devtools/python/python3-setuptools-scm_5.0.1.bb create mode 100644 poky/meta/recipes-devtools/python/python3-setuptools_50.3.2.bb delete mode 100644 poky/meta/recipes-devtools/python/python3-setuptools_51.0.0.bb create mode 100644 poky/meta/recipes-devtools/python/python3/CVE-2020-27619.patch create mode 100644 poky/meta/recipes-devtools/python/python3_3.9.0.bb delete mode 100644 poky/meta/recipes-devtools/python/python3_3.9.1.bb (limited to 'poky/meta/recipes-devtools/python') diff --git a/poky/meta/recipes-devtools/python/python3-hypothesis_5.41.4.bb b/poky/meta/recipes-devtools/python/python3-hypothesis_5.41.4.bb new file mode 100644 index 000000000..416acc8d7 --- /dev/null +++ b/poky/meta/recipes-devtools/python/python3-hypothesis_5.41.4.bb @@ -0,0 +1,14 @@ +SUMMARY = "A library for property-based testing" +HOMEPAGE = "https://github.com/HypothesisWorks/hypothesis/tree/master/hypothesis-python" +LICENSE = "MPL-2.0" +LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=4ee62c16ebd0f4f99d906f36b7de8c3c" + +PYPI_PACKAGE = "hypothesis" + +inherit pypi setuptools3 + +SRC_URI[sha256sum] = "7ef22dd2ae4a906ef1e237dcd6806aa7f97e30c37f924a0e6d595f4639350b53" + +RDEPENDS_${PN} += "python3-core" + +BBCLASSEXTEND = "native nativesdk" diff --git a/poky/meta/recipes-devtools/python/python3-hypothesis_5.43.3.bb b/poky/meta/recipes-devtools/python/python3-hypothesis_5.43.3.bb deleted file mode 100644 index 4d93cba86..000000000 --- a/poky/meta/recipes-devtools/python/python3-hypothesis_5.43.3.bb +++ /dev/null @@ -1,14 +0,0 @@ -SUMMARY = "A library for property-based testing" -HOMEPAGE = "https://github.com/HypothesisWorks/hypothesis/tree/master/hypothesis-python" -LICENSE = "MPL-2.0" -LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=4ee62c16ebd0f4f99d906f36b7de8c3c" - -PYPI_PACKAGE = "hypothesis" - -inherit pypi setuptools3 - -SRC_URI[sha256sum] = "d97ba7ae2cfe7096b0c045fdb611ee9850ccdd6050a9b36cb96812242062c2cc" - -RDEPENDS_${PN} += "python3-attrs python3-core python3-sortedcontainers" - -BBCLASSEXTEND = "native nativesdk" diff --git a/poky/meta/recipes-devtools/python/python3-importlib-metadata_3.1.0.bb b/poky/meta/recipes-devtools/python/python3-importlib-metadata_3.1.0.bb new file mode 100644 index 000000000..d89621bed --- /dev/null +++ b/poky/meta/recipes-devtools/python/python3-importlib-metadata_3.1.0.bb @@ -0,0 +1,18 @@ +DESCRIPTION = "Read metadata from Python packages" +HOMEPAGE = "https://pypi.org/project/importlib-metadata/" +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://LICENSE;md5=e88ae122f3925d8bde8319060f2ddb8e" + +inherit pypi setuptools3 + +SRC_URI = "https://files.pythonhosted.org/packages/7d/d4/dbc58eed92be61bae65a7d80a7604d35bf6ded3e3c53c14f2d45b4a28831/importlib_metadata-3.1.0.tar.gz" +SRC_URI[sha256sum] = "d9b8a46a0885337627a6430db287176970fff18ad421becec1d64cfc763c2099" + +S = "${WORKDIR}/importlib_metadata-${PV}" + +DEPENDS += "${PYTHON_PN}-setuptools-scm-native" +RDEPENDS_${PN} += "${PYTHON_PN}-zipp ${PYTHON_PN}-pathlib2" +RDEPENDS_${PN}_append_class-target = " python3-misc" +RDEPENDS_${PN}_append_class-nativesdk = " python3-misc" + +BBCLASSEXTEND = "native nativesdk" diff --git a/poky/meta/recipes-devtools/python/python3-importlib-metadata_3.3.0.bb b/poky/meta/recipes-devtools/python/python3-importlib-metadata_3.3.0.bb deleted file mode 100644 index 23f2e2dba..000000000 --- a/poky/meta/recipes-devtools/python/python3-importlib-metadata_3.3.0.bb +++ /dev/null @@ -1,20 +0,0 @@ -DESCRIPTION = "Read metadata from Python packages" -HOMEPAGE = "https://pypi.org/project/importlib-metadata/" -LICENSE = "Apache-2.0" -LIC_FILES_CHKSUM = "file://LICENSE;md5=e88ae122f3925d8bde8319060f2ddb8e" - -inherit pypi setuptools3 - -PYPI_PACKAGE = "importlib_metadata" -UPSTREAM_CHECK_REGEX = "/importlib-metadata/(?P(\d+[\.\-_]*)+)/" - -SRC_URI[sha256sum] = "5c5a2720817414a6c41f0a49993908068243ae02c1635a228126519b509c8aed" - -S = "${WORKDIR}/importlib_metadata-${PV}" - -DEPENDS += "${PYTHON_PN}-setuptools-scm-native" -RDEPENDS_${PN} += "${PYTHON_PN}-zipp ${PYTHON_PN}-pathlib2" -RDEPENDS_${PN}_append_class-target = " python3-misc" -RDEPENDS_${PN}_append_class-nativesdk = " python3-misc" - -BBCLASSEXTEND = "native nativesdk" diff --git a/poky/meta/recipes-devtools/python/python3-packaging_20.4.bb b/poky/meta/recipes-devtools/python/python3-packaging_20.4.bb new file mode 100644 index 000000000..c75707e69 --- /dev/null +++ b/poky/meta/recipes-devtools/python/python3-packaging_20.4.bb @@ -0,0 +1,14 @@ +DESCRIPTION = "Core utilities for Python packages" +HOMEPAGE = "https://github.com/pypa/packaging" +LICENSE = "Apache-2.0 & BSD" +LIC_FILES_CHKSUM = "file://LICENSE;md5=faadaedca9251a90b205c9167578ce91" + +SRC_URI[md5sum] = "3208229da731c5d8e29d4d8941e75005" +SRC_URI[sha256sum] = "4357f74f47b9c12db93624a82154e9b120fa8293699949152b22065d556079f8" + +inherit pypi setuptools3 + +BBCLASSEXTEND = "native" + +DEPENDS += "${PYTHON_PN}-setuptools-scm-native" +RDEPENDS_${PN} += "${PYTHON_PN}-six ${PYTHON_PN}-pyparsing" diff --git a/poky/meta/recipes-devtools/python/python3-packaging_20.8.bb b/poky/meta/recipes-devtools/python/python3-packaging_20.8.bb deleted file mode 100644 index 658c3d1f3..000000000 --- a/poky/meta/recipes-devtools/python/python3-packaging_20.8.bb +++ /dev/null @@ -1,13 +0,0 @@ -DESCRIPTION = "Core utilities for Python packages" -HOMEPAGE = "https://github.com/pypa/packaging" -LICENSE = "Apache-2.0 & BSD" -LIC_FILES_CHKSUM = "file://LICENSE;md5=faadaedca9251a90b205c9167578ce91" - -SRC_URI[sha256sum] = "78598185a7008a470d64526a8059de9aaa449238f280fc9eb6b13ba6c4109093" - -inherit pypi setuptools3 - -BBCLASSEXTEND = "native" - -DEPENDS += "${PYTHON_PN}-setuptools-scm-native" -RDEPENDS_${PN} += "${PYTHON_PN}-six ${PYTHON_PN}-pyparsing" diff --git a/poky/meta/recipes-devtools/python/python3-py_1.10.0.bb b/poky/meta/recipes-devtools/python/python3-py_1.10.0.bb deleted file mode 100644 index 4e16ad174..000000000 --- a/poky/meta/recipes-devtools/python/python3-py_1.10.0.bb +++ /dev/null @@ -1,14 +0,0 @@ -SUMMARY = "Library with cross-python path, ini-parsing, io, code, log facilities" -HOMEPAGE = "http://py.readthedocs.io/" -LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://LICENSE;md5=a6bb0320b04a0a503f12f69fea479de9" - -SRC_URI[sha256sum] = "21b81bda15b66ef5e1a777a21c4dcd9c20ad3efd0b3f817e7a809035269e1bd3" - -DEPENDS += "${PYTHON_PN}-setuptools-scm-native" - -inherit pypi setuptools3 - -BBCLASSEXTEND = "native nativesdk" - -RDEPENDS_${PN} += "${PYTHON_PN}-netclient" diff --git a/poky/meta/recipes-devtools/python/python3-py_1.9.0.bb b/poky/meta/recipes-devtools/python/python3-py_1.9.0.bb new file mode 100644 index 000000000..794ec2a87 --- /dev/null +++ b/poky/meta/recipes-devtools/python/python3-py_1.9.0.bb @@ -0,0 +1,15 @@ +SUMMARY = "Library with cross-python path, ini-parsing, io, code, log facilities" +HOMEPAGE = "http://py.readthedocs.io/" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://LICENSE;md5=a6bb0320b04a0a503f12f69fea479de9" + +SRC_URI[md5sum] = "b80db4e61eef724f49feb4d20b649e62" +SRC_URI[sha256sum] = "9ca6883ce56b4e8da7e79ac18787889fa5206c79dcc67fb065376cd2fe03f342" + +DEPENDS += "${PYTHON_PN}-setuptools-scm-native" + +inherit pypi setuptools3 + +BBCLASSEXTEND = "native nativesdk" + +RDEPENDS_${PN} += "${PYTHON_PN}-netclient" diff --git a/poky/meta/recipes-devtools/python/python3-pygments_2.7.2.bb b/poky/meta/recipes-devtools/python/python3-pygments_2.7.2.bb new file mode 100644 index 000000000..00e5dc6e3 --- /dev/null +++ b/poky/meta/recipes-devtools/python/python3-pygments_2.7.2.bb @@ -0,0 +1,19 @@ +SUMMARY = "Pygments is a syntax highlighting package written in Python." +DESCRIPTION = "Pygments is a syntax highlighting package written in Python." +HOMEPAGE = "http://pygments.org/" +LICENSE = "BSD-2-Clause" +LIC_FILES_CHKSUM = "file://LICENSE;md5=1f5d0c4cf38dfc8122c00d6f1a97a0cc" + +inherit setuptools3 +SRC_URI[sha256sum] = "381985fcc551eb9d37c52088a32914e00517e57f4a21609f48141ba08e193fa0" + +DEPENDS += "\ + ${PYTHON_PN} \ + " + +PYPI_PACKAGE = "Pygments" + +inherit pypi + +BBCLASSEXTEND = "native nativesdk" + diff --git a/poky/meta/recipes-devtools/python/python3-pygments_2.7.3.bb b/poky/meta/recipes-devtools/python/python3-pygments_2.7.3.bb deleted file mode 100644 index 379d85dbd..000000000 --- a/poky/meta/recipes-devtools/python/python3-pygments_2.7.3.bb +++ /dev/null @@ -1,19 +0,0 @@ -SUMMARY = "Pygments is a syntax highlighting package written in Python." -DESCRIPTION = "Pygments is a syntax highlighting package written in Python." -HOMEPAGE = "http://pygments.org/" -LICENSE = "BSD-2-Clause" -LIC_FILES_CHKSUM = "file://LICENSE;md5=1f5d0c4cf38dfc8122c00d6f1a97a0cc" - -inherit setuptools3 -SRC_URI[sha256sum] = "ccf3acacf3782cbed4a989426012f1c535c9a90d3a7fc3f16d231b9372d2b716" - -DEPENDS += "\ - ${PYTHON_PN} \ - " - -PYPI_PACKAGE = "Pygments" - -inherit pypi - -BBCLASSEXTEND = "native nativesdk" - diff --git a/poky/meta/recipes-devtools/python/python3-pytest/0001-setup.py-remove-the-setup_requires-for-setuptools-scm.patch b/poky/meta/recipes-devtools/python/python3-pytest/0001-setup.py-remove-the-setup_requires-for-setuptools-scm.patch index 1abd531c6..8c5c17247 100644 --- a/poky/meta/recipes-devtools/python/python3-pytest/0001-setup.py-remove-the-setup_requires-for-setuptools-scm.patch +++ b/poky/meta/recipes-devtools/python/python3-pytest/0001-setup.py-remove-the-setup_requires-for-setuptools-scm.patch @@ -1,7 +1,8 @@ -From ead04f2da75efeca3369feff6161ea4a8baecbc9 Mon Sep 17 00:00:00 2001 +From ff784f4803ab33f5e3389e40d038d52d1e211843 Mon Sep 17 00:00:00 2001 From: Yuan Chao Date: Wed, 28 Aug 2019 16:12:27 +0900 -Subject: [PATCH] setup.py: remove the setup_requires for setuptools-scm +Subject: [PATCH] [PATCH] setup.py: remove the setup_requires for + setuptools-scm The setup_requires argument forces the download of the egg file for setuptools-scm during the do_compile phase. This download is incompatible with the typical fetch @@ -17,20 +18,22 @@ Signed-off-by: Yuan Chao Rebase for pytest 6.1.0. Signed-off-by: Kai Kang - --- setup.cfg | 1 - 1 file changed, 1 deletion(-) diff --git a/setup.cfg b/setup.cfg -index 6ed0792..0137090 100644 +index 60f6564..c4d1471 100644 --- a/setup.cfg +++ b/setup.cfg -@@ -53,7 +53,6 @@ package_dir = +@@ -55,7 +55,6 @@ package_dir = =src setup_requires = - setuptools>=>=42.0 -- setuptools-scm>=3.4 + setuptools>=40.0 +- setuptools-scm zip_safe = no [options.entry_points] +-- +2.17.1 + diff --git a/poky/meta/recipes-devtools/python/python3-pytest_6.1.2.bb b/poky/meta/recipes-devtools/python/python3-pytest_6.1.2.bb new file mode 100644 index 000000000..6fc3b6f32 --- /dev/null +++ b/poky/meta/recipes-devtools/python/python3-pytest_6.1.2.bb @@ -0,0 +1,39 @@ +SUMMARY = "Simple powerful testing with python" + +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://LICENSE;md5=81eb9f71d006c6b268cf4388e3c98f7b" + +SRC_URI_append = " file://0001-setup.py-remove-the-setup_requires-for-setuptools-scm.patch " + +SRC_URI[sha256sum] = "c0a7e94a8cdbc5422a51ccdad8e6f1024795939cc89159a0ae7f0b316ad3823e" + +inherit update-alternatives pypi setuptools3 + +RDEPENDS_${PN}_class-target += " \ + ${PYTHON_PN}-atomicwrites \ + ${PYTHON_PN}-attrs \ + ${PYTHON_PN}-debugger \ + ${PYTHON_PN}-doctest \ + ${PYTHON_PN}-importlib-metadata \ + ${PYTHON_PN}-iniconfig \ + ${PYTHON_PN}-json \ + ${PYTHON_PN}-more-itertools \ + ${PYTHON_PN}-packaging \ + ${PYTHON_PN}-pathlib2 \ + ${PYTHON_PN}-pluggy \ + ${PYTHON_PN}-py \ + ${PYTHON_PN}-setuptools \ + ${PYTHON_PN}-six \ + ${PYTHON_PN}-toml \ + ${PYTHON_PN}-wcwidth \ +" + +ALTERNATIVE_${PN} += "py.test pytest" + +NATIVE_LINK_NAME[pytest] = "${bindir}/pytest" +ALTERNATIVE_TARGET[pytest] = "${bindir}/pytest" + +ALTERNATIVE_LINK_NAME[py.test] = "${bindir}/py.test" +ALTERNATIVE_TARGET[py.test] = "${bindir}/py.test" + +BBCLASSEXTEND = "native nativesdk" diff --git a/poky/meta/recipes-devtools/python/python3-pytest_6.2.1.bb b/poky/meta/recipes-devtools/python/python3-pytest_6.2.1.bb deleted file mode 100644 index 6843b4da2..000000000 --- a/poky/meta/recipes-devtools/python/python3-pytest_6.2.1.bb +++ /dev/null @@ -1,39 +0,0 @@ -SUMMARY = "Simple powerful testing with python" - -LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://LICENSE;md5=81eb9f71d006c6b268cf4388e3c98f7b" - -SRC_URI_append = " file://0001-setup.py-remove-the-setup_requires-for-setuptools-scm.patch " - -SRC_URI[sha256sum] = "66e419b1899bc27346cb2c993e12c5e5e8daba9073c1fbce33b9807abc95c306" - -inherit update-alternatives pypi setuptools3 - -RDEPENDS_${PN}_class-target += " \ - ${PYTHON_PN}-atomicwrites \ - ${PYTHON_PN}-attrs \ - ${PYTHON_PN}-debugger \ - ${PYTHON_PN}-doctest \ - ${PYTHON_PN}-importlib-metadata \ - ${PYTHON_PN}-iniconfig \ - ${PYTHON_PN}-json \ - ${PYTHON_PN}-more-itertools \ - ${PYTHON_PN}-packaging \ - ${PYTHON_PN}-pathlib2 \ - ${PYTHON_PN}-pluggy \ - ${PYTHON_PN}-py \ - ${PYTHON_PN}-setuptools \ - ${PYTHON_PN}-six \ - ${PYTHON_PN}-toml \ - ${PYTHON_PN}-wcwidth \ -" - -ALTERNATIVE_${PN} += "py.test pytest" - -NATIVE_LINK_NAME[pytest] = "${bindir}/pytest" -ALTERNATIVE_TARGET[pytest] = "${bindir}/pytest" - -ALTERNATIVE_LINK_NAME[py.test] = "${bindir}/py.test" -ALTERNATIVE_TARGET[py.test] = "${bindir}/py.test" - -BBCLASSEXTEND = "native nativesdk" diff --git a/poky/meta/recipes-devtools/python/python3-setuptools-scm_4.1.2.bb b/poky/meta/recipes-devtools/python/python3-setuptools-scm_4.1.2.bb new file mode 100644 index 000000000..48bad2b99 --- /dev/null +++ b/poky/meta/recipes-devtools/python/python3-setuptools-scm_4.1.2.bb @@ -0,0 +1,23 @@ +SUMMARY = "the blessed package to manage your versions by scm tags" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://PKG-INFO;beginline=8;endline=8;md5=8227180126797a0148f94f483f3e1489" + +SRC_URI[md5sum] = "e6c9fad17c90516d640868eb833d5150" +SRC_URI[sha256sum] = "a8994582e716ec690f33fec70cca0f85bd23ec974e3f783233e4879090a7faa8" + +PYPI_PACKAGE = "setuptools_scm" +inherit pypi setuptools3 + +UPSTREAM_CHECK_REGEX = "setuptools_scm-(?P.*)\.tar" + +RDEPENDS_${PN} = "\ + ${PYTHON_PN}-debugger \ + ${PYTHON_PN}-json \ + ${PYTHON_PN}-py \ + ${PYTHON_PN}-setuptools \ +" +RDEPENDS_${PN}_class-native = "\ + ${PYTHON_PN}-setuptools-native \ +" + +BBCLASSEXTEND = "native nativesdk" diff --git a/poky/meta/recipes-devtools/python/python3-setuptools-scm_5.0.1.bb b/poky/meta/recipes-devtools/python/python3-setuptools-scm_5.0.1.bb deleted file mode 100644 index 406404ec6..000000000 --- a/poky/meta/recipes-devtools/python/python3-setuptools-scm_5.0.1.bb +++ /dev/null @@ -1,24 +0,0 @@ -SUMMARY = "the blessed package to manage your versions by scm tags" -LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://PKG-INFO;beginline=8;endline=8;md5=8227180126797a0148f94f483f3e1489" - -SRC_URI[sha256sum] = "c85b6b46d0edd40d2301038cdea96bb6adc14d62ef943e75afb08b3e7bcf142a" - -PYPI_PACKAGE = "setuptools_scm" -inherit pypi setuptools3 - -UPSTREAM_CHECK_REGEX = "setuptools_scm-(?P.*)\.tar" - -RDEPENDS_${PN} = "\ - ${PYTHON_PN}-debugger \ - ${PYTHON_PN}-json \ - ${PYTHON_PN}-py \ - ${PYTHON_PN}-setuptools \ - ${PYTHON_PN}-toml \ -" -RDEPENDS_${PN}_class-native = "\ - ${PYTHON_PN}-setuptools-native \ - ${PYTHON_PN}-toml-native \ -" - -BBCLASSEXTEND = "native nativesdk" diff --git a/poky/meta/recipes-devtools/python/python3-setuptools_50.3.2.bb b/poky/meta/recipes-devtools/python/python3-setuptools_50.3.2.bb new file mode 100644 index 000000000..4480d5677 --- /dev/null +++ b/poky/meta/recipes-devtools/python/python3-setuptools_50.3.2.bb @@ -0,0 +1,65 @@ +SUMMARY = "Download, build, install, upgrade, and uninstall Python packages" +HOMEPAGE = "https://pypi.org/project/setuptools" +SECTION = "devel/python" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://LICENSE;beginline=1;endline=19;md5=9a33897f1bca1160d7aad3835152e158" + +PYPI_PACKAGE_EXT = "zip" + +inherit pypi setuptools3 + +SRC_URI_append_class-native = " file://0001-conditionally-do-not-fetch-code-by-easy_install.patch" + +SRC_URI += "file://0001-change-shebang-to-python3.patch" + +SRC_URI[sha256sum] = "ed0519d27a243843b05d82a5e9d01b0b083d9934eaa3d02779a23da18077bd3c" + +DEPENDS += "${PYTHON_PN}" + +RDEPENDS_${PN} = "\ + ${PYTHON_PN}-2to3 \ + ${PYTHON_PN}-compile \ + ${PYTHON_PN}-compression \ + ${PYTHON_PN}-ctypes \ + ${PYTHON_PN}-distutils \ + ${PYTHON_PN}-email \ + ${PYTHON_PN}-html \ + ${PYTHON_PN}-json \ + ${PYTHON_PN}-netserver \ + ${PYTHON_PN}-numbers \ + ${PYTHON_PN}-pickle \ + ${PYTHON_PN}-pkgutil \ + ${PYTHON_PN}-plistlib \ + ${PYTHON_PN}-shell \ + ${PYTHON_PN}-stringold \ + ${PYTHON_PN}-threading \ + ${PYTHON_PN}-unittest \ + ${PYTHON_PN}-xml \ +" + +do_install_prepend() { + install -d ${D}${PYTHON_SITEPACKAGES_DIR} +} + +do_install_append() { + mv ${D}${bindir}/easy_install ${D}${bindir}/easy3_install +} + +BBCLASSEXTEND = "native nativesdk" + +# The pkg-resources module can be used by itself, without the package downloader +# and easy_install. Ship it in a separate package so that it can be used by +# minimal distributions. +PACKAGES =+ "${PYTHON_PN}-pkg-resources " +FILES_${PYTHON_PN}-pkg-resources = "${PYTHON_SITEPACKAGES_DIR}/pkg_resources/*" +RDEPENDS_${PYTHON_PN}-pkg-resources = "\ + ${PYTHON_PN}-compression \ + ${PYTHON_PN}-email \ + ${PYTHON_PN}-plistlib \ + ${PYTHON_PN}-pprint \ +" +# Due to the way OE-Core implemented native recipes, the native class cannot +# have a dependency on something that is not a recipe name. Work around that by +# manually setting RPROVIDES. +RDEPENDS_${PN}_append = " ${PYTHON_PN}-pkg-resources" +RPROVIDES_append_class-native = " ${PYTHON_PN}-pkg-resources-native" diff --git a/poky/meta/recipes-devtools/python/python3-setuptools_51.0.0.bb b/poky/meta/recipes-devtools/python/python3-setuptools_51.0.0.bb deleted file mode 100644 index 6ee935f8f..000000000 --- a/poky/meta/recipes-devtools/python/python3-setuptools_51.0.0.bb +++ /dev/null @@ -1,65 +0,0 @@ -SUMMARY = "Download, build, install, upgrade, and uninstall Python packages" -HOMEPAGE = "https://pypi.org/project/setuptools" -SECTION = "devel/python" -LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://LICENSE;beginline=1;endline=19;md5=9a33897f1bca1160d7aad3835152e158" - -PYPI_PACKAGE_EXT = "zip" - -inherit pypi setuptools3 - -SRC_URI_append_class-native = " file://0001-conditionally-do-not-fetch-code-by-easy_install.patch" - -SRC_URI += "file://0001-change-shebang-to-python3.patch" - -SRC_URI[sha256sum] = "029c49fd713e9230f6a41c0298e6e1f5839f2cde7104c0ad5e053a37777e7688" - -DEPENDS += "${PYTHON_PN}" - -RDEPENDS_${PN} = "\ - ${PYTHON_PN}-2to3 \ - ${PYTHON_PN}-compile \ - ${PYTHON_PN}-compression \ - ${PYTHON_PN}-ctypes \ - ${PYTHON_PN}-distutils \ - ${PYTHON_PN}-email \ - ${PYTHON_PN}-html \ - ${PYTHON_PN}-json \ - ${PYTHON_PN}-netserver \ - ${PYTHON_PN}-numbers \ - ${PYTHON_PN}-pickle \ - ${PYTHON_PN}-pkgutil \ - ${PYTHON_PN}-plistlib \ - ${PYTHON_PN}-shell \ - ${PYTHON_PN}-stringold \ - ${PYTHON_PN}-threading \ - ${PYTHON_PN}-unittest \ - ${PYTHON_PN}-xml \ -" - -do_install_prepend() { - install -d ${D}${PYTHON_SITEPACKAGES_DIR} -} - -do_install_append() { - mv ${D}${bindir}/easy_install ${D}${bindir}/easy3_install -} - -BBCLASSEXTEND = "native nativesdk" - -# The pkg-resources module can be used by itself, without the package downloader -# and easy_install. Ship it in a separate package so that it can be used by -# minimal distributions. -PACKAGES =+ "${PYTHON_PN}-pkg-resources " -FILES_${PYTHON_PN}-pkg-resources = "${PYTHON_SITEPACKAGES_DIR}/pkg_resources/*" -RDEPENDS_${PYTHON_PN}-pkg-resources = "\ - ${PYTHON_PN}-compression \ - ${PYTHON_PN}-email \ - ${PYTHON_PN}-plistlib \ - ${PYTHON_PN}-pprint \ -" -# Due to the way OE-Core implemented native recipes, the native class cannot -# have a dependency on something that is not a recipe name. Work around that by -# manually setting RPROVIDES. -RDEPENDS_${PN}_append = " ${PYTHON_PN}-pkg-resources" -RPROVIDES_append_class-native = " ${PYTHON_PN}-pkg-resources-native" diff --git a/poky/meta/recipes-devtools/python/python3/CVE-2020-27619.patch b/poky/meta/recipes-devtools/python/python3/CVE-2020-27619.patch new file mode 100644 index 000000000..b2053e7a4 --- /dev/null +++ b/poky/meta/recipes-devtools/python/python3/CVE-2020-27619.patch @@ -0,0 +1,69 @@ +From b664a1df4ee71d3760ab937653b10997081b1794 Mon Sep 17 00:00:00 2001 +From: "Miss Skeleton (bot)" <31488909+miss-islington@users.noreply.github.com> +Date: Tue, 6 Oct 2020 05:37:36 -0700 +Subject: [PATCH] bpo-41944: No longer call eval() on content received via HTTP + in the CJK codec tests (GH-22566) + +(cherry picked from commit 2ef5caa58febc8968e670e39e3d37cf8eef3cab8) + +Co-authored-by: Serhiy Storchaka + +Upstream-Status: Backport [https://github.com/python/cpython/commit/b664a1df4ee71d3760ab937653b10997081b1794] +CVE: CVE-2020-27619 +Signed-off-by: Chee Yang Lee + +--- + Lib/test/multibytecodec_support.py | 22 +++++++------------ + .../2020-10-05-17-43-46.bpo-41944.rf1dYb.rst | 1 + + 2 files changed, 9 insertions(+), 14 deletions(-) + create mode 100644 Misc/NEWS.d/next/Tests/2020-10-05-17-43-46.bpo-41944.rf1dYb.rst + +diff --git a/Lib/test/multibytecodec_support.py b/Lib/test/multibytecodec_support.py +index cca8af67d6d1d..f76c0153f5ecf 100644 +--- a/Lib/test/multibytecodec_support.py ++++ b/Lib/test/multibytecodec_support.py +@@ -305,29 +305,23 @@ def test_mapping_file(self): + self._test_mapping_file_plain() + + def _test_mapping_file_plain(self): +- unichrs = lambda s: ''.join(map(chr, map(eval, s.split('+')))) ++ def unichrs(s): ++ return ''.join(chr(int(x, 16)) for x in s.split('+')) ++ + urt_wa = {} + + with self.open_mapping_file() as f: + for line in f: + if not line: + break +- data = line.split('#')[0].strip().split() ++ data = line.split('#')[0].split() + if len(data) != 2: + continue + +- csetval = eval(data[0]) +- if csetval <= 0x7F: +- csetch = bytes([csetval & 0xff]) +- elif csetval >= 0x1000000: +- csetch = bytes([(csetval >> 24), ((csetval >> 16) & 0xff), +- ((csetval >> 8) & 0xff), (csetval & 0xff)]) +- elif csetval >= 0x10000: +- csetch = bytes([(csetval >> 16), ((csetval >> 8) & 0xff), +- (csetval & 0xff)]) +- elif csetval >= 0x100: +- csetch = bytes([(csetval >> 8), (csetval & 0xff)]) +- else: ++ if data[0][:2] != '0x': ++ self.fail(f"Invalid line: {line!r}") ++ csetch = bytes.fromhex(data[0][2:]) ++ if len(csetch) == 1 and 0x80 <= csetch[0]: + continue + + unich = unichrs(data[1]) +diff --git a/Misc/NEWS.d/next/Tests/2020-10-05-17-43-46.bpo-41944.rf1dYb.rst b/Misc/NEWS.d/next/Tests/2020-10-05-17-43-46.bpo-41944.rf1dYb.rst +new file mode 100644 +index 0000000000000..4f9782f1c85af +--- /dev/null ++++ b/Misc/NEWS.d/next/Tests/2020-10-05-17-43-46.bpo-41944.rf1dYb.rst +@@ -0,0 +1 @@ ++Tests for CJK codecs no longer call ``eval()`` on content received via HTTP. diff --git a/poky/meta/recipes-devtools/python/python3_3.9.0.bb b/poky/meta/recipes-devtools/python/python3_3.9.0.bb new file mode 100644 index 000000000..19a8950f1 --- /dev/null +++ b/poky/meta/recipes-devtools/python/python3_3.9.0.bb @@ -0,0 +1,376 @@ +SUMMARY = "The Python Programming Language" +HOMEPAGE = "http://www.python.org" +LICENSE = "PSFv2" +SECTION = "devel/python" + +LIC_FILES_CHKSUM = "file://LICENSE;md5=33223c9ef60c31e3f0e866cb09b65e83" + +SRC_URI = "http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.xz \ + file://run-ptest \ + file://create_manifest3.py \ + file://get_module_deps3.py \ + file://python3-manifest.json \ + file://check_build_completeness.py \ + file://reformat_sysconfig.py \ + file://cgi_py.patch \ + file://0001-Do-not-add-usr-lib-termcap-to-linker-flags-to-avoid-.patch \ + ${@bb.utils.contains('PACKAGECONFIG', 'tk', '', 'file://avoid_warning_about_tkinter.patch', d)} \ + file://0001-Do-not-use-the-shell-version-of-python-config-that-w.patch \ + file://python-config.patch \ + file://0001-Makefile.pre-use-qemu-wrapper-when-gathering-profile.patch \ + file://0001-python3-use-cc_basename-to-replace-CC-for-checking-c.patch \ + file://0001-Makefile-fix-Issue36464-parallel-build-race-problem.patch \ + file://0001-bpo-36852-proper-detection-of-mips-architecture-for-.patch \ + file://crosspythonpath.patch \ + file://0001-Use-FLAG_REF-always-for-interned-strings.patch \ + file://0001-test_locale.py-correct-the-test-output-format.patch \ + file://0017-setup.py-do-not-report-missing-dependencies-for-disa.patch \ + file://0001-setup.py-pass-missing-libraries-to-Extension-for-mul.patch \ + file://0001-Makefile-do-not-compile-.pyc-in-parallel.patch \ + file://0020-configure.ac-setup.py-do-not-add-a-curses-include-pa.patch \ + file://0001-Lib-sysconfig.py-use-libdir-values-from-configuratio.patch \ + file://CVE-2020-27619.patch \ + " + +SRC_URI_append_class-native = " \ + file://0001-distutils-sysconfig-append-STAGING_LIBDIR-python-sys.patch \ + file://12-distutils-prefix-is-inside-staging-area.patch \ + file://0001-Don-t-search-system-for-headers-libraries.patch \ + " + +SRC_URI[sha256sum] = "9c73e63c99855709b9be0b3cc9e5b072cb60f37311e8c4e50f15576a0bf82854" + +# exclude pre-releases for both python 2.x and 3.x +UPSTREAM_CHECK_REGEX = "[Pp]ython-(?P\d+(\.\d+)+).tar" +UPSTREAM_CHECK_URI = "https://www.python.org/downloads/source/" + +CVE_PRODUCT = "python" + +# Upstream consider this expected behaviour +CVE_CHECK_WHITELIST += "CVE-2007-4559" +# This is not exploitable when glibc has CVE-2016-10739 fixed. +CVE_CHECK_WHITELIST += "CVE-2019-18348" + +# This is windows only issue. +CVE_CHECK_WHITELIST += "CVE-2020-15523" + +PYTHON_MAJMIN = "3.9" + +S = "${WORKDIR}/Python-${PV}" + +BBCLASSEXTEND = "native nativesdk" + +inherit autotools pkgconfig qemu ptest multilib_header update-alternatives + +MULTILIB_SUFFIX = "${@d.getVar('base_libdir',1).split('/')[-1]}" + +ALTERNATIVE_${PN}-dev = "python3-config" +ALTERNATIVE_LINK_NAME[python3-config] = "${bindir}/python${PYTHON_MAJMIN}-config" +ALTERNATIVE_TARGET[python3-config] = "${bindir}/python${PYTHON_MAJMIN}-config-${MULTILIB_SUFFIX}" + + +DEPENDS = "bzip2-replacement-native libffi bzip2 openssl sqlite3 zlib virtual/libintl xz virtual/crypt util-linux libtirpc libnsl2" +DEPENDS_append_class-target = " python3-native" +DEPENDS_append_class-nativesdk = " python3-native" + +EXTRA_OECONF = " --without-ensurepip --enable-shared --with-platlibdir=${baselib}" +EXTRA_OECONF_append_class-native = " --bindir=${bindir}/${PN}" + +export CROSSPYTHONPATH="${STAGING_LIBDIR_NATIVE}/python${PYTHON_MAJMIN}/lib-dynload/" + +EXTRANATIVEPATH += "python3-native" + +# LTO will be enabled via packageconfig depending upong distro features +LTO_class-target = "" + +CACHED_CONFIGUREVARS = " \ + ac_cv_file__dev_ptmx=yes \ + ac_cv_file__dev_ptc=no \ + ac_cv_working_tzset=yes \ +" + +def possibly_include_pgo(d): + # PGO currently causes builds to not be reproducible, so disable it for + # now. See YOCTO #13407 + if bb.utils.contains('MACHINE_FEATURES', 'qemu-usermode', True, False, d) and d.getVar('BUILD_REPRODUCIBLE_BINARIES') != '1': + return 'pgo' + + return '' + +PACKAGECONFIG_class-target ??= "readline ${@possibly_include_pgo(d)} gdbm ${@bb.utils.filter('DISTRO_FEATURES', 'lto', d)}" +PACKAGECONFIG_class-native ??= "readline gdbm" +PACKAGECONFIG_class-nativesdk ??= "readline gdbm" +PACKAGECONFIG[readline] = ",,readline" +# Use profile guided optimisation by running PyBench inside qemu-user +PACKAGECONFIG[pgo] = "--enable-optimizations,,qemu-native" +PACKAGECONFIG[tk] = ",,tk" +PACKAGECONFIG[gdbm] = ",,gdbm" +PACKAGECONFIG[lto] = "--with-lto,," + +do_configure_prepend () { + mkdir -p ${B}/Modules + cat > ${B}/Modules/Setup.local << EOF +*disabled* +${@bb.utils.contains('PACKAGECONFIG', 'gdbm', '', '_gdbm _dbm', d)} +${@bb.utils.contains('PACKAGECONFIG', 'readline', '', 'readline', d)} +EOF +} + +CPPFLAGS_append = " -I${STAGING_INCDIR}/ncursesw -I${STAGING_INCDIR}/uuid" + +EXTRA_OEMAKE = '\ + STAGING_LIBDIR=${STAGING_LIBDIR} \ + STAGING_INCDIR=${STAGING_INCDIR} \ + LIB=${baselib} \ +' + +do_compile_prepend_class-target() { + if ${@bb.utils.contains('PACKAGECONFIG', 'pgo', 'true', 'false', d)}; then + qemu_binary="${@qemu_wrapper_cmdline(d, '${STAGING_DIR_TARGET}', ['${B}', '${STAGING_DIR_TARGET}/${base_libdir}'])}" + cat >pgo-wrapper < ${B}/Modules/Setup.local << EOF -*disabled* -${@bb.utils.contains('PACKAGECONFIG', 'gdbm', '', '_gdbm _dbm', d)} -${@bb.utils.contains('PACKAGECONFIG', 'readline', '', 'readline', d)} -EOF -} - -CPPFLAGS_append = " -I${STAGING_INCDIR}/ncursesw -I${STAGING_INCDIR}/uuid" - -EXTRA_OEMAKE = '\ - STAGING_LIBDIR=${STAGING_LIBDIR} \ - STAGING_INCDIR=${STAGING_INCDIR} \ - LIB=${baselib} \ -' - -do_compile_prepend_class-target() { - if ${@bb.utils.contains('PACKAGECONFIG', 'pgo', 'true', 'false', d)}; then - qemu_binary="${@qemu_wrapper_cmdline(d, '${STAGING_DIR_TARGET}', ['${B}', '${STAGING_DIR_TARGET}/${base_libdir}'])}" - cat >pgo-wrapper <