Commit bada2a32 authored by Mathieu Faverge's avatar Mathieu Faverge
Browse files

Make sure we do not unset LAPACKE_MT in case of multiple calls to lapacke

parent c5c49994
...@@ -203,6 +203,10 @@ if( LAPACKE_FIND_COMPONENTS ) ...@@ -203,6 +203,10 @@ if( LAPACKE_FIND_COMPONENTS )
endforeach() endforeach()
endif() endif()
if (DEFINED LAPACKE_MT )
set( LAPACKE_MT_internal ${LAPACKE_MT} )
endif()
# LAPACKE may depend on TMG (which depends on lapack), try to find it # LAPACKE may depend on TMG (which depends on lapack), try to find it
if (LAPACKE_WITH_TMG) if (LAPACKE_WITH_TMG)
if (DEFINED LAPACKE_MT) if (DEFINED LAPACKE_MT)
...@@ -217,7 +221,7 @@ if (LAPACKE_WITH_TMG) ...@@ -217,7 +221,7 @@ if (LAPACKE_WITH_TMG)
# Lapacke depends only on TMG, which itself depends on the correct # Lapacke depends only on TMG, which itself depends on the correct
# lapack. No need to look for the MT/SEQ one anymore # lapack. No need to look for the MT/SEQ one anymore
set( LAPACKE_dep TMG ) set( LAPACKE_dep TMG )
unset(LAPACKE_MT) unset( LAPACKE_MT_internal )
else() else()
# LAPACKE depends on LAPACK, try to find it # LAPACKE depends on LAPACK, try to find it
...@@ -230,8 +234,8 @@ else() ...@@ -230,8 +234,8 @@ else()
set( LAPACKE_dep LAPACK ) set( LAPACKE_dep LAPACK )
endif() endif()
if(DEFINED LAPACKE_MT) if(DEFINED LAPACKE_MT_internal)
if (LAPACKE_MT) if (LAPACKE_MT_internal)
lapacke_init_variables("${LAPACKE_dep}_MT") lapacke_init_variables("${LAPACKE_dep}_MT")
else() else()
lapacke_init_variables("${LAPACKE_dep}_SEQ") lapacke_init_variables("${LAPACKE_dep}_SEQ")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment