diff options
author | Martin Jansa <martin.jansa@gmail.com> | 2024-02-27 12:37:10 +0100 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2024-02-27 09:05:17 -0800 |
commit | 8c5720df4a1f4ea0f72196029aae495fd58565b2 (patch) | |
tree | 6d83f103ef84879d37657ca27a1a932eeabba49f | |
parent | 39028d0d9da7aef2dd547f76dd5f9b02b0209c00 (diff) | |
download | meta-openembedded-8c5720df4a1f4ea0f72196029aae495fd58565b2.tar.gz |
gattlib: use python3native and depend on python3-packaging-native
* it uses gdbus-codegen from glib-2.0-native which depended
on python3-distutils-native until
https://lists.openembedded.org/g/openembedded-core/message/196136
but distutils on host was enforced by sanity check only until mickledore with:
https://git.openembedded.org/openembedded-core/commit/?id=8e3a5b0709384f2b455a82ac1e8e212686fe4456
so on hosts without distutils this was already failing with:
http://errors.yoctoproject.org/Errors/Details/754696/
cd TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/build/dbus && gdbus-codegen --pragma-once --interface-prefix org.bluez.Descriptor1. --generate-c-code TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/build/dbus/org-bluez-gattdescriptor1 TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/git/dbus/dbus-bluez-v5.48/org.bluez.GattDescriptor1.xml
Traceback (most recent call last):
File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/recipe-sysroot-native/usr/bin/gdbus-codegen", line 53, in <module>
from codegen import codegen_main
File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/recipe-sysroot-native/usr/share/glib-2.0/codegen/codegen_main.py", line 29, in <module>
from . import dbustypes
File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/recipe-sysroot-native/usr/share/glib-2.0/codegen/dbustypes.py", line 22, in <module>
from . import utils
File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/recipe-sysroot-native/usr/share/glib-2.0/codegen/utils.py", line 22, in <module>
import distutils.version
ModuleNotFoundError: No module named 'distutils'
and the glib-2.0-native change only changes the dependency from
distutils to packaging which results in:
http://errors.yoctoproject.org/Errors/Details/754692/
FAILED: dbus/org-bluez-gattdescriptor1.c TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/build/dbus/org-bluez-gattdescriptor1.c
cd TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/build/dbus && gdbus-codegen --pragma-once --interface-prefix org.bluez.Descriptor1. --generate-c-code TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/build/dbus/org-bluez-gattdescriptor1 TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/git/dbus/dbus-bluez-v5.48/org.bluez.GattDescriptor1.xml
Traceback (most recent call last):
File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/recipe-sysroot-native/usr/bin/gdbus-codegen", line 53, in <module>
from codegen import codegen_main
File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/recipe-sysroot-native/usr/share/glib-2.0/codegen/codegen_main.py", line 29, in <module>
from . import dbustypes
File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/recipe-sysroot-native/usr/share/glib-2.0/codegen/dbustypes.py", line 22, in <module>
from . import utils
File "TOPDIR/tmp-glibc/work/core2-64-oe-linux/gattlib/0.2+git/recipe-sysroot-native/usr/share/glib-2.0/codegen/utils.py", line 22, in <module>
import packaging.version
ModuleNotFoundError: No module named 'packaging'
* packaging probably isn't as wide spread on host distros as old
distutils was, so make sure it's available by using
python3-native with python3-packaging-native from OE build
Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r-- | meta-oe/recipes-connectivity/gattlib/gattlib_git.bb | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/meta-oe/recipes-connectivity/gattlib/gattlib_git.bb b/meta-oe/recipes-connectivity/gattlib/gattlib_git.bb index f54d833a0..7ad28d594 100644 --- a/meta-oe/recipes-connectivity/gattlib/gattlib_git.bb +++ b/meta-oe/recipes-connectivity/gattlib/gattlib_git.bb | |||
@@ -4,8 +4,7 @@ SECTION = "libs/network" | |||
4 | LICENSE = "GPL-2.0-or-later | BSD-3-Clause" | 4 | LICENSE = "GPL-2.0-or-later | BSD-3-Clause" |
5 | LIC_FILES_CHKSUM = "file://CMakeLists.txt;beginline=1;endline=6;md5=a87ee154f005a6f035b8b34ac2191f3b" | 5 | LIC_FILES_CHKSUM = "file://CMakeLists.txt;beginline=1;endline=6;md5=a87ee154f005a6f035b8b34ac2191f3b" |
6 | 6 | ||
7 | DEPENDS = "bluez5 glib-2.0" | 7 | DEPENDS = "bluez5 glib-2.0 glib-2.0-native python3-packaging-native" |
8 | DEPENDS += "glib-2.0-native" | ||
9 | 8 | ||
10 | PV = "0.2+git" | 9 | PV = "0.2+git" |
11 | 10 | ||
@@ -26,7 +25,7 @@ PACKAGECONFIG[force-dbus] = "-DGATTLIB_FORCE_DBUS=TRUE,-DGATTLIB_FORCE_DBUS=FALS | |||
26 | EXTRA_OECMAKE += "-DGATTLIB_PYTHON_INTERFACE=OFF" | 25 | EXTRA_OECMAKE += "-DGATTLIB_PYTHON_INTERFACE=OFF" |
27 | EXTRA_OECMAKE += "-DGATTLIB_BUILD_DOCS=OFF" | 26 | EXTRA_OECMAKE += "-DGATTLIB_BUILD_DOCS=OFF" |
28 | 27 | ||
29 | inherit pkgconfig cmake | 28 | inherit pkgconfig cmake python3native |
30 | 29 | ||
31 | do_compile:append() { | 30 | do_compile:append() { |
32 | for f in org-bluez-gattdescriptor1.c org-bluez-battery1.c org-bluez-adaptater1.c \ | 31 | for f in org-bluez-gattdescriptor1.c org-bluez-battery1.c org-bluez-adaptater1.c \ |