collect1:error:ld returned 1 exit status 解决办法

简介: collect1:error:ld returned 1 exit status 解决办法

写qt 编译时出错【collect1:error:ld returned 1 exit status】


网上查了一下,是因为【.h文件中相关的函数在cpp文件中没有定义,或者说函数的声明(.h中)与定义(.cpp中)不一致】


所以我在我项目的【diolag.h】文件中看了一下函数声明,发现多了几个之前不用好函数的声明。


修改前:


1.png



修改后:


1.png


将不用的函数声明去掉后,问题就解决了。


相关文章
|
7月前
|
开发者 iOS开发
no identity found Command CodeSign failed with a nonzero exit code
no identity found Command CodeSign failed with a nonzero exit code
83 0
|
7月前
Showing Recent Messages Command CodeSign failed with a nonzero exit code
Showing Recent Messages Command CodeSign failed with a nonzero exit code
74 0
|
7月前
|
C语言 C++
关于DEV中collect2.exe [Error] ld returned 1 exit status的问题解决!!!
关于DEV中collect2.exe [Error] ld returned 1 exit status的问题解决!!!
|
C语言
安装mujoco报错:distutils.errors.DistutilsExecError: command ‘gcc‘ failed with exit status 1
安装mujoco报错:distutils.errors.DistutilsExecError: command ‘gcc‘ failed with exit status 1
664 0
|
Perl
Command PhaseScriptExecution failed with a nonzero exit code问题解决
在某次pod install后,run项目出现以下错误
715 0
|
C++
ERROR: Command errored out with exit status 1:
ERROR: Command errored out with exit status 1:
328 0
ERROR: Command errored out with exit status 1:
|
jenkins 持续交付 图形学
报错Command XXXX/dsymutil failed with exit code 11
报错Command XXXX/dsymutil failed with exit code 11
315 0
报错Command XXXX/dsymutil failed with exit code 11
|
应用服务中间件 nginx
[error] OpenEvent(“Global\ngx_reload_11812“) failed (2: The system cannot find the file specified
[error] OpenEvent(“Global\ngx_reload_11812“) failed (2: The system cannot find the file specified