内核头文件选择不正确:预期为 4.9.x,使用 BR 2022.02 和 menuconfig 中的 bootlin 工具链得到 4.6.x

发布于 2025-01-16 04:15:39 字数 920 浏览 3 评论 0原文

我想尝试 buildroot 中的 bootlin 工具链支持,因为现在我可以简单地在 menuconfig 中选择它们。

  • BR 版本:分支 2022.02
  • Defconfig:atmel_sama5d3_xplained_defconfig
  • 工具链:`工具链 ->工具链(Bootlin 工具链)”
    • “Bootlin 工具链变体”:armv7-eabihf glibc stable 2021.11-1

在干净的 git checkout 上,通过 menuconfig 加载并修改上述 defconfig 后,构建停止:

Incorrect selection of kernel headers: expected 4.9.x, got 4.6.x

预期(由帮助程序脚本 gen-bootlin-toolchains 自动生成)似乎没问题,因为 发布公告还提到了稳定工具链版本的 4.9。

知道这里出了什么问题吗?或者 buildroot 如何计算“got”版本? (除了标记文件和文件列表文件之外,我在 output/build/toolchain-external-bootlin-2021.11-1 中没有看到任何下载的文件)

如果我手动下载文件并检查arm-buildroot-linux-gnueabihf/sysroot/usr/include/linux/version.h,版本确实是4.9


我可以手动下载工具链并手动指定参数,但是然后bootlin 集成(这很好)没有意义。

I wanted to try out the bootlin toolchain support in buildroot, because now I can simply select them in menuconfig.

  • BR version: branch 2022.02
  • Defconfig: atmel_sama5d3_xplained_defconfig
  • Toolchain: `Toolchain -> Toolchain (Bootlin toolchains)"
    • "Bootlin toolchain variant": armv7-eabihf glibc stable 2021.11-1

On a clean git checkout, after loading and modifying the above defconfig via menuconfig, the build stops with:

Incorrect selection of kernel headers: expected 4.9.x, got 4.6.x

The expectation (autogenerated by helper script gen-bootlin-toolchains) seems to be ok, because the release announcement also mentions 4.9 for stable toolchain versions.

Any idea what goes wrong here? Or how buildroot calculates the "got" version? (I don't see any downloaded files in output/build/toolchain-external-bootlin-2021.11-1 other then the stamp files and the file-list files)

If I download the file manually and check arm-buildroot-linux-gnueabihf/sysroot/usr/include/linux/version.h, the version is indeed 4.9


I could just manually download the toolchain and specify the parameters manually, but then the bootlin integration (which is nice) doesn't make sense.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

街道布景 2025-01-23 04:15:39

这种不匹配的根本原因是 buildroot 不会自动下载 bootlin 工具链,但在 PATH 中预计为 arm-linux-gcc。我的 PATH 中有 arm-linux-gcc 但链接到另一个工具链。

手动安装(下载+解压)bootlin工具链并将工具链的“bin”文件夹添加到buildroot运行环境的PATH中后,构建按预期成功。

The root cause for this mis-match was that the bootlin toolchain won't be downloaded by buildroot automatically, but is expected in the PATH as arm-linux-gcc. I did have arm-linux-gcc in my PATH but linked to another toolchain.

After manually installing (download+extract) the bootlin toolchain and adding the "bin" folder of the toolchain to the PATH of the environment in which buildroot was run, the build succeeded as expected.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文