summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2015-10-08 14:31:48 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2015-10-08 14:31:48 (GMT)
commitc997595ea36b60803068fafdbe0f7041b3cc9da0 (patch)
tree89f3b68430efaebe4665f019fb0453c5815d705e
parent3cf71728a17899673f7a07dea9d0242e7d7bff1f (diff)
parent3758af12fab8bc3c6279400621be94c4aa540a70 (diff)
downloadCMake-c997595ea36b60803068fafdbe0f7041b3cc9da0.zip
CMake-c997595ea36b60803068fafdbe0f7041b3cc9da0.tar.gz
CMake-c997595ea36b60803068fafdbe0f7041b3cc9da0.tar.bz2
Merge topic 'cpack-nsis-bitmap'
3758af12 CPackNSIS: Add options to set the bitmap for NSIS installer left side
-rw-r--r--Help/release/dev/cpack-nsis-bitmap.rst6
-rw-r--r--Modules/CPackNSIS.cmake8
-rw-r--r--Modules/NSIS.template.in2
-rw-r--r--Source/CPack/cmCPackNSISGenerator.cxx22
4 files changed, 38 insertions, 0 deletions
diff --git a/Help/release/dev/cpack-nsis-bitmap.rst b/Help/release/dev/cpack-nsis-bitmap.rst
new file mode 100644
index 0000000..c5ccfb5
--- /dev/null
+++ b/Help/release/dev/cpack-nsis-bitmap.rst
@@ -0,0 +1,6 @@
+cpack-nsis-bitmap
+-----------------
+
+* The :module:`CPackNSIS` module learned new variables to add bitmaps to the
+ installer. See the :variable:`CPACK_NSIS_MUI_WELCOMEFINISHPAGE_BITMAP`
+ and :variable:`CPACK_NSIS_MUI_UNWELCOMEFINISHPAGE_BITMAP` variables.
diff --git a/Modules/CPackNSIS.cmake b/Modules/CPackNSIS.cmake
index c6b3d19..db5984a 100644
--- a/Modules/CPackNSIS.cmake
+++ b/Modules/CPackNSIS.cmake
@@ -30,6 +30,14 @@
#
# undocumented.
#
+# .. variable:: CPACK_NSIS_MUI_WELCOMEFINISHPAGE_BITMAP
+#
+# The filename of a bitmap to use as the NSIS MUI_WELCOMEFINISHPAGE_BITMAP.
+#
+# .. variable:: CPACK_NSIS_MUI_UNWELCOMEFINISHPAGE_BITMAP
+#
+# The filename of a bitmap to use as the NSIS MUI_UNWELCOMEFINISHPAGE_BITMAP.
+#
# .. variable:: CPACK_NSIS_EXTRA_PREINSTALL_COMMANDS
#
# Extra NSIS commands that will be added to the beginning of the install
diff --git a/Modules/NSIS.template.in b/Modules/NSIS.template.in
index 76310af..1ef3d28 100644
--- a/Modules/NSIS.template.in
+++ b/Modules/NSIS.template.in
@@ -542,6 +542,8 @@ FunctionEnd
; Define some macro setting for the gui
@CPACK_NSIS_INSTALLER_MUI_ICON_CODE@
@CPACK_NSIS_INSTALLER_ICON_CODE@
+@CPACK_NSIS_INSTALLER_MUI_WELCOMEFINISH_CODE@
+@CPACK_NSIS_INSTALLER_MUI_UNWELCOMEFINISH_CODE@
@CPACK_NSIS_INSTALLER_MUI_COMPONENTS_DESC@
@CPACK_NSIS_INSTALLER_MUI_FINISHPAGE_RUN_CODE@
diff --git a/Source/CPack/cmCPackNSISGenerator.cxx b/Source/CPack/cmCPackNSISGenerator.cxx
index 52fbdaf..5ba639f 100644
--- a/Source/CPack/cmCPackNSISGenerator.cxx
+++ b/Source/CPack/cmCPackNSISGenerator.cxx
@@ -157,6 +157,28 @@ int cmCPackNSISGenerator::PackageFiles()
installerIconCode.c_str());
}
+ if (this->IsSet("CPACK_NSIS_MUI_WELCOMEFINISHPAGE_BITMAP"))
+ {
+ std::string installerBitmapCode =
+ "!define MUI_WELCOMEFINISHPAGE_BITMAP \"";
+ installerBitmapCode +=
+ this->GetOption("CPACK_NSIS_MUI_WELCOMEFINISHPAGE_BITMAP");
+ installerBitmapCode += "\"\n";
+ this->SetOptionIfNotSet("CPACK_NSIS_INSTALLER_MUI_WELCOMEFINISH_CODE",
+ installerBitmapCode.c_str());
+ }
+
+ if (this->IsSet("CPACK_NSIS_MUI_UNWELCOMEFINISHPAGE_BITMAP"))
+ {
+ std::string installerBitmapCode =
+ "!define MUI_UNWELCOMEFINISHPAGE_BITMAP \"";
+ installerBitmapCode +=
+ this->GetOption("CPACK_NSIS_MUI_UNWELCOMEFINISHPAGE_BITMAP");
+ installerBitmapCode += "\"\n";
+ this->SetOptionIfNotSet("CPACK_NSIS_INSTALLER_MUI_UNWELCOMEFINISH_CODE",
+ installerBitmapCode.c_str());
+ }
+
if(this->IsSet("CPACK_NSIS_MUI_FINISHPAGE_RUN"))
{
std::string installerRunCode = "!define MUI_FINISHPAGE_RUN \"$INSTDIR\\";