Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove exact eigen requirement #23

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions recipe/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,13 @@ package:
source:
url: http://ceres-solver.org/ceres-solver-{{ version }}.tar.gz
sha256: 10298a1d75ca884aa0507d1abb0e0f04800a92871cd400d4c361b56a777a7603
patches:
- remove-exact-eigen-requirement.patch

build:
number: 4
number: 5
run_exports:
- {{ pin_subpackage('ceres-solver', max_pin='x.x') }}
- {{ pin_compatible('eigen', max_pin='x.x.x') }}

requirements:
build:
Expand Down
22 changes: 22 additions & 0 deletions recipe/remove-exact-eigen-requirement.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
diff --git a/cmake/CeresConfig.cmake.in b/cmake/CeresConfig.cmake.in
index e5e2976..184d4eb 100644
--- a/cmake/CeresConfig.cmake.in
+++ b/cmake/CeresConfig.cmake.in
@@ -193,17 +193,6 @@ set(CERES_EIGEN_VERSION @EIGEN3_VERSION_STRING@)
# match and reject with an explanation below.
find_package(Eigen3 ${CERES_EIGEN_VERSION} QUIET)
if (EIGEN3_FOUND)
- if (NOT EIGEN3_VERSION_STRING VERSION_EQUAL CERES_EIGEN_VERSION)
- # CMake's VERSION check in FIND_PACKAGE() will accept any version >= the
- # specified version. However, only version = is supported. Improve
- # usability by explaining why we don't accept non-exact version matching.
- ceres_report_not_found("Found Eigen dependency, but the version of Eigen "
- "found (${EIGEN3_VERSION_STRING}) does not exactly match the version of Eigen "
- "Ceres was compiled with (${CERES_EIGEN_VERSION}). This can cause subtle "
- "bugs by triggering violations of the One Definition Rule. See the "
- "Wikipedia article http://en.wikipedia.org/wiki/One_Definition_Rule "
- "for more details")
- endif ()
ceres_message(STATUS "Found required Ceres dependency: "
"Eigen version ${CERES_EIGEN_VERSION} in ${EIGEN3_INCLUDE_DIRS}")
else (EIGEN3_FOUND)