Open neolib opened 2 years ago
I have seen PCH issues with MinGW-w64 for as long as I can remember, so I usually avoid precompiled headers.
See also for example these bug reports: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105858 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14940
I want to ammend an interesting finding.
I can successfully compile PCH using gcc 12.2 Rev1 provided by MSYS2, either used in MSY2 terminal or bare CMD window. But 12.2 Rev2 has the same old behavior. That's very strange.
I want to ammend an interesting finding.
I can successfully compile PCH using gcc 12.2 Rev1 provided by MSYS2, either used in MSY2 terminal or bare CMD window. But 12.2 Rev2 has the same old behavior. That's very strange.
The MSYS2 team applies two patches of their own in order to fix PCH support issues on mingw-based host platforms:
Although they still build GCC with the --disable-libstdcxx-pch
flag ^4 instead of building it with the --enable-libstdcxx-pch
flag.
[^2]: Added in https://github.com/gcc-mirror/gcc/commit/747380f47da0da6c11fd5262ac428bb53433ea19 but the mingw-specific host-side support for this feature is incomplete.
When I try to make a wxWidgets program, I get an unexpected fatal error (which I did not have before):
I am using
gcc version 12.1.0 (MinGW-W64 i686-posix-dwarf, built by Brecht Sanders)
.I can confirm that
gcc version 8.1.0 (i686-win32-sjlj-rev0, Built by MinGW-W64 project)
can compile pch.h without any problems.