It is because the Borland headers are little different. C code works, C++ gives your error. I think that including windows.h before glut.h fix it. A perhaps better solution is to change “if 0” to “if 1” in glut.h or make this for C++ only.
i think in your bc-project you must apply:
“console”, and switch to “c-node” under “advanced”.
everything else you must turn off, or you use some kind of code templates, but you don’t need this.
and on a windows-system you need to include “windows.h” before “glut.h”.
Ok… I just tried doing just that with the free command-line compiler from Borland. (5.5) I had no errors… curious about what is on that line, I opened up stdlib.h and went to line 584. I found this…
Originally posted by Deiussum:
[b]Ok… I just tried doing just that with the free command-line compiler from Borland. (5.5) I had no errors… curious about what is on that line, I opened up stdlib.h and went to line 584. I found this…
Do you have your own exit function somewhere? Perhaps that is the reason commenting out that line causes it to work for you. I hadn’t really posted that to suggest you should comment it out, but if doing so helps you, it at least gives a clearer indication of what the problem is… You probably have two exit() functions defined! One in stdlib.h, and one someplace else.