Set BLAS_openblas_LIBRARY instead of LIBRARIES

Signed-off-by: Omar Shrit <omar@shrit.me>
This commit is contained in:
Omar Shrit
2021-05-04 00:32:43 +02:00
parent aa989db797
commit ea5a69f4d1
+3 -3
View File
@@ -7,7 +7,7 @@
if (CMAKE_CROSSCOMPILING)
include(board/flags-config.cmake)
if(NOT CMAKE_SYSROOT AND (NOT TOOLCHAIN_PREFIX))
if (NOT CMAKE_SYSROOT AND (NOT TOOLCHAIN_PREFIX))
message(FATAL_ERROR "Neither of CMAKE_SYSROOT or TOOLCHAIN_PREFIX is set, please set both of them and try again")
elseif(NOT CMAKE_SYSROOT)
message(FATAL_ERROR "Can not proceed CMAKE_SYSROOT is not set")
@@ -21,7 +21,7 @@ endif()
macro(search_openblas version)
set(BLA_STATIC ON)
find_package(BLAS)
if(NOT BLAS_FOUND OR (NOT BLAS_LIBRARIES))
if (NOT BLAS_FOUND OR (NOT BLAS_LIBRARIES))
get_deps(https://github.com/xianyi/OpenBLAS/releases/download/v${version}/OpenBLAS-${version}.tar.gz OpenBLAS OpenBLAS-${version}.tar.gz)
if (NOT MSVC)
if (NOT EXISTS "${CMAKE_BINARY_DIR}/deps/OpenBLAS-${version}/libopenblas.a")
@@ -30,7 +30,7 @@ macro(search_openblas version)
endif()
file(GLOB OPENBLAS_LIBRARIES "${CMAKE_BINARY_DIR}/deps/OpenBLAS-${version}/libopenblas.a")
set(BLAS_LIBRARIES ${OPENBLAS_LIBRARIES})
set(BLAS_openblas_LIBRARIES ${OPENBLAS_LIBRARIES})
set(BLAS_openblas_LIBRARY ${OPENBLAS_LIBRARIES})
message(STATUS "SHOW BLAS libraries: ${BLAS_LIBRARIES}")
set(BLA_VENDOR OpenBLAS)
set(BLAS_FOUND ON)