PlatformIO unable to find the board ID native_posix

Hi,

I am working on compiling zephyr based custom application on native platform. Following is the content of platformio.ini

[env:native_posix]
platform = native
framework = zephyr
board = native_posix
test_build_project_src = true

I am getting this Error: Unknown board ID ‘native_posix’. However, native_posix is listed in boards but PIO is not able to recognize it, zephyr/boards/posix at main · zephyrproject-rtos/zephyr · GitHub

Is it because the PIO does not support any board for native platform as mentioned on this link, PlatformIO Registry

How to fix this error?
Is there any way to make PIO to recognize native_posix board?

This platform does not recognize any board = ... value since it has no boards/ folder (GitHub - platformio/platform-native: Native: development platform for PlatformIO). Further it does not support any framework = .. value because it has none implemented. The platform is intended for natively compiling only the sources in a project’s src/ and lib/ folder.

I see you’ve also opened an issue about this in PlatformIO unable to find the board ID native_posix · Issue #16 · platformio/platform-native · GitHub without linking it here. This is however already a duplicate of Feature Request: Zephyr + native_posix board · Issue #14 · platformio/platform-native · GitHub.

1 Like

Thanks @maxgerhardt
I will post the link of this page on github issue.