mirror of
https://github.com/openembedded/meta-openembedded.git
synced 2025-07-19 15:29:08 +02:00

Some python modules rely on "import ninja". Only build and ship the python parts, and don't download and build ninja from sources. Use the already built ninja instead. The CMakeLists.txt file is a crippled copy from this ninja python module's sources, removing almost everything, and adding a dummy install target, so do_install() doesn't fail. The python code is patched so ninja is used from PATH. Signed-off-by: Zoltán Böszörményi <zboszor@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
35 lines
790 B
BlitzBasic
35 lines
790 B
BlitzBasic
SUMMARY = "Ninja is a small build system with a focus on speed"
|
|
LICENSE = "Apache-2.0"
|
|
LIC_FILES_CHKSUM = "file://LICENSE_Apache_20;md5=19cbd64715b51267a47bf3750cc6a8a5"
|
|
|
|
DEPENDS = "ninja-native cmake-native python3-scikit-build-native"
|
|
|
|
PYPI_PACKAGE = "ninja"
|
|
PYPI_ARCHIVE_NAME_PREFIX = "pypi-"
|
|
|
|
inherit pypi python_setuptools_build_meta
|
|
SRC_URI[sha256sum] = "c833a47d39b2d1eee3f9ca886fa1581efd5be6068b82734ac229961ee8748f90"
|
|
|
|
SRC_URI += " \
|
|
file://CMakeLists.txt \
|
|
file://run-ninja-from-path.patch \
|
|
"
|
|
|
|
addtask do_patchbuild after do_patch before do_configure
|
|
|
|
do_patchbuild () {
|
|
rm -f ${S}/CMakeLists.txt
|
|
cp ${WORKDIR}/CMakeLists.txt ${S}/
|
|
}
|
|
|
|
do_install:append () {
|
|
rm -rf ${D}${bindir}
|
|
}
|
|
|
|
RDEPENDS:${PN} = " \
|
|
ninja \
|
|
python3-scikit-build \
|
|
"
|
|
|
|
BBCLASSEXTEND = "native nativesdk"
|