I am working my way through an OpenGl programming book doing some simple examples. I just got openGL working with the Nvidia drivers. I just ran into a new error.
/usr/lib/gcc-lib/i586-mandrake-linux-gnu/2.96/…/…/…/crt1.0: in function ‘_start’:
undefined reference to ‘main’
collect2: ld returned 1 exit status
any ideas.
ALSO:
in general, how do you diagnose these types of undefined reference errors?
The real problem is that you forgot to link in a “main” function, either because you didn’t write one or you forget to include the object that contains “main” in your link.
On mandrake, cc is just a symlink to gcc, so you probably solved your problem by including the right objects the second time around.