diff options
author | Brad King <brad.king@kitware.com> | 2019-06-17 12:03:29 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2019-06-17 12:03:29 (GMT) |
commit | dad271e8b7eec9ce781bccb9e7e7c9ed4f55003c (patch) | |
tree | e619d59ecc1866b5c3a8f2976c5ddf903043621d /Modules | |
parent | 3d8216330da76bac8267d64d4940af0b05e502a9 (diff) | |
parent | 276b56f01c757ef0fc8b08d2a55422c59b3f007c (diff) | |
download | CMake-dad271e8b7eec9ce781bccb9e7e7c9ed4f55003c.zip CMake-dad271e8b7eec9ce781bccb9e7e7c9ed4f55003c.tar.gz CMake-dad271e8b7eec9ce781bccb9e7e7c9ed4f55003c.tar.bz2 |
Merge branch 'FindBLAS-OpenBLAS-thread' into release-3.15
Merge-request: !3434
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/FindBLAS.cmake | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/Modules/FindBLAS.cmake b/Modules/FindBLAS.cmake index 65e5d1c..77f9d0e 100644 --- a/Modules/FindBLAS.cmake +++ b/Modules/FindBLAS.cmake @@ -152,7 +152,9 @@ macro(Check_Fortran_Libraries LIBRARIES _prefix _name _flags _list _thread) foreach(_library ${_list}) set(_combined_name ${_combined_name}_${_library}) - + if(NOT "${_thread}" STREQUAL "") + set(_combined_name ${_combined_name}_thread) + endif() if(_libraries_work) if (BLA_STATIC) if (WIN32) @@ -479,6 +481,18 @@ if (BLA_VENDOR STREQUAL "OpenBLAS" OR BLA_VENDOR STREQUAL "All") "" ) endif() + if(NOT BLAS_LIBRARIES) + find_package(Threads) + # OpenBLAS (http://www.openblas.net) + check_fortran_libraries( + BLAS_LIBRARIES + BLAS + sgemm + "" + "openblas" + "${CMAKE_THREAD_LIBS_INIT}" + ) + endif() endif () if (BLA_VENDOR STREQUAL "FLAME" OR BLA_VENDOR STREQUAL "All") |