diff options
author | Martell Malone <martellmalone@gmail.com> | 2017-11-04 02:15:49 +0000 |
---|---|---|
committer | Martell Malone <martellmalone@gmail.com> | 2017-11-04 02:15:49 +0000 |
commit | b22e600484c8941a7d543c3010364048eaf5cdc0 (patch) | |
tree | 4dbdcb6a31c83e347e3d8874ef7a9c6f405cff59 /clang/lib/CodeGen/CodeGenModule.cpp | |
parent | db5b34ce3061b4f611ff28f86b05eefbbe0d93e4 (diff) | |
download | bcm5719-llvm-b22e600484c8941a7d543c3010364048eaf5cdc0.tar.gz bcm5719-llvm-b22e600484c8941a7d543c3010364048eaf5cdc0.zip |
CodeGenCXX: no default dllimport storage for mingw
GNU frontends don't have options like /MT, /MD
This fixes a few link error regressions with libc++ and libc++abi
Reviewers: rnk, mstorsjo, compnerd
Differential Revision: https://reviews.llvm.org/D33620
llvm-svn: 317398
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r-- | clang/lib/CodeGen/CodeGenModule.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp index b1550170acc..61a1ed2393e 100644 --- a/clang/lib/CodeGen/CodeGenModule.cpp +++ b/clang/lib/CodeGen/CodeGenModule.cpp @@ -2284,7 +2284,8 @@ CodeGenModule::CreateRuntimeFunction(llvm::FunctionType *FTy, StringRef Name, F->setCallingConv(getRuntimeCC()); if (!Local && getTriple().isOSBinFormatCOFF() && - !getCodeGenOpts().LTOVisibilityPublicStd) { + !getCodeGenOpts().LTOVisibilityPublicStd && + !getTriple().isWindowsGNUEnvironment()) { const FunctionDecl *FD = GetRuntimeFunctionDecl(Context, Name); if (!FD || FD->hasAttr<DLLImportAttr>()) { F->setDLLStorageClass(llvm::GlobalValue::DLLImportStorageClass); |