https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98860
--- Comment #31 from Mikael Pettersson <mikpelinux at gmail dot com> --- Created attachment 50158 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=50158&action=edit conftest.c (based configure's cross compilation test) This runs Ok when compiled with "-O2 -g -gdwarf-4", but fails with Windows error code 193 aka "Exec format error" when compiled with "-O2 -g -gdwarf-5". The error is reproducible with a x86_64-w64-mingw32 cross (just transfer the EXEs to Windows for execution). Compiling with -S shows differences in several .debug sections.