summaryrefslogtreecommitdiffstats
path: root/meta-python
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2020-01-21 13:24:07 -0800
committerKhem Raj <raj.khem@gmail.com>2020-01-22 09:56:34 -0800
commita16eaae6fdb0889ca71f35b708a437f60a239c78 (patch)
tree9305d14854cd8662723b03777fc10a323054fc1d /meta-python
parent51272d11594e8609237e0e049b1f97ff95ab7d19 (diff)
downloadmeta-openembedded-a16eaae6fdb0889ca71f35b708a437f60a239c78.tar.gz
python3-robotframework-seriallibrary: Backport a patch to fix py3 build
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-python')
-rw-r--r--meta-python/recipes-devtools/python/python3-robotframework-seriallibrary/e31d5fdf2ea00ac6349e64580a20816783064dd4.patch45
-rw-r--r--meta-python/recipes-devtools/python/python3-robotframework-seriallibrary_0.3.1.bb20
2 files changed, 64 insertions, 1 deletions
diff --git a/meta-python/recipes-devtools/python/python3-robotframework-seriallibrary/e31d5fdf2ea00ac6349e64580a20816783064dd4.patch b/meta-python/recipes-devtools/python/python3-robotframework-seriallibrary/e31d5fdf2ea00ac6349e64580a20816783064dd4.patch
new file mode 100644
index 0000000000..21e97fd93a
--- /dev/null
+++ b/meta-python/recipes-devtools/python/python3-robotframework-seriallibrary/e31d5fdf2ea00ac6349e64580a20816783064dd4.patch
@@ -0,0 +1,45 @@
1From e31d5fdf2ea00ac6349e64580a20816783064dd4 Mon Sep 17 00:00:00 2001
2From: Hideki Takeoka <hideki.takeoka@smartfrog.com>
3Date: Sun, 25 Aug 2019 19:25:00 +0200
4Subject: [PATCH] Update setup.py for python3.7+ support
5
6---
7 setup.py | 9 +++++----
8 src/SerialLibrary/version.py | 3 +++
9 2 files changed, 8 insertions(+), 4 deletions(-)
10
11diff --git a/setup.py b/setup.py
12index 4c34705..70bb1af 100644
13--- a/setup.py
14+++ b/setup.py
15@@ -1,6 +1,5 @@
16 #!/usr/bin/env python
17
18-from imp import load_source
19 from os.path import abspath, dirname, join
20 from sys import platform
21
22@@ -18,9 +17,11 @@
23
24
25 CURDIR = dirname(abspath(__file__))
26-VERSION = load_source(
27- 'version', 'version',
28- open(join(CURDIR, 'src', 'SerialLibrary', 'version.py'))).VERSION
29+
30+with open(join(CURDIR, 'src', 'SerialLibrary', 'version.py')) as f:
31+ exec(f.read())
32+ VERSION = get_version()
33+
34 README = open(join(CURDIR, 'README.rst')).read()
35 CLASSIFIERS = '\n'.join(
36 map(' :: '.join, [
37diff --git a/src/SerialLibrary/version.py b/src/SerialLibrary/version.py
38index 6ce65c4..19831bc 100644
39--- a/src/SerialLibrary/version.py
40+++ b/src/SerialLibrary/version.py
41@@ -1 +1,4 @@
42 VERSION = (0, 3, 1)
43+
44+def get_version():
45+ return VERSION;
diff --git a/meta-python/recipes-devtools/python/python3-robotframework-seriallibrary_0.3.1.bb b/meta-python/recipes-devtools/python/python3-robotframework-seriallibrary_0.3.1.bb
index d82b7b96ae..b6de42f7c1 100644
--- a/meta-python/recipes-devtools/python/python3-robotframework-seriallibrary_0.3.1.bb
+++ b/meta-python/recipes-devtools/python/python3-robotframework-seriallibrary_0.3.1.bb
@@ -1,2 +1,20 @@
1SUMMARY = "Robot Framework test library for serial connection"
2HOMEPAGE = "https://github.com/whosaysni/robotframework-seriallibrary"
3LICENSE = "Apache-2.0"
4LIC_FILES_CHKSUM = "file://PKG-INFO;beginline=8;endline=8;md5=7145f7cdd263359b62d342a02f005515"
5
6SRC_URI[md5sum] = "b7c9565d54c30df7cd3f3c0e29adffa3"
7SRC_URI[sha256sum] = "256ad60fc0b7df4be44d82c302f5ed8fad4935cda99e4b45942e3c88179d1e19"
8
9PYPI_PACKAGE = "robotframework-seriallibrary"
10
1inherit pypi setuptools3 11inherit pypi setuptools3
2require python-robotframework-seriallibrary.inc 12
13SRC_URI += "file://e31d5fdf2ea00ac6349e64580a20816783064dd4.patch"
14
15RDEPENDS_${PN} += " \
16 ${PYTHON_PN}-pyserial \
17 ${PYTHON_PN}-robotframework \
18"
19
20BBCLASSEXTEND = "native nativesdk"