![]() |
|
Does not exist!!! |
Lavargian
Member #8,133
December 2006
|
Hi, I just downloaded Allegro a few minutes ago, and I am using a jGRASP editor to write my code. I am trying to test it out by creating a program that creates a white background screen, and draws two circles, two rectangles, and two triangles. One of each will be not colored in, and one of each will be filled in with a color. The problem is when I try to compile this program it comes up with an error that says "allegro.h: No such file or directory" So, I was wondering if any one could tell me how to install or use allegro with the jGRASP editor? Thanks for all your responses!!! oh and here is a copy of the program that I wrote. Just in case you need to see it to help me out.
|
Rick
Member #3,572
June 2003
![]() |
Do you have allegro.h in your include directory to the compiler you are using. Also I usually do "allegro.h" not <allegro.h>, not sure if that does anything or not. ======================================================== |
Lavargian
Member #8,133
December 2006
|
I tried writing "allegro.h" and the same error came up, so I guess that doesn't really matter, but Anyway, I think I need to know how to do what you suggested. See I am pretty much a complete noob when it comes to this stuff, and I have learned the basics of C++, and now I want to get into some light game programming. I just need to know how to include the allegro files into my compiler so it knows where to find the allegro files. By the way I am using a g++ - MinGW (C:\mingw\bin) compiler, and I am using jGRASP as an editor. |
ixilom
Member #7,167
April 2006
![]() |
If you are using the prebuilt allegro binaries, the zip contains 3 folders
Copy the "include" and "lib" directories to your c:\mingw directory. After copying those directories, you should have allegro.h in your c:\mingw\include directory. The bin directory contains the DLL files allegro uses when you compile a dynamic version of your game/program. Personally, I copy these to c:\windows\system32. Someone might object to that because it "clutters" your harddrive Now you should be able to do #include <allegro.h>
___________________________________________ |
Tobias Dammers
Member #2,604
August 2002
![]() |
Quote: Also I usually do "allegro.h" not <allegro.h>, not sure if that does anything or not.
You use "" quotes for local includes (headers specific to the current project, that are located in the project's folder or one of its subfolders), and <> brackets to include headers from the compiler's include directory - stdlib, stl, and all libraries you have installed. --- |
|