I'm trying to compile one of my games on Windows, but unfortunately, no matter what, I'm getting this segmentation fault every time I run the program.
Compilation is successful, and without any warning.
Program received signal SIGSEGV, Segmentation fault.
__chkstk_ms () at ../../../../../src/gcc-4.8.1/libgcc/config/i386/cygwin.S:172
172 ../../../../../src/gcc-4.8.1/libgcc/config/i386/cygwin.S: No such file or directory.
I've tried:
- Compiling on a Windows x86 machine
- Compiling on a Windows x64 machine
- nuwen.net's MinGW distro
- TDM MinGW 4.8.1 SJLJ
- MinGW builds x86 SJLJ
- MinGW builds x64 SJLJ
- MinGW builds x86 DW2
I've built all dependencies from source multiple times, tried linking both statically and dynamically.
Debugging doesn't help either - GDB gives me that error message just upon entering main(). I've used -g3 and -O0 flags.
How can I figure out what's happening?
-fstack-usagemight help you figure what's using a lot of stack. - Michael Burr