Allegro

Whether you're a newbie or an experienced programmer, any questions, help, or just talk of any language will be welcomed here.

Moderator: Coders of Rage

Post Reply
User avatar
Martijn
Chaos Rift Newbie
Chaos Rift Newbie
Posts: 22
Joined: Thu Jun 04, 2009 4:47 pm
Programming Language of Choice: C++

Allegro

Post by Martijn »

I'm using devcpp and I just can't get allegro to work.
I've installed "allegro-4.2.1-1mol.DevPak" and at project options -> parameters -> linker I wrote "-lalleg".
and umm.. used if I compile the code from this tutorial (or any) http://loomsoft.net/resources/alltut/alltut_lesson1.htm

Code: Select all

  Circular main <- main.o dependency dropped. 
 C:\Documents and Settings\Admin\Bureaublad\allegro\Makefile.win [Build Error]  [Project1.exe] Error 1 
I get that compile error, here is the outcome of that tutorial:
(I also downloaded there outcome, same error)

Code: Select all

#include <allegro.h>

int main(int argc, char *argv[])
{
allegro_init(); // Initalize Allegro

install_keyboard();

// set_gfx_mode(GRAPHICS MODE, Width, Height, Virtual Width, Virtual Height);
set_gfx_mode(GFX_AUTODETECT, 640,480,0,0); 

readkey(); // wait for input
return 0;
}

END_OF_MAIN() // This must be called right after the closing bracket of your MAIN function.
              // It is Allegro specific.
User avatar
Sanshin77
Chaos Rift Regular
Chaos Rift Regular
Posts: 160
Joined: Tue Mar 10, 2009 9:36 am
Current Project: C++/SDL engine, zaActionWizardMagic game
Favorite Gaming Platforms: Xbox 360, Playstation 2, Nintendo DS, mac and PC
Programming Language of Choice: C++

Re: Allegro

Post by Sanshin77 »

I think the Allegro DevPak comes with a "template project" that you can create(?).
Have you tried that?
Check out videos of my C++ games as well as my "Amateur Game Dev" series over at
My YouTube Channel: http://www.youtube.com/user/Zanchill
User avatar
Pickzell
Chaos Rift Junior
Chaos Rift Junior
Posts: 233
Joined: Sat May 16, 2009 10:21 am

Re: Allegro

Post by Pickzell »

If you have UAC (User Account Control) on then turn it off.

Start -> Control Panel -> User Accounts -> Turn user account control on and off -> uncheck Use UAC to protect my computer. Click OK

Now reinstall the devpack and it should work.
I'm an altogether bad-natured Cupid.
Post Reply