当前位置:网站首页>Eigen(3):error: ‘Eigen’ has not been declared
Eigen(3):error: ‘Eigen’ has not been declared
2022-06-26 14:16:00 【biter0088】
Compiling c++ When you file , Report errors :
error: ‘Eigen’ has not been declared

Solution examples :
CMakeLists.txt in
Note that there are “#”
cmake_minimum_required(VERSION 2.8.3)
project(xxx)
set(CMAKE_BUILD_TYPE "Release")
set(CMAKE_CXX_FLAGS "-std=c++11")
set(CMAKE_CXX_FLAGS_RELEASE "-O3 -Wall -g")
find_package(catkin REQUIRED COMPONENTS
geometry_msgs
nav_msgs
sensor_msgs
roscpp
rospy
rosbag
std_msgs
image_transport
cv_bridge
tf
pcl_conversions
)
include_directories("/usr/local/include/eigen3")#eigen3 route
set(PCL_DIR "/usr/share/pcl-1.8")
set(OpenCV_DIR "/usr/share/OpenCV")
find_package(Eigen3 REQUIRED)# lookup eigen3 package
find_package(PCL REQUIRED)
find_package(OpenCV 3.2 REQUIRED)
find_package(Ceres REQUIRED)
include_directories(
# include
${catkin_INCLUDE_DIRS}
${PCL_INCLUDE_DIRS}
${EIGEN3_INCLUDE_DIR}# take eigen3 Contents included
${CERES_INCLUDE_DIRS}
${OpenCV_INCLUDE_DIRS})
catkin_package(
CATKIN_DEPENDS geometry_msgs nav_msgs roscpp rospy std_msgs pcl_conversions
DEPENDS EIGEN3 PCL # As a dependency
# INCLUDE_DIRS include
)cpp In file
Add... In the header file
#include <Eigen/Dense>Here's the ros answer in , Propose reference header file :
#include <eigen3/Eigen/Eigen>#include <Eigen/Eigen>I tried , It fails to work well ( Maybe you can try )
Eigen libriary does not work - ROS Answers: Open Source Q&A Forum
边栏推荐
- Knowledge about adsorption
- 9 regulations and 6 prohibitions! The Ministry of education and the emergency management department jointly issued the nine provisions on fire safety management of off campus training institutions
- GC is not used in D
- Bucket of P (segment tree + linear basis)
- [wc2006] director of water management
- RISC-V 芯片架构新规范
- Half search, character array definition, character array uses D11
- BP neural network for prediction
- Calculate the distance between two points (2D, 3D)
- 2021-10-09
猜你喜欢

Pycharm远程连接服务器来跑代码

Calculate the distance between two points (2D, 3D)

Codeforces Global Round 21A~D

How to call self written functions in MATLAB

Zero basics of C language lesson 8: Functions

Included angle of 3D vector

9 articles, 6 interdits! Le Ministère de l'éducation et le Ministère de la gestion des urgences publient et publient conjointement neuf règlements sur la gestion de la sécurité incendie dans les établ

2021-10-18 character array

Reprint - easy to use wechat applet UI component library

Self created notes (unique in the whole network, continuously updated)
随机推荐
"Scoi2016" delicious problem solution
[path of system analyst] Chapter 15 double disk database system (database case analysis)
Introduction to granular computing
[hnoi2010] flying sheep
证券开户安全吗,有没有什么危险啊
Mongodb series window environment deployment configuration
Pytorch based generation countermeasure Network Practice (7) -- using pytorch to build SGAN (semi supervised GaN) to generate handwritten digits and classify them
Jianzhi offer 43.47.46.48 dynamic planning (medium)
Calculate the distance between two points (2D, 3D)
Hard (magnetic) disk (I)
[sdoi2013] forest
FreeFileSync 文件夹比较与同步软件
Knowledge about adsorption
7.Consul服务注册与发现
Lucky numbers in the matrix
Luogu p4145 seven minutes of God created questions 2 / Huashen travels around the world
服务器创建虚拟环境跑代码
array
Relevant knowledge of information entropy
MySQL configuration improves data insertion efficiency