diff options
author | Brad King <brad.king@kitware.com> | 2019-05-17 13:38:50 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2019-05-17 13:39:48 (GMT) |
commit | 94b2c757725b86a38b7934f9e1084debe6dbe2de (patch) | |
tree | c2f27edb7be045eb43cfb049faee075aa155d059 | |
parent | e1c95bc2788c0c71418a303306a66ff5bad7c938 (diff) | |
parent | 89ab54c11239f4832668ecca6a0b0b9edf112bd8 (diff) | |
download | CMake-94b2c757725b86a38b7934f9e1084debe6dbe2de.zip CMake-94b2c757725b86a38b7934f9e1084debe6dbe2de.tar.gz CMake-94b2c757725b86a38b7934f9e1084debe6dbe2de.tar.bz2 |
Merge topic 'findblas_mklroot_bla_vendor'
89ab54c112 FindBLAS: Choose MKL arch based on BLA_VENDOR
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !3330
-rw-r--r-- | Modules/FindBLAS.cmake | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/Modules/FindBLAS.cmake b/Modules/FindBLAS.cmake index 8d55ac7..65e5d1c 100644 --- a/Modules/FindBLAS.cmake +++ b/Modules/FindBLAS.cmake @@ -403,20 +403,19 @@ if (BLA_VENDOR MATCHES "Intel" OR BLA_VENDOR STREQUAL "All") endif () if (DEFINED ENV{MKLROOT}) - set(_BLAS_MKLROOT_LIB_DIR "$ENV{MKLROOT}") + if (BLA_VENDOR STREQUAL "Intel10_32") + set(_BLAS_MKLROOT_LIB_DIR "$ENV{MKLROOT}/lib/ia32") + elseif (BLA_VENDOR MATCHES "^Intel10_64i?lp$" OR BLA_VENDOR MATCHES "^Intel10_64i?lp_seq$") + set(_BLAS_MKLROOT_LIB_DIR "$ENV{MKLROOT}/lib/intel64") + endif () endif () if (_BLAS_MKLROOT_LIB_DIR) - if( SIZEOF_INTEGER EQUAL 8 ) - set( _BLAS_MKL_PATH_PREFIX "intel64" ) - else() - set( _BLAS_MKL_PATH_PREFIX "ia32" ) - endif() if (WIN32) - string(APPEND _BLAS_MKLROOT_LIB_DIR "/lib/${_BLAS_MKL_PATH_PREFIX}_win") + string(APPEND _BLAS_MKLROOT_LIB_DIR "_win") elseif (APPLE) - string(APPEND _BLAS_MKLROOT_LIB_DIR "/lib/${_BLAS_MKL_PATH_PREFIX}_mac") + string(APPEND _BLAS_MKLROOT_LIB_DIR "_mac") else () - string(APPEND _BLAS_MKLROOT_LIB_DIR "/lib/${_BLAS_MKL_PATH_PREFIX}_lin") + string(APPEND _BLAS_MKLROOT_LIB_DIR "_lin") endif () endif () |