Hector_slam not find eigen

eigen library location, often found cmake can not find, modify cmake, the link below

https://github.com/tu-darmstadt-ros-pkg/hector_slam/commit/d9e44fb85087cdf40d4fe702082701b2882eefea

      find_package(Eigen3)
      if(NOT EIGEN3_FOUND)
      # Fallback to cmake_modules
      find_package(cmake_modules REQUIRED)
      find_package(Eigen REQUIRED)
      set(EIGEN3_INCLUDE_DIRS ${EIGEN_INCLUDE_DIRS})
      set(EIGEN3_LIBRARIES ${EIGEN_LIBRARIES}) # Not strictly necessary as Eigen is head only
      # Possibly map additional variables to the EIGEN3_ prefix.
      else()
      set(EIGEN3_INCLUDE_DIRS ${EIGEN3_INCLUDE_DIR})
      endif()
     

Guess you like

Origin www.cnblogs.com/Baron-Lu/p/11431274.html