main函数最后一行报错

来源:互联网 发布:ember.js 教程 编辑:程序博客网 时间:2024/06/08 06:21
get_ipv6_addr.c:95:5: error: expected declaration or statement at end of input
     return 0;
     ^
Makefile:7: recipe for target 'get_ipv6_addr' failed
make: *** [get_ipv6_addr] Error 1





这个问题经常是在windows平台创建并编辑了源文件之后导致字符集不兼容问题造成的,可以使用dos2unix工具转换格式即可
file dos_to_unix.c
dos_to_unix.c: C source, ASCII text, with CRLF line terminators

dos2unix dos_to_unix.c
dos2unix: converting file dos_to_unix.c to Unix format ...

原创粉丝点击