aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChangqing Li <changqing.li@windriver.com>2020-04-24 09:09:41 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2020-04-26 13:58:59 +0100
commitc49ea8d5640d984e28ad63919e0b9ee549a4e17f (patch)
treef46970e9ebd6401b70b804870918e253c1169286
parent4a4fabaa8f6915513a3b1ef2268c402e96eca888 (diff)
downloadopenembedded-core-contrib-c49ea8d5640d984e28ad63919e0b9ee549a4e17f.tar.gz
openembedded-core-contrib-c49ea8d5640d984e28ad63919e0b9ee549a4e17f.tar.bz2
openembedded-core-contrib-c49ea8d5640d984e28ad63919e0b9ee549a4e17f.zip
python3-setuptools: change shebang to python3
we have offcially dropped python2, so it is possible that our code run on python3 only host, so change shebang to python3 to avoid error like: python: command not found Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-devtools/python/python-setuptools.inc2
-rw-r--r--meta/recipes-devtools/python/python3-setuptools/0001-change-shebang-to-python3.patch36
2 files changed, 38 insertions, 0 deletions
diff --git a/meta/recipes-devtools/python/python-setuptools.inc b/meta/recipes-devtools/python/python-setuptools.inc
index f7c3202fde9..07c2f8b2164 100644
--- a/meta/recipes-devtools/python/python-setuptools.inc
+++ b/meta/recipes-devtools/python/python-setuptools.inc
@@ -10,6 +10,8 @@ inherit pypi
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[md5sum] = "0c956eea142af9c2b02d72e3c042af30"
SRC_URI[sha256sum] = "89c6e6011ec2f6d57d43a3f9296c4ef022c2cbf49bab26b407fe67992ae3397f"
diff --git a/meta/recipes-devtools/python/python3-setuptools/0001-change-shebang-to-python3.patch b/meta/recipes-devtools/python/python3-setuptools/0001-change-shebang-to-python3.patch
new file mode 100644
index 00000000000..33af8daed74
--- /dev/null
+++ b/meta/recipes-devtools/python/python3-setuptools/0001-change-shebang-to-python3.patch
@@ -0,0 +1,36 @@
+From c39d0896930e25c224cc897660fc8511ccae30c8 Mon Sep 17 00:00:00 2001
+From: Changqing Li <changqing.li@windriver.com>
+Date: Thu, 23 Apr 2020 10:01:12 +0000
+Subject: [PATCH] change shebang to python3
+
+Upstream-Status: Pending
+
+Signed-off-by: Changqing Li <changqing.li@windriver.com>
+---
+ pkg_resources/_vendor/appdirs.py | 2 +-
+ setuptools/command/easy_install.py | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/pkg_resources/_vendor/appdirs.py b/pkg_resources/_vendor/appdirs.py
+index ae67001..933e398 100644
+--- a/pkg_resources/_vendor/appdirs.py
++++ b/pkg_resources/_vendor/appdirs.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python
++#!/usr/bin/env python3
+ # -*- coding: utf-8 -*-
+ # Copyright (c) 2005-2010 ActiveState Software Inc.
+ # Copyright (c) 2013 Eddy Petrișor
+diff --git a/setuptools/command/easy_install.py b/setuptools/command/easy_install.py
+index abca1ae..6bcdc98 100644
+--- a/setuptools/command/easy_install.py
++++ b/setuptools/command/easy_install.py
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python
++#!/usr/bin/env python3
+ """
+ Easy Install
+ ------------
+--
+2.24.1
+