diff options
author | Alexander Kanavin <alexander.kanavin@linux.intel.com> | 2016-06-22 15:06:35 +0300 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-07-01 16:22:42 +0100 |
commit | cf1af6b384ab102fc3d8d703546cafcc6ffc8a0a (patch) | |
tree | 6476c48f766a957618b38f494288b4ee6cf266ea /meta/classes/python3native.bbclass | |
parent | 83b11dcd55f907d845c8efa45a2616b8890f3004 (diff) | |
download | poky-cf1af6b384ab102fc3d8d703546cafcc6ffc8a0a.tar.gz |
pythonnative.bbclass, python3native.bbclass: export STAGING_INCDIR, STAGING_LIBDIR, PYTHON variables
We patch Python's distutils modules to access STAGING_INCDIR/LIBDIR, so when
they are not set, scripts that utilize distutils (e.g. python-config) fail.
Several recipes need to export those manually to prevent such failures,
so let's do that in the class instead.
PYTHON variable is exported because otherwise autotools' python.m4
macro will pick up its own internal default, which may not be the version
that we want.
glib recipe in particular was previously using Python 2.x during build due to python.m4
defaulting to it - now it's using Python 3.x, and so needs a small fix in
deletion of *.pyc files.
(From OE-Core rev: c1e0eb62f2d89b10b187016200018830b1c77945)
Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/python3native.bbclass')
-rw-r--r-- | meta/classes/python3native.bbclass | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/meta/classes/python3native.bbclass b/meta/classes/python3native.bbclass index 18998636b4..d7b2d357e9 100644 --- a/meta/classes/python3native.bbclass +++ b/meta/classes/python3native.bbclass | |||
@@ -3,3 +3,11 @@ inherit python3-dir | |||
3 | PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}" | 3 | PYTHON="${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN}" |
4 | EXTRANATIVEPATH += "${PYTHON_PN}-native" | 4 | EXTRANATIVEPATH += "${PYTHON_PN}-native" |
5 | DEPENDS += " ${PYTHON_PN}-native " | 5 | DEPENDS += " ${PYTHON_PN}-native " |
6 | |||
7 | # python-config and other scripts are using distutils modules | ||
8 | # which we patch to access these variables | ||
9 | export STAGING_INCDIR | ||
10 | export STAGING_LIBDIR | ||
11 | |||
12 | # autoconf macros will use their internal default preference otherwise | ||
13 | export PYTHON | ||