This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "CMake".
The branch, next has been updated via 5c9b7cdd52158b5255a3ad204a88a11c528db33f (commit) via e30e4a83729c9b038b252e0a004e9b5af31c8fc3 (commit) via 97a900623eb87fcc64f6dfc78985bc813f1669ee (commit) from 73c5a58100f075a22068da3689c0e7313adc1c87 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=5c9b7cdd52158b5255a3ad204a88a11c528db33f commit 5c9b7cdd52158b5255a3ad204a88a11c528db33f Merge: 73c5a58 e30e4a8 Author: Brad King <brad.k...@kitware.com> AuthorDate: Fri Aug 22 09:35:36 2014 -0400 Commit: CMake Topic Stage <kwro...@kitware.com> CommitDate: Fri Aug 22 09:35:36 2014 -0400 Merge topic 'vs-windows-apps' into next e30e4a83 Help: Add notes for topic 'vs-windows-apps' 97a90062 VS: Do not compile C sources as WinRT (#15100) diff --cc Source/cmVisualStudio10TargetGenerator.cxx index c6b78ce,6f1fe52..309ceb6 --- a/Source/cmVisualStudio10TargetGenerator.cxx +++ b/Source/cmVisualStudio10TargetGenerator.cxx @@@ -1486,12 -1462,11 +1488,16 @@@ bool cmVisualStudio10TargetGenerator::O { clOptions.AddFlag("CompileAs", compileAs); } + if(noWinRT) + { + clOptions.AddFlag("CompileAsWinRT", "false"); + } clOptions.Parse(flags.c_str()); + if(clOptions.HasFlag("AdditionalIncludeDirectories")) + { + clOptions.AppendFlag("AdditionalIncludeDirectories", + "%(AdditionalIncludeDirectories)"); + } clOptions.AddDefines(configDefines.c_str()); clOptions.SetConfiguration((*config).c_str()); clOptions.OutputAdditionalOptions(*this->BuildFileStream, " ", ""); http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=e30e4a83729c9b038b252e0a004e9b5af31c8fc3 commit e30e4a83729c9b038b252e0a004e9b5af31c8fc3 Author: Brad King <brad.k...@kitware.com> AuthorDate: Fri Aug 22 09:33:58 2014 -0400 Commit: Brad King <brad.k...@kitware.com> CommitDate: Fri Aug 22 09:33:58 2014 -0400 Help: Add notes for topic 'vs-windows-apps' diff --git a/Help/release/dev/vs-windows-apps.rst b/Help/release/dev/vs-windows-apps.rst new file mode 100644 index 0000000..63dae28 --- /dev/null +++ b/Help/release/dev/vs-windows-apps.rst @@ -0,0 +1,6 @@ +vs-windows-apps +--------------- + +* The :prop_tgt:`VS_WINRT_COMPONENT` target property was created to + tell Visual Studio generators to compile a shared library as a + Windows Runtime (WinRT) component. http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=97a900623eb87fcc64f6dfc78985bc813f1669ee commit 97a900623eb87fcc64f6dfc78985bc813f1669ee Author: Brad King <brad.k...@kitware.com> AuthorDate: Fri Aug 22 09:27:00 2014 -0400 Commit: Brad King <brad.k...@kitware.com> CommitDate: Fri Aug 22 09:32:24 2014 -0400 VS: Do not compile C sources as WinRT (#15100) The MSVC /ZW flag is valid only for C++ sources. Whenever we enable CompileAsWinRT for the whole target, disable it for all C sources. Update the documentation of VS_WINRT_COMPONENT to drop the statement about undefined behavior for non-C++ sources, because it is now defined as expected. diff --git a/Help/prop_tgt/VS_WINRT_COMPONENT.rst b/Help/prop_tgt/VS_WINRT_COMPONENT.rst index a017f0e..e160bd6 100644 --- a/Help/prop_tgt/VS_WINRT_COMPONENT.rst +++ b/Help/prop_tgt/VS_WINRT_COMPONENT.rst @@ -7,8 +7,5 @@ For ``SHARED`` and ``MODULE`` libraries, this also defines the ``_WINRT_DLL`` preprocessor macro. .. note:: - Behavior is not defined for targets with source files that compile as - any language other than ``CXX``. - Currently this is implemented only by Visual Studio generators. Support may be added to other generators in the future. diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx index a1dd7ab..6f1fe52 100644 --- a/Source/cmVisualStudio10TargetGenerator.cxx +++ b/Source/cmVisualStudio10TargetGenerator.cxx @@ -159,6 +159,7 @@ cmVisualStudio10TargetGenerator(cmTarget* target, this->GUID = this->GlobalGenerator->GetGUID(this->Name.c_str()); this->Platform = gg->GetPlatformName(); this->MSTools = true; + this->TargetCompileAsWinRT = false; this->BuildFileStream = 0; this->IsMissingFiles = false; this->DefaultArtifactDir = @@ -1414,6 +1415,7 @@ bool cmVisualStudio10TargetGenerator::OutputSourceSpecificFlags( compileAs = "CompileAsC"; } } + bool noWinRT = this->TargetCompileAsWinRT && lang == "C"; bool hasFlags = false; // for the first time we need a new line if there is something // produced here. @@ -1447,7 +1449,7 @@ bool cmVisualStudio10TargetGenerator::OutputSourceSpecificFlags( } // if we have flags or defines for this config then // use them - if(!flags.empty() || !configDefines.empty() || compileAs) + if(!flags.empty() || !configDefines.empty() || compileAs || noWinRT) { (*this->BuildFileStream ) << firstString; firstString = ""; // only do firstString once @@ -1460,6 +1462,10 @@ bool cmVisualStudio10TargetGenerator::OutputSourceSpecificFlags( { clOptions.AddFlag("CompileAs", compileAs); } + if(noWinRT) + { + clOptions.AddFlag("CompileAsWinRT", "false"); + } clOptions.Parse(flags.c_str()); clOptions.AddDefines(configDefines.c_str()); clOptions.SetConfiguration((*config).c_str()); @@ -1711,6 +1717,13 @@ bool cmVisualStudio10TargetGenerator::ComputeClOptions( clOptions.AddFlag("CompileAsWinRT", "false"); } } + if(const char* winRT = clOptions.GetFlag("CompileAsWinRT")) + { + if(cmSystemTools::IsOn(winRT)) + { + this->TargetCompileAsWinRT = true; + } + } } this->ClOptions[configName] = pOptions.release(); diff --git a/Source/cmVisualStudio10TargetGenerator.h b/Source/cmVisualStudio10TargetGenerator.h index 9d94365..e558f74 100644 --- a/Source/cmVisualStudio10TargetGenerator.h +++ b/Source/cmVisualStudio10TargetGenerator.h @@ -134,6 +134,7 @@ private: std::string GUID; std::string Name; bool MSTools; + bool TargetCompileAsWinRT; cmGlobalVisualStudio10Generator* GlobalGenerator; cmGeneratedFileStream* BuildFileStream; cmLocalVisualStudio7Generator* LocalGenerator; ----------------------------------------------------------------------- Summary of changes: Help/prop_tgt/VS_WINRT_COMPONENT.rst | 3 --- Help/release/dev/vs-windows-apps.rst | 6 ++++++ Source/cmVisualStudio10TargetGenerator.cxx | 15 ++++++++++++++- Source/cmVisualStudio10TargetGenerator.h | 1 + 4 files changed, 21 insertions(+), 4 deletions(-) create mode 100644 Help/release/dev/vs-windows-apps.rst hooks/post-receive -- CMake _______________________________________________ Cmake-commits mailing list Cmake-commits@cmake.org http://public.kitware.com/mailman/listinfo/cmake-commits