diff options
author | Brad King <brad.king@kitware.com> | 2019-12-13 15:36:29 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2019-12-13 15:36:35 (GMT) |
commit | e3059f7bb48cf7435af26033868ada5030e18615 (patch) | |
tree | 1199bafbba44dcc6264c92598a8108589d895a6a | |
parent | c55b4b4b24dcb8ff1234a4386112fed467f1c3f5 (diff) | |
parent | d1e111d166891dea7653f49acb13b2262242758e (diff) | |
download | CMake-e3059f7bb48cf7435af26033868ada5030e18615.zip CMake-e3059f7bb48cf7435af26033868ada5030e18615.tar.gz CMake-e3059f7bb48cf7435af26033868ada5030e18615.tar.bz2 |
Merge topic 'FindBLAS-OpenBLAS-thread' into release-3.16
d1e111d166 FindBLAS: Consider OpenBLAS with thread libraries only with C or CXX
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4134
-rw-r--r-- | Modules/FindBLAS.cmake | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Modules/FindBLAS.cmake b/Modules/FindBLAS.cmake index 77f9d0e..d3acafc 100644 --- a/Modules/FindBLAS.cmake +++ b/Modules/FindBLAS.cmake @@ -481,8 +481,12 @@ if (BLA_VENDOR STREQUAL "OpenBLAS" OR BLA_VENDOR STREQUAL "All") "" ) endif() - if(NOT BLAS_LIBRARIES) - find_package(Threads) + if(NOT BLAS_LIBRARIES AND (CMAKE_C_COMPILER_LOADED OR CMAKE_CXX_COMPILER_LOADED)) + if(BLAS_FIND_QUIETLY OR NOT BLAS_FIND_REQUIRED) + find_package(Threads) + else() + find_package(Threads REQUIRED) + endif() # OpenBLAS (http://www.openblas.net) check_fortran_libraries( BLAS_LIBRARIES |