diff --git a/CMakeLists.txt b/CMakeLists.txt index cd141c12dea..3f54336dd3e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1127,8 +1127,6 @@ elseif(DEFINED BOARD_LINKER_SCRIPT) set(LINKER_SCRIPT ${BOARD_LINKER_SCRIPT}) elseif(DEFINED SOC_LINKER_SCRIPT) set(LINKER_SCRIPT ${SOC_LINKER_SCRIPT}) -else() - find_package(Deprecated COMPONENTS SEARCHED_LINKER_SCRIPT) endif() if(NOT EXISTS ${LINKER_SCRIPT}) diff --git a/cmake/compiler/gcc/target.cmake b/cmake/compiler/gcc/target.cmake index bca99be1692..2e90f00f659 100644 --- a/cmake/compiler/gcc/target.cmake +++ b/cmake/compiler/gcc/target.cmake @@ -5,7 +5,6 @@ set_ifndef(C++ g++) # Configures CMake for using GCC, this script is re-used by several # GCC-based toolchains -find_package(Deprecated COMPONENTS SPARSE) find_program(CMAKE_C_COMPILER ${CROSS_COMPILE}${CC} PATHS ${TOOLCHAIN_HOME} NO_DEFAULT_PATH) if(${CMAKE_C_COMPILER} STREQUAL CMAKE_C_COMPILER-NOTFOUND) diff --git a/cmake/modules/FindDeprecated.cmake b/cmake/modules/FindDeprecated.cmake index 8030c759531..23357760034 100644 --- a/cmake/modules/FindDeprecated.cmake +++ b/cmake/modules/FindDeprecated.cmake @@ -37,58 +37,6 @@ if("${Deprecated_FIND_COMPONENTS}" STREQUAL "") message(WARNING "find_package(Deprecated) missing required COMPONENTS keyword") endif() -if("CROSS_COMPILE" IN_LIST Deprecated_FIND_COMPONENTS) - list(REMOVE_ITEM Deprecated_FIND_COMPONENTS CROSS_COMPILE) - # This code was deprecated after Zephyr v3.1.0 - if(NOT DEFINED ZEPHYR_TOOLCHAIN_VARIANT) - set(ZEPHYR_TOOLCHAIN_VARIANT $ENV{ZEPHYR_TOOLCHAIN_VARIANT}) - endif() - - if(NOT ZEPHYR_TOOLCHAIN_VARIANT AND - (CROSS_COMPILE OR (DEFINED ENV{CROSS_COMPILE}))) - set(ZEPHYR_TOOLCHAIN_VARIANT cross-compile CACHE STRING "Zephyr toolchain variant" FORCE) - message(DEPRECATION "Setting CROSS_COMPILE without setting ZEPHYR_TOOLCHAIN_VARIANT is deprecated." - "Please set ZEPHYR_TOOLCHAIN_VARIANT to 'cross-compile'" - ) - endif() -endif() - -if("SPARSE" IN_LIST Deprecated_FIND_COMPONENTS) - list(REMOVE_ITEM Deprecated_FIND_COMPONENTS SPARSE) - # This code was deprecated after Zephyr v3.2.0 - if(SPARSE) - message(DEPRECATION - "Setting SPARSE='${SPARSE}' is deprecated. " - "Please set ZEPHYR_SCA_VARIANT to 'sparse'" - ) - if("${SPARSE}" STREQUAL "y") - set_ifndef(ZEPHYR_SCA_VARIANT sparse) - endif() - endif() -endif() - -if("SOURCES" IN_LIST Deprecated_FIND_COMPONENTS) - list(REMOVE_ITEM Deprecated_FIND_COMPONENTS SOURCES) - if(SOURCES) - message(DEPRECATION - "Setting SOURCES prior to calling find_package() for unit tests is deprecated." - " To add sources after find_package() use:\n" - " target_sources(testbinary PRIVATE )") - endif() -endif() - -if("PYTHON_PREFER" IN_LIST Deprecated_FIND_COMPONENTS) - # This code was deprecated after Zephyr v3.4.0 - list(REMOVE_ITEM Deprecated_FIND_COMPONENTS PYTHON_PREFER) - if(DEFINED PYTHON_PREFER) - message(DEPRECATION "'PYTHON_PREFER' variable is deprecated. Please use " - "Python3_EXECUTABLE instead.") - if(NOT DEFINED Python3_EXECUTABLE) - set(Python3_EXECUTABLE ${PYTHON_PREFER}) - endif() - endif() -endif() - if("toolchain_ld_base" IN_LIST Deprecated_FIND_COMPONENTS) # This code was deprecated after Zephyr v4.0.0 list(REMOVE_ITEM Deprecated_FIND_COMPONENTS toolchain_ld_base) @@ -142,23 +90,5 @@ if(NOT "${Deprecated_FIND_COMPONENTS}" STREQUAL "") "${Deprecated_FIND_COMPONENTS}") endif() -if("SEARCHED_LINKER_SCRIPT" IN_LIST Deprecated_FIND_COMPONENTS) - # This code was deprecated after Zephyr v3.5.0 - list(REMOVE_ITEM Deprecated_FIND_COMPONENTS SEARCHED_LINKER_SCRIPT) - - # Try a board specific linker file - set(LINKER_SCRIPT ${BOARD_DIR}/linker.ld) - if(NOT EXISTS ${LINKER_SCRIPT}) - # If not available, try an SoC specific linker file - set(LINKER_SCRIPT ${SOC_FULL_DIR}/linker.ld) - endif() - message(DEPRECATION - "Pre-defined `linker.ld` script is deprecated. Please set " - "BOARD_LINKER_SCRIPT or SOC_LINKER_SCRIPT to point to ${LINKER_SCRIPT} " - "or one of the Zephyr provided common linker scripts for the ${ARCH} " - "architecture." - ) -endif() - set(Deprecated_FOUND True) set(DEPRECATED_FOUND True) diff --git a/cmake/modules/FindHostTools.cmake b/cmake/modules/FindHostTools.cmake index f0954a26b75..a73d52956aa 100644 --- a/cmake/modules/FindHostTools.cmake +++ b/cmake/modules/FindHostTools.cmake @@ -48,8 +48,6 @@ if(HostTools_FOUND) return() endif() -find_package(Deprecated COMPONENTS CROSS_COMPILE) - find_package(Zephyr-sdk 0.16) # gperf is an optional dependency diff --git a/cmake/modules/python.cmake b/cmake/modules/python.cmake index ffebec7d5c2..e01d3192120 100644 --- a/cmake/modules/python.cmake +++ b/cmake/modules/python.cmake @@ -13,8 +13,6 @@ endif() set(PYTHON_MINIMUM_REQUIRED 3.10) -find_package(Deprecated COMPONENTS PYTHON_PREFER) - if(NOT DEFINED Python3_EXECUTABLE AND DEFINED WEST_PYTHON) set(Python3_EXECUTABLE "${WEST_PYTHON}") endif() diff --git a/cmake/modules/unittest.cmake b/cmake/modules/unittest.cmake index e33d072fc48..4c80283aa0e 100644 --- a/cmake/modules/unittest.cmake +++ b/cmake/modules/unittest.cmake @@ -44,8 +44,6 @@ if((NOT DEFINED ZEPHYR_BASE) AND (DEFINED ENV_ZEPHYR_BASE)) set(ZEPHYR_BASE ${ENV_ZEPHYR_BASE} CACHE PATH "Zephyr base") endif() -find_package(Deprecated COMPONENTS SOURCES) - if(NOT SOURCES AND EXISTS main.c) set(SOURCES main.c) endif()