diff options
author | Patrick Williams <patrick@stwcx.xyz> | 2016-08-17 14:31:25 -0500 |
---|---|---|
committer | Patrick Williams <patrick@stwcx.xyz> | 2016-08-22 16:43:26 +0000 |
commit | 60f9d69e016b11c468c98ea75ba0a60c44afbbc4 (patch) | |
tree | ecb49581a9e41a37943c22cd9ef3f63451b20ee7 /import-layers/yocto-poky/meta/recipes-devtools/python/python/builddir.patch | |
parent | e18c61205e0234b03697129c20cc69c9b3940efc (diff) | |
download | blackbird-openbmc-60f9d69e016b11c468c98ea75ba0a60c44afbbc4.tar.gz blackbird-openbmc-60f9d69e016b11c468c98ea75ba0a60c44afbbc4.zip |
yocto-poky: Move to import-layers subdir
We are going to import additional layers, so create a subdir to
hold all of the layers that we import with git-subtree.
Change-Id: I6f732153a22be8ca663035c518837e3cc5ec0799
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Diffstat (limited to 'import-layers/yocto-poky/meta/recipes-devtools/python/python/builddir.patch')
-rw-r--r-- | import-layers/yocto-poky/meta/recipes-devtools/python/python/builddir.patch | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/import-layers/yocto-poky/meta/recipes-devtools/python/python/builddir.patch b/import-layers/yocto-poky/meta/recipes-devtools/python/python/builddir.patch new file mode 100644 index 000000000..ad629a022 --- /dev/null +++ b/import-layers/yocto-poky/meta/recipes-devtools/python/python/builddir.patch @@ -0,0 +1,46 @@ +When cross compiling python, we used to need to install the Makefile, pyconfig.h +and the python library to their final location before being able to compile the +rest of python. This change allows us to point python at its own source when +building, avoiding a variety of sysroot staging issues and simplifying the main +python recipe. + +Upstream-Status: Inappropriate +RP 2012/11/13 + +Index: Python-2.7.9/Lib/sysconfig.py +=================================================================== +--- Python-2.7.9.orig/Lib/sysconfig.py ++++ Python-2.7.9/Lib/sysconfig.py +@@ -93,6 +93,7 @@ _PREFIX = os.path.normpath(sys.prefix) + _EXEC_PREFIX = os.path.normpath(sys.exec_prefix) + _CONFIG_VARS = None + _USER_BASE = None ++_PYTHONBUILDDIR = os.environ.get("PYTHONBUILDDIR", None) + + def _safe_realpath(path): + try: +@@ -100,7 +101,9 @@ def _safe_realpath(path): + except OSError: + return path + +-if sys.executable: ++if _PYTHONBUILDDIR: ++ _PROJECT_BASE = _PYTHONBUILDDIR ++elif sys.executable: + _PROJECT_BASE = os.path.dirname(_safe_realpath(sys.executable)) + else: + # sys.executable can be empty if argv[0] has been changed and Python is +Index: Python-2.7.9/Lib/distutils/sysconfig.py +=================================================================== +--- Python-2.7.9.orig/Lib/distutils/sysconfig.py ++++ Python-2.7.9/Lib/distutils/sysconfig.py +@@ -26,6 +26,9 @@ EXEC_PREFIX = os.path.normpath(sys.exec_ + # live in project/PCBuild9. If we're dealing with an x64 Windows build, + # it'll live in project/PCbuild/amd64. + project_base = os.path.dirname(os.path.abspath(sys.executable)) ++_PYTHONBUILDDIR = os.environ.get("PYTHONBUILDDIR", None) ++if _PYTHONBUILDDIR: ++ project_base = _PYTHONBUILDDIR + if os.name == "nt" and "pcbuild" in project_base[-8:].lower(): + project_base = os.path.abspath(os.path.join(project_base, os.path.pardir)) + # PC/VS7.1 |