【发布时间】:2011-10-16 11:06:34
【问题描述】:
我正在尝试使用以下命令运行带有 gcc 的 hello world 程序
gcc hello.c
但我收到以下错误。
/usr/lib/gcc/i386-redhat-linux/4.1.2/../../../crt1.o: In function `_start':
(.text+0x18): undefined reference to `main'
collect2: ld returned 1 exit status
【问题讨论】:
-
请在您的帖子中添加 hello.c 的文本
标签: gcc reference undefined main