Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE] RP2040 board tree needs CMakeLists.txt files #15770

Open
1 task done
digiexchris opened this issue Feb 5, 2025 · 0 comments
Open
1 task done

[FEATURE] RP2040 board tree needs CMakeLists.txt files #15770

digiexchris opened this issue Feb 5, 2025 · 0 comments
Labels
Type: Enhancement New feature or request

Comments

@digiexchris
Copy link

digiexchris commented Feb 5, 2025

Is your feature request related to a problem? Please describe.

I have a cmake project that is using nuttx as a library (make export) with a CMake c++ project. It would be more convenient for me if I could do out of tree building like the wiki suggests. https://nuttx.apache.org/docs/latest/quickstart/compiling_cmake.html#out-of-tree-building .

This works fine with the board stated in the example, but as there are CMakeLists.txt files missing from the rp2040 and rp2040/ directories, CMake cannot generate a configuration for any RP2040 boards.

I use nuttx-base as a submodule in order to ensure I keep it clean and are able to sync with main quickly so an out of tree build is ideal.

Describe the solution you'd like

With the RP2040 boards becoming popular, and CMake use increasing, please consider providing cmake out-of-tree support for the RP2040 (or at least the basic rp2040/raspberrypi-pico) to enable the CMake out of tree example to work:

cmake -B build -DBOARD_CONFIG=raspberrypi-pico:usbnsh -GNinja

Describe alternatives you've considered

For a reason I don't quite understand, the exported tarball contains target and toolchain cmake files that when I reference them directly in my cmakelists.txt files, I can compile for an RP2040 successfully. This suggests to me that there may already be some measure of CMake generation for those boards in place already, and maybe just need to create matching CMakeLists.txt files from that. This is currently my workaround, but exporting a new export every time I change config options is tiresome during the initial phase where I'm working through config options during the early phases of a project. I'd prefer if I can just build against a normal nuttx dir out of tree like is possible with the stm32f4-disco.

Verification

  • I have verified before submitting the report.
@digiexchris digiexchris added the Type: Enhancement New feature or request label Feb 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant