Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / Managed C++ / September 2007

Tip: Looking for answers? Try searching our database.

Problems #include'ing a file

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Todd Dobmeyer - 24 Sep 2007 18:44 GMT
I am working on developing a program using Visual Studio 2003 but am having
problems getting my program to find my GL.h and GLU.h, and I am guessing it
will have the same problems trying to link to the .lib and .dll files. What
do I all need to do to get this to properly compile and link. Here is what I
have done so far.

Inside my main project directory, I added a folder called "OpenGL" and
inside this folder are 3 sub-folders, "include", "lib", "bin" with the .h
files going into include, the .lib files into lib and the .dll files into bin.

I right-clicked onto my project and clicked on "Properties". In the left
list, I clicked on C\C++ and then on the sub-option "General". On the
"Additional Include Directories" I added the path
"$(ProjectDir)\OpenGL\include" to the listing. Then on the Linker option, I
added 2 paths to the "Additional Library Directories" with
"$(ProjectDir)\OpenGL\bin" and "$(ProjectDir)\OpenGL\lib".

But after doing this and cleaning my project and re-compiling, I get a whole
bunch of compiler errors saying "fatal error C1083: Cannot open include file:
'GL.h': No such file or directory". I have in my .h file added the line:

#include "GL.h"
#include "GLU.h"

Does anyone have any ideas on what else I need to do to be able to include
these files into my project? Thanks!
Todd Dobmeyer - 24 Sep 2007 19:06 GMT
> I am working on developing a program using Visual Studio 2003 but am having
> problems getting my program to find my GL.h and GLU.h, and I am guessing it
[quoted text clipped - 22 lines]
> Does anyone have any ideas on what else I need to do to be able to include
> these files into my project? Thanks!

Well I found that I already had GLU.h inside my VisualStudio directory
located at "C:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\PlatformSDK\Include\gl" but unfortunately, I cannot get it to find
this .h file. I have just used the statement

#include "GLU.h"

and it says it cannot open the include file. What do I need to do to find
the one include with my Visual Studio install? Thanks again!
Todd Dobmeyer - 24 Sep 2007 19:14 GMT
> #include "GLU.h"
>
> and it says it cannot open the include file. What do I need to do to find
> the one include with my Visual Studio install? Thanks again!

I am a moron...I needed

#include <gl\glu.h>
JP - 25 Sep 2007 01:48 GMT
You might need to see if the Include directories is correctly set under
Tool->Options
->Projects and Solutions->VC++ Directories.

you might need to that include path as well.

Thanks
JP

> > #include "GLU.h"
> >
[quoted text clipped - 4 lines]
>
> #include <gl\glu.h>

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.