diff options
author | Brad King <brad.king@kitware.com> | 2019-01-09 16:51:12 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2019-01-10 12:52:51 (GMT) |
commit | 163cc8bbdd20fceaa6958a071e3d15f53b224864 (patch) | |
tree | 2c925c3df0b20c073d0c529fd31477c572bd7f1f /Source/cmGlobalVisualStudioGenerator.cxx | |
parent | 6d99406e698a3d1b0b69b0fc0f6e09e93fc4ed79 (diff) | |
download | CMake-163cc8bbdd20fceaa6958a071e3d15f53b224864.zip CMake-163cc8bbdd20fceaa6958a071e3d15f53b224864.tar.gz CMake-163cc8bbdd20fceaa6958a071e3d15f53b224864.tar.bz2 |
VS: Convert WriteSLNHeader to non-virtual lookup table
Diffstat (limited to 'Source/cmGlobalVisualStudioGenerator.cxx')
-rw-r--r-- | Source/cmGlobalVisualStudioGenerator.cxx | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/Source/cmGlobalVisualStudioGenerator.cxx b/Source/cmGlobalVisualStudioGenerator.cxx index ff53487..adf0a81 100644 --- a/Source/cmGlobalVisualStudioGenerator.cxx +++ b/Source/cmGlobalVisualStudioGenerator.cxx @@ -62,6 +62,58 @@ const char* cmGlobalVisualStudioGenerator::GetIDEVersion() const return ""; } +void cmGlobalVisualStudioGenerator::WriteSLNHeader(std::ostream& fout) +{ + switch (this->Version) { + case cmGlobalVisualStudioGenerator::VS9: + fout << "Microsoft Visual Studio Solution File, Format Version 10.00\n"; + fout << "# Visual Studio 2008\n"; + break; + case cmGlobalVisualStudioGenerator::VS10: + fout << "Microsoft Visual Studio Solution File, Format Version 11.00\n"; + if (this->ExpressEdition) { + fout << "# Visual C++ Express 2010\n"; + } else { + fout << "# Visual Studio 2010\n"; + } + break; + case cmGlobalVisualStudioGenerator::VS11: + fout << "Microsoft Visual Studio Solution File, Format Version 12.00\n"; + if (this->ExpressEdition) { + fout << "# Visual Studio Express 2012 for Windows Desktop\n"; + } else { + fout << "# Visual Studio 2012\n"; + } + break; + case cmGlobalVisualStudioGenerator::VS12: + fout << "Microsoft Visual Studio Solution File, Format Version 12.00\n"; + if (this->ExpressEdition) { + fout << "# Visual Studio Express 2013 for Windows Desktop\n"; + } else { + fout << "# Visual Studio 2013\n"; + } + break; + case cmGlobalVisualStudioGenerator::VS14: + // Visual Studio 14 writes .sln format 12.00 + fout << "Microsoft Visual Studio Solution File, Format Version 12.00\n"; + if (this->ExpressEdition) { + fout << "# Visual Studio Express 14 for Windows Desktop\n"; + } else { + fout << "# Visual Studio 14\n"; + } + break; + case cmGlobalVisualStudioGenerator::VS15: + // Visual Studio 15 writes .sln format 12.00 + fout << "Microsoft Visual Studio Solution File, Format Version 12.00\n"; + if (this->ExpressEdition) { + fout << "# Visual Studio Express 15 for Windows Desktop\n"; + } else { + fout << "# Visual Studio 15\n"; + } + break; + } +} + std::string cmGlobalVisualStudioGenerator::GetRegistryBase() { return cmGlobalVisualStudioGenerator::GetRegistryBase(this->GetIDEVersion()); |