Advertisement

Lesson 6 Dev-C++ Compile Problems (Help Request)

Started by October 19, 2003 01:58 PM
2 comments, last by Rellik 21 years, 4 months ago
Hi, I use Dev-C++. I''m been following NeHe''s tutorials (very nice tutorials =D) and am at lesson 6. I typed in the code as I went along, and eventually tried to compile. It gave me several errors. Seeking to rectify the problem, I downloaded the conversion by Dan (thank you Dan =D) but it still didn''t work. I changed ''#include ""'' to ''#include ""'', but I do that with every conversion, because it''s just the way it must be set up or something (it works, it must be basically the same thing). It still gives me these errors. I''ve checked the linking, and I''ve linked everything I can think of that might be relevant. Here are the errors: " 32 C:\Documents and Settings\Owner\Desktop\lesson06\lesson6.cpp syntax error before `*'' token 41 C:\Documents and Settings\Owner\Desktop\lesson06\lesson6.cpp ISO C++ forbids declaration of `File'' with no type 41 C:\Documents and Settings\Owner\Desktop\lesson06\lesson6.cpp `Filename'' was not declared in this scope 43 C:\Documents and Settings\Owner\Desktop\lesson06\lesson6.cpp parse error before `if'' C:\Documents and Settings\Owner\Desktop\lesson06\lesson6.cpp [Warning] In function `int LoadGLTextures()'': 56 C:\Documents and Settings\Owner\Desktop\lesson06\lesson6.cpp `AUX_RGBImageRec'' undeclared (first use this function) (Each undeclared identifier is reported only once for each 56 C:\Documents and Settings\Owner\Desktop\lesson06\lesson6.cpp `TextureImage'' undeclared (first use this function) 61 C:\Documents and Settings\Owner\Desktop\lesson06\lesson6.cpp `LoadBMP'' undeclared (first use this function) C:\Documents and Settings\Owner\Desktop\lesson06\Makefile.win [Build Error] [lesson6.o] Error 1 " Here is the compile log: " Compiler: Default compiler Building Makefile: "C:\Documents and Settings\Owner\Desktop\lesson06\Makefile.win" Executing make... make.exe -f "C:\Documents and Settings\Owner\Desktop\lesson06\Makefile.win" all g++.exe -c lesson6.cpp -o lesson6.o -I"C:/Dev-Cpp/include/c++" -I"C:/Dev-Cpp/include/c++/mingw32" -I"C:/Dev-Cpp/include/c++/backward" -I"C:/Dev-Cpp/include" -fexpensive-optimizations lesson6.cpp:32: syntax error before `*'' token lesson6.cpp:41: ISO C++ forbids declaration of `File'' with no type lesson6.cpp:41: `Filename'' was not declared in this scope lesson6.cpp:43: parse error before `if'' lesson6.cpp: In function `int LoadGLTextures()'': lesson6.cpp:56: `AUX_RGBImageRec'' undeclared (first use this function) lesson6.cpp:56: (Each undeclared identifier is reported only once for each function it appears in.) lesson6.cpp:56: `TextureImage'' undeclared (first use this function) lesson6.cpp:61: `LoadBMP'' undeclared (first use this function) make.exe: *** [lesson6.o] Error 1 Execution terminated " Here is what I am linking: "-lopengl32 -lglu32 -lglaux -lkernel32 -luser32 -lgdi32 -lwinspool -lcomdlg32 -ladvapi32 -lshell32 -lole32 -loleaut32 -luuid -lodbc32 -lodbccp32" If you need the source code, I will post it, but otherwise I think it''s probably too big. So if any of you have any ideas of what is causing this problem, or how I could fix it, I would really appreciate your replies! Thanks. End of Post
End of Post
You can''t just arbitrarily change glaux to glext and expect it to work.

[twitter]warrenm[/twitter]

Advertisement
Oh; I see. I didn''t know there was a difference (didn''t quite know what either of them were, actually). I will download glaux from somewhere or other.

Thanks!
End of Post
GLaux is a deprecated library originally created to simplify OpenGL coding by providing functions to draw certain 3D shapes, load images, etc. It is now regarded unkindly by most experienced programmers since it is buggy, generally speaking. You probably won't notice any problems using its BMP loader, but dependence on the library in general is not advised. There are many other BMP loaders out there, and you can write your own. For now however, since you are using a tutorial and you don't have much control, just go with it and understand that this is the way things are.

GLext is a header (or a family of headers; there are different versions for different releases of OpenGL and various platforms) that supplements the extension mechanism of OpenGL on platforms that have out-of-date MCDs. This problem is especially acute on Windows, since Microsoft has not updated its OpenGL MCD since OpenGL 1.2. Basically, GLext just contains function declarations and macros that allow you to more easily use extensions (features that are added to the API but which have not yet propagated through platform libraries).

So, yeah, for the time being, find AUX somewhere and use it blissfully. Learn as you go.

Regards,
ZE.

[edited by - zealouselixir on October 19, 2003 12:49:38 AM]

[twitter]warrenm[/twitter]

This topic is closed to new replies.

Advertisement