diff options
-rw-r--r-- | version_info.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/version_info.c b/version_info.c index 37601cf7e7..6c80bd9174 100644 --- a/version_info.c +++ b/version_info.c @@ -184,7 +184,18 @@ get_compiler_info(GString *str) * distinguish between them. */ #if defined(__clang__) + /* + * Microsoft have a version of their compiler that has Clang + * as the front end and their code generator as the back end. + * + * My head asplode. + */ + #if defined(__MSC_VER) + g_string_append_printf(str, "\n\nBuilt using Microsoft Visual C++ %d.%d.%d clang/C2 %s and -fno-ms-compatibility.\n", + (_MSC_VER / 100) - 6, _MSC_VER % 100, __VERSION__); + #else g_string_append_printf(str, "\n\nBuilt using clang %s.\n", __VERSION__); + #endif /* defined(__MSC_VER) */ #elif defined(__llvm__) g_string_append_printf(str, "\n\nBuilt using llvm-gcc %s.\n", __VERSION__); #else /* boring old GCC */ @@ -248,6 +259,13 @@ get_compiler_info(GString *str) g_string_append_printf(str, "\n"); #elif defined(_MSC_VER) /* _MSC_FULL_VER not defined, but _MSC_VER defined */ + #if defined(__clang__) + /* More head asplosion; see above. */ + g_string_append_printf(str, "\n\nBuilt using Microsoft Visual C++ %d.%d.%d clang/C2 %s.\n", + (_MSC_VER / 100) - 6, _MSC_VER % 100, __VERSION__); + #else + g_string_append_printf(str, "\n\nBuilt using clang %s.\n", __VERSION__); + #endif /* defined(__MSC_VER) */ g_string_append_printf(str, "\n\nBuilt using Microsoft Visual C++ %d.%d\n", (_MSC_VER / 100) - 6, _MSC_VER % 100); #elif defined(__SUNPRO_C) |