[Cmake-commits] CMake branch, next, updated. v3.0.0-4622-gee75b00
Brad King
brad.king at kitware.com
Wed Jul 30 09:14:07 EDT 2014
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 ee75b00eadb9b6edb840873c6056bc66c70dc3e4 (commit)
via e7511b7fbe09a4007269992edcde2dc98144da47 (commit)
via b234000184bbf314bf0a7380a1d4ebb54f7c8f69 (commit)
from 7d5a57c48614053a182eb46c3badd5886adcb894 (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=ee75b00eadb9b6edb840873c6056bc66c70dc3e4
commit ee75b00eadb9b6edb840873c6056bc66c70dc3e4
Merge: 7d5a57c e7511b7
Author: Brad King <brad.king at kitware.com>
AuthorDate: Wed Jul 30 09:14:06 2014 -0400
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Wed Jul 30 09:14:06 2014 -0400
Merge topic 'cpack-ifw-generator' into next
e7511b7f CPackIFW: Add package configuration variables
b2340001 CPackIFW: Document cpack_ifw_configure_component DEPENDS option
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=e7511b7fbe09a4007269992edcde2dc98144da47
commit e7511b7fbe09a4007269992edcde2dc98144da47
Author: Konstantin Podsvirov <konstantin at podsvirov.pro>
AuthorDate: Tue Jul 29 01:58:37 2014 +0400
Commit: Brad King <brad.king at kitware.com>
CommitDate: Tue Jul 29 15:55:19 2014 -0400
CPackIFW: Add package configuration variables
diff --git a/CMakeCPack.cmake b/CMakeCPack.cmake
index 5b096ad..b27cd69 100644
--- a/CMakeCPack.cmake
+++ b/CMakeCPack.cmake
@@ -74,6 +74,7 @@ if(EXISTS "${CMAKE_ROOT}/Modules/CPack.cmake")
string(TOUPPER ${_CPACK_IFW_COMPONENT_NAME} _CPACK_IFW_COMPONENT_UNAME)
if(${CMAKE_SYSTEM_NAME} MATCHES Windows)
+ set(_CPACK_IFW_PACKAGE_ICON "set(CPACK_IFW_PACKAGE_ICON \"${CMake_SOURCE_DIR}/Source/QtDialog/CMakeSetup.ico\")")
if(BUILD_QtDialog)
set(_CPACK_IFW_SHORTCUT_OPTIONAL "${_CPACK_IFW_SHORTCUT_OPTIONAL}component.addOperation(\"CreateShortcut\", \"@TargetDir@/bin/cmake-gui.exe\", \"@StartMenuDir@/CMake (cmake-gui).lnk\");\n")
endif()
diff --git a/CMakeCPackOptions.cmake.in b/CMakeCPackOptions.cmake.in
index 135c07d..5127220 100644
--- a/CMakeCPackOptions.cmake.in
+++ b/CMakeCPackOptions.cmake.in
@@ -34,12 +34,17 @@ include("@QT_DIALOG_CPACK_OPTIONS_FILE@" OPTIONAL)
if(CPACK_GENERATOR MATCHES "IFW")
# Version with QtIFW limitations
set(CPACK_PACKAGE_VERSION "@_CPACK_IFW_PACKAGE_VERSION@")
+ # Installer configuration
+ set(CPACK_IFW_PACKAGE_TITLE "CMake Build Tool")
+ set(CPACK_IFW_PRODUCT_URL "http://www.cmake.org")
+ @_CPACK_IFW_PACKAGE_ICON@
+ set(CPACK_IFW_PACKAGE_WINDOW_ICON "@CMake_SOURCE_DIR@/Source/QtDialog/CMakeSetup128.png")
# Enable install default component
set(CPACK_COMPONENTS_ALL "@_CPACK_IFW_COMPONENT_NAME@")
- # Configuration
+ # Component configuration
set(CPACK_COMPONENT_ at _CPACK_IFW_COMPONENT_UNAME@_DISPLAY_NAME "@CPACK_PACKAGE_NAME@")
set(CPACK_COMPONENT_ at _CPACK_IFW_COMPONENT_UNAME@_DESCRIPTION "@CPACK_PACKAGE_DESCRIPTION_SUMMARY@")
- # IFW Configuration
+ # IFW component onfiguration
set(CPACK_IFW_COMPONENT_ at _CPACK_IFW_COMPONENT_UNAME@_NAME "@CPACK_PACKAGE_NAME@")
set(CPACK_IFW_COMPONENT_ at _CPACK_IFW_COMPONENT_UNAME@_LICENSES "@CPACK_PACKAGE_NAME@ Copyright" "@CPACK_RESOURCE_FILE_LICENSE@")
@_CPACK_IFW_COMPONENT_SCRIPT@
diff --git a/Modules/CPackIFW.cmake b/Modules/CPackIFW.cmake
index 8207b5e..1f6de8f 100644
--- a/Modules/CPackIFW.cmake
+++ b/Modules/CPackIFW.cmake
@@ -29,8 +29,37 @@
# Variables
# ^^^^^^^^^
#
-# Variables that Change Behavior
-# """"""""""""""""""""""""""""""
+# You can use the following variables to change behavior of CPack ``IFW`` generator.
+#
+# Package
+# """""""
+#
+# .. variable:: CPACK_IFW_PACKAGE_TITLE
+#
+# Name of the installer as displayed on the title bar.
+# By default used :variable:`CPACK_PACKAGE_DESCRIPTION_SUMMARY`
+#
+# .. variable:: CPACK_IFW_PACKAGE_PUBLISHER
+#
+# Publisher of the software (as shown in the Windows Control Panel).
+# By default used :variable:`CPACK_PACKAGE_VENDOR`
+#
+# .. variable:: CPACK_IFW_PRODUCT_URL
+#
+# URL to a page that contains product information on your web site.
+#
+# .. variable:: CPACK_IFW_PACKAGE_ICON
+#
+# Filename for a custom installer icon. The actual file is '.icns' (Mac OS X),
+# '.ico' (Windows). No functionality on Unix.
+#
+# .. variable:: CPACK_IFW_PACKAGE_WINDOW_ICON
+#
+# Filename for a custom window icon in PNG format for the Installer application.
+#
+# .. variable:: CPACK_IFW_PACKAGE_LOGO
+#
+# Filename for a logo used as QWizard::LogoPixmap.
#
# .. variable:: CPACK_IFW_TARGET_DIRECTORY
#
@@ -45,6 +74,9 @@
#
# You can use predefined variables.
#
+# Components
+# """"""""""
+#
# .. variable:: CPACK_IFW_RESOLVE_DUPLICATE_NAMES
#
# Resolve duplicate names when installing components with groups.
@@ -54,8 +86,8 @@
# Additional prepared packages dirs that will be used to resolve
# dependent components.
#
-# Advanced Variables
-# """"""""""""""""""
+# Advanced
+# """"""""
#
# .. variable:: CPACK_IFW_BINARYCREATOR_EXECUTABLE
#
diff --git a/Source/CPack/cmCPackIFWGenerator.cxx b/Source/CPack/cmCPackIFWGenerator.cxx
index 51c0f2e..3a7f539 100644
--- a/Source/CPack/cmCPackIFWGenerator.cxx
+++ b/Source/CPack/cmCPackIFWGenerator.cxx
@@ -680,14 +680,19 @@ int cmCPackIFWGenerator::IfwCreateConfigFile()
ifwPkgName = "Your package";
}
- std::string ifwPkgDescription;
- if (const char *name = this->GetOption("CPACK_PACKAGE_DESCRIPTION_SUMMARY"))
+ std::string pkgTitle;
+ if (const char *title = this->GetOption("CPACK_IFW_PACKAGE_TITLE"))
{
- ifwPkgDescription = name;
+ pkgTitle = title;
+ }
+ else if (const char *description =
+ this->GetOption("CPACK_PACKAGE_DESCRIPTION_SUMMARY"))
+ {
+ pkgTitle = description;
}
else
{
- ifwPkgDescription = "Your package description";
+ pkgTitle = "Your package description";
}
std::string ifwPkgVersion;
@@ -711,9 +716,64 @@ int cmCPackIFWGenerator::IfwCreateConfigFile()
cfg << "<Installer>" << std::endl;
cfg << " <Name>" << cmXMLSafe(ifwPkgName).str() << "</Name>" << std::endl;
cfg << " <Version>" << ifwPkgVersion << "</Version>" << std::endl;
- cfg << " <Title>" << cmXMLSafe(ifwPkgDescription).str() << "</Title>"
+ cfg << " <Title>" << cmXMLSafe(pkgTitle).str() << "</Title>"
<< std::endl;
+ // Publisher
+ std::string ifwPublisher;
+ if(const char *publisher = GetOption("CPACK_IFW_PACKAGE_PUBLISHER"))
+ {
+ ifwPublisher = publisher;
+ }
+ else if(const char *vendor = GetOption("CPACK_PACKAGE_VENDOR"))
+ {
+ ifwPublisher = vendor;
+ }
+ if(!ifwPublisher.empty())
+ {
+ cfg << " <Publisher>" << cmXMLSafe(ifwPublisher).str()
+ << "</Publisher>" << std::endl;
+ }
+
+ // ProductUrl
+ if(const char *url = GetOption("CPACK_IFW_PRODUCT_URL"))
+ {
+ cfg << " <ProductUrl>" << url << "</ProductUrl>" << std::endl;
+ }
+
+ // ApplicationIcon
+ const char *pkgApplicationIcon = GetOption("CPACK_IFW_PACKAGE_ICON");
+ if(pkgApplicationIcon && cmSystemTools::FileExists(pkgApplicationIcon))
+ {
+ std::string name = cmSystemTools::GetFilenameName(pkgApplicationIcon);
+ std::string path = this->toplevel + "/config/" + name;
+ name = cmSystemTools::GetFilenameWithoutExtension(name);
+ cmsys::SystemTools::CopyFileIfDifferent(pkgApplicationIcon, path.data());
+ cfg << " <InstallerApplicationIcon>" << name
+ << "</InstallerApplicationIcon>" << std::endl;
+ }
+
+ // WindowIcon
+ const char *pkgWindowIcon = GetOption("CPACK_IFW_PACKAGE_WINDOW_ICON");
+ if(pkgWindowIcon && cmSystemTools::FileExists(pkgWindowIcon))
+ {
+ std::string name = cmSystemTools::GetFilenameName(pkgWindowIcon);
+ std::string path = this->toplevel + "/config/" + name;
+ cmsys::SystemTools::CopyFileIfDifferent(pkgWindowIcon, path.data());
+ cfg << " <InstallerWindowIcon>" << name
+ << "</InstallerWindowIcon>" << std::endl;
+ }
+
+ // Logo
+ const char *pkgLogo = GetOption("CPACK_IFW_PACKAGE_LOGO");
+ if(pkgLogo && cmSystemTools::FileExists(pkgLogo))
+ {
+ std::string name = cmSystemTools::GetFilenameName(pkgLogo);
+ std::string path = this->toplevel + "/config/" + name;
+ cmsys::SystemTools::CopyFileIfDifferent(pkgLogo, path.data());
+ cfg << " <Logo>" << name << "</Logo>" << std::endl;
+ }
+
// Default target directory for installation
if (ifwTargetDir)
{
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=b234000184bbf314bf0a7380a1d4ebb54f7c8f69
commit b234000184bbf314bf0a7380a1d4ebb54f7c8f69
Author: Konstantin Podsvirov <konstantin at podsvirov.pro>
AuthorDate: Fri Jul 25 10:47:07 2014 +0400
Commit: Brad King <brad.king at kitware.com>
CommitDate: Tue Jul 29 15:52:01 2014 -0400
CPackIFW: Document cpack_ifw_configure_component DEPENDS option
diff --git a/Modules/CPackIFW.cmake b/Modules/CPackIFW.cmake
index f99488a..8207b5e 100644
--- a/Modules/CPackIFW.cmake
+++ b/Modules/CPackIFW.cmake
@@ -95,6 +95,7 @@
# [SCRIPT <script>]
# [NAME <name>]
# [PRIORITY <priority>]
+# [DEPENDS <com_id> ...]
# [LICENSES <display_name> <file_path> ...])
#
# This command should be called after cpack_add_component command.
@@ -109,6 +110,8 @@
#
# ``PRIORITY`` is priority of the component in the tree.
#
+# ``DEPENDS`` list of dependency component identifiers in QtIFW_ style.
+#
# ``LICENSES`` pair of <display_name> and <file_path> of license text for this
# component. You can specify more then one license.
#
-----------------------------------------------------------------------
Summary of changes:
CMakeCPack.cmake | 1 +
CMakeCPackOptions.cmake.in | 9 ++++-
Modules/CPackIFW.cmake | 43 +++++++++++++++++++--
Source/CPack/cmCPackIFWGenerator.cxx | 70 +++++++++++++++++++++++++++++++---
4 files changed, 112 insertions(+), 11 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list