954,164 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

FLTK compiling issues...

Hi

I have Microsoft Visual C++ 2008 Express Edition and I downloaded fltk from fltk.org. When I tried compiling it, i got many of these errors:

LINK : fatal error LNK1181: cannot open input file 'fltk.lib'

How do i compile FLTK now? Please help

tundra010
Light Poster
38 posts since Jun 2009
Reputation Points: 11
Solved Threads: 5
 

Try reading the documentation on how to install it perhaps?

Check your linker settings, make sure you have entered everything correctly.

William Hemsworth
Posting Virtuoso
1,591 posts since Mar 2008
Reputation Points: 1,429
Solved Threads: 129
 

I read the directions in the documentation, and I followed the directions, but it didn't work, it still gave me the same error.

My linker settings seem to be ok...

tundra010
Light Poster
38 posts since Jun 2009
Reputation Points: 11
Solved Threads: 5
 

In your linker settings have you typed in the complete path to where fltk.lib is located ? By default it'll look for it in the current project directory. If fltk.lib is something you are supposed to compile also, then make sure that project is added as a dependency for your current project, so that it compiles before, and fltk.lib exists for you to use.

stilllearning
Posting Whiz
309 posts since Oct 2007
Reputation Points: 161
Solved Threads: 43
 

thanks, stilllearning and William. I got FLTK compiled, but when I try to compile and run the following program, I get the error messages under that.

#include
#include

int main() {
FL_Window win(400, 200);
win.show();
return FL::run();
}

Error messages:
error C2065: 'FL_Window' : undeclared identifier
error C2146: syntax error : missing ';' before identifier 'win'
error C3861: 'win': identifier not found
error C2065: 'win' : undeclared identifier
error C2228: left of '.show' must have class/struct/union

sorry if the answer is obvious, I am new to C++ :)

tundra010
Light Poster
38 posts since Jun 2009
Reputation Points: 11
Solved Threads: 5
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You