platform-ststm32
platform-ststm32 copied to clipboard
PlatformIO does not properly generate mbed_config.h
Check out the platformio https://github.com/faydr/QMesh.git . If you attempt to build it using platformio run, it fails, outputting errors such as these:
Compiling .pio/build/nucleo_h743zi/FrameworkMbeddrivers/source/BusInOut.o Compiling .pio/build/nucleo_h743zi/FrameworkMbeddrivers/source/BusOut.o Compiling .pio/build/nucleo_h743zi/FrameworkMbeddrivers/source/CAN.o /home/drfay/.platformio/packages/framework-mbed/features/storage/system_storage/SystemStorage.cpp:96:9: error: 'MBED_CONF_SPIF_DRIVER_SPI_CLK' was not declared in this scope; did you mean 'MBED_CONF_DRIVERS_QSPI_CSN'? 96 | MBED_CONF_SPIF_DRIVER_SPI_CLK, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | MBED_CONF_DRIVERS_QSPI_CSN /home/drfay/.platformio/packages/framework-mbed/features/storage/system_storage/SystemStorage.cpp:97:9: error: 'MBED_CONF_SPIF_DRIVER_SPI_CS' was not declared in this scope; did you mean 'MBED_CONF_DRIVERS_QSPI_CSN'? 97 | MBED_CONF_SPIF_DRIVER_SPI_CS, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ | MBED_CONF_DRIVERS_QSPI_CSN Compiling .pio/build/nucleo_h743zi/FrameworkMbeddrivers/source/DigitalIn.o /home/drfay/.platformio/packages/framework-mbed/features/storage/system_storage/SystemStorage.cpp:98:9: error: 'MBED_CONF_SPIF_DRIVER_SPI_FREQ' was not declared in this scope 98 | MBED_CONF_SPIF_DRIVER_SPI_FREQ | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Compiling .pio/build/nucleo_h743zi/FrameworkMbeddrivers/source/DigitalInOut.o *** [.pio/build/nucleo_h743zi/FrameworkMbedfeatures/storage/system_storage/SystemStorage.o] Error 1
Comparing the mbed_config.h produced by the mbed compile command with the mbed_config.h produced by platformio run, it appears that platformio is not generating all of the defines that the mbed toolchain generates.