The Allegro Wiki is migrating to github at https://github.com/liballeg/allegro_wiki/wiki
Dev-C++ (a.k.a. Dev-Cpp) is an open source IDE coded in Delphi. It supports most GCC based compilers, and comes with MinGW. There are also installers that don't contain a compiler, and thus you can easily switch to Cygwin etc.
It has all the basics: custom syntax highlighting, profiling and debugging support, class browsing, CVS support, and more. Its most notable feature is its low profile; the entire thing (MinGW included) extracts to about 90MB! This is impressive when you compare it to the insane amount of time and disk space required to install a Microsoft compiler of any caliber.
Dev-C++ comes with a really cool feature called Dev-paks. You can use the IDE's built in updater to search for dev-paks. If you prefer to look for them yourself, there is a little site called http://www.devpaks.org! Remember that there is no 'c' or dash when typing in the URL. See the Using DevPaks section below.
I highly recommend NOT using the latest version, as it is still in beta and spurts errors unexpectedly. If you like software testing while you code, you can download it along with the old versions at http://www.bloodshed.net/.
A walkthrough detailing how to install Dev-C++ and Allegro can be found here: http://www.gamedev.net/community/forums/topic.asp?topic_id=354954&whichpage=1�
Setting up Allegro
Windows needs DirectX to run Allegro (to my knowledge). Dev-C++ comes with some dated DirectX headers and libraries, which may or may not need replacement. Since A4 uses DirectX 7, it is doubtful that replacement is necessary for an Allegro program. If you do need it you can download a MinGW copy of DX7 here.
Making an Allegro Project
- Click "File", "New", and "Project..."
- Select "Empty Project", give it a name, and click OK.
- Save your project somewhere (I recommend using a separate folder for each project).
- Right-click on the name of your project (in the left sidebar) and click "Project Options".
- Click the "Parameters" tab, and click "Add Library or Object"
- Find the "liballeg.a" file, usually under "/allegro/lib/mingw32".
- Click the "Directories" tab, click "Include Directories", and click the Folder Icon on the right.
- Find the "/allegro/include/" folder and click OK.
- Click "Add" then press OK.
- Click "File", "New", "Source File" then click Yes.
- Write your program here, then save and compile.
- If you are using MinGW don't forget to put END_OF_MAIN() after the main function.
Alternatively, I usually install Allegro libraries to the default library directory ("/lib/"), and the headers to the default header directory ("/include/"). This way, setting the include and lib directories is not necessary for creating a new project, and this makes setup a little easier.
Once you have Dev-c++ installed, you can download a package that will automatically install itself. These are called DevPaks and are the neatest thing since potato bread. They allow even the most inexperienced (or lazy) programmer install a library for the MinGW compiler. Allegro isn't the only library available for download; other libraries like libPNG, lame enc, DX 9c, and more are pre-made for your installation pleasure.
- Click the Tools menu at the top of the window, then click Check for Updates/Packages.
- When the next menu comes up, click Check for Updates at the bottom. (If nothing appears try changing the DevPak server you are using by clicking on the drop-down menu at the top of the updates window.)
- Find allegro by clicking the Update box just above the updates twice so that updates starting with 'A' are shown.
- Check Allegro and then click Download Selected.
- Once it is done, go through the installation wizard.