Description
The pico_btstack
library CMakeLists.txt
hard-codes all of the btstack
source files. This means that it's tightly coupled to a specific btstack
version.
This is causing problems for my project, picow_ds4
(see usedbytes/picow_ds4#1) which submodules btstack
in order to support Playstation 4 controllers (which have HID descriptors which are too big for the upstream default) - and uses PICO_BTSTACK_PATH
to use that submoduled version. pico-sdk
has updated its btstack
, I have not, so now my project doesn't build with an updated pico-sdk
.
Having all of the source files listed in a CMakeLists.txt
which lives inside pico-sdk
seems like a layering violation - it's effectively an unmanaged dependency to a specific version of btstack
, which is somewhat fragile.
You're welcome to argue that the submodule provides the versioning :-) - if you have the same version of btstack
as what's submoduled in to pico-sdk
then there's no issue. However it does make it basically impossible for projects to use PICO_BTSTACK_PATH
unless they also submodule pico-sdk
, which I'd like to avoid if possible.
I wonder if it would be better to have the pico_btstack
build done within btstack
itself, as a port, rather than managed by the pico-sdk
build directly?
Related to #1379 / #1380 which is the specific PR which caused the particular breakage in usedbytes/picow_ds4#1