diff --git a/cmake/addOpenBLAS.cmake b/cmake/addOpenBLAS.cmake
index 9795a6a98..978589eff 100644
--- a/cmake/addOpenBLAS.cmake
+++ b/cmake/addOpenBLAS.cmake
@@ -1,43 +1,46 @@
-# This program is a part of EASIFEM library
-# Copyright (C) 2020-2021 Vikas Sharma, Ph.D
+# This program is a part of EASIFEM library Copyright (C) 2020-2021 Vikas
+# Sharma, Ph.D
#
-# This program is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
+# This program is free software: you can redistribute it and/or modify it under
+# the terms of the GNU General Public License as published by the Free Software
+# Foundation, either version 3 of the License, or (at your option) any later
+# version.
#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
+# This program is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+# FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+# details.
#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see
+# You should have received a copy of the GNU General Public License along with
+# this program. If not, see
#
-IF( ${PROJECT_NAME} MATCHES "easifemBase" )
- #SET(BLA_VENDOR "OpenBLAS")
- FIND_PACKAGE( LAPACK REQUIRED )
- IF( LAPACK_FOUND )
- MESSAGE(STATUS "FOUND LAPACK")
- ENDIF()
- IF( BLA_VENDOR MATCHES "MKL" )
- MESSAGE(STATUS "BLA_VENDOR : MKL")
- LIST( APPEND TARGET_COMPILE_DEF "-DUSE_INTEL_MKL" )
- ELSEIF( BLA_VENDOR MATCHES "OpenBLAS" )
- MESSAGE(STATUS "BLA_VENDOR : OpenBLAS")
- LIST( APPEND TARGET_COMPILE_DEF "-DUSE_OpenBLAS" )
- ELSE( )
- MESSAGE(STATUS "BLA_VENDOR : ${BLA_VENDOR}")
- MESSAGE(STATUS "BLA_VENDOR : System provided")
- LIST( APPEND TARGET_COMPILE_DEF "-DUSE_NativeBLAS" )
+if(${PROJECT_NAME} MATCHES "easifemBase")
+ # SET(BLA_VENDOR "OpenBLAS")
+ find_package(LAPACK REQUIRED)
+ if(LAPACK_FOUND)
+ message(STATUS "FOUND LAPACK")
+ endif()
+ if(BLA_VENDOR MATCHES "MKL")
+ message(STATUS "BLA_VENDOR : MKL")
+ list(APPEND TARGET_COMPILE_DEF "-DUSE_INTEL_MKL")
+ elseif(BLA_VENDOR MATCHES "OpenBLAS")
+ message(STATUS "BLA_VENDOR : OpenBLAS")
+ list(APPEND TARGET_COMPILE_DEF "-DUSE_OpenBLAS")
+ else()
+ message(STATUS "BLA_VENDOR : ${BLA_VENDOR}")
+ message(STATUS "BLA_VENDOR : System provided")
+ list(APPEND TARGET_COMPILE_DEF "-DUSE_NativeBLAS")
- IF(APPLE)
- LIST( APPEND TARGET_COMPILE_DEF "-DUSE_APPLE_NativeBLAS" )
- ENDIF()
+ if(APPLE)
+ list(APPEND TARGET_COMPILE_DEF "-DUSE_APPLE_NativeBLAS")
+ endif()
- ENDIF( )
- TARGET_LINK_LIBRARIES(
- ${PROJECT_NAME} PUBLIC ${LAPACK_LIBRARIES} ${BLAS_LIBRARIES}
- )
-ENDIF()
+ endif()
+
+ message(STATUS "BLAS_LIBRARIES: ${BLAS_LIBRARIES}")
+ message(STATUS "LAPACK_LIBRARIES: ${LAPACK_LIBRARIES}")
+
+ target_link_libraries(${PROJECT_NAME} PUBLIC ${LAPACK_LIBRARIES}
+ ${BLAS_LIBRARIES})
+endif()