pico-sdk icon indicating copy to clipboard operation
pico-sdk copied to clipboard

Fix unexpected (CMake) behavior with PICO_BOARD variable.

Open tjko opened this issue 2 years ago • 4 comments

Changing PICO_BOARD value from "pico_w" to "pico" did not unset PICO_CYW43_SUPPORTED variable. Which could lead CYW43 driver included in builds for "pico". (See issue https://github.com/raspberrypi/pico-sdk/issues/1046)

Instructions: (please delete)

  • please do not submit against master, use develop instead
  • please make sure there is an associated issue for your PR, and reference it via "Fixes #num" in the description
  • please enter a detailed description

tjko avatar Oct 06 '22 01:10 tjko

  • please do not submit against master, use develop instead

lurch avatar Oct 06 '22 09:10 lurch

Does this actually work as expected; I would think you need FORCE on the set commands

kilograham avatar Oct 06 '22 14:10 kilograham

I see the value changing in CMakeCache.txt. It does seem contradict the cmake documentation though

peterharperuk avatar Oct 06 '22 15:10 peterharperuk

I'm not really familiar with CMake so not sure if this is "correct" way to fix the issue. But it definitely fixed the issue I was having...

tjko avatar Oct 06 '22 17:10 tjko

I updated the fix to have the PICO_CYW43_SUPPORTED not be a cache variable

kilograham avatar Oct 16 '22 21:10 kilograham