RT-Thread / RT-Thread/rt-thread

[Bug] RP2040/Pico build error

Open
#9,278 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
12.2k
Forks
5.4k
Avg merge
4d 12h
Merged PRs (30d)
40

Description

RT-Thread Version

5.1.0

Hardware Type/Architectures

pico

Develop Toolchain

GCC

Describe the bug

How to Reproduce:

直接构建即可复现

cd bsp/raspberry-pico
pkgs --update
scons -c
scons

Error Message:

In file included from packages\raspberrypi-pico-sdk-latest\src\rp2_common\pico_bootrom\include/pico/bootrom.h:10,
                 from board\board.c:16:
packages\raspberrypi-pico-sdk-latest\src\common\pico_base\include/pico.h:25:10: fatal error: pico/version.h: No such file or directory
   25 | #include "pico/version.h"
      |          ^~~~~~~~~~~~~~~~
compilation terminated.
scons: *** [build\board\board.o] Error 1
scons: building terminated because of errors.

Note

  1. 本机配置:windows 11 并装有 cmake
  2. 该问题在PICO的bsp更新的PR#8117后出现,讨论中CI报错与该报错一致。相关的PR是这两个#8117和 #8121。

该错误疑似缺少pico-sdk生成的若干文件,PR作者尝试使用脚本修复 #8121,并合并后到软件包仓库地址里,对应PR。添加了对应的generate_headers.py等文件。但在我本机使用scons构建时没有生成对应文件。

Other additional context

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in bsp/raspberry-pico and reproduce with pkgs --update, scons -c, and scons. Read the raspberrypi-pico-sdk-latest package and its generate_headers.py, along with the related PRs #8117 and #8121. Done means the required pico/version.h file is generated and the Pico build completes successfully.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, cmake
Domain
build-system, embedded-iot
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.