解决Can't use SPARSE_SCHUR with EIGEN_SPARSE because Eigen's sparse linear algebra was not enabled whe

如图问题:(墙内没有。。墙外好像也没搜到,只有自己解决咯)

Can't use SPARSE_SCHUR with EIGEN_SPARSE because Eigen's sparse linear algebra was not enabled when Ceres was built

下载Ceres

* 链接: https://pan.baidu.com/s/17qOxlCb8db38_TEZM1jgaA 提取码: 5usg 

#Cmake
$ sudo apt-get install cmake
# google-glog + gflags
$ sudo apt-get install libgoogle-glog-dev
# BLAS & LAPAC
$ sudo apt-get install libatlas-base-dev
# Eigen3
$ sudo apt-get install libeigen3-dev
# SuiteSparse和CXSparse(可选)
# - 如果您希望将Ceres构建为*static*库(默认),则可以在Ubuntu主包repository中使用SuiteSparse包
$ sudo apt-get install libsuitesparse-dev
# - 但是,如果您要将Ceres构建为* shared *库,则必须添加以下PPA:
$ sudo add-apt-repository ppa:bzindovic /suitesparse-bugfix-1319687
$ sudo apt-get update
$ sudo apt-get install libsuitesparse-dev

修改CMAKE:

196行加一句: set(EIGENSPARSE TRUE)

你可能感兴趣的:(IDE与GNU工具链)