ARC: MWDT: cleanup search path handling
Cleanup ARC MWDT search path handling: * Don't print warning if ARCMWDT_TOOLCHAIN_PATH is missing but METAWARE_ROOT is set. Treat it as valid case and do message with status level instead of warning. * Make rest of the error messages more understandable for users. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Evgeniy Paltsev <PaltsevEvgeniy@gmail.com>
This commit is contained in:
parent
b9d46b5483
commit
c75bf5ebc5
1 changed files with 5 additions and 5 deletions
|
|
@ -2,17 +2,17 @@
|
|||
|
||||
zephyr_get(ARCMWDT_TOOLCHAIN_PATH)
|
||||
|
||||
if(NOT DEFINED ARCMWDT_TOOLCHAIN_PATH AND DEFINED ENV{METAWARE_ROOT})
|
||||
message(WARNING "ARCMWDT_TOOLCHAIN_PATH is not set, use default toolchain from METAWARE_ROOT")
|
||||
set(METAWARE_ROOT $ENV{METAWARE_ROOT})
|
||||
set(METAWARE_ROOT $ENV{METAWARE_ROOT})
|
||||
if(NOT DEFINED ARCMWDT_TOOLCHAIN_PATH AND DEFINED METAWARE_ROOT)
|
||||
message(STATUS "ARCMWDT_TOOLCHAIN_PATH is not set, use default toolchain from METAWARE_ROOT: '${METAWARE_ROOT}'")
|
||||
if(NOT EXISTS ${METAWARE_ROOT})
|
||||
message(FATAL_ERROR "Nothing found at METAWARE_ROOT: '${METAWARE_ROOT}'")
|
||||
endif()
|
||||
cmake_path(GET METAWARE_ROOT PARENT_PATH ARCMWDT_TOOLCHAIN_PATH)
|
||||
elseif(NOT DEFINED ARCMWDT_TOOLCHAIN_PATH AND NOT DEFINED METAWARE_ROOT)
|
||||
message(FATAL_ERROR "No MWDT toolchain specified: neither ARCMWDT_TOOLCHAIN_PATH nor METAWARE_ROOT defined")
|
||||
endif()
|
||||
|
||||
assert(ARCMWDT_TOOLCHAIN_PATH "ARCMWDT_TOOLCHAIN_PATH is not set")
|
||||
|
||||
if(NOT EXISTS ${ARCMWDT_TOOLCHAIN_PATH})
|
||||
message(FATAL_ERROR "Nothing found at ARCMWDT_TOOLCHAIN_PATH: '${ARCMWDT_TOOLCHAIN_PATH}'")
|
||||
endif()
|
||||
|
|
|
|||
Loading…
Reference in a new issue