cannot build zephyr bluetooth tests in nrf-sdk

Following the installation guide for the latest nrf-connect sdk (v2.5.2) I am unable to run the zephyr bsim unit tests for the bluetooth mesh stack

#!/bin/bash
export BSIM_OUT_PATH=$HOME/dev/nrf-connect-sdk/tools/bsim/
export BSIM_COMPONENTS_PATH=${BSIM_OUT_PATH}/components

export WORK_DIR=${ZEPHYR_BASE}/bsim_out
export RESULTS_FILE=${ZEPHYR_BASE}/myresults.xml
export SEARCH_PATH=${ZEPHYR_BASE}/tests/bsim/bluetooth/mesh

${ZEPHYR_BASE}/tests/bsim/bluetooth/mesh/compile.sh

I am following the Readme on how to run these tests

- github.com/.../README.md

I have built and installed babblesim and set the correct paths. It fails with a linking error.

/usr/bin/ld.bfd: cannot find -lSOFTDEVICE_CONTROLLER_LIB_DIR-NOTFOUND/libsoftdevice_controller_multirole.a: No such file or directory
/usr/bin/ld.bfd: cannot find -lMPSL_LIB_DIR-NOTFOUND/libmpsl.a: No such file or directory
collect2: error: ld returned 1 exit status
ninja: build stopped: subcommand failed.

If I do the same thing from the standard zephyr repo (v3.5) it works without issue. So I don't think its something with my setup? 

Parents
  • Hi pquevedo, 

    It seems that the compiler couldn't find the binary libraries: libsoftdevice_controller_multirole.a , libmpsl.a. 
    You can find  libsoftdevice_controller_multirole.a in \nrfxlib\softdevice_controller\lib\cortex-m4
    And libmpsl.a in \nrfxlib\mpsl\lib\cortex-m4. 
    YOu would need to select the library folder that match with your chip floating point configuration. Then you include in the project configuration the CONFIG_SOFTDEVICE_CONTROLLER_LIB_DIR and CONFIG_MPSL_LIB_DIR that point to the right folder. 


    The reason you don't have an issue with Zephyr controller is that Zephyr controller doesn't use MPSL or Softdevice controller library. 

Reply
  • Hi pquevedo, 

    It seems that the compiler couldn't find the binary libraries: libsoftdevice_controller_multirole.a , libmpsl.a. 
    You can find  libsoftdevice_controller_multirole.a in \nrfxlib\softdevice_controller\lib\cortex-m4
    And libmpsl.a in \nrfxlib\mpsl\lib\cortex-m4. 
    YOu would need to select the library folder that match with your chip floating point configuration. Then you include in the project configuration the CONFIG_SOFTDEVICE_CONTROLLER_LIB_DIR and CONFIG_MPSL_LIB_DIR that point to the right folder. 


    The reason you don't have an issue with Zephyr controller is that Zephyr controller doesn't use MPSL or Softdevice controller library. 

Children
Related