I'm currently in the process of migrating an existing codebase from ESP-IDF 4.4.6 to ESP-IDF 5.4.2. I've followed the migration guides as set out on the Programming Guide.
I'm not able to compile the code currently, the linker is returning errors for undefined references to the following symbols:
ble_store_config_csfcs
ble_store_config_persist_csfcs
ble_store_config_rpa_recs
These all appear to be defined inside preprocessor #if statements, evaluated by the MYNEWT_VAL() macro each with a different macro as its argument:
BLE_STORE_MAX_CSFCS
BLE_STORE_CONFIG_PERSIST
BLE_STORE_MAX_BONDS
I cannot find where these macros are defined anywhere in the sourcecode, and so I presume each of the #if statements is evaluated as 0 and the definition of the symbols is skipped.
Neither can I find reference to these in any documentation, and googling has yielded no clues.
Are BLE_STORE_MAX_CSFCS etc set as parameters in a config somewhere? How do I set these values so that the preprocessor defines the symbols that the linker cannot find?
I've attached the CMake build log and the terminal output.
Thanks!
linker error to unknown references in NimBLE source code
linker error to unknown references in NimBLE source code
- Attachments
-
- CMakeOutput.txt
- (77.75 KiB) Downloaded 22 times
-
- build_log.txt
- (50.36 KiB) Downloaded 13 times
Re: linker error to unknown references in NimBLE source code
These are configurable from menuconfig. They have some default predefined values ( i.e. it is not 0 )
Re: linker error to unknown references in NimBLE source code
Thanks for your response!These are configurable from menuconfig. They have some default predefined values ( i.e. it is not 0 )
When I use the jump to symbol tool in the menuconfig editor, it returns "no results" for BLE_STORE_MAX_CSFCS, BLE_STORE_CONFIG_PERSIST, or BLE_STORE_MAX_BONDS.
Is it possible that I have to add them in? Or are they stored under a different macro in menuconfig?
Thanks!
Re: linker error to unknown references in NimBLE source code
BLE_STORE_MAX_CSFCS and BLE_STORE_MAX_BONDS : Both are driven by menu config macro: BT_NIMBLE_MAX_BONDSWhen I use the jump to symbol tool in the menuconfig editor, it returns "no results" for BLE_STORE_MAX_CSFCS, BLE_STORE_CONFIG_PERSIST, or BLE_STORE_MAX_BONDS.
BLE_STORE_CONFIG_PERSIST : Driven by menuconfig macro: BT_NIMBLE_NVS_PERSIST
Re: linker error to unknown references in NimBLE source code
BT_NIMBLE_MAX_BONDS had been changed to 0, so setting that to 1 has fixed the issue and I can compile the code now.BLE_STORE_MAX_CSFCS and BLE_STORE_MAX_BONDS : Both are driven by menu config macro: BT_NIMBLE_MAX_BONDS
BLE_STORE_CONFIG_PERSIST : Driven by menuconfig macro: BT_NIMBLE_NVS_PERSIST
Thanks for your help!
Who is online
Users browsing this forum: Baidu [Spider], Bing [Bot], Qwantbot and 10 guests
