infrastructure: Remove hwmv1 support
Removes support for the deprecated hardware model version 1 Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
This commit is contained in:
parent
4bb5ffd786
commit
9f12f8afb2
23 changed files with 132 additions and 388 deletions
|
@ -11,48 +11,30 @@ unset(_SOC_IS_IN_TREE)
|
|||
|
||||
add_subdirectory(common)
|
||||
|
||||
if(HWMv1)
|
||||
message(DEPRECATION "
|
||||
---------------------------------------------------------------------
|
||||
--- WARNING: Functionality to describe SoCs in HWMv1 is ---
|
||||
--- deprecated and should be replaced with HWMv2, including ---
|
||||
--- boards. HWMv1 SoCs support remains only to ease the migration ---
|
||||
--- of out-of-tree SoCs and associated boards. It will not be ---
|
||||
--- possible to build using HWMv1 SoCs at all in future releases. ---
|
||||
---------------------------------------------------------------------"
|
||||
)
|
||||
# Below is inclusion of HWMv2 SoC CMake lists.
|
||||
string(TOUPPER SOC_FAMILY_${SOC_FAMILY}_DIR family_setting_dir)
|
||||
string(TOUPPER SOC_SERIES_${SOC_SERIES}_DIR series_setting_dir)
|
||||
string(TOUPPER SOC_${SOC_NAME}_DIR soc_setting_dir)
|
||||
|
||||
if(EXISTS ${SOC_DIR}/${ARCH}/CMakeLists.txt)
|
||||
add_subdirectory(${SOC_DIR}/${ARCH} soc/${ARCH})
|
||||
else()
|
||||
add_subdirectory(${SOC_DIR}/${ARCH}/${SOC_PATH} soc/${ARCH}/${SOC_PATH})
|
||||
endif()
|
||||
elseif(HWMv2)
|
||||
# Below is inclusion of HWMv2 SoC CMake lists.
|
||||
string(TOUPPER SOC_FAMILY_${SOC_FAMILY}_DIR family_setting_dir)
|
||||
string(TOUPPER SOC_SERIES_${SOC_SERIES}_DIR series_setting_dir)
|
||||
string(TOUPPER SOC_${SOC_NAME}_DIR soc_setting_dir)
|
||||
|
||||
if(DEFINED ${soc_setting_dir})
|
||||
add_subdirectory(${${soc_setting_dir}} soc/${SOC_NAME})
|
||||
elseif(DEFINED ${series_setting_dir})
|
||||
add_subdirectory(${${series_setting_dir}} soc/${SOC_SERIES})
|
||||
elseif(DEFINED ${family_setting_dir})
|
||||
add_subdirectory(${${family_setting_dir}} soc/${SOC_FAMILY})
|
||||
else()
|
||||
message(FATAL_ERROR "No CMakeLists.txt file found for SoC: ${SOC_NAME}, "
|
||||
"series: ${SOC_SERIES}, family: ${SOC_FAMILY}")
|
||||
endif()
|
||||
|
||||
# Include all SoC roots except Zephyr, as we are already in the Zephyr SoC root.
|
||||
set(local_soc_root ${SOC_ROOT})
|
||||
list(REMOVE_ITEM local_soc_root ${ZEPHYR_BASE})
|
||||
foreach(root ${local_soc_root})
|
||||
cmake_path(GET root FILENAME name)
|
||||
# A SoC root for HWMv1 may not contain a CMakeLists.txt file on this so
|
||||
# let's check for existence before including.
|
||||
if(EXISTS ${root}/soc/CMakeLists.txt)
|
||||
add_subdirectory(${root}/soc soc/${name})
|
||||
endif()
|
||||
endforeach()
|
||||
if(DEFINED ${soc_setting_dir})
|
||||
add_subdirectory(${${soc_setting_dir}} soc/${SOC_NAME})
|
||||
elseif(DEFINED ${series_setting_dir})
|
||||
add_subdirectory(${${series_setting_dir}} soc/${SOC_SERIES})
|
||||
elseif(DEFINED ${family_setting_dir})
|
||||
add_subdirectory(${${family_setting_dir}} soc/${SOC_FAMILY})
|
||||
else()
|
||||
message(FATAL_ERROR "No CMakeLists.txt file found for SoC: ${SOC_NAME}, "
|
||||
"series: ${SOC_SERIES}, family: ${SOC_FAMILY}")
|
||||
endif()
|
||||
|
||||
# Include all SoC roots except Zephyr, as we are already in the Zephyr SoC root.
|
||||
set(local_soc_root ${SOC_ROOT})
|
||||
list(REMOVE_ITEM local_soc_root ${ZEPHYR_BASE})
|
||||
foreach(root ${local_soc_root})
|
||||
cmake_path(GET root FILENAME name)
|
||||
# A SoC root for HWMv1 may not contain a CMakeLists.txt file on this so
|
||||
# let's check for existence before including.
|
||||
if(EXISTS ${root}/soc/CMakeLists.txt)
|
||||
add_subdirectory(${root}/soc soc/${name})
|
||||
endif()
|
||||
endforeach()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue