Mail Archives: djgpp/2004/02/09/01:30:13
>Two of my projects has succumbed to a strange error in which my
>program compiles with no errors or warnings (even with pedantic) and
>then crashes on the first line, regardless of what the first line is.
>GDB can tell me nothing, the backtrace is simply:
>#0 xxxxxxxxxx in main () at program.cpp:13
>#1 xxxxxxxxxx in ___crt1_startup ()
>
>I'm running Windows XP and using DJGPP for compilation. I am also
>using the Allegro graphics libraries, which could be the source of
>this problem. Has anyone run into these problems with DJGPP (I'm
>sorry for posting this here if it is an Allegro problem, but I really
>don't know).
This is going to take a while to sort out as this is not a nice combo.
For starters:-
1) Are you using the latest Allegro 4.1.12 from
http://alleg.sourceforge.net/ if not then if you are not using 4.x
then please upgrade. In either case give the 4.1.2 a try.
2) Are you using DJGPP 2.04 beta release? If not then please go and
update all of the zip files and then check that none of the exe files
in the bin directory are all dated in the second half of 2003. DJGPP
2.04 beta is as compatible as can be doen at the moment on XP and the
majority of exes in the zips from the 2.03 directories ahve not been
re-built witht eh DJGPP LIBC that is compatibale with XP, there a few
exceptions to this.
3) Does a hello world program work? In C and C++? If yes then DJGPP
setup (with the exception of XP compatability).
4) Does the Allegro examples run?
After going through the 4 steps above you should have a working DJGPP
2.04 setup with Allegro 4.1.12. Now the fun stuff...
If the 4 steps above work and your program still does not work then
try adding in the allgro init calls one at a time. If you find that
the problem is in the call to initalised the video then change the
resolution, color depth and even the driver as under XP some of the
options just do not work.
If this is too cumbersome then just try running the demo and selecting
different options until you find one that works and chaneg your app to
use the same setup. I have done this in the past in order to save time
and then I have come back later and investiated the problem.
Andrew
- Raw text -