python3-numpy: Upgrade to 1.19.4
PATCH 1/4 python3-numpy: Upgrade to 1.19.4
Unify inc file into single recipe, py2 is gone
---
meta/recipes-devtools/python-numpy/python3-numpy_1.19.3.bb | 3 ---
.../{python-numpy.inc => python3-numpy_1.19.4.bb} | 6 ++++--
2 files changed, 4 insertions(+), 5 deletions(-)
delete mode 100644 meta/recipes-devtools/python-numpy/python3-numpy_1.19.3.bb
rename meta/recipes-devtools/python-numpy/{python-numpy.inc => python3-numpy_1.19.4.bb} (94%)meta/recipes-devtools/python-numpy/python3-numpy_1.19.3.bb deleted +0 -3
@@ -1,3 +0,0 @@ -inherit setuptools3 -require python-numpy.inc -
meta/recipes-devtools/python-numpy/python3-numpy_1.19.4.bb renamed from meta/recipes-devtools/python-numpy/python-numpy.inc +4 -2
@@ -8,14 +8,16 @@ SRCNAME = "numpy" SRC_URI = "https://github.com/${SRCNAME}/${SRCNAME}/releases/download/v${PV}/${SRCNAME}-${PV}.tar.gz \ file://0001-Don-t-search-usr-and-so-on-for-libraries-by-default-.patch \ file://0001-numpy-core-Define-RISCV-32-support.patch \ - " -SRC_URI[sha256sum] = "9179d259a9bc53ed7b153d31fc3156d1ca560d61079f53191cf177c3efc4a498" +" +SRC_URI[sha256sum] = "fe836a685d6838dbb3f603caef01183ea98e88febf4ce956a2ea484a75378413" UPSTREAM_CHECK_URI = "https://github.com/numpy/numpy/releases" UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)\.tar" DEPENDS += "python3-cython-native" +inherit setuptools3 + S = "${WORKDIR}/numpy-${PV}" CLEANBROKEN = "1"
Signature · 1 line
2.29.2
PATCH 2/4 python3-hypothesis: Add recipe
Its used in many python packages for testing eg. numpy
--- .../python/python3-hypothesis_5.41.2.bb | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 meta/recipes-devtools/python/python3-hypothesis_5.41.2.bb
meta/recipes-devtools/python/python3-hypothesis_5.41.2.bb new file +12 -0
@@ -0,0 +1,12 @@ +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] = "f8c281355aaba1da696e40f1488c2bb47c42660424f5750daea45a85e2d047b3" + +RDEPENDS_${PN} += "python3-core"
Signature · 1 line
2.29.2
PATCH 3/4 python3-sortedcontainers: Add recipe
In reply to Khem RajUsed in some python package testing infrastructures
--- .../python/python3-sortedcontainers_2.3.0.bb | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 meta/recipes-devtools/python/python3-sortedcontainers_2.3.0.bb
meta/recipes-devtools/python/python3-sortedcontainers_2.3.0.bb new file +9 -0
@@ -0,0 +1,9 @@ +SUMMARY = "Sorted Containers is an Apache2 licensed sorted collections library, written in pure-Python, and fast as C-extensions." +HOMEPAGE = "http://www.grantjenks.com/docs/sortedcontainers/" +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://LICENSE;md5=7c7c6a1a12ec816da16c1839137d53ae" + +inherit pypi setuptools3 +SRC_URI[sha256sum] = "59cc937650cf60d677c16775597c89a960658a09cf7c1a668f86e1e4464b10a1" + +BBCLASSEXTEND = "native nativesdk"
Signature · 1 line
2.29.2
PATCH 4/4 python-numpy: Add ptest
In reply to Khem RajSince 1.15, numpy have replaced nose with pytest testing framework it additionally needs hypothesis and sortedcontainers modules
--- meta/recipes-devtools/python-numpy/files/run-ptest | 5 +++++ meta/recipes-devtools/python-numpy/python3-numpy_1.19.4.bb | 7 +++++-- 2 files changed, 10 insertions(+), 2 deletions(-) create mode 100644 meta/recipes-devtools/python-numpy/files/run-ptest
meta/recipes-devtools/python-numpy/files/run-ptest new file +5 -0
@@ -0,0 +1,5 @@ +#!/usr/bin/env python3 + +import numpy +numpy.test(label='full', verbose=2) +
meta/recipes-devtools/python-numpy/python3-numpy_1.19.4.bb +5 -2
@@ -8,6 +8,7 @@ SRCNAME = "numpy" SRC_URI = "https://github.com/${SRCNAME}/${SRCNAME}/releases/download/v${PV}/${SRCNAME}-${PV}.tar.gz \ file://0001-Don-t-search-usr-and-so-on-for-libraries-by-default-.patch \ file://0001-numpy-core-Define-RISCV-32-support.patch \ + file://run-ptest \ " SRC_URI[sha256sum] = "fe836a685d6838dbb3f603caef01183ea98e88febf4ce956a2ea484a75378413"
@@ -16,7 +17,7 @@ UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)\.tar" DEPENDS += "python3-cython-native" -inherit setuptools3 +inherit ptest setuptools3 S = "${WORKDIR}/numpy-${PV}"
@@ -30,7 +31,6 @@ RDEPENDS_${PN} = "${PYTHON_PN}-unittest \ ${PYTHON_PN}-pprint \ ${PYTHON_PN}-pickle \ ${PYTHON_PN}-shell \ - ${PYTHON_PN}-nose \ ${PYTHON_PN}-doctest \ ${PYTHON_PN}-datetime \ ${PYTHON_PN}-distutils \
@@ -39,6 +39,9 @@ RDEPENDS_${PN} = "${PYTHON_PN}-unittest \ ${PYTHON_PN}-netclient \ ${PYTHON_PN}-numbers \ ${PYTHON_PN}-pydoc \ + ${PYTHON_PN}-pytest \ + ${PYTHON_PN}-hypothesis \ + ${PYTHON_PN}-sortedcontainers \ ${PYTHON_PN}-pkgutil \ ${PYTHON_PN}-email \ ${PYTHON_PN}-compression \
Signature · 1 line
2.29.2
Re: [OE-core] [PATCH 4/4] python-numpy: Add ptest
Quoted 9 lines · Khem Raj
Since 1.15, numpy have replaced nose with pytest testing framework it additionally needs hypothesis and sortedcontainers modules
Signed-off-by Khem Raj <[email protected]>--- meta/recipes-devtools/python-numpy/files/run-ptest | 5 +++++ meta/recipes-devtools/python-numpy/python3-numpy_1.19.4.bb | 7 +++++-- 2 files changed, 10 insertions(+), 2 deletions(-) create mode 100644 meta/recipes-devtools/python-numpy/files/run-ptest
This series isn't quite there as it needs python3-pytest and I think its missing some BBCLASSEXTENDs too.
stdio: WARNING: Nothing RPROVIDES 'nativesdk-python3-hypothesis' (but virtual:nativesdk:/home/pokybuild/yocto-worker/a-full/build/meta/recipes-devtools/python-numpy/python3-numpy_1.19.4.bb RDEPENDS on or otherwise requires it)
stdio: WARNING: Nothing RPROVIDES 'nativesdk-python3-pytest' (but virtual:nativesdk:/home/pokybuild/yocto-worker/a-full/build/meta/recipes-devtools/python-numpy/python3-numpy_1.19.4.bb RDEPENDS on or otherwise requires it)
stdio: WARNING: Nothing RPROVIDES 'python3-pytest' (but /home/pokybuild/yocto-worker/a-full/build/meta/recipes-devtools/python-numpy/python3-numpy_1.19.4.bb RDEPENDS on or otherwise requires it)
stdio: WARNING: Nothing RPROVIDES 'python3-numpy' (but /home/pokybuild/yocto-worker/a-full/build/meta/recipes-devtools/python-numpy/python3-numpy_1.19.4.bb RDEPENDS on or otherwise requires it)
Cheers,
Richard