From 34d02f94b59330724317554dc7613362cef1a766 Mon Sep 17 00:00:00 2001 From: Luo Tao Date: Thu, 9 Nov 2017 20:58:09 +0800 Subject: [PATCH] RollBACK the openblas.cmake --- cmake/external/openblas.cmake | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cmake/external/openblas.cmake b/cmake/external/openblas.cmake index 06ca85820d..42ffd6cf34 100644 --- a/cmake/external/openblas.cmake +++ b/cmake/external/openblas.cmake @@ -115,7 +115,11 @@ INCLUDE_DIRECTORIES(${CBLAS_INC_DIR}) # linear algebra libraries for cc_library(xxx SRCS xxx.c DEPS cblas) SET(dummyfile ${CMAKE_CURRENT_BINARY_DIR}/cblas_dummy.c) FILE(WRITE ${dummyfile} "const char * dummy = \"${dummyfile}\";") -ADD_LIBRARY(cblas STATIC ${dummyfile}) +IF(${CBLAS_PROVIDER} EQUAL MKLML) + ADD_LIBRARY(cblas SHARED ${dummyfile}) +ELSE() + ADD_LIBRARY(cblas STATIC ${dummyfile}) +ENDIF() TARGET_LINK_LIBRARIES(cblas ${CBLAS_LIBRARIES}) IF(NOT ${CBLAS_FOUND}) -- GitLab