mirror of
https://github.com/ceres-solver/ceres-solver.git
synced 2026-08-29 16:40:38 +08:00
Fix compilation error on systems without SuiteSparse installed
Issue was caused by declaring class PerThreadContext with some members of choldmod-specific types. This class in only used from an #ifndef CERES_NO_SUITESPARSE block and solved compilation error by simply wrapping PerThreadContext with the same #ifndef block. Change-Id: Icdc329073fcbd4a328e41ea8c0af0962e9c34ba8
This commit is contained in:
@@ -54,6 +54,7 @@ namespace internal {
|
||||
namespace {
|
||||
|
||||
// Per thread storage for SuiteSparse.
|
||||
#ifndef CERES_NO_SUITESPARSE
|
||||
struct PerThreadContext {
|
||||
explicit PerThreadContext(int num_rows)
|
||||
: solution(NULL),
|
||||
@@ -79,6 +80,7 @@ struct PerThreadContext {
|
||||
cholmod_dense* rhs;
|
||||
SuiteSparse ss;
|
||||
};
|
||||
#endif
|
||||
|
||||
} // namespace
|
||||
|
||||
|
||||
Reference in New Issue
Block a user