summaryrefslogtreecommitdiffstats
path: root/Source/cmVisualStudio10TargetGenerator.cxx
diff options
context:
space:
mode:
authorPascal Bach <pascal.bach@siemens.com>2014-09-15 13:46:43 (GMT)
committerBrad King <brad.king@kitware.com>2014-09-15 14:37:40 (GMT)
commita3298f7790316322c60b7f2e618fb2ae01819a17 (patch)
tree82ea9e81af4de89e089d34e88f8a2ce23dec94d4 /Source/cmVisualStudio10TargetGenerator.cxx
parent0f2defba7d89aced3b667c6afe031abdfd152540 (diff)
downloadCMake-a3298f7790316322c60b7f2e618fb2ae01819a17.zip
CMake-a3298f7790316322c60b7f2e618fb2ae01819a17.tar.gz
CMake-a3298f7790316322c60b7f2e618fb2ae01819a17.tar.bz2
VS: Teach VS >= 10 generator about Windows CE
When CMAKE_SYSTEM_NAME is 'WindowsCE': * Set the Subsystem and EntryPointSymbol accordingly. * When CMAKE_SYSTEM_VERSION is 8.0 (Windows CE 2013), select the CE800 toolset by default.
Diffstat (limited to 'Source/cmVisualStudio10TargetGenerator.cxx')
-rw-r--r--Source/cmVisualStudio10TargetGenerator.cxx20
1 files changed, 18 insertions, 2 deletions
diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx
index c525b7c..4b5c83f 100644
--- a/Source/cmVisualStudio10TargetGenerator.cxx
+++ b/Source/cmVisualStudio10TargetGenerator.cxx
@@ -2115,11 +2115,27 @@ cmVisualStudio10TargetGenerator::ComputeLinkOptions(std::string const& config)
if ( this->Target->GetPropertyAsBool("WIN32_EXECUTABLE") )
{
- linkOptions.AddFlag("SubSystem", "Windows");
+ if (this->GlobalGenerator->TargetsWindowsCE())
+ {
+ linkOptions.AddFlag("SubSystem", "WindowsCE");
+ linkOptions.AddFlag("EntryPointSymbol", "WinMainCRTStartup");
+ }
+ else
+ {
+ linkOptions.AddFlag("SubSystem", "Windows");
+ }
}
else
{
- linkOptions.AddFlag("SubSystem", "Console");
+ if (this->GlobalGenerator->TargetsWindowsCE())
+ {
+ linkOptions.AddFlag("SubSystem", "WindowsCE");
+ linkOptions.AddFlag("EntryPointSymbol", "mainACRTStartup");
+ }
+ else
+ {
+ linkOptions.AddFlag("SubSystem", "Console");
+ };
}
if(const char* stackVal =