交叉编译 yocto 的物联网堆栈时出错,调试启用" cannot find -lgcov"



我在运行之后获得的这些日志" scons target_os = yocto target_ark = i586 target_transport = ble tc_prefix = i586-poky-linux-linux-linux- tc_path =/opt/poky-ed/poky-edison/poky-edison/opt/poky-edison/1.6/sysroots/x86_64-pokysdk-linux/usr/bin/i586-poky-linux版本= 0"

scons: done reading SConscript files.
scons: Building targets ...
scons: building associated VariantDir targets: out/yocto/i586/debug
Linking out/yocto/i586/debug/service/resource-encapsulation/src/common/librcs_common.so
/opt/poky-edison/1.6/sysroots/x86_64-pokysdk-linux/usr/libexec/i586-poky-linux/gcc/i586-poky-linux/4.8.2/ld: cannot find -lgcov
collect2: error: ld returned 1 exit status
scons: *** [out/yocto/i586/debug/service/resource-encapsulation/src/common/librcs_common.so] Error 1
scons: building terminated because of errors.

->这似乎是一个链接错误,因此我尝试安装GCOVR和LCOV。我仍然遇到同样的错误,因此任何人都面临或解决了此问题,请帮助我。

在调试模式下与GCOV链接(reparess = 0)是新的,也许它将其进入Yocto构建的方式可能存在错误。跨构建故事中有孔,提交错误将有助于跟踪事物(https://jira.iotivity.org)。您安装的两个PKG对此没有影响,它们是工具,投诉是关于缺少图书馆的 - 您在跨构建环境(Sysroot)中是否有libgcov?在我的系统上,我看到了两个地方:

/usr/lib/gcc/x86_64-redhat-linux/7/libgcov.a
/usr/lib/gcc/arm-none-eabi/7.1.0/libgcov.a  + target-specific variants

后者并未用于IOTIVE,而是在使用跨工具链中显示了一个安装。前者来自PKG GCC-7.1.1-3.fc26.x86_64,后者来自PKG ARM-NONE-NONE-NONE-EABI-AEBI-GCC-CS-7.1.0.0-2.fc26.x86.x86_64。

您是否沿Bitbake构建?如果是,则应该在Poky上使用,除非您使用需要几个相关GCOV的clang。

https://gerrit.iotivity.org/gerrit/#/c/18437/

无论如何,带有yocto标签的错误报告

最新更新