The Allegro library is a popular gaming library which was popular among Dev C++ IDE users. Now that Code::Blocks has pretty much taken over as the premiere free cross platform IDE for the C/C++ Programming language I decided to attempt to use the Allegro library with my Code::Blocks IDE and encountered some issues. After researching briefly on the internet I found a rather simple solution to my problem and decided to share it with the community.

First: Head over to the synaptic package manager and mark for install the Allegro libraries. This is easiest found using the handy search feature located conveniently atop of the package manager.

Once installed fire up Code::Blocks, this is where a little problem I encountered occurred.

Allegro is not linked up to Code::Blocks by default so in your IDE select Settings > Compiler and Debugger > Linker Settings and type the following into "Other linker options"

`allegro-config --libs --static`

Be sure to include the back ticks as well. That should take care of it. Not to difficult to do but seems a lot of people experienced some problems getting Allegro to work with Code::Blocks.

Now lets test Allegro out.

Open up a new file in Code::Blocks and name it something like allegroTestFile.c and enter the following code:

I might not have installed all the needed Allegro libraries but I installed everything I could find in synaptic. Do you know what I may be missing or doing wrong?

Edit:
I still cant get your example to work but I downloaded a demo .cpp file that my professor has online. I believe it was made in Dev-C++. Anyways it works just fine and it uses Allegro. Maybe that will help with figuring out my problem. Thanks.