https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104057
--- Comment #16 from Andrew Pinski <pinskia at gcc dot gnu.org> --- There are a definitely a few steps missing, Where is the Linux headers installed? How did you configure glibc and install it? I don't see you copying the headers of glibc anywhere. sysroots make it easier to place just the normal OS directory structure under ${prefix}/${target}/sys-root/ which is why it is the recommened way. If sys-root is broken for mingw we should fix that instead.