Reputation:

Why do I get this error: Cannot open include file: 'FL/Fl.h'?

I've tried to compile a program on VSEXPRESS 2008 EDITION coupled with fltk-1.1.9 but I coutinuosly get the following error: fatal error C1083: Cannot open include file: 'FL/Fl.h': No such file or directory

Can anyone one help me out? Thanks a lot

Upvotes: 1

Views: 7842

Answers (3)

fbrereto
fbrereto

Reputation: 35945

Make sure the include directory is not the FL directory, but its parent. The reason for this is when you say #include "FL/Fl.h", you're asking the compiler to step into a folder called FL to find Fl.h, which will reside in FL's parent. If you specify FL as an include directory then you need only say #include "Fl.h"

Upvotes: 1

Igor Zevaka
Igor Zevaka

Reputation: 76610

A neat trick you can do for these types of errors is to place your cursor into the file name of the #include statement and press Ctrl+Shift+G. It will fail and display a message box showing what the include paths are.

The solution is to simply add additional include paths to the SDK by right clicking your project and going to Properties>C/C++>General and setting "Additional Include Directories".

Upvotes: 1

Mark Rushakoff
Mark Rushakoff

Reputation: 258608

Is the fltk library on your computer? You probably did not set up your includes to point to that directory.

Upvotes: 3

Related Questions