码迷,mamicode.com
首页 > 其他好文 > 详细

运行代码时报linker command failed with exit code 1 错误

时间:2017-08-22 20:15:10      阅读:202      评论:0      收藏:0      [点我收藏+]

标签:com   文件中   and   声明   back   变量   with   mil   color   

一个c语言项目,在.h文件中原来只有一些方法的声明,后来我加入了一些变量声明后,编译的时候报错:

运行代码时报linker command failed with exit code 1 错误

怎么回事那?

【解决方法】

将变量的声明都移到.c文件中去就好了。

运行代码时报linker command failed with exit code 1 错误

标签:com   文件中   and   声明   back   变量   with   mil   color   

原文地址:http://www.cnblogs.com/time-is-life/p/7413381.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!