@@ -13,57 +13,11 @@ if (NOT DEFINED ENV{BSIM_OUT_PATH})
1313 https://babblesim.github.io/folder_structure_and_env.html" )
1414endif ()
1515
16- #Let's check that the HW models are the needed version or newer
17- #That is, that the needed tag is somewhere in the past of its branch
18- if (NOT DEFINED ENV{NO_NRF52_BSIM_VERSION_WARNING})
19- if (GIT_FOUND) #boilerplate.cmake searches for git
20- file (STRINGS "hw_models_version" NRF52_HW_MODELS_TAG) #desired version
21- execute_process (COMMAND ${GIT_EXECUTABLE} merge-base --is-ancestor
22- ${NRF52_HW_MODELS_TAG} HEAD
23- WORKING_DIRECTORY $ENV{BSIM_COMPONENTS_PATH} /ext_NRF52_hw_models/
24- OUTPUT_VARIABLE NRF52_HW_MODELS_TAG_FOUND
25- OUTPUT_STRIP_TRAILING_WHITESPACE
26- ERROR_STRIP_TRAILING_WHITESPACE
27- ERROR_VARIABLE stderr
28- RESULT_VARIABLE return_code
29- )
30- if (return_code)
31- message (WARNING "The NRF52 HW models are out of date\
32- (${NRF52_HW_MODELS_TAG} needed at least); Please update them or expect\
33- problems!\n Reported error while trying to find the tag: \" ${stderr} \" " )
34-
35- #let's print the latest actual tag for the available models:
36- execute_process (COMMAND ${GIT_EXECUTABLE} describe --tags
37- WORKING_DIRECTORY $ENV{BSIM_COMPONENTS_PATH} /ext_NRF52_hw_models/
38- OUTPUT_VARIABLE NRF52_HW_MODELS_TAG_FOUND
39- OUTPUT_STRIP_TRAILING_WHITESPACE
40- ERROR_STRIP_TRAILING_WHITESPACE
41- ERROR_VARIABLE stderr
42- RESULT_VARIABLE return_code
43- )
44- message (STATUS "Found NRF52 models version ${NRF52_HW_MODELS_TAG_FOUND} " )
45-
46- message (FATAL_ERROR "To disable this check set the environment variable\
47- NO_NRF52_BSIM_VERSION_WARNING" )
48-
49- elseif (CMAKE_VERBOSE_MAKEFILE )
50- message (STATUS "nrf52_bsim: git merge-base --is-ancestor\
51- ${NRF52_HW_MODELS_TAG} HEAD,
52- stdout: ${NRF52_HW_MODELS_TAG_FOUND}
53- stderr: ${stderr} " )
54- endif ()
55- endif ()
56- endif ()
57-
5816zephyr_library()
5917zephyr_library_compile_definitions(NO_POSIX_CHEATS)
6018
6119zephyr_include_directories(
6220 fake
63- $ENV{BSIM_COMPONENTS_PATH} /ext_NRF52_hw_models/src/
64- $ENV{BSIM_COMPONENTS_PATH} /ext_NRF52_hw_models/src/nrfx/hal/
65- $ENV{BSIM_COMPONENTS_PATH} /ext_NRF52_hw_models/src/nrfx/
66- $ENV{BSIM_COMPONENTS_PATH} /ext_NRF52_hw_models/src/HW_models/
6721)
6822
6923#Due to the BLE controller assumption about enum size
@@ -85,8 +39,6 @@ zephyr_library_include_directories(
8539 fake
8640 $ENV{BSIM_COMPONENTS_PATH} /libUtilv1/src/
8741 $ENV{BSIM_COMPONENTS_PATH} /libPhyComv1/src/
88- $ENV{BSIM_COMPONENTS_PATH} /ext_NRF52_hw_models/src/HW_models/
89- $ENV{BSIM_COMPONENTS_PATH} /ext_NRF52_hw_models/src/nrfx_hal/
9042 $ENV{BSIM_COMPONENTS_PATH} /libRandv2/src/
9143 ${ZEPHYR_BASE} /kernel/include
9244 ${ZEPHYR_BASE} /arch/posix/include
@@ -101,7 +53,6 @@ zephyr_library_import(bsim_libUtilv1 ${libpath}/libUtilv1.32.a)
10153zephyr_library_import(bsim_libPhyComv1 ${libpath} /libPhyComv1.32.a)
10254zephyr_library_import(bsim_lib2G4PhyComv1 ${libpath} /lib2G4PhyComv1.32.a)
10355zephyr_library_import(bsim_libRandv2 ${libpath} /libRandv2.32.a)
104- zephyr_library_import(bsim_libNRF52_hw ${libpath} /libNRF52_hw_models.32.a)
10556
10657# This is due to some tests using _Static_assert which is a 2011 feature, but
10758# otherwise relying on compilers supporting it also when set to C99.
0 commit comments