summaryrefslogtreecommitdiffstats
path: root/meta-python/recipes-devtools/python/python3-ninja_1.11.1.bb
diff options
context:
space:
mode:
authorZoltán Böszörményi <zboszor@gmail.com>2023-03-10 14:46:37 +0100
committerKhem Raj <raj.khem@gmail.com>2023-03-10 09:01:54 -0800
commitbf6779b62a72269f8cabeb416255c3f75d76d051 (patch)
treea73b270be99b3a92950bf1b745882d1894094ab0 /meta-python/recipes-devtools/python/python3-ninja_1.11.1.bb
parentb3d875df4d6023835e2272a630df3b90c48f5bb9 (diff)
downloadmeta-openembedded-bf6779b62a72269f8cabeb416255c3f75d76d051.tar.gz
python3-ninja: New recipe
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>
Diffstat (limited to 'meta-python/recipes-devtools/python/python3-ninja_1.11.1.bb')
-rw-r--r--meta-python/recipes-devtools/python/python3-ninja_1.11.1.bb34
1 files changed, 34 insertions, 0 deletions
diff --git a/meta-python/recipes-devtools/python/python3-ninja_1.11.1.bb b/meta-python/recipes-devtools/python/python3-ninja_1.11.1.bb
new file mode 100644
index 0000000000..635fd076a5
--- /dev/null
+++ b/meta-python/recipes-devtools/python/python3-ninja_1.11.1.bb
@@ -0,0 +1,34 @@
1SUMMARY = "Ninja is a small build system with a focus on speed"
2LICENSE = "Apache-2.0"
3LIC_FILES_CHKSUM = "file://LICENSE_Apache_20;md5=19cbd64715b51267a47bf3750cc6a8a5"
4
5DEPENDS = "ninja-native cmake-native python3-scikit-build-native"
6
7PYPI_PACKAGE = "ninja"
8PYPI_ARCHIVE_NAME_PREFIX = "pypi-"
9
10inherit pypi python_setuptools_build_meta
11SRC_URI[sha256sum] = "c833a47d39b2d1eee3f9ca886fa1581efd5be6068b82734ac229961ee8748f90"
12
13SRC_URI += " \
14 file://CMakeLists.txt \
15 file://run-ninja-from-path.patch \
16"
17
18addtask do_patchbuild after do_patch before do_configure
19
20do_patchbuild () {
21 rm -f ${S}/CMakeLists.txt
22 cp ${WORKDIR}/CMakeLists.txt ${S}/
23}
24
25do_install:append () {
26 rm -rf ${D}${bindir}
27}
28
29RDEPENDS:${PN} = " \
30 ninja \
31 python3-scikit-build \
32"
33
34BBCLASSEXTEND = "native nativesdk"