Application build error with Soft Device Controller

Hi,

I try to use Soft Device Controller (sdc) on my application. I use VS Code, Zephyr and NRF Connect SDK v2.1.2 .

I got error during build. Could please help me on this?

Do you have any example with SDC with using Zephyr and NRF Connect SDK ?

CMakeLists:

# SPDX-License-Identifier: Apache-2.0

cmake_minimum_required(VERSION 3.20.0)
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
project(blinky)

target_sources(app PRIVATE src/main.c dhlib/src/dh_nvs_data.c dhlib/src/data_logger.c dhlib/src/dh_console.c dhlib/src/proj_cmds.c src/proj_common.c  dhlib/src/dh_led_btn.c dhlib/src/dh_adc.c)
include_directories(dhlib/inc src)


set(MYLIB_LIB_DIR     ${CMAKE_CURRENT_SOURCE_DIR}/sdc)
set(MYLIB_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/sdc/include)

add_library(softdevice_controller_multirole_lib STATIC IMPORTED GLOBAL)
add_dependencies(
  softdevice_controller_multirole_lib
  dhlib_project
  )
set_target_properties(softdevice_controller_multirole_lib PROPERTIES IMPORTED_LOCATION             ${MYLIB_LIB_DIR}/libsoftdevice_controller_multirole.a)
set_target_properties(softdevice_controller_multirole_lib PROPERTIES INTERFACE_INCLUDE_DIRECTORIES ${MYLIB_INCLUDE_DIR})

target_link_libraries(app PUBLIC softdevice_controller_multirole_lib)

 conf file:

project folder:

sdc folder(from GitHub):

BUILD LOG:

131/148] Linking C static library modules\nrf\drivers\hw_cc310\lib..__nrf__drivers__hw_cc310.a
[132/148] Linking C static library zephyr\drivers\usb\device\libdrivers__usb__device.a
[133/148] Building C object zephyr/kernel/CMakeFiles/kernel.dir/banner.c.obj
[134/148] Building C object zephyr/kernel/CMakeFiles/kernel.dir/xip.c.obj
[135/148] Building C object zephyr/kernel/CMakeFiles/kernel.dir/kheap.c.obj
[136/148] Linking C static library modules\nrfxlib\nrfxlib\nrf_security\src\zephyr\libmbedtls_zephyr.a
[137/148] Linking C static library zephyr\kernel\libkernel.a
[138/148] Linking C executable zephyr\zephyr_pre0.elf
FAILED: zephyr/zephyr_pre0.elf zephyr/zephyr_pre0.map
cmd.exe /C "cd . && C:\nordic\toolchains\v2.1.2\opt\zephyr-sdk\arm-zephyr-eabi\bin\arm-zephyr-eabi-gcc.exe @CMakeFiles\zephyr_pre0.rsp -o zephyr\zephyr_pre0.elf && cmd.exe /C "cd /D C:\nordic\myapps\impact_device_release\build_52840\zephyr && C:\nordic\toolchains\v2.1.2\opt\bin\cmake.exe -E echo ""
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: error: ../sdc/libsoftdevice_controller_multirole.a(libsoftdevice_controller_s140_debug_hardfp__obfuscated.elf) uses VFP register arguments, zephyr\zephyr_pre0.elf does not
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: failed to merge target specific data of file ../sdc/libsoftdevice_controller_multirole.a(libsoftdevice_controller_s140_debug_hardfp__obfuscated.elf)
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: ../sdc/libsoftdevice_controller_multirole.a(libsoftdevice_controller_s140_debug_hardfp__obfuscated.elf): in function `sdc_enable':
(.text+0x12): undefined reference to `sym_W7ROFHNOSDKPIRUKDGIZZ5YR3MC3DAM2YLJOUIA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: ../sdc/libsoftdevice_controller_multirole.a(libsoftdevice_controller_s140_debug_hardfp__obfuscated.elf): in function `sym_A7PVZLRTORLFMETW3GOBE4DG32WTH46LP2SW5QQ':
(.text+0x30): undefined reference to `sym_VSILKYHVQ5DVF6LG5MG267DQVA3A2XZQ6FSCLXA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: ../sdc/libsoftdevice_controller_multirole.a(libsoftdevice_controller_s140_debug_hardfp__obfuscated.elf): in function `sym_6DYG6C6ROXZA67GZINNB2XIQHL3KE2RCKK4QFXA':
(.text+0x4c): undefined reference to `sym_VSILKYHVQ5DVF6LG5MG267DQVA3A2XZQ6FSCLXA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: ../sdc/libsoftdevice_controller_multirole.a(libsoftdevice_controller_s140_debug_hardfp__obfuscated.elf): in function `sym_4BWYV6G4KVCKUYOBWE3RR7UUW2WCKQUGSW3GHWI':
(.text+0xc): undefined reference to `sym_VSILKYHVQ5DVF6LG5MG267DQVA3A2XZQ6FSCLXA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: ../sdc/libsoftdevice_controller_multirole.a(libsoftdevice_controller_s140_debug_hardfp__obfuscated.elf): in function `sym_62DUXM4M5AM4URNPP7IKDX3NCPAODBT4BMADGAY':
(.text+0xa): undefined reference to `sym_VSILKYHVQ5DVF6LG5MG267DQVA3A2XZQ6FSCLXA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: (.text+0x14): undefined reference to `sym_VSILKYHVQ5DVF6LG5MG267DQVA3A2XZQ6FSCLXA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: ../sdc/libsoftdevice_controller_multirole.a(libsoftdevice_controller_s140_debug_hardfp__obfuscated.elf):(.text+0x16): more undefined references to `sym_VSILKYHVQ5DVF6LG5MG267DQVA3A2XZQ6FSCLXA' follow
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: ../sdc/libsoftdevice_controller_multirole.a(libsoftdevice_controller_s140_debug_hardfp__obfuscated.elf): in function `sym_MJMICEV3AHUJUDNI6JLXYNXCJNL4PTPUQLXISYA':
(.text+0x2): undefined reference to `sym_ETIE3PCEXQYLK2GIVZENQ6V7PLBRV57MB7BDMNY'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: ../sdc/libsoftdevice_controller_multirole.a(libsoftdevice_controller_s140_debug_hardfp__obfuscated.elf): in function `sym_5U52OLHW5BTVCP2BD6UAUWBCBDJG46EBSAKZZ6I':
(.text+0x36): undefined reference to `sym_VSILKYHVQ5DVF6LG5MG267DQVA3A2XZQ6FSCLXA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: ../sdc/libsoftdevice_controller_multirole.a(libsoftdevice_controller_s140_debug_hardfp__obfuscated.elf): in function `sym_RUQBFILZ5CHV2AAL6C3D2J5Y33TCCAPZTHBGZ3A':
(.text+0xa): undefined reference to `sym_VSILKYHVQ5DVF6LG5MG267DQVA3A2XZQ6FSCLXA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: (.text+0x24): undefined reference to `sym_5EMXP3L6SPQSCAJKKRH62ZOKJCCSKLI3WEX2WHY'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: (.text+0x30): undefined reference to `sym_H2QJCU2ORTYAFBAQQ2FHUYIAZO4HCXEKCQ4SS2Q'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: (.text+0x36): undefined reference to `sym_SWIBDSDMHUYNCG5ZWLB52J7NETJIUBPCO5IIQFA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: (.text+0x42): undefined reference to `sym_VSILKYHVQ5DVF6LG5MG267DQVA3A2XZQ6FSCLXA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: (.text+0x4e): undefined reference to `sym_USR4MDT6VMTQLOGKNN4MALBZ3GJPD2KOEY4HFAQ'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: (.text+0x54): undefined reference to `sym_6PVOPWDLWTXOTRZZ7LP36TLYTLPTQHNAUQNFHEA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: (.text+0x60): undefined reference to `sym_VSILKYHVQ5DVF6LG5MG267DQVA3A2XZQ6FSCLXA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: (.text+0x72): undefined reference to `sym_VSILKYHVQ5DVF6LG5MG267DQVA3A2XZQ6FSCLXA'
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: zephyr\zephyr_pre0.elf: hidden symbol `sym_6PVOPWDLWTXOTRZZ7LP36TLYTLPTQHNAUQNFHEA' isn't defined
c:/nordic/toolchains/v2.1.2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/10.3.0/../../../../arm-zephyr-eabi/bin/ld.exe: final link failed: bad value
collect2.exe: error: ld returned 1 exit status
ninja: build stopped: subcommand failed.
FATAL ERROR: command exited with status 1: 'c:\nordic\toolchains\v2.1.2\opt\bin\cmake.EXE' --build 'c:\nordic\myapps\impact_device_release\build_52840'

Related