点云技术相关产学研社区

 找回密码
 立即注册加入PCL中国点云技术相关产学研社区

扫一扫,访问微社区

查看: 7348|回复: 3

PCL库编译问题 PCL1.8,boost1.61,VS2013

[复制链接]
发表于 2016-8-1 18:23:48 | 显示全部楼层 |阅读模式
VS编译PCL1.8,出现很多错误:

错误        692        error C2039: “Literal”: 不是“Eigen::NumTraits<pcl::ndt2d::NormalDist<PointT>>”的成员        d:\pcl\3rdpartysrccode\eigen\include\eigen3\eigen\src\Core\util\XprHelper.h        74
错误        694        error C2065: “Literal”: 未声明的标识符        d:\pcl\3rdpartysrccode\eigen\include\eigen3\eigen\src\Core\util\XprHelper.h        74
错误        693        error C2146: 语法错误: 缺少“,”(在标识符“Literal”的前面)        d:\pcl\3rdpartysrccode\eigen\include\eigen3\eigen\src\Core\util\XprHelper.h        74
错误        600        error C2664: “Eigen::aligned_allocator<U>::aligned_allocator(const Eigen::aligned_allocator<U> &)”: 无法将参数 1 从“std::allocator<T>”转换为“const Eigen::aligned_allocator<U> &”        D:\PCL\3rdPartySrcCode\boost\boost\unordered\detail\allocate.hpp        489
错误        601        error C2664: “Eigen::aligned_allocator<U>::aligned_allocator(const Eigen::aligned_allocator<U> &)”: 无法将参数 1 从“std::allocator<T>”转换为“const Eigen::aligned_allocator<U> &”        D:\PCL\3rdPartySrcCode\boost\boost\unordered\detail\allocate.hpp        489
错误        602        error C2664: “Eigen::aligned_allocator<U>::aligned_allocator(const Eigen::aligned_allocator<U> &)”: 无法将参数 1 从“std::allocator<T>”转换为“const Eigen::aligned_allocator<U> &”        D:\PCL\3rdPartySrcCode\boost\boost\unordered\detail\allocate.hpp        489
错误        695        error C2975: “ConvertibleToLiteral”:“Eigen::internal::promote_scalar_arg_unsupported”的模板参数无效,应为编译时常量表达式        d:\pcl\3rdpartysrccode\eigen\include\eigen3\eigen\src\Core\util\XprHelper.h        74
错误        629        error LNK1181: 无法打开输入文件“..\lib\pcl_surface_release.lib”        D:\PCL\PCLSrcCode\PCL\build\tools\LINK
错误        638        error LNK1181: 无法打开输入文件“..\lib\pcl_surface_release.lib”        D:\PCL\PCLSrcCode\PCL\build\tools\LINK
错误        656        error LNK1181: 无法打开输入文件“..\lib\pcl_surface_release.lib”        D:\PCL\PCLSrcCode\PCL\build\tools\LINK
错误        680        error LNK1181: 无法打开输入文件“..\lib\pcl_surface_release.lib”        D:\PCL\PCLSrcCode\PCL\build\tools\LINK
错误        686        error LNK1181: 无法打开输入文件“..\lib\pcl_surface_release.lib”        D:\PCL\PCLSrcCode\PCL\build\tools\LINK
错误        734        error LNK1181: 无法打开输入文件“..\lib\pcl_surface_release.lib”        D:\PCL\PCLSrcCode\PCL\build\tools\LINK

求高手指导!!!
回复

使用道具 举报

发表于 2016-12-2 13:48:23 | 显示全部楼层
目前没有找到确切的解决方案。老外的方法是自己将Literal 定义加上。
namespace Eigen
{
  /* This NumTraits specialisation is necessary because NormalDist is used as
   * the element type of an Eigen Matrix.
   */
  template<typename PointT> struct NumTraits<pcl::ndt2d::NormalDist<PointT> >
  {
    typedef double Real;
    typedef double Literal; //加在这里。
    static Real dummy_precision () { return 1.0; }
    enum {
      IsComplex = 0,
      IsInteger = 0,
      IsSigned = 0,
      RequireInitialization = 1,
      ReadCost = 1,
      AddCost = 1,
      MulCost = 1
    };
  };
}
回复 支持 反对

使用道具 举报

发表于 2017-1-13 19:37:32 | 显示全部楼层
hanbing6174 发表于 2016-12-2 13:48
目前没有找到确切的解决方案。老外的方法是自己将Literal 定义加上。
namespace Eigen
{

这个是在哪个文件里面定义的?可以告诉一下吗?
老外的方法,有没有网址链接,希望您告诉一下
回复 支持 反对

使用道具 举报

发表于 2017-1-13 21:15:19 | 显示全部楼层
hanbing6174 发表于 2016-12-2 13:48
目前没有找到确切的解决方案。老外的方法是自己将Literal 定义加上。
namespace Eigen
{

我解决这个问题了。你因为Eigen版本的问题。因为PCL还没有支持Eigen3.2.8以上版本的原因吧。所以,你要按照Eigen 3.2.8版本。 具体的名字应该是:eigen-eigen-07105f7124f9
回复 支持 反对

使用道具 举报

本版积分规则

QQ|小黑屋|点云技术相关产学研社区 ( 陕ICP备13001629号 )

GMT+8, 2024-5-12 00:42 , Processed in 1.289748 second(s), 17 queries .

Powered by Discuz! X3.4

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表