gpt4 book ai didi

linux - Yocto:bitbake 退出代码困惑

转载 作者:塔克拉玛干 更新时间:2023-11-03 00:07:48 25 4
gpt4 key购买 nike

我在使用 Yocto 构建图像时遇到错误(头晕):

ERROR: Creation of tar /mnt/workspace/build/tmp/deploy/tar/xev-dbg-1.2.1-r0.tar.gz failed.

bitbake 命令失败并显示以下报告:

No currently running tasks (6291 of 6292)
NOTE: Tasks Summary: Attempted 6292 tasks of which 18 didn't need to be rerun and all succeeded.
Summary: There were 13 WARNING messages shown.
Summary: There were 3 ERROR messages shown, returning a non-zero exit code.

如果我检查文件 xev-dbg-1.2.1-r0.tar.gz,我得到:

$ file  /mnt/workspace/build/tmp/deploy/tar/xev-dbg-1.2.1-r0.tar.gz
/mnt/workspace/build/tmp/deploy/tar/xev-dbg-1.2.1-r0.tar.gz: gzip compressed data, from Unix, last modified: Mon Mar 27 20:19:55 201

其余两个错误同理。

我很困惑:

  • 如果出现错误,为什么 bitbake 报告所有任务都已成功?

  • 如果文件创建成功,为什么 bitbake 以非零值退出?

最佳答案

Bitbake 没有返回 0 退出代码。这意味着 bitbake 过程中存在错误。

如图所示,尝试创建 tar 文件时出现 3 个错误。压缩文件在那里,但不完整。例如。就像您如何下载文件并中断它并且下载文件仍然存在一样。所以我们通常使用 md5sum 或某种哈希值来检查文件的完整性。

更好的理解可能是:Bitbake 试图运行 6292 任务。其中 18 个不需要重新运行。 Bitbake 尝试重新运行其余的 6274(6292-18) 并成功重新运行它们。这并不意味着它们都已成功编译。在重新运行它们的过程中,出现了 13 个警告和 3 个错误。由于 3 个错误,bitbake 返回非零退出代码。

No currently running tasks (6291 of 6292)
NOTE: Tasks Summary: Attempted 6292 tasks of which 18 didn't need to be rerun and all succeeded.
Summary: There were 13 WARNING messages shown.
Summary: There were 3 ERROR messages shown, returning a non-zero exit code.

关于linux - Yocto:bitbake 退出代码困惑,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43063159/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com