When I enable dmesg from the systemcmds tab of boardconfig, and then try to build make px4_sitl_default, I get the following error:
PX4-Autopilot/src/systemcmds/dmesg/dmesg.cpp:40:2: error: #error "This module can only be used on boards that enable BOARD_ENABLE_CONSOLE_BUFFER"
40 | #error "This module can only be used on boards that enable BOARD_ENABLE_CONSOLE_BUFFER"
| ^~~~~
compilation terminated due to -Wfatal-errors.
[750/1000] Building CXX object src/...ation__gz_bridge.dir/GZBridge.cpp.o
ninja: build stopped: subcommand failed.
make: *** [Makefile:227: px4_sitl] Error 1
ChatGPT suggesting me to add #define BOARD_ENABLE_CONSOLE_BUFFER to the boards/px4/sitl/src/board_config.h file. But that leads to some undefined variable errors.
I really need dmesg to debug some of my custom modules. Am I doing this wrong? What is the correct way to enable dmesg in px4_sitl?