mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
Add support for Apple's Accelerate sparse matrix solvers
This commit is contained in:
committed by
Rasmus Munk Larsen
parent
008ff3483a
commit
3a9d404d76
@@ -134,6 +134,17 @@ else()
|
||||
ei_add_property(EIGEN_MISSING_BACKENDS "SPQR, ")
|
||||
endif()
|
||||
|
||||
find_package(Accelerate)
|
||||
if(Accelerate_FOUND)
|
||||
add_definitions("-DEIGEN_ACCELERATE_SUPPORT")
|
||||
include_directories(${Accelerate_INCLUDES})
|
||||
set(SPARSE_LIBS ${SPARSE_LIBS} ${Accelerate_LIBRARIES})
|
||||
set(Accelerate_ALL_LIBS ${Accelerate_LIBRARIES})
|
||||
ei_add_property(EIGEN_TESTED_BACKENDS "Accelerate, ")
|
||||
else()
|
||||
ei_add_property(EIGEN_MISSING_BACKENDS "Accelerate, ")
|
||||
endif()
|
||||
|
||||
option(EIGEN_TEST_NOQT "Disable Qt support in unit tests" OFF)
|
||||
if(NOT EIGEN_TEST_NOQT)
|
||||
find_package(Qt4)
|
||||
@@ -344,6 +355,10 @@ if(METIS_FOUND)
|
||||
ei_add_test(metis_support "" "${METIS_LIBRARIES}")
|
||||
endif()
|
||||
|
||||
if(Accelerate_FOUND)
|
||||
ei_add_test(accelerate_support "" "${Accelerate_ALL_LIBS}")
|
||||
endif()
|
||||
|
||||
string(TOLOWER "${CMAKE_CXX_COMPILER}" cmake_cxx_compiler_tolower)
|
||||
if(cmake_cxx_compiler_tolower MATCHES "qcc")
|
||||
set(CXX_IS_QCC "ON")
|
||||
|
||||
Reference in New Issue
Block a user