[PATCH] D37530: [MinGW] Allow overriding which version of msvcrt to link to

Reid Kleckner via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Sep 6 14:41:59 PDT 2017


rnk added a comment.

What do you think of letting people spell this as `-lmsvcrt120`? We could forward those options and suppress our implicit addition of `-lmsvcrt` if we see `-lmsvcr*` anywhere.



================
Comment at: lib/Driver/ToolChains/MinGW.cpp:161
       if (TC.getArch() == llvm::Triple::x86)
-        CmdArgs.push_back("_DllMainCRTStartup at 12");
+        CmdArgs.push_back("DllMainCRTStartup at 12");
       else
----------------
I guess ld.bfd for COFF does some wacky name mangling. =/


https://reviews.llvm.org/D37530





More information about the cfe-commits mailing list