summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools
diff options
context:
space:
mode:
authorZhang Xiao <xiao.zhang@windriver.com>2018-03-12 02:12:58 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-07-02 21:37:47 +0100
commit69b588ea2ad37f6c798aee8e49c5b375e52b7e81 (patch)
tree7703f9d253008f7e049ed9c852ac17b6664722c0 /meta/recipes-devtools
parent960ab9ef8cb861b00b02501e9d0c8f168ca34512 (diff)
downloadpoky-69b588ea2ad37f6c798aee8e49c5b375e52b7e81.tar.gz
python3: fix file conflict when multilib enabled
Config file python3.5m-config conflicts between 32 and 64 bit packages. Use update-alternatives to add base_libdir as suffix to avoid it. [YOCTO #12511] (From OE-Core rev: bbb5e55abd0e628a5b0dae90d5eace0a2483f1fc) Signed-off-by: Zhang Xiao <xiao.zhang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools')
-rw-r--r--meta/recipes-devtools/python/python3_3.5.5.bb12
1 files changed, 10 insertions, 2 deletions
diff --git a/meta/recipes-devtools/python/python3_3.5.5.bb b/meta/recipes-devtools/python/python3_3.5.5.bb
index 4dae4fa4c6..50f63e39c1 100644
--- a/meta/recipes-devtools/python/python3_3.5.5.bb
+++ b/meta/recipes-devtools/python/python3_3.5.5.bb
@@ -4,7 +4,7 @@ DEPENDS = "python3-native libffi bzip2 gdbm openssl sqlite3 zlib virtual/libintl
4 4
5PR = "${INC_PR}.0" 5PR = "${INC_PR}.0"
6PYTHON_MAJMIN = "3.5" 6PYTHON_MAJMIN = "3.5"
7PYTHON_BINABI= "${PYTHON_MAJMIN}m" 7PYTHON_BINABI = "${PYTHON_MAJMIN}m"
8DISTRO_SRC_URI ?= "file://sitecustomize.py" 8DISTRO_SRC_URI ?= "file://sitecustomize.py"
9DISTRO_SRC_URI_linuxstdbase = "" 9DISTRO_SRC_URI_linuxstdbase = ""
10SRC_URI = "http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.xz \ 10SRC_URI = "http://www.python.org/ftp/python/${PV}/Python-${PV}.tar.xz \
@@ -48,7 +48,13 @@ UPSTREAM_CHECK_REGEX = "[Pp]ython-(?P<pver>\d+(\.\d+)+).tar"
48 48
49S = "${WORKDIR}/Python-${PV}" 49S = "${WORKDIR}/Python-${PV}"
50 50
51inherit autotools multilib_header python3native pkgconfig 51inherit autotools multilib_header python3native pkgconfig update-alternatives
52
53MULTILIB_SUFFIX = "${@d.getVar('base_libdir',1).split('/')[-1]}"
54
55ALTERNATIVE_${PN}-dev = "python-config"
56ALTERNATIVE_LINK_NAME[python-config] = "${bindir}/python${PYTHON_BINABI}-config"
57ALTERNATIVE_TARGET[python-config] = "${bindir}/python${PYTHON_BINABI}-config-${MULTILIB_SUFFIX}"
52 58
53CONFIGUREOPTS += " --with-system-ffi " 59CONFIGUREOPTS += " --with-system-ffi "
54 60
@@ -207,6 +213,8 @@ py_package_preprocess () {
207 ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} \ 213 ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} \
208 -c "from py_compile import compile; compile('./${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py', optimize=2)" 214 -c "from py_compile import compile; compile('./${libdir}/python${PYTHON_MAJMIN}/_sysconfigdata.py', optimize=2)"
209 cd - 215 cd -
216
217 mv ${PKGD}/${bindir}/python3.5m-config ${PKGD}/${bindir}/python3.5m-config-${MULTILIB_SUFFIX}
210} 218}
211 219
212# manual dependency additions 220# manual dependency additions