diff --git a/Source/cmCoreTryCompile.cxx b/Source/cmCoreTryCompile.cxx index 9f38b2529..ebfcae0cb 100644 --- a/Source/cmCoreTryCompile.cxx +++ b/Source/cmCoreTryCompile.cxx @@ -111,7 +111,7 @@ int cmCoreTryCompile::TryCompileCode(std::vector const& argv) ++i) { extraArgs++; - libsToLink += argv[i] + " "; + libsToLink += "\"" + argv[i] + "\" "; cmTarget *tgt = this->Makefile->FindTargetToUse(argv[i].c_str()); if (!tgt) {