mirror of
https://github.com/meshcore-dev/MeshCore.git
synced 2026-04-20 22:13:47 +00:00
Fix build on Pico W
Use `lib_ldf_mode=chain+` so the LDF evaluates preprocessor conditions when scanning for library dependencies. Without this, the LDF (in default 'deep' mode) ignores it to find #include <BLEDevice.h> inside the #ifdef ESP32 block in esp32/BLELogInterface.h, pulling in the Arduino-Pico BLE library. That library only compiles correctly when PIO_FRAMEWORK_ARDUINO_ENABLE_BLUETOOTH is set (which enables the required BTstack defines), so without that flag the build fails. chain+ prevents this by honouring the #ifdef ESP32 guard.
This commit is contained in:
parent
382a5403b7
commit
d8e838fe4d
3 changed files with 23 additions and 2 deletions
|
|
@ -26,6 +26,15 @@ build_src_filter = ${rp2040_base.build_src_filter}
|
|||
+<PicoWBoard.cpp>
|
||||
+<../variants/rpi_picow>
|
||||
lib_deps = ${rp2040_base.lib_deps}
|
||||
; Use chain+ so the LDF evaluates preprocessor conditions when scanning for
|
||||
; library dependencies. Without this, the LDF (in default 'deep' mode) ignores
|
||||
; #ifdef guards and follows all #include directives unconditionally. That causes
|
||||
; it to find #include <BLEDevice.h> inside the #ifdef ESP32 block in
|
||||
; esp32/BLELogInterface.h, pulling in the Arduino-Pico BLE library. That
|
||||
; library only compiles correctly when PIO_FRAMEWORK_ARDUINO_ENABLE_BLUETOOTH is
|
||||
; set (which enables the required BTstack defines), so without that flag the
|
||||
; build fails. chain+ prevents this by honouring the #ifdef ESP32 guard.
|
||||
lib_ldf_mode = chain+
|
||||
|
||||
[env:PicoW_repeater]
|
||||
extends = rpi_picow
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue