Archived

This topic is now archived and is closed to further replies.

worvy

Clanlib compiling programs

Recommended Posts

worvy    122
I got the Clanlib tutorial, and tried to compile the first example program. there is a problem ;It can''t compile. It says there is a parse error before the ''{'' after class hello : public CL_ClanApplication I am also using the -lclanLib option on g++. what''s going on?

Share this post


Link to post
Share on other sites
Kylotan    9870
"Parse Error" is a fancy way of saying there''s something spelt wrong, or something in the wrong place. The code doesn''t make sense. Check for spelling mistakes before the line it mentions. Check there aren''t any hidden characters that got in there somehow, especially if you just copy-pasted the code from somewhere.

Share this post


Link to post
Share on other sites
worvy    122
Well here is the code:

#include ClanLib/core.h
#include ClanLib/display.h
/*#include ClanLib/Core/System/setupcore.h
#include ClanLib/Display/setupdisplay.h
#include ClanLib/Sound/setupsound.h
#include ClanLib/Application/clanapp.h
#include ClanLib/Core/System/clanstring.h*/

class hello : public CL_ClanApplication {
virtual char *get_title();
virtual int main(int, char**);
} app;

p.s. all the #includes DO have triangle brackets but it won't display them for some reason.

Edited by - worvy on August 28, 2001 4:45:42 AM

Share this post


Link to post
Share on other sites
Sheep    152
Hmmm... do all of the includes have /*...*/ around them? If so, they are commented out, and if not then I am an idiot, ok?

Share this post


Link to post
Share on other sites
worvy    122
Good thinking, Kylotan. Sorry I thought it was included by the core.h file!

thankyou so much

Well Sheep, that bit of code is cut & pasted from my code so, no, the includes aren''t comented out

Share this post


Link to post
Share on other sites