summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorTim Orling <ticotimo@gmail.com>2022-02-22 11:16:29 -0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2022-02-25 15:07:50 +0000
commit29d6a3ae348422a6a286fb08ed1c4c722a9f6a25 (patch)
treeac358c2480f4d9a9a0d16b40cc37c93f0a26b648 /meta
parent72887eca0d24036def5a9601df5fafae7c572359 (diff)
downloadpoky-29d6a3ae348422a6a286fb08ed1c4c722a9f6a25.tar.gz
flit_core.bbclass: add helper for newer python packaging
Some python packages now use pyproject.toml and declare flit_core.buildapi as the build engine Use pip_install_wheel class to install. [YOCTO #14638] (From OE-Core rev: f0292098dc5afc62e0cd91d475edeb1784700795) Signed-off-by: Tim Orling <tim.orling@konsulko.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/classes/flit_core.bbclass16
1 files changed, 16 insertions, 0 deletions
diff --git a/meta/classes/flit_core.bbclass b/meta/classes/flit_core.bbclass
new file mode 100644
index 0000000000..0f2eec85d0
--- /dev/null
+++ b/meta/classes/flit_core.bbclass
@@ -0,0 +1,16 @@
1inherit pip_install_wheel python3native python3-dir
2
3DEPENDS += "python3 python3-flit-core-native python3-pip-native"
4
5do_configure () {
6 mkdir -p ${S}/dist
7 cat > ${S}/build-it.py << EOF
8from flit_core import buildapi
9buildapi.build_wheel('./dist')
10EOF
11}
12
13do_compile () {
14 ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} ${S}/build-it.py
15}
16