Skip to content
Permalink
Browse files

cmake: check ZEPHYR_SDK_INSTALL_DIR is set

Check for ZEPHYR_SDK_INSTALL_DIR being invalid instead of
checking for SDK_VERSION being not defined. This change
relates to commit bb09c45 ("cmake: Prevent infinite
recursion").

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
  • Loading branch information...
cvinayak authored and nashif committed Jul 3, 2019
1 parent f81176a commit a1e25b91ff358275eaaefabd355068339050cced
Showing with 2 additions and 2 deletions.
  1. +2 −2 cmake/toolchain/zephyr/generic.cmake
@@ -1,7 +1,7 @@
# SPDX-License-Identifier: Apache-2.0

if(NOT DEFINED SDK_VERSION)
message(FATAL_ERROR "SDK_VERSION must be set")
if (NOT ZEPHYR_SDK_INSTALL_DIR)
message(FATAL_ERROR "ZEPHYR_SDK_INSTALL_DIR must be set")
endif()

include(${ZEPHYR_BASE}/cmake/toolchain/zephyr/${SDK_VERSION}/generic.cmake)

0 comments on commit a1e25b9

Please sign in to comment.
You can’t perform that action at this time.