IT数码 购物 网址 头条 软件 日历 阅读 图书馆
TxT小说阅读器
↓语音阅读,小说下载,古典文学↓
图片批量下载器
↓批量下载图片,美女图库↓
图片自动播放器
↓图片自动播放器↓
一键清除垃圾
↓轻轻一点,清除系统垃圾↓
开发: C++知识库 Java知识库 JavaScript Python PHP知识库 人工智能 区块链 大数据 移动开发 嵌入式 开发工具 数据结构与算法 开发测试 游戏开发 网络协议 系统运维
教程: HTML教程 CSS教程 JavaScript教程 Go语言教程 JQuery教程 VUE教程 VUE3教程 Bootstrap教程 SQL数据库教程 C语言教程 C++教程 Java教程 Python教程 Python3教程 C#教程
数码: 电脑 笔记本 显卡 显示器 固态硬盘 硬盘 耳机 手机 iphone vivo oppo 小米 华为 单反 装机 图拉丁
 
   -> 人工智能 -> |usr/bin/ld: warning: libIlmImf-2_2.so.22 needed by /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install -> 正文阅读

[人工智能]|usr/bin/ld: warning: libIlmImf-2_2.so.22 needed by /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install

调用opencv时编译报错,libilmlmf.so问题

[ 66%] Linking CXX executable testinit
/usr/bin/ld: warning: libIlmImf-2_2.so.22, needed by /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libHalf.so.12, needed by /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0, not found (try using -rpath or -rpath-link)
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::globalThreadCount()'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::ChannelList::insert(char const*, Imf_2_2::Channel const&)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::InputFile::header() const'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::hasChromaticities(Imf_2_2::Header const&)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::OutputFile::writePixels(int)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::InputFile::setFrameBuffer(Imf_2_2::FrameBuffer const&)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::InputFile::readPixels(int, int)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::Channel::Channel(Imf_2_2::PixelType, int, int, bool)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::Slice::Slice(Imf_2_2::PixelType, char*, unsigned long, unsigned long, int, int, double, bool, bool)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::OutputFile::setFrameBuffer(Imf_2_2::FrameBuffer const&)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::Header::dataWindow() const'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::Header::channels()'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `half::_eLut'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::Header::channels() const'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::Header::~Header()'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::Header::Header(int, int, float, Imath_2_2::Vec2<float> const&, float, Imf_2_2::LineOrder, Imf_2_2::Compression)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::InputFile::InputFile(char const*, int)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::OutputFile::OutputFile(char const*, Imf_2_2::Header const&, int)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::FrameBuffer::insert(char const*, Imf_2_2::Slice const&)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::ChannelList::findChannel(char const*) const'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::chromaticities(Imf_2_2::Header const&)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `half::convert(int)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::Chromaticities::Chromaticities(Imath_2_2::Vec2<float> const&, Imath_2_2::Vec2<float> const&, Imath_2_2::Vec2<float> const&, Imath_2_2::Vec2<float> const&)'
/usr/bin/ld: /home/tonglu/pkg/opencv3.2/opencv-3.2.0/install/lib/libopencv_imgcodecs.so.3.2.0: undefined reference to `Imf_2_2::OutputFile::~OutputFile()'
collect2: error: ld returned 1 exit status
make[2]: *** [CMakeFiles/testinit.dir/build.make:129: testinit] Error 1
make[1]: *** [CMakeFiles/Makefile2:107: CMakeFiles/testinit.dir/all] Error 2
make: *** [Makefile:84: all] Error 2

opencv  undefined reference to `Imf_2_2::hasChromaticities(Imf_2_2::H

这两个库找不到,所以导致了undefined reference的问题

我查了一下:libilmlmf.so在系统路径下:

~$ locate libIlmImf
/home/tonglu/tergeo/tergeo/tools/mapper/lib/3rdparty/libIlmImf-2_2.so.22
/tergeo/tools/mapper/lib/3rdparty/libIlmImf-2_2.so.22
/usr/lib/x86_64-linux-gnu/libIlmImf-2_2.so.22
/usr/lib/x86_64-linux-gnu/libIlmImf-2_2.so.22.0.0
/usr/lib/x86_64-linux-gnu/libIlmImf.a
/usr/lib/x86_64-linux-gnu/libIlmImf.so
/usr/lib/x86_64-linux-gnu/libIlmImfUtil-2_2.so.22
/usr/lib/x86_64-linux-gnu/libIlmImfUtil-2_2.so.22.0.0
/usr/lib/x86_64-linux-gnu/libIlmImfUtil.a
/usr/lib/x86_64-linux-gnu/libIlmImfUtil.so

不应该存在找不到的问题

结果发现是编译opencv make之后,忘记了

sudo make install

由于我是在CMakeLists.txt中相对路径查找opencv3.2的库,所以g++可能就没有在系统路径下查找,所以出了错,吧opencv安到本机之后,就找到了所需的库,不再报错了。

一点点参考:
https://blog.csdn.net/sz76211822/article/details/76129620

  人工智能 最新文章
2022吴恩达机器学习课程——第二课(神经网
第十五章 规则学习
FixMatch: Simplifying Semi-Supervised Le
数据挖掘Java——Kmeans算法的实现
大脑皮层的分割方法
【翻译】GPT-3是如何工作的
论文笔记:TEACHTEXT: CrossModal Generaliz
python从零学(六)
详解Python 3.x 导入(import)
【答读者问27】backtrader不支持最新版本的
上一篇文章      下一篇文章      查看所有文章
加:2021-08-18 12:42:30  更:2021-08-18 12:44:54 
 
开发: C++知识库 Java知识库 JavaScript Python PHP知识库 人工智能 区块链 大数据 移动开发 嵌入式 开发工具 数据结构与算法 开发测试 游戏开发 网络协议 系统运维
教程: HTML教程 CSS教程 JavaScript教程 Go语言教程 JQuery教程 VUE教程 VUE3教程 Bootstrap教程 SQL数据库教程 C语言教程 C++教程 Java教程 Python教程 Python3教程 C#教程
数码: 电脑 笔记本 显卡 显示器 固态硬盘 硬盘 耳机 手机 iphone vivo oppo 小米 华为 单反 装机 图拉丁

360图书馆 购物 三丰科技 阅读网 日历 万年历 2024年11日历 -2024/11/1 7:45:52-

图片自动播放器
↓图片自动播放器↓
TxT小说阅读器
↓语音阅读,小说下载,古典文学↓
一键清除垃圾
↓轻轻一点,清除系统垃圾↓
图片批量下载器
↓批量下载图片,美女图库↓
  网站联系: qq:121756557 email:121756557@qq.com  IT数码