-
-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert "Always use Stan's eigen fix #4288"
This reverts commit eca71c6.
- Loading branch information
Showing
9 changed files
with
88 additions
and
119 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# - Try to find Eigen3 lib | ||
# | ||
# This module supports requiring a minimum version, e.g. you can do | ||
# find_package(Eigen3 3.1.2) | ||
# to require version 3.1.2 or newer of Eigen3. | ||
# | ||
# Once done this will define | ||
# | ||
# EIGEN_FOUND - system has eigen lib with correct version | ||
# EIGEN_INCLUDE_DIR - the eigen include directory | ||
# EIGEN_VERSION - eigen version | ||
|
||
# Copyright (c) 2006, 2007 Montel Laurent, <montel@kde.org> | ||
# Copyright (c) 2008, 2009 Gael Guennebaud, <g.gael@free.fr> | ||
# Copyright (c) 2009 Benoit Jacob <jacob.benoit.1@gmail.com> | ||
# Redistribution and use is allowed according to the terms of the 2-clause BSD license. | ||
|
||
macro(_eigen3_get_version) | ||
file(READ "${EIGEN_INCLUDE_DIR}/Eigen/src/Core/util/Macros.h" _eigen3_version_header) | ||
|
||
string(REGEX MATCH "define[ \t]+EIGEN_WORLD_VERSION[ \t]+([0-9]+)" _eigen3_world_version_match "${_eigen3_version_header}") | ||
set(EIGEN_WORLD_VERSION "${CMAKE_MATCH_1}") | ||
string(REGEX MATCH "define[ \t]+EIGEN_MAJOR_VERSION[ \t]+([0-9]+)" _eigen3_major_version_match "${_eigen3_version_header}") | ||
set(EIGEN_MAJOR_VERSION "${CMAKE_MATCH_1}") | ||
string(REGEX MATCH "define[ \t]+EIGEN_MINOR_VERSION[ \t]+([0-9]+)" _eigen3_minor_version_match "${_eigen3_version_header}") | ||
set(EIGEN_MINOR_VERSION "${CMAKE_MATCH_1}") | ||
|
||
set(EIGEN_VERSION ${EIGEN_WORLD_VERSION}.${EIGEN_MAJOR_VERSION}.${EIGEN_MINOR_VERSION}) | ||
|
||
endmacro(_eigen3_get_version) | ||
|
||
find_path(EIGEN_INCLUDE_DIR NAMES signature_of_eigen3_matrix_library | ||
PATHS | ||
${CMAKE_INSTALL_PREFIX}/include | ||
PATH_SUFFIXES eigen3 eigen | ||
) | ||
|
||
if(EIGEN_INCLUDE_DIR) | ||
_eigen3_get_version() | ||
endif(EIGEN_INCLUDE_DIR) | ||
|
||
include(FindPackageHandleStandardArgs) | ||
find_package_handle_standard_args (Eigen3 REQUIRED_VARS EIGEN_INCLUDE_DIR VERSION_VAR EIGEN_VERSION) | ||
|
||
mark_as_advanced(EIGEN_INCLUDE_DIR) | ||
SET(EIGEN_INCLUDE_DIRS ${EIGEN_INCLUDE_DIR} CACHE PATH "The Eigen include path.") | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
set(EIGEN_INCLUDE_DIR ${THIRD_PARTY_INCLUDE_DIR}/eigen) | ||
set(EIGEN_VERSION 3.3.4) | ||
include(ExternalProject) | ||
ExternalProject_Add( | ||
Eigen3 | ||
PREFIX ${CMAKE_BINARY_DIR}/Eigen3 | ||
DOWNLOAD_DIR ${THIRD_PARTY_DIR}/Eigen3 | ||
URL https://bitbucket.org/eigen/eigen/get/${EIGEN_VERSION}.tar.bz2 | ||
URL_MD5 a7aab9f758249b86c93221ad417fbe18 | ||
CMAKE_ARGS -DINCLUDE_INSTALL_DIR:STRING=${EIGEN_INCLUDE_DIR} | ||
-DCMAKE_C_FLAGS:STRING=${CMAKE_C_FLAGS}${CMAKE_DEFINITIONS} | ||
-DCMAKE_CXX_FLAGS:STRING=${CMAKE_CXX_FLAGS}${CMAKE_DEFINITIONS} | ||
-DCMAKE_C_COMPILER:STRING=${CMAKE_C_COMPILER} | ||
-DCMAKE_CXX_COMPILER:STRING=${CMAKE_CXX_COMPILER} | ||
-DCMAKE_BUILD_TYPE:STRING=Release | ||
-DEIGEN_BUILD_PKGCONFIG=0 | ||
) | ||
|
||
add_dependencies(libshogun Eigen3) | ||
|
||
UNSET(C_COMPILER) | ||
UNSET(CXX_COMPILER) |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.