zephyr CMakefile: Set HAL version based on Kconfig

Select the HAL variant macros based on the
provisional Zephyr board kconfig options.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
This commit is contained in:
Alberto Escolar Piedras 2023-09-12 13:54:34 +02:00
parent 4404106985
commit 8316930e41
1 changed files with 10 additions and 4 deletions

View File

@ -40,12 +40,18 @@ if(CONFIG_SOC_SERIES_BSIM_NRFXX)
elseif(CONFIG_SOC_SERIES_BSIM_NRF53X)
file(STRINGS make_inc/5340_hw_files HW_MODEL_SRCS)
file(STRINGS make_inc/5340_hal_files HAL_SRCS)
# Pending definitions in Zephyr side for app and net core targets as well as of support
# for multi core native simulator based targets, by now we build the HAL as for the network core
set(VARIANT_FLAGS
if(CONFIG_BOARD_NRF53_BSIM_CPUNET)
set(VARIANT_FLAGS
-DNRF5340_XXAA_NETWORK
-DNRF5340
)
)
elseif(CONFIG_BOARD_NRF53_BSIM_CPUAPP)
set(VARIANT_FLAGS
-DNRF5340_XXAA_APPLICATION
-DNRF5340
)
endif()
endif()
# The nrfx HAL is built in the context of the embedded software