diff options
author | Seth R Johnson <johnsonsr@ornl.gov> | 2021-07-14 01:27:52 (GMT) |
---|---|---|
committer | Seth R Johnson <johnsonsr@ornl.gov> | 2021-07-14 15:00:20 (GMT) |
commit | 76487b04b152b2dc6abc258b21306f58c57a3e80 (patch) | |
tree | 099be044f1c6393aa1c1e718cda225650caa3bdc /Modules/FindBLAS.cmake | |
parent | fc54e68c053436c22c4c17a3c265f59974852179 (diff) | |
download | CMake-76487b04b152b2dc6abc258b21306f58c57a3e80.zip CMake-76487b04b152b2dc6abc258b21306f58c57a3e80.tar.gz CMake-76487b04b152b2dc6abc258b21306f58c57a3e80.tar.bz2 |
Find{BLAS,LAPACK}: clean variables
Diffstat (limited to 'Modules/FindBLAS.cmake')
-rw-r--r-- | Modules/FindBLAS.cmake | 35 |
1 files changed, 19 insertions, 16 deletions
diff --git a/Modules/FindBLAS.cmake b/Modules/FindBLAS.cmake index a6fd2c9..0898240 100644 --- a/Modules/FindBLAS.cmake +++ b/Modules/FindBLAS.cmake @@ -441,7 +441,7 @@ if(BLA_VENDOR MATCHES "Intel" OR BLA_VENDOR STREQUAL "All") if(BLA_F95) set(BLAS_mkl_SEARCH_SYMBOL "sgemm_f95") - set(_LIBRARIES BLAS95_LIBRARIES) + set(_BLAS_LIBRARIES BLAS95_LIBRARIES) if(WIN32) # Find the main file (32-bit or 64-bit) set(BLAS_SEARCH_LIBS_WIN_MAIN "") @@ -503,7 +503,7 @@ if(BLA_VENDOR MATCHES "Intel" OR BLA_VENDOR STREQUAL "All") endif() else() set(BLAS_mkl_SEARCH_SYMBOL sgemm) - set(_LIBRARIES BLAS_LIBRARIES) + set(_BLAS_LIBRARIES BLAS_LIBRARIES) if(WIN32) # Find the main file (32-bit or 64-bit) set(BLAS_SEARCH_LIBS_WIN_MAIN "") @@ -615,15 +615,15 @@ if(BLA_VENDOR MATCHES "Intel" OR BLA_VENDOR STREQUAL "All") "lib/${BLAS_mkl_ARCH_NAME}" ) - foreach(IT ${BLAS_SEARCH_LIBS}) - string(REPLACE " " ";" SEARCH_LIBS ${IT}) - if(NOT ${_LIBRARIES}) + foreach(_search ${BLAS_SEARCH_LIBS}) + string(REPLACE " " ";" _search ${_search}) + if(NOT ${_BLAS_LIBRARIES}) check_blas_libraries( - ${_LIBRARIES} + ${_BLAS_LIBRARIES} BLAS ${BLAS_mkl_SEARCH_SYMBOL} "" - "${SEARCH_LIBS}" + "${_search}" "${CMAKE_THREAD_LIBS_INIT};${BLAS_mkl_LM};${BLAS_mkl_LDL}" "${BLAS_mkl_MKLROOT}" "${BLAS_mkl_LIB_PATH_SUFFIXES}" @@ -631,6 +631,7 @@ if(BLA_VENDOR MATCHES "Intel" OR BLA_VENDOR STREQUAL "All") endif() endforeach() + unset(_search) unset(BLAS_mkl_ILP_MODE) unset(BLAS_mkl_INTFACE) unset(BLAS_mkl_THREADING) @@ -736,14 +737,14 @@ if(BLA_VENDOR MATCHES "Arm" OR BLA_VENDOR STREQUAL "All") # Check for 64bit Integer support if(BLA_VENDOR MATCHES "_ilp64") - set(BLAS_armpl_LIB "armpl_ilp64") + set(_blas_armpl_lib "armpl_ilp64") else() - set(BLAS_armpl_LIB "armpl_lp64") + set(_blas_armpl_lib "armpl_lp64") endif() # Check for OpenMP support, VIA BLA_VENDOR of Arm_mp or Arm_ipl64_mp if(BLA_VENDOR MATCHES "_mp") - set(BLAS_armpl_LIB "${BLAS_armpl_LIB}_mp") + set(_blas_armpl_lib "${_blas_armpl_lib}_mp") endif() if(NOT BLAS_LIBRARIES) @@ -752,13 +753,13 @@ if(BLA_VENDOR MATCHES "Arm" OR BLA_VENDOR STREQUAL "All") BLAS sgemm "" - "${BLAS_armpl_LIB}" + "${_blas_armpl_lib}" "" "" "" ) endif() - + set(_blas_armpl_lib) endif() # FLAME's blis library? (https://github.com/flame/blis) @@ -1089,11 +1090,11 @@ endif() # Elbrus Math Library? if(BLA_VENDOR MATCHES "EML" OR BLA_VENDOR STREQUAL "All") - set(BLAS_EML_LIB "eml") + set(_blas_eml_lib "eml") # Check for OpenMP support, VIA BLA_VENDOR of eml_mt if(BLA_VENDOR MATCHES "_mt") - set(BLAS_EML_LIB "${BLAS_EML_LIB}_mt") + set(_blas_eml_lib "${BLAS_EML_LIB}_mt") endif() if(NOT BLAS_LIBRARIES) @@ -1102,13 +1103,13 @@ if(BLA_VENDOR MATCHES "EML" OR BLA_VENDOR STREQUAL "All") BLAS sgemm "" - "${BLAS_EML_LIB}" + "${_blas_eml_lib}" "" "" "" ) endif() - + set(_blas_eml_lib) endif() # Fujitsu SSL2 Library? @@ -1165,3 +1166,5 @@ if(NOT BLA_F95) endif() _add_blas_target() +unset(_blas_fphsa_req_var) +unset(_BLAS_LIBRARIES) |