mirror of
https://github.com/openembedded/meta-openembedded.git
synced 2026-07-16 04:17:25 +00:00
weechat: fix cross Python detection
Inherit python3targetconfig point CMake's FindPython at the target sysroot libpython/headers so Embed component resolves when cross compiling. Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
This commit is contained in:
@@ -10,7 +10,7 @@ SRC_URI = "https://weechat.org/files/src/weechat-${PV}.tar.xz"
|
|||||||
|
|
||||||
SRC_URI[sha256sum] = "d1389a9e521bda0c4ebfa108e2abf885ee6c5150c385299f5dca0181a43a0914"
|
SRC_URI[sha256sum] = "d1389a9e521bda0c4ebfa108e2abf885ee6c5150c385299f5dca0181a43a0914"
|
||||||
|
|
||||||
inherit cmake pkgconfig
|
inherit cmake pkgconfig python3targetconfig
|
||||||
|
|
||||||
PACKAGECONFIG ??= " ncurses python"
|
PACKAGECONFIG ??= " ncurses python"
|
||||||
PACKAGECONFIG[ncurses] = "-DENABLE_NCURSES=ON,-DENABLE_NCURSES=OFF,ncurses"
|
PACKAGECONFIG[ncurses] = "-DENABLE_NCURSES=ON,-DENABLE_NCURSES=OFF,ncurses"
|
||||||
@@ -21,6 +21,14 @@ EXTRA_OECMAKE:append = " -DENABLE_PHP=OFF -DENABLE_TCL=OFF -DENABLE_LUA=OFF \
|
|||||||
-DENABLE_GUILE=OFF -DENABLE_PERL=OFF -DENABLE_ASPELL=ON \
|
-DENABLE_GUILE=OFF -DENABLE_PERL=OFF -DENABLE_ASPELL=ON \
|
||||||
-DLIBDIR=${libdir}"
|
-DLIBDIR=${libdir}"
|
||||||
|
|
||||||
|
# CMake's FindPython queries the (native) interpreter for the Development.Embed
|
||||||
|
# component, which then fails to locate the cross (target) libpython/headers.
|
||||||
|
# Point it explicitly at the target sysroot library and include directory.
|
||||||
|
EXTRA_OECMAKE:append = " \
|
||||||
|
-DPython_INCLUDE_DIR=${STAGING_INCDIR}/python${PYTHON_BASEVERSION} \
|
||||||
|
-DPython_LIBRARY=${STAGING_LIBDIR}/libpython${PYTHON_BASEVERSION}.so \
|
||||||
|
"
|
||||||
|
|
||||||
do_configure:prepend(){
|
do_configure:prepend(){
|
||||||
# Make sure we get dependencies from recipe-sysroot
|
# Make sure we get dependencies from recipe-sysroot
|
||||||
sed -i -e 's# /usr/bin# ${RECIPE_SYSROOT}/${bindir}/#g' ${S}/cmake/FindPerl.cmake
|
sed -i -e 's# /usr/bin# ${RECIPE_SYSROOT}/${bindir}/#g' ${S}/cmake/FindPerl.cmake
|
||||||
|
|||||||
Reference in New Issue
Block a user