I've got a Clang-based project which uses MinGW (w64). I'm in the process of updating it to Clang 3.6. Apparently MinGW changed their ABI in 4.7 and Clang now uses that new ABI, so I'm updating MinGW at the same time.
However, now I'm having a slight problem. Using Clang to load the libstdc++ headers results in a great many compilation errors- particularly stuff about constant expressions never being constant. I have enabled C++14 and C++1y support.
Furthermore, I'm unable to get Clang to recognize that the target is MinGW. It seems that their triple support for MinGW was removed in 3.6 and now I don't know how to communicate to Clang that they should emit code compatible with the MinGW ABI.
How can I make Clang be compatible with MinGW w64?