QT编译含libjpeg库的程序出错

weixin_38087180 2019-09-19 06:22:33
出错内容:videomonitor.cpp:(.text+0x2704): undefined reference to `jpeg_std_error(jpeg_error_mgr*)'videomonitor.cpp:(.text+0x271c): undefined reference to `jpeg_CreateCompress(jpeg_compress_struct*, int, unsigned int)'videomonitor.cpp:(.text+0x274c): undefined reference to `jpeg_set_defaults(jpeg_compress_struct*)'videomonitor.cpp:(.text+0x275c): undefined reference to `jpeg_set_quality(jpeg_compress_struct*, int, int)'videomonitor.cpp:(.text+0x2768): undefined reference to `jpeg_start_compress(jpeg_compress_struct*, int)'videomonitor.cpp:(.text+0x279c): undefined reference to `jpeg_write_scanlines(jpeg_compress_struct*, unsigned char**, unsigned int)'videomonitor.cpp:(.text+0x27b4): undefined reference to `jpeg_finish_compress(jpeg_compress_struct*)'videomonitor.cpp:(.text+0x27bc): undefined reference to `jpeg_destroy_compress(jpeg_compress_struct*)'单独把这些函数写在一个.c的文件里用gcc(arm-linux-gcc)编译是没有问题的,用Qt creator编译x86版本也没错,但用qmake命令交叉编译arm版本就出现上面的错误(库和头文件都已经放进编译器的相关目录里)。请问是什么原因呢?
...全文
39 回复 打赏 收藏 转发到动态 举报
写回复
用AI写文章
回复
切换为时间正序
请发表友善的回复…
发表回复

433

社区成员

发帖
与我相关
我的任务
社区描述
其他技术讨论专区
其他 技术论坛(原bbs)
社区管理员
  • 其他技术讨论专区社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧