[Cmake-commits] CMake branch, next, updated. v3.2.0-870-g49a85a8

Nils Gladitz nilsgladitz at gmail.com
Fri Mar 6 15:05:53 EST 2015


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  49a85a895ac60be51f27c581ebb1460ce61a5b47 (commit)
       via  dae043fb7d436054801515025ebf5414aa1bc55a (commit)
       via  72adc8e8f8674770424148e70c32866d542e3a25 (commit)
      from  26594e5deb1e9c8e3332cd52da9f96c5ed196d9b (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=49a85a895ac60be51f27c581ebb1460ce61a5b47
commit 49a85a895ac60be51f27c581ebb1460ce61a5b47
Merge: 26594e5 dae043f
Author:     Nils Gladitz <nilsgladitz at gmail.com>
AuthorDate: Fri Mar 6 15:05:52 2015 -0500
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Fri Mar 6 15:05:52 2015 -0500

    Merge topic 'fix-wixobj-filenames' into next
    
    dae043fb CPackWIX: Fix .wixobj file output locations and make sure they are unique.
    72adc8e8 CPackWIX: Support patching of root <Feature> elements.


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=dae043fb7d436054801515025ebf5414aa1bc55a
commit dae043fb7d436054801515025ebf5414aa1bc55a
Author:     Nils Gladitz <nilsgladitz at gmail.com>
AuthorDate: Fri Mar 6 21:04:56 2015 +0100
Commit:     Nils Gladitz <nilsgladitz at gmail.com>
CommitDate: Fri Mar 6 21:04:56 2015 +0100

    CPackWIX: Fix .wixobj file output locations and make sure they are unique.

diff --git a/Source/CPack/WiX/cmCPackWIXGenerator.cxx b/Source/CPack/WiX/cmCPackWIXGenerator.cxx
index 83b0948..257ce7a 100644
--- a/Source/CPack/WiX/cmCPackWIXGenerator.cxx
+++ b/Source/CPack/WiX/cmCPackWIXGenerator.cxx
@@ -265,14 +265,30 @@ bool cmCPackWIXGenerator::PackageFilesImpl()
 
   AppendUserSuppliedExtraSources();
 
+  std::set<std::string> usedBaseNames;
+
   std::stringstream objectFiles;
   for(size_t i = 0; i < this->WixSources.size(); ++i)
     {
     std::string const& sourceFilename = this->WixSources[i];
 
+    std::string baseName =
+      cmSystemTools::GetFilenameWithoutLastExtension(sourceFilename);
+
+    unsigned int counter = 0;
+    std::string uniqueBaseName = baseName;
+
+    while(usedBaseNames.find(uniqueBaseName) != usedBaseNames.end())
+      {
+      std::stringstream tmp;
+      tmp << baseName << ++counter;
+      uniqueBaseName = tmp.str();
+      }
+
+    usedBaseNames.insert(uniqueBaseName);
+
     std::string objectFilename =
-      cmSystemTools::GetFilenameWithoutLastExtension(sourceFilename) +
-      ".wixobj";
+      this->CPackTopLevel + "/" + uniqueBaseName + ".wixobj";
 
     if(!RunCandleCommand(sourceFilename, objectFilename))
       {

http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=72adc8e8f8674770424148e70c32866d542e3a25
commit 72adc8e8f8674770424148e70c32866d542e3a25
Author:     Nils Gladitz <nilsgladitz at gmail.com>
AuthorDate: Fri Mar 6 20:40:53 2015 +0100
Commit:     Nils Gladitz <nilsgladitz at gmail.com>
CommitDate: Fri Mar 6 20:40:53 2015 +0100

    CPackWIX: Support patching of root <Feature> elements.

diff --git a/Modules/CPackWIX.cmake b/Modules/CPackWIX.cmake
index 105df96..5fe51a6 100644
--- a/Modules/CPackWIX.cmake
+++ b/Modules/CPackWIX.cmake
@@ -148,8 +148,10 @@
 #  Currently fragments can be injected into most
 #  Component, File and Directory elements.
 #
-#  The special Id ``#PRODUCT`` can be used to inject content
-#  into the ``<Product>`` element.
+#  The following additional special Ids can be used:
+#
+#  * ``#PRODUCT`` for the ``<Product>`` element.
+#  * ``#PRODUCTFEATURE`` for the root ``<Feature>`` element.
 #
 #  The following example illustrates how this works.
 #
diff --git a/Source/CPack/WiX/cmCPackWIXGenerator.cxx b/Source/CPack/WiX/cmCPackWIXGenerator.cxx
index d1d1d58..83b0948 100644
--- a/Source/CPack/WiX/cmCPackWIXGenerator.cxx
+++ b/Source/CPack/WiX/cmCPackWIXGenerator.cxx
@@ -475,6 +475,7 @@ bool cmCPackWIXGenerator::CreateWiXSourceFiles()
 
   featureDefinitions.AddAttribute("Title", cpackPackageName);
   featureDefinitions.AddAttribute("Level", "1");
+  this->Patch->ApplyFragment("#PRODUCTFEATURE", featureDefinitions);
 
   const char* package = GetOption("CPACK_WIX_CMAKE_PACKAGE_REGISTRY");
   if(package)

-----------------------------------------------------------------------

Summary of changes:
 Modules/CPackWIX.cmake                   |    6 ++++--
 Source/CPack/WiX/cmCPackWIXGenerator.cxx |   21 +++++++++++++++++++--
 2 files changed, 23 insertions(+), 4 deletions(-)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list