mirror of
https://git.yoctoproject.org/poky
synced 2026-02-05 16:28:43 +01:00
We have a patch unixccompiler.patch where we try to throw away everything except first element of CC string but this does not work if gcc is prepended with something e.g. CC="ccache gcc" then the logic fails and it ends up in some modules failing on you silently (_sqlite3) in my case. The fix here is to drop basename so we keep the whole string as it is and then the detection function searches for gcc string in the whole CC. This works in both cases one the original intent of the patch and the second described above. One place where it will fail is if someone has non-gcc compiler installed in some subdir which has gcc in it e.g. /usr/gcc/fakecc but for OE this should never happen. Ideally the the detection logic should have tried to execute gcc and then parsed --version output or something. (From OE-Core rev: 9b13b9024d24953dedb35f62d3d8b06a29036992) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
44 lines
1.3 KiB
BlitzBasic
44 lines
1.3 KiB
BlitzBasic
require python.inc
|
|
DEPENDS = "openssl-native bzip2-full-native zlib-native readline-native sqlite3-native"
|
|
PR = "${INC_PR}.1"
|
|
|
|
SRC_URI += "file://04-default-is-optimized.patch \
|
|
file://05-enable-ctypes-cross-build.patch \
|
|
file://06-ctypes-libffi-fix-configure.patch \
|
|
file://10-distutils-fix-swig-parameter.patch \
|
|
file://11-distutils-never-modify-shebang-line.patch \
|
|
file://12-distutils-prefix-is-inside-staging-area.patch \
|
|
file://debug.patch \
|
|
file://unixccompiler.patch \
|
|
file://nohostlibs.patch \
|
|
file://multilib.patch "
|
|
S = "${WORKDIR}/Python-${PV}"
|
|
|
|
inherit native
|
|
|
|
EXTRA_OEMAKE = '\
|
|
BUILD_SYS="" \
|
|
HOST_SYS="" \
|
|
LIBC="" \
|
|
STAGING_LIBDIR=${STAGING_LIBDIR_NATIVE} \
|
|
STAGING_INCDIR=${STAGING_INCDIR_NATIVE} \
|
|
'
|
|
|
|
do_configure_prepend() {
|
|
autoreconf --verbose --install --force --exclude=autopoint Modules/_ctypes/libffi || bbnote "_ctypes failed to autoreconf"
|
|
}
|
|
|
|
do_install() {
|
|
oe_runmake 'DESTDIR=${D}' install
|
|
install -d ${D}${bindir}/
|
|
install -m 0755 Parser/pgen ${D}${bindir}/
|
|
|
|
# Make sure we use /usr/bin/env python
|
|
for PYTHSCRIPT in `grep -rIl ${bindir}/python ${D}${bindir}`; do
|
|
sed -i -e '1s|^#!.*|#!/usr/bin/env python|' $PYTHSCRIPT
|
|
done
|
|
|
|
ln -sf python ${D}${bindir}/python2
|
|
|
|
}
|