Re: undefined reference to `main'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



vinod wrote:

When I using gcc to compile my code.c to code , I got the error msg as
follows :
/usr/lib/gcc/i486-linux-gnu/4.3.2/../../../../lib/crt1.o: In function
`_start':
(.text+0x18): undefined reference to `main'
collect2: ld returned 1 exit status

Could it be possible that you haven't the function 'main()' in your C
application ?

Maybe the current C courses and books teach that "C programs always
start from WinMain()"... :)


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux