Undefined reference to ...
问题: error: undefined reference to `QApplication::QApplication(int&, char**, int)'
error: undefined reference to `QApplication::exec()'
error: undefined reference to `QApplication::~QApplication()'
解决方案: 注释掉*.pro中 QT -= gui;
分析:“undefined reference”错误一般是在连接的时候没有找到需要的库而产生的错误。上面的程序就是由于连接时没有指定相应的 Qt 库从而造成了连接错误。这说明是 Makefile 建立得不正确。
转载于:https://blog.51cto.com/1108038/400481
Undefined reference to ...相关推荐
- undefined reference to 'pthread_create'问题解决(转)
undefined reference to 'pthread_create' undefined reference to 'pthread_join' 问题原因: pthread 库不是 ...
- undefined reference to `libiconv_open 无法编译PHP libiconv
原文:http://hi.baidu.com/ostech/blog/item/a63f9b0dabed1ae7ab6457d0.html ./configure --with-mysql=/back ...
- 【Qt】error: undefined reference to `vtable for MainWindow‘
1.问题描述 在写一个demo时,想尽量简单,就把MainWindow类的定义和实现都写在main.cpp中,结果编译时报错: main.cpp:-1: error: undefined refere ...
- 【Qt】报错error: undefined reference to `vtable for的解决方法
1.问题描述 编译Qt程序时,在某个类构造函数定义处报错: error: undefined reference to `vtable for 2.原因分析 导致错误信息的原因是:子类没有实现父类的纯 ...
- 【ffmpeg】编译时报错:error: undefined reference to `av...
1.问题描述 昨天使用ffmpeg库编译demo一切正常,今天再次链接ffmpeg库时报了一堆错误: error: undefined reference to `av_frame_alloc()' ...
- undefined reference to android log print,undefined reference to '__android_log_print'
场景:undefined reference to `android_log_print' undefined reference to `__android_log_print' 原因:没有加入支持 ...
- undefined reference to 'WinMain@16' 的四种情况
undefined reference to 'WinMain@16' 意思为提示找不到 WinMain 函数,WinMain是windows程序的入口函数,有几种可能: int main() 写成了 ...
- 报错解决:undefined reference to `snappy::MaxCompressedLength(unsigned long)'
下午在编译phxpaxos的样例时报错了,报错如下: g++ echo_sm.o echo_server.o main.o -o phxecho -L/home/zhang/phxpaxos/.lib ...
- 重新编译php又出错了。undefined reference to `php_xx
2019独角兽企业重金招聘Python工程师标准>>> main/rfc1867.lo(.text+0x1c): In function `php_mb_flush_gpc_vari ...
- gcc:undefined reference to 'std::cout'
gcc says: undefined reference to 'std::cout' @ 10/17/2005 计算人生 boss让写的程序,要在linux跟windows下跑,结果我先用vs.n ...
最新文章
- 检索数据表中重复的记录
- 华为面试题之大整数相加
- php模板技术smarty,PHP模板技术Smarty
- 坡道行驶电动小车_事发红绿灯路口!东莞一女子骑电动滑板车被撞致颅内出血…...
- 【机器学习基础】数学推导+纯Python实现机器学习算法26:随机森林
- [Everyday Mathematics]20150103
- mybatis中的查询缓存
- Python刷题-6
- 电子相册系统(八)验证用户是否可用
- 计算机黑屏什么原因,教您电脑黑屏的原因是什么
- matlab中sl设置频率为95khz,BOOST电路设计及matlab仿真
- linux字符集中文转英文,oracle字符集(英文-中文)转换
- Kaldi的安装与测试
- Go官方的使用Gin开发Web服务教程 | Gopher Daily (2021.08.19) ʕ◔ϖ◔ʔ
- 黑苹果电源键睡眠关机的分析及解决办法
- 硬实时RTLinux安装配置详解 (一):准备工作
- VBA 连接Oracle 数据库
- 【Ubuntu】Ubuntu16.04的主题和终端美化
- 谷歌浏览器无法翻译中文解决办法
- Ae和Pr有什么不一样