Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/xpath/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Linux 如何解决bluez5和;皮布鲁兹_Linux_Yocto_Bluez_Bitbake_Pybluez - Fatal编程技术网

Linux 如何解决bluez5和;皮布鲁兹

Linux 如何解决bluez5和;皮布鲁兹,linux,yocto,bluez,bitbake,pybluez,Linux,Yocto,Bluez,Bitbake,Pybluez,我有一个用于Gumstix板的基于Yocto的Linux映像。该图像包括Bluez5蓝牙堆栈 local.conf: ... DISTRO_FEATURES_append = " bluetooth bluez5" ... 这成功构建了一个映像,我可以从CLI使用蓝牙模块。 我想在Python中使用蓝牙模块,因此我添加了pybluez支持- myimage.bb: ... PYTHON_INSTALL_append = "python-pybluez \" ... python_pyblue

我有一个用于Gumstix板的基于Yocto的Linux映像。该图像包括Bluez5蓝牙堆栈

local.conf:

... DISTRO_FEATURES_append = " bluetooth bluez5" ...
这成功构建了一个映像,我可以从CLI使用蓝牙模块。 我想在Python中使用蓝牙模块,因此我添加了pybluez支持-

myimage.bb:

... PYTHON_INSTALL_append = "python-pybluez \" ...
python_pybluez.bb:

DESCRIPTION = "Python bindings for the Linux Bluetooth stack"   
SECTION = "devel/python"    
DEPENDS = "bluez5"  
LICENSE = "GPL" 
SRC_URI = "https://github.com/karulis/pybluez/archive/master.zip"
SRC_URI[md5sum] = "37733f35ad5a0522b86fe39467481fd1"
SRC_URI[sha256sum] = "8e7e5e4e343da7e0ec2cd37b6dc12ee77da8e4c0863dd8a2d03ab06f9b657238"
S = "${WORKDIR}/PyBluez-${PV}"
inherit distutils
当Bitbake和构建失败时,这会导致大量冲突:

NOTE: Preparing RunQueue
ERROR: Multiple .bb files are due to be built which each provide bluez-hcidump (/home/parallels/yocto/poky/meta/recipes-connectivity/bluez5/bluez5_5.28.bb /home/parallels/yocto/poky/meta/recipes-connectivity/bluez/bluez-hcidump_2.5.bb).
 This usually means one provides something the other doesn't and should.
NOTE: Executing SetScene Tasks
ERROR: The recipe bluez5 is trying to install files into a shared area when those files already exist. Those files and their manifest location are:
   /media/parallels/build/tmp/sysroots/overo/pkgdata/runtime-reverse/libasound-module-bluez
 Matched in manifest-overo-bluez4.packagedata
 /media/parallels/build/tmp/sysroots/overo/pkgdata/runtime/libasound-module-bluez.packaged
 Matched in manifest-overo-bluez4.packagedata
 /media/parallels/build/tmp/sysroots/overo/pkgdata/runtime/libasound-module-bluez
 Matched in manifest-overo-bluez4.packagedata
Please verify which recipe should provide the above files.
The build has stopped as continuing in this scenario WILL break things, if not now, possibly in the future (we've seen builds fail several months later). If the system knew how to recover from this automatically it would however there are several different scenarios which can result in this and we don't know which one this is. It may be you have switched providers of something like virtual/kernel (e.g. from linux-yocto to linux-yocto-dev), in that case you need to execute the clean task for both recipes and it will resolve this error. It may be you changed DISTRO_FEATURES from systemd to udev or vice versa. Cleaning those recipes should again resolve this error however switching DISTRO_FEATURES on an existing build directory is not supported, you should really clean out tmp and rebuild (reusing sstate should be safe). It could be the overlapping files detected are harmless in which case adding them to SSTATE_DUPWHITELIST may be the correct solution. It could also be your build is including two different conflicting versions of things (e.g. bluez 4 and bluez 5 and the correct solution for that would be to resolve the conflict. If in doubt, please ask on the mailing list, sharing the error and filelist above.
ERROR: If the above message is too much, the simpler version is you're advised to wipe out tmp and rebuild (reusing sstate is fine). That will likely fix things in most (but not all) cases.
WARNING: Logfile for failed setscene task is /media/parallels/build/tmp/work/cortexa8hf-vfp-neon-poky-linux-gnueabi/bluez5/5.28-r0/temp/log.do_packagedata_setscene.16687
WARNING: Setscene task 803 (/home/parallels/yocto/poky/meta/recipes-connectivity/bluez5/bluez5_5.28.bb, do_packagedata_setscene) failed with exit code '1' - real task will be run instead
ERROR: The recipe bluez5 is trying to install files into a shared area when those files already exist. Those files and their manifest location are:
   /media/parallels/build/tmp/sysroots/overo/usr/lib/libbluetooth.so
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/lib/libbluetooth.la
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/lib/libbluetooth.so.3
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/lib/pkgconfig/bluez.pc
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/include/bluetooth/sdp.h
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/include/bluetooth/bnep.h
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/include/bluetooth/cmtp.h
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/include/bluetooth/hci.h
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/include/bluetooth/rfcomm.h
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/include/bluetooth/bluetooth.h
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/include/bluetooth/hci_lib.h
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/include/bluetooth/l2cap.h
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/include/bluetooth/sco.h
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/include/bluetooth/hidp.h
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/usr/include/bluetooth/sdp_lib.h
 Matched in manifest-overo-bluez4.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/sysroot-providers/bluez-hcidump
 Matched in manifest-overo-bluez-hcidump.populate_sysroot
 /media/parallels/build/tmp/sysroots/overo/lib/udev/hid2hci
 Matched in manifest-overo-bluez4.populate_sysroot
Please verify which recipe should provide the above files.
The build has stopped as continuing in this scenario WILL break things, if not now, possibly in the future (we've seen builds fail several months later). If the system knew how to recover from this automatically it would however there are several different scenarios which can result in this and we don't know which one this is. It may be you have switched providers of something like virtual/kernel (e.g. from linux-yocto to linux-yocto-dev), in that case you need to execute the clean task for both recipes and it will resolve this error. It may be you changed DISTRO_FEATURES from systemd to udev or vice versa. Cleaning those recipes should again resolve this error however switching DISTRO_FEATURES on an existing build directory is not supported, you should really clean out tmp and rebuild (reusing sstate should be safe). It could be the overlapping files detected are harmless in which case adding them to SSTATE_DUPWHITELIST may be the correct solution. It could also be your build is including two different conflicting versions of things (e.g. bluez 4 and bluez 5 and the correct solution for that would be to resolve the conflict. If in doubt, please ask on the mailing list, sharing the error and filelist above.
ERROR: If the above message is too much, the simpler version is you're advised to wipe out tmp and rebuild (reusing sstate is fine). That will likely fix things in most (but not all) cases.
看起来pybluez依赖于一堆Bluez4配方和库,这些配方和库与Bluez5对应的配方和库冲突。通过强制pybluez使用Bluez5版本来解决这个问题是正确的吗?如果是,应该如何以及在哪里将其指定给Bitbake?如果不是,甚至可以在Yocto Linux系统中将pybluez与Bluez5一起使用吗

看起来pybluez依赖于一大堆Bluez4配方和库

根据您所展示的内容,这是不正确的。您的python pybluez配方只依赖于bluez5(以及python things distutils带来的)。Yocto可以基于链接神奇地将运行时依赖项添加到包中,但在这种情况下,您将收到一条关于可能缺少构建时依赖项的警告

我认为更可能的情况是,您使用的图像已经包含bluez4包(可能是旧的,也可能只是没有更新),而python pybluez在bluez5中拖动会破坏一切


哦,忘了牛肉:您注意到消息的结尾了吗:建议您删除tmp并重新构建(重用sstate很好)——如果您只是删除TMPDIR并重新构建,那么单独构建python-pybluez配方应该继续。如果您的图像确实包含bluez4,那么在创建图像之前您仍然需要处理冲突,谢谢,@jku。你一点也不过分——python pybluez引入了bluez5,但令人惊讶的是bluez4被我的local.conf“DISTRO_FEATURES_append=bluez5”引入到构建中!这对我来说似乎完全是一种扭曲(我运行了一些bitbake-g指令来查看不同附件的依赖性)。与其试图更新这个问题来询问这是如何发生的,我可能只是接受这个问题的答案&询问一个新的问题,关于bluez5指令是如何引入bluez4的……你看过图像配方了吗,也许他们列出了bluez4包?或者你可以链接到包含图像配方的层的repo吗?我很确定,当我在local.conf中附加bluez5时,bluez4只是作为一个依赖项(bitbake-g)出现的-它以前不存在,这就是为什么它如此奇怪的原因。我今天没有机会确认,但会在周一确认!