I've done a bit of research through the site and have found very little conclusive, so I figured I'd make a post to address a few issues I'm having with some code.
The first thing I'll note, is that I've stepped away from Allegro for a fair amount of time (about 2 years or so), so when I saw that Allegro 5 had dropped I went for the download. Right now, I'm using GCC version 4.4.1, and Allegro 5.0.0 RC3. My IDE is code::blocks.
My First 3 issues:
When running the executable, I had to run in compatibility mode with windows XP SP2 in order for it to successfully allocate memory without heap fragmentation. Is this an issue with just the version of allegro I'm using, or one with windows 7? (Code provided below other questions).
Secondly, I get another similar issue when trying to open a file. The file has been verified to exist at the path given, and the access rights to the file are everyone. Which, just as an added precaution I allowed it to run as administrator.
Lastly, when I exit the code with the al_uninstall_system(); it crashes with (yet again) another sigserv.
I attribute these issues to either myself with a bad programming practice somewhere along the way, or with me using an early version of Allegro 5.
bmp = al_create_bitmap(100
, 100); //Crashes here with SIGSERV, when run in compatibility mode this succeeds
bmp = al_load_bitmap("B:\\d.bmp"); // it crashes here with a sigserv. debugger points to the DLL itself, unless run in compatibility mode
13 //All is well
width = al_get_bitmap_width(
height = al_get_bitmap_height(
, width, height, 0
, 0); //Crashes here, with or without the compatibility mode. SIGSERV, debugger points to this function call
23 al_uninstall_system(); //Crashes here, no matter what kind of compatibility settings I have.
24 return 0;
Lastly, When I tried to update to the latest Allegro (5.0.6) it'd get a Missing DLL error, which through research on here says to link with -static-gcc, and 2 other things. Since I've since removed the linking's and reverted to 5.0.0 again I don't have them to copy and paste back. But I did attempt them.
I've tried other versions with varying results, none good.
Any and all information, questions, comments or thoughts to help me out would be greatly appreciated.