VS: Do not pass CUDA compile options to C compiler

This commit is contained in:
Brad King
2017-03-07 16:08:45 -05:00
parent b966f489c1
commit 29f07b0867

View File

@@ -2235,8 +2235,10 @@ bool cmVisualStudio10TargetGenerator::ComputeClOptions(
if (linkLanguage == "CXX") { if (linkLanguage == "CXX") {
clOptions.AddFlag("CompileAs", "CompileAsCpp"); clOptions.AddFlag("CompileAs", "CompileAsCpp");
} }
this->LocalGenerator->AddCompileOptions(flags, this->GeneratorTarget, if (linkLanguage != "CUDA") {
linkLanguage, configName.c_str()); this->LocalGenerator->AddCompileOptions(flags, this->GeneratorTarget,
linkLanguage, configName.c_str());
}
// Get preprocessor definitions for this directory. // Get preprocessor definitions for this directory.
std::string defineFlags = std::string defineFlags =