summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/python/python3
diff options
context:
space:
mode:
authorAlexander Kanavin <alexander.kanavin@linux.intel.com>2016-04-06 17:58:36 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-06-01 12:38:41 +0100
commit4977a0743ba439a46716c6ef10c5958d5a561115 (patch)
tree3372a088a3e8503fbf50df08bb227a6c2ad07025 /meta/recipes-devtools/python/python3
parent49557a5e9d93665e2409e4b12850dc325dee19dd (diff)
downloadpoky-4977a0743ba439a46716c6ef10c5958d5a561115.tar.gz
python-native, python3-native: remove the use of exported HOST_SYS and BUILD_SYS variables
The code that utilized them was superseded by the code (in the same patch!) that is utilizing STAGING_LIBDIR/STAGING_INCDIR, and wasn't correct in the first place as HOST_SYS is not necessarily the same as the sysroot directory name. (From OE-Core rev: 8834e81a38c24a066bb4fefa93da61011d0db244) Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/python/python3')
-rw-r--r--meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch49
1 files changed, 9 insertions, 40 deletions
diff --git a/meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch b/meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch
index 8b93c1cf4f..c53ec0cfc8 100644
--- a/meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch
+++ b/meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch
@@ -1,4 +1,4 @@
1From d4dd67daa1555bf13272cc071706338572539bad Mon Sep 17 00:00:00 2001 1From 7630ab22578746d3d790d0598c0d279cf7afed97 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com> 2From: Khem Raj <raj.khem@gmail.com>
3Date: Tue, 14 May 2013 15:00:26 -0700 3Date: Tue, 14 May 2013 15:00:26 -0700
4Subject: [PATCH 01/20] python3: Add target and native recipes 4Subject: [PATCH 01/20] python3: Add target and native recipes
@@ -14,27 +14,14 @@ Upstream-Status: Inappropriate [embedded specific]
14# Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com> 14# Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com>
15 15
16--- 16---
17 Lib/distutils/sysconfig.py | 10 ++++++++--
18 1 file changed, 8 insertions(+), 2 deletions(-)
19
17diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py 20diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py
18index 573724d..418b478 100644 21index 573724d..390c485 100644
19--- a/Lib/distutils/sysconfig.py 22--- a/Lib/distutils/sysconfig.py
20+++ b/Lib/distutils/sysconfig.py 23+++ b/Lib/distutils/sysconfig.py
21@@ -17,10 +17,11 @@ import sys 24@@ -84,7 +84,9 @@ def get_python_inc(plat_specific=0, prefix=None):
22 from .errors import DistutilsPlatformError
23
24 # These are needed in a couple of spots, so just compute them once.
25-PREFIX = os.path.normpath(sys.prefix)
26-EXEC_PREFIX = os.path.normpath(sys.exec_prefix)
27-BASE_PREFIX = os.path.normpath(sys.base_prefix)
28-BASE_EXEC_PREFIX = os.path.normpath(sys.base_exec_prefix)
29+PREFIX = os.path.normpath(sys.prefix).replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
30+EXEC_PREFIX = os.path.normpath(sys.exec_prefix).replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
31+BASE_PREFIX = os.path.normpath(sys.base_prefix).replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
32+BASE_EXEC_PREFIX= os.path.normpath(sys.base_exec_prefix).replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
33+
34
35 # Path to the base directory of the project. On Windows the binary may
36 # live in project/PCBuild/win32 or project/PCBuild/amd64.
37@@ -84,7 +85,9 @@ def get_python_inc(plat_specific=0, prefix=None):
38 If 'prefix' is supplied, use it instead of sys.base_prefix or 25 If 'prefix' is supplied, use it instead of sys.base_prefix or
39 sys.base_exec_prefix -- i.e., ignore 'plat_specific'. 26 sys.base_exec_prefix -- i.e., ignore 'plat_specific'.
40 """ 27 """
@@ -45,7 +32,7 @@ index 573724d..418b478 100644
45 prefix = plat_specific and BASE_EXEC_PREFIX or BASE_PREFIX 32 prefix = plat_specific and BASE_EXEC_PREFIX or BASE_PREFIX
46 if os.name == "posix": 33 if os.name == "posix":
47 if python_build: 34 if python_build:
48@@ -125,6 +128,10 @@ def get_python_lib(plat_specific=0, standard_lib=0, prefix=None): 35@@ -125,6 +127,10 @@ def get_python_lib(plat_specific=0, standard_lib=0, prefix=None):
49 If 'prefix' is supplied, use it instead of sys.base_prefix or 36 If 'prefix' is supplied, use it instead of sys.base_prefix or
50 sys.base_exec_prefix -- i.e., ignore 'plat_specific'. 37 sys.base_exec_prefix -- i.e., ignore 'plat_specific'.
51 """ 38 """
@@ -56,7 +43,7 @@ index 573724d..418b478 100644
56 if prefix is None: 43 if prefix is None:
57 if standard_lib: 44 if standard_lib:
58 prefix = plat_specific and BASE_EXEC_PREFIX or BASE_PREFIX 45 prefix = plat_specific and BASE_EXEC_PREFIX or BASE_PREFIX
59@@ -133,7 +140,7 @@ def get_python_lib(plat_specific=0, standard_lib=0, prefix=None): 46@@ -133,7 +139,7 @@ def get_python_lib(plat_specific=0, standard_lib=0, prefix=None):
60 47
61 if os.name == "posix": 48 if os.name == "posix":
62 libpython = os.path.join(prefix, 49 libpython = os.path.join(prefix,
@@ -65,24 +52,6 @@ index 573724d..418b478 100644
65 if standard_lib: 52 if standard_lib:
66 return libpython 53 return libpython
67 else: 54 else:
68@@ -233,7 +240,7 @@ def get_config_h_filename():
69 else:
70 inc_dir = get_python_inc(plat_specific=1)
71
72- return os.path.join(inc_dir, 'pyconfig.h')
73+ return os.path.join(inc_dir, 'pyconfig.h'.replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") ))
74
75
76 def get_makefile_filename():
77@@ -242,7 +249,7 @@ def get_makefile_filename():
78 return os.path.join(_sys_home or project_base, "Makefile")
79 lib_dir = get_python_lib(plat_specific=0, standard_lib=1)
80 config_file = 'config-{}{}'.format(get_python_version(), build_flags)
81- return os.path.join(lib_dir, config_file, 'Makefile')
82+ return os.path.join(lib_dir, config_file, 'Makefile').replace( os.getenv("BUILD_SYS"), os.getenv("HOST_SYS") )
83
84
85 def parse_config_h(fp, g=None):
86-- 55--
872.7.0 562.8.0.rc3
88 57