system
September 5, 2001, 3:55am
1
Hey, I’m trying to write a portable app, and I need to be able to compile it with Borland Builder 4. When linking, I get the error:
Unresolved external ‘_main’ referenced from ‘BORLANDPATH’\LIB\C0X32.OBJ
(that’s c zero x 32)
Any ideas what might be wrong and how to fix it? Thanks for helping out a newbie.
Are you using GLUT or SDL ?
The message indicates that your main() function is missing.
Mikael
system
September 5, 2001, 12:17pm
3
I’m using SDL. The annoying thing is that I have a main() function. The program also compiles with gcc (if that helps).
Morglum
September 5, 2001, 11:12pm
4
are you sure that your main function has the good definition ? Even if you don’t use commend-line arguments, you have to write it as :
int main (int argc, char *argv [])
{
…
return 0;
}
system
September 6, 2001, 3:39am
5
Yeah, I have both the int main(int argc, char *argv[]), the {}, and the return 0; within…