mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-01-17 14:28:24 +01:00
Use CPack for building the windows installer
This commit is contained in:
parent
51fba9ae62
commit
18aba6856b
@ -11,15 +11,23 @@ ENDIF( ${CMAKE_VERSION} VERSION_GREATER 2.8.3 )
|
||||
SET( TOMAHAWK_ORGANIZATION_NAME "Tomahawk" )
|
||||
SET( TOMAHAWK_ORGANIZATION_DOMAIN "tomahawk-player.org" )
|
||||
SET( TOMAHAWK_APPLICATION_NAME "Tomahawk" )
|
||||
SET( TOMAHAWK_VERSION "0.1.0" )
|
||||
SET( TOMAHAWK_DESCRIPTION_SUMMARY "The social media player" )
|
||||
|
||||
SET( TOMAHAWK_VERSION_MAJOR 0 )
|
||||
SET( TOMAHAWK_VERSION_MINOR 1 )
|
||||
SET( TOMAHAWK_VERSION_PATCH 0 )
|
||||
SET( TOMAHAWK_VERSION ${TOMAHAWK_VERSION_MAJOR}.${TOMAHAWK_VERSION_MINOR}.${TOMAHAWK_VERSION_PATCH} )
|
||||
|
||||
|
||||
# set paths
|
||||
SET( CMAKE_MODULE_PATH "${CMAKE_MODULE_PATH}" "${CMAKE_SOURCE_DIR}/CMakeModules" )
|
||||
SET( THIRDPARTY_DIR ${CMAKE_SOURCE_DIR}/thirdparty )
|
||||
SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}")
|
||||
SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}")
|
||||
SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}")
|
||||
SET( CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}" )
|
||||
SET( CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}" )
|
||||
SET( CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}" )
|
||||
|
||||
# installer creation
|
||||
INCLUDE( CPack.cmake )
|
||||
|
||||
# Check if we need qtgui:
|
||||
IF( "${gui}" STREQUAL "no" )
|
||||
|
24
CMakeModules/NSIS.InstallOptions.ini.in
Normal file
24
CMakeModules/NSIS.InstallOptions.ini.in
Normal file
@ -0,0 +1,24 @@
|
||||
[Settings]
|
||||
NumFields=3
|
||||
|
||||
[Field 1]
|
||||
Type=Label
|
||||
Left=0
|
||||
Right=-1
|
||||
Top=0
|
||||
Bottom=24
|
||||
|
||||
[Field 2]
|
||||
Type=RadioButton
|
||||
Left=30
|
||||
Right=-1
|
||||
Top=50
|
||||
Bottom=58
|
||||
State=1
|
||||
|
||||
[Field 3]
|
||||
Type=RadioButton
|
||||
Left=30
|
||||
Right=-1
|
||||
Top=70
|
||||
Bottom=78
|
665
CMakeModules/NSIS.template.in
Normal file
665
CMakeModules/NSIS.template.in
Normal file
@ -0,0 +1,665 @@
|
||||
;Tomahawk installer script.
|
||||
|
||||
;-----------------------------------------------------------------------------
|
||||
; Some installer script options (comment-out options not required)
|
||||
;-----------------------------------------------------------------------------
|
||||
;!define OPTION_LICENSE_AGREEMENT
|
||||
!define OPTION_UAC_PLUGIN_ENHANCED
|
||||
!define OPTION_SECTION_SC_START_MENU
|
||||
!define OPTION_SECTION_SC_DESKTOP
|
||||
!define OPTION_SECTION_SC_QUICK_LAUNCH
|
||||
!define OPTION_FINISHPAGE
|
||||
!define OPTION_FINISHPAGE_LAUNCHER
|
||||
!define OPTION_FINISHPAGE_RELEASE_NOTES
|
||||
|
||||
;-----------------------------------------------------------------------------
|
||||
; Some paths.
|
||||
;-----------------------------------------------------------------------------
|
||||
!ifndef MING_PATH
|
||||
!define MING_PATH "/usr/i686-w64-mingw32/sys-root/mingw"
|
||||
!endif
|
||||
!define MING_BIN "${MING_PATH}/bin"
|
||||
!define MING_LIB "${MING_PATH}/lib"
|
||||
!define BUILD_PATH "@CMAKE_BINARY_DIR@"
|
||||
!define QT_DLL_PATH "${MING_BIN}"
|
||||
!define SQLITE_DLL_PATH "${MING_LIB}/qt4/plugins/sqldrivers"
|
||||
!define IMAGEFORMATS_DLL_PATH "${MING_LIB}/qt4/plugins/imageformats"
|
||||
!define VLC_PLUGIN_PATH "${MING_LIB}\vlc\plugins"
|
||||
!define NSI_PATH "@CMAKE_SOURCE_DIR@/admin/win/nsi"
|
||||
|
||||
;-----------------------------------------------------------------------------
|
||||
; Increment installer revision number as part of this script.
|
||||
;-----------------------------------------------------------------------------
|
||||
!define /file REVISION_LAST ${NSI_PATH}/revision.txt
|
||||
!define /math REVISION ${REVISION_LAST} + 1
|
||||
!delfile revision.txt
|
||||
!appendfile revision.txt ${REVISION}
|
||||
|
||||
!define VER_MAJOR "@CPACK_PACKAGE_VERSION_MAJOR@"
|
||||
!define VER_MINOR "@CPACK_PACKAGE_VERSION_MINOR@"
|
||||
!define VER_BUILD "@CPACK_PACKAGE_VERSION_PATCH@"
|
||||
!define VERSION "@CPACK_PACKAGE_VERSION@"
|
||||
|
||||
;-----------------------------------------------------------------------------
|
||||
; Installer build timestamp.
|
||||
;-----------------------------------------------------------------------------
|
||||
!define /date BUILD_TIME "built on %Y/%m/%d at %I:%M %p (rev. ${REVISION})"
|
||||
|
||||
;-----------------------------------------------------------------------------
|
||||
; Initial installer setup and definitions.
|
||||
;-----------------------------------------------------------------------------
|
||||
Name "@CPACK_NSIS_PACKAGE_NAME@"
|
||||
Caption "Tomahawk Installer"
|
||||
BrandingText "Tomahawk ${VERSION} -- ${BUILD_TIME}"
|
||||
OutFile "@CPACK_TOPLEVEL_DIRECTORY@/@CPACK_OUTPUT_FILE_NAME@"
|
||||
InstallDir "$PROGRAMFILES\@CPACK_PACKAGE_INSTALL_DIRECTORY@"
|
||||
InstallDirRegKey HKCU "Software\Tomahawk" ""
|
||||
InstType Standard
|
||||
InstType Full
|
||||
InstType Minimal
|
||||
CRCCheck On
|
||||
SetCompressor @CPACK_NSIS_COMPRESSOR@
|
||||
RequestExecutionLevel user ;Now using the UAC plugin.
|
||||
ReserveFile NSIS.InstallOptions.ini
|
||||
ReserveFile "${NSISDIR}\Plugins\InstallOptions.dll"
|
||||
|
||||
@CPACK_NSIS_SECTION_SELECTED_VARS@
|
||||
|
||||
;-----------------------------------------------------------------------------
|
||||
; Include some required header files.
|
||||
;-----------------------------------------------------------------------------
|
||||
!include LogicLib.nsh ;Used by APPDATA uninstaller.
|
||||
!include nsDialogs.nsh ;Used by APPDATA uninstaller.
|
||||
!include MUI2.nsh ;Used by APPDATA uninstaller.
|
||||
!include InstallOptions.nsh ;Required by MUI2 to support old MUI_INSTALLOPTIONS.
|
||||
!include Memento.nsh ;Remember user selections.
|
||||
!include WinVer.nsh ;Windows version detection.
|
||||
!include WordFunc.nsh ;Used by VersionCompare macro function.
|
||||
!include UAC.nsh ;Used by the UAC elevation to install as user or admin.
|
||||
|
||||
;-----------------------------------------------------------------------------
|
||||
; Memento selections stored in registry.
|
||||
;-----------------------------------------------------------------------------
|
||||
!define MEMENTO_REGISTRY_ROOT HKLM
|
||||
!define MEMENTO_REGISTRY_KEY Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk
|
||||
|
||||
;-----------------------------------------------------------------------------
|
||||
; Modern User Interface (MUI) defintions and setup.
|
||||
;-----------------------------------------------------------------------------
|
||||
!define MUI_ABORTWARNING
|
||||
!define MUI_ICON ${NSI_PATH}\installer.ico
|
||||
!define MUI_UNICON ${NSI_PATH}\installer.ico
|
||||
!define MUI_WELCOMEFINISHPAGE_BITMAP ${NSI_PATH}\welcome.bmp
|
||||
!define MUI_WELCOMEPAGE_TITLE "@CPACK_PACKAGE_NAME@ ${VERSION} Setup$\r$\nInstaller Build Revision ${REVISION}"
|
||||
!define MUI_WELCOMEPAGE_TEXT "This wizard will guide you through the installation.$\r$\n$\r$\n$_CLICK"
|
||||
!define MUI_HEADERIMAGE
|
||||
!define MUI_HEADERIMAGE_BITMAP ${NSI_PATH}\page_header.bmp
|
||||
!define MUI_COMPONENTSPAGE_SMALLDESC
|
||||
!define MUI_FINISHPAGE_TITLE "@CPACK_PACKAGE_NAME@ Install Completed"
|
||||
!define MUI_FINISHPAGE_LINK "Click here to visit the @CPACK_PACKAGE_NAME@ website."
|
||||
!define MUI_FINISHPAGE_LINK_LOCATION "http://@TOMAHAWK_ORGANIZATION_DOMAIN@"
|
||||
!define MUI_FINISHPAGE_NOREBOOTSUPPORT
|
||||
!ifdef OPTION_FINISHPAGE_RELEASE_NOTES
|
||||
!define MUI_FINISHPAGE_SHOWREADME_NOTCHECKED
|
||||
!define MUI_FINISHPAGE_SHOWREADME "$INSTDIR\NOTES.txt"
|
||||
!define MUI_FINISHPAGE_SHOWREADME_TEXT "Show release notes"
|
||||
!endif
|
||||
!ifdef OPTION_FINISHPAGE_LAUNCHER
|
||||
!define MUI_FINISHPAGE_NOAUTOCLOSE
|
||||
!define MUI_FINISHPAGE_RUN
|
||||
!define MUI_FINISHPAGE_RUN_FUNCTION "LaunchTomahawk"
|
||||
!endif
|
||||
|
||||
;-----------------------------------------------------------------------------
|
||||
; Page macros.
|
||||
;-----------------------------------------------------------------------------
|
||||
!insertmacro MUI_PAGE_WELCOME
|
||||
!ifdef OPTION_LICENSE_AGREEMENT
|
||||
!insertmacro MUI_PAGE_LICENSE "LICENSE.txt"
|
||||
!endif
|
||||
Page custom PageReinstall PageLeaveReinstall
|
||||
!insertmacro MUI_PAGE_COMPONENTS
|
||||
!insertmacro MUI_PAGE_DIRECTORY
|
||||
!insertmacro MUI_PAGE_INSTFILES
|
||||
!ifdef OPTION_FINISHPAGE
|
||||
!insertmacro MUI_PAGE_FINISH
|
||||
!endif
|
||||
!insertmacro MUI_UNPAGE_CONFIRM
|
||||
UninstPage custom un.UnPageUserAppData un.UnPageUserAppDataLeave
|
||||
!insertmacro MUI_UNPAGE_INSTFILES
|
||||
|
||||
;-----------------------------------------------------------------------------
|
||||
; Other MUI macros.
|
||||
;-----------------------------------------------------------------------------
|
||||
!insertmacro MUI_LANGUAGE "English"
|
||||
|
||||
##############################################################################
|
||||
# #
|
||||
# FINISH PAGE LAUNCHER FUNCTIONS #
|
||||
# #
|
||||
##############################################################################
|
||||
|
||||
Function LaunchTomahawk
|
||||
${UAC.CallFunctionAsUser} LaunchTomahawkAsUser
|
||||
FunctionEnd
|
||||
|
||||
Function LaunchTomahawkAsUser
|
||||
Exec "$INSTDIR\tomahawk.exe"
|
||||
FunctionEnd
|
||||
|
||||
##############################################################################
|
||||
# #
|
||||
# PROCESS HANDLING FUNCTIONS AND MACROS #
|
||||
# #
|
||||
##############################################################################
|
||||
|
||||
!macro CheckForProcess processName gotoWhenFound gotoWhenNotFound
|
||||
Processes::FindProcess ${processName}
|
||||
StrCmp $R0 "0" ${gotoWhenNotFound} ${gotoWhenFound}
|
||||
!macroend
|
||||
|
||||
!macro ConfirmEndProcess processName
|
||||
MessageBox MB_YESNO|MB_ICONEXCLAMATION \
|
||||
"Found ${processName} process(s) which need to be stopped.$\nDo you want the installer to stop these for you?" \
|
||||
IDYES process_${processName}_kill IDNO process_${processName}_ended
|
||||
process_${processName}_kill:
|
||||
DetailPrint "Killing ${processName} processes."
|
||||
Processes::KillProcess ${processName}
|
||||
Sleep 1500
|
||||
StrCmp $R0 "1" process_${processName}_ended
|
||||
DetailPrint "Process to kill not found!"
|
||||
process_${processName}_ended:
|
||||
!macroend
|
||||
|
||||
!macro CheckAndConfirmEndProcess processName
|
||||
!insertmacro CheckForProcess ${processName} 0 no_process_${processName}_to_end
|
||||
!insertmacro ConfirmEndProcess ${processName}
|
||||
no_process_${processName}_to_end:
|
||||
!macroend
|
||||
|
||||
Function EnsureTomahawkShutdown
|
||||
!insertmacro CheckAndConfirmEndProcess "tomahawk.exe"
|
||||
FunctionEnd
|
||||
|
||||
##############################################################################
|
||||
# #
|
||||
# RE-INSTALLER FUNCTIONS #
|
||||
# #
|
||||
##############################################################################
|
||||
|
||||
Function PageReinstall
|
||||
ReadRegStr $R0 HKLM "Software\Tomahawk" ""
|
||||
StrCmp $R0 "" 0 +2
|
||||
Abort
|
||||
|
||||
;Detect version
|
||||
ReadRegDWORD $R0 HKLM "Software\Tomahawk" "VersionMajor"
|
||||
IntCmp $R0 ${VER_MAJOR} minor_check new_version older_version
|
||||
minor_check:
|
||||
ReadRegDWORD $R0 HKLM "Software\Tomahawk" "VersionMinor"
|
||||
IntCmp $R0 ${VER_MINOR} build_check new_version older_version
|
||||
build_check:
|
||||
ReadRegDWORD $R0 HKLM "Software\Tomahawk" "VersionBuild"
|
||||
IntCmp $R0 ${VER_BUILD} revision_check new_version older_version
|
||||
revision_check:
|
||||
ReadRegDWORD $R0 HKLM "Software\Tomahawk" "VersionRevision"
|
||||
IntCmp $R0 ${REVISION} same_version new_version older_version
|
||||
|
||||
new_version:
|
||||
!insertmacro INSTALLOPTIONS_WRITE "NSIS.InstallOptions.ini" "Field 1" "Text" "An older version of Tomahawk is installed on your system. It is recommended that you uninstall the current version before installing. Select the operation you want to perform and click Next to continue."
|
||||
!insertmacro INSTALLOPTIONS_WRITE "NSIS.InstallOptions.ini" "Field 2" "Text" "Uninstall before installing"
|
||||
!insertmacro INSTALLOPTIONS_WRITE "NSIS.InstallOptions.ini" "Field 3" "Text" "Do not uninstall"
|
||||
!insertmacro MUI_HEADER_TEXT "Already Installed" "Choose how you want to install Tomahawk."
|
||||
StrCpy $R0 "1"
|
||||
Goto reinst_start
|
||||
|
||||
older_version:
|
||||
!insertmacro INSTALLOPTIONS_WRITE "NSIS.InstallOptions.ini" "Field 1" "Text" "A newer version of Tomahawk is already installed! It is not recommended that you install an older version. If you really want to install this older version, it is better to uninstall the current version first. Select the operation you want to perform and click Next to continue."
|
||||
!insertmacro INSTALLOPTIONS_WRITE "NSIS.InstallOptions.ini" "Field 2" "Text" "Uninstall before installing"
|
||||
!insertmacro INSTALLOPTIONS_WRITE "NSIS.InstallOptions.ini" "Field 3" "Text" "Do not uninstall"
|
||||
!insertmacro MUI_HEADER_TEXT "Already Installed" "Choose how you want to install Tomahawk."
|
||||
StrCpy $R0 "1"
|
||||
Goto reinst_start
|
||||
|
||||
same_version:
|
||||
!insertmacro INSTALLOPTIONS_WRITE "NSIS.InstallOptions.ini" "Field 1" "Text" "Tomahawk ${VERSION} is already installed.\r\nSelect the operation you want to perform and click Next to continue."
|
||||
!insertmacro INSTALLOPTIONS_WRITE "NSIS.InstallOptions.ini" "Field 2" "Text" "Add/Reinstall components"
|
||||
!insertmacro INSTALLOPTIONS_WRITE "NSIS.InstallOptions.ini" "Field 3" "Text" "Uninstall Tomahawk"
|
||||
!insertmacro MUI_HEADER_TEXT "Already Installed" "Choose the maintenance option to perform."
|
||||
StrCpy $R0 "2"
|
||||
|
||||
reinst_start:
|
||||
!insertmacro INSTALLOPTIONS_DISPLAY "NSIS.InstallOptions.ini"
|
||||
FunctionEnd
|
||||
|
||||
Function PageLeaveReinstall
|
||||
!insertmacro INSTALLOPTIONS_READ $R1 "NSIS.InstallOptions.ini" "Field 2" "State"
|
||||
StrCmp $R0 "1" 0 +2
|
||||
StrCmp $R1 "1" reinst_uninstall reinst_done
|
||||
StrCmp $R0 "2" 0 +3
|
||||
StrCmp $R1 "1" reinst_done reinst_uninstall
|
||||
reinst_uninstall:
|
||||
ReadRegStr $R1 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "UninstallString"
|
||||
HideWindow
|
||||
ClearErrors
|
||||
ExecWait '$R1 _?=$INSTDIR'
|
||||
IfErrors no_remove_uninstaller
|
||||
IfFileExists "$INSTDIR\tomahawk.exe" no_remove_uninstaller
|
||||
Delete $R1
|
||||
RMDir $INSTDIR
|
||||
no_remove_uninstaller:
|
||||
StrCmp $R0 "2" 0 +3
|
||||
UAC::Unload
|
||||
Quit
|
||||
BringToFront
|
||||
reinst_done:
|
||||
FunctionEnd
|
||||
|
||||
##############################################################################
|
||||
# #
|
||||
# INSTALLER SECTIONS #
|
||||
# #
|
||||
##############################################################################
|
||||
Section "Tomahawk Player" SEC_TOMAHAWK_PLAYER
|
||||
SectionIn 1 2 3 RO
|
||||
SetDetailsPrint listonly
|
||||
|
||||
SetDetailsPrint textonly
|
||||
DetailPrint "Installing Tomahawk Player essentials."
|
||||
SetDetailsPrint listonly
|
||||
SetOutPath "$INSTDIR"
|
||||
|
||||
!ifdef INSTALL_PATH
|
||||
;Main executable.
|
||||
File "${INSTALL_PATH}\bin\tomahawk.exe"
|
||||
|
||||
File "${INSTALL_PATH}\bin\libqxtweb-standalone.dll"
|
||||
File "${INSTALL_PATH}\bin\libtomahawk_portfwd.dll"
|
||||
File "${INSTALL_PATH}\bin\libtomahawk_lastfm2.dll"
|
||||
File "${INSTALL_PATH}\bin\libtomahawklib.dll"
|
||||
File "${INSTALL_PATH}\lib\libtomahawk_sip*.dll"
|
||||
!endif
|
||||
!ifndef INSTALL_PATH
|
||||
;Main executable.
|
||||
File "${BUILD_PATH}\tomahawk.exe"
|
||||
|
||||
File "${BUILD_PATH}\libtomahawklib.dll"
|
||||
File "${BUILD_PATH}\libqxtweb-standalone.dll"
|
||||
File "${BUILD_PATH}\libtomahawk_portfwd.dll"
|
||||
File "${BUILD_PATH}\libtomahawk_lastfm2.dll"
|
||||
File "${BUILD_PATH}\libtomahawk_sip*.dll"
|
||||
!endif
|
||||
|
||||
;License & release notes.
|
||||
File "@CPACK_RESOURCE_FILE_LICENSE@"
|
||||
File /oname=NOTES.txt ${NSI_PATH}\RELEASE_NOTES.txt
|
||||
|
||||
;QT stuff:
|
||||
File "${QT_DLL_PATH}\QtCore4.dll"
|
||||
File "${QT_DLL_PATH}\QtGui4.dll"
|
||||
File "${QT_DLL_PATH}\QtNetwork4.dll"
|
||||
File "${QT_DLL_PATH}\QtSql4.dll"
|
||||
File "${QT_DLL_PATH}\QtXml4.dll"
|
||||
File "${QT_DLL_PATH}\QtWebKit4.dll"
|
||||
|
||||
;SQLite driver
|
||||
SetOutPath "$INSTDIR\sqldrivers"
|
||||
File "${SQLITE_DLL_PATH}\qsqlite4.dll"
|
||||
SetOutPath "$INSTDIR"
|
||||
|
||||
;Image plugins
|
||||
SetOutPath "$INSTDIR\imageformats"
|
||||
File "${IMAGEFORMATS_DLL_PATH}\qgif4.dll"
|
||||
File "${IMAGEFORMATS_DLL_PATH}\qjpeg4.dll"
|
||||
SetOutPath "$INSTDIR"
|
||||
|
||||
;Cygwin/c++ stuff
|
||||
;File "${MING_BIN}\cygmad-0.dll"
|
||||
;File "${MING_BIN}\libgcc_s_dw2-1.dll"
|
||||
;File "${MING_BIN}\mingwm10.dll"
|
||||
File "${MING_BIN}\libgcc_s_sjlj-1.dll"
|
||||
File "${MING_BIN}\libstdc++-6.dll"
|
||||
|
||||
;Phonon stuff
|
||||
|
||||
;Fix the phonon build to not use Dbus
|
||||
File "${QT_DLL_PATH}\QtDbus4.dll"
|
||||
File "${MING_BIN}\libdbus-1-3.dll"
|
||||
File "${MING_BIN}\dbus-daemon.exe"
|
||||
|
||||
File "${MING_BIN}\libphonon.dll"
|
||||
SetOutPath "$INSTDIR\phonon_backend"
|
||||
File "${MING_BIN}\phonon_backend\phonon_vlc.dll"
|
||||
SetOutPath "$INSTDIR"
|
||||
|
||||
;VLC
|
||||
;SetOutPath "$INSTDIR\phonon_backend"
|
||||
File "${MING_BIN}\libvlc.dll"
|
||||
File "${MING_BIN}\libvlccore.dll"
|
||||
SetOutPath "$INSTDIR\plugins"
|
||||
File /r "${VLC_PLUGIN_PATH}\*.dll"
|
||||
SetOutPath "$INSTDIR"
|
||||
File "${MING_BIN}\libmad-0.dll" ; MP3
|
||||
File "${MING_BIN}\libFLAC-8.dll" ; FLAC
|
||||
File "${MING_BIN}\libogg-0.dll" ; OGG, FLAC
|
||||
File "${MING_BIN}\libvorbis-0.dll" ; OGG
|
||||
File "${MING_BIN}\libvorbisenc-2.dll" ; OGG
|
||||
|
||||
|
||||
|
||||
; Other
|
||||
File "${MING_BIN}\libqjson.dll"
|
||||
File "${MING_BIN}\libtag.dll"
|
||||
File "${MING_BIN}\libpng15-15.dll"
|
||||
File "${MING_BIN}\libjpeg-8.dll"
|
||||
File "${MING_BIN}\zlib1.dll"
|
||||
|
||||
File "${MING_BIN}\libechonest.dll"
|
||||
File "${MING_BIN}\libQTweetLib.dll"
|
||||
|
||||
; Jabber
|
||||
File "${MING_BIN}\libjreen.dll"
|
||||
File "${MING_BIN}\libqca.dll"
|
||||
SetOutPath "$INSTDIR\crypto"
|
||||
File "${MING_LIB}\qt4\plugins\crypto\libqca-ossl.dll"
|
||||
SetOutPath "$INSTDIR"
|
||||
File "${MING_BIN}\libssl-8.dll"
|
||||
File "${MING_BIN}\libcrypto-8.dll"
|
||||
|
||||
File "${MING_LIB}\libclucene-core.dll"
|
||||
File "${MING_LIB}\libclucene-shared.dll"
|
||||
|
||||
File "${MING_BIN}\libqtsparkle.dll"
|
||||
SectionEnd
|
||||
|
||||
SectionGroup "Shortcuts"
|
||||
|
||||
!ifdef OPTION_SECTION_SC_START_MENU
|
||||
${MementoSection} "Start Menu Program Group" SEC_START_MENU
|
||||
SectionIn 1 2
|
||||
SetDetailsPrint textonly
|
||||
DetailPrint "Adding shortcuts for the Tomahawk program group to the Start Menu."
|
||||
SetDetailsPrint listonly
|
||||
SetShellVarContext all
|
||||
RMDir /r "$SMPROGRAMS\Tomahawk"
|
||||
CreateDirectory "$SMPROGRAMS\Tomahawk"
|
||||
CreateShortCut "$SMPROGRAMS\Tomahawk\LICENSE.lnk" "$INSTDIR\LICENSE.txt"
|
||||
CreateShortCut "$SMPROGRAMS\Tomahawk\Tomahawk.lnk" "$INSTDIR\tomahawk.exe"
|
||||
CreateShortCut "$SMPROGRAMS\Tomahawk\Release notes.lnk" "$INSTDIR\NOTES.txt"
|
||||
CreateShortCut "$SMPROGRAMS\Tomahawk\Uninstall.lnk" "$INSTDIR\uninstall.exe"
|
||||
SetShellVarContext current
|
||||
${MementoSectionEnd}
|
||||
!endif
|
||||
|
||||
!ifdef OPTION_SECTION_SC_DESKTOP
|
||||
${MementoSection} "Desktop Shortcut" SEC_DESKTOP
|
||||
SectionIn 1 2
|
||||
SetDetailsPrint textonly
|
||||
DetailPrint "Creating Desktop Shortcuts"
|
||||
SetDetailsPrint listonly
|
||||
CreateShortCut "$DESKTOP\Tomahawk.lnk" "$INSTDIR\tomahawk.exe"
|
||||
${MementoSectionEnd}
|
||||
!endif
|
||||
|
||||
!ifdef OPTION_SECTION_SC_QUICK_LAUNCH
|
||||
${MementoSection} "Quick Launch Shortcut" SEC_QUICK_LAUNCH
|
||||
SectionIn 1 2
|
||||
SetDetailsPrint textonly
|
||||
DetailPrint "Creating Quick Launch Shortcut"
|
||||
SetDetailsPrint listonly
|
||||
CreateShortCut "$QUICKLAUNCH\Tomahawk.lnk" "$INSTDIR\tomahawk.exe"
|
||||
${MementoSectionEnd}
|
||||
!endif
|
||||
|
||||
SectionGroupEnd
|
||||
|
||||
${MementoSectionDone}
|
||||
|
||||
; Installer section descriptions
|
||||
;--------------------------------
|
||||
!insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
|
||||
!insertmacro MUI_DESCRIPTION_TEXT ${SEC_TOMAHAWK_PLAYER} "Tomahawk player essentials."
|
||||
!insertmacro MUI_DESCRIPTION_TEXT ${SEC_START_MENU} "Tomahawk program group."
|
||||
!insertmacro MUI_DESCRIPTION_TEXT ${SEC_DESKTOP} "Desktop shortcut for Tomahawk."
|
||||
!insertmacro MUI_DESCRIPTION_TEXT ${SEC_QUICK_LAUNCH} "Quick Launch shortcut for Tomahawk."
|
||||
!insertmacro MUI_FUNCTION_DESCRIPTION_END
|
||||
|
||||
Section -post
|
||||
|
||||
;Uninstaller file.
|
||||
SetDetailsPrint textonly
|
||||
DetailPrint "Writing Uninstaller"
|
||||
SetDetailsPrint listonly
|
||||
WriteUninstaller $INSTDIR\uninstall.exe
|
||||
|
||||
;Registry keys required for installer version handling and uninstaller.
|
||||
SetDetailsPrint textonly
|
||||
DetailPrint "Writing Installer Registry Keys"
|
||||
SetDetailsPrint listonly
|
||||
|
||||
;Version numbers used to detect existing installation version for comparisson.
|
||||
WriteRegStr HKLM "Software\Tomahawk" "" $INSTDIR
|
||||
WriteRegDWORD HKLM "Software\Tomahawk" "VersionMajor" "${VER_MAJOR}"
|
||||
WriteRegDWORD HKLM "Software\Tomahawk" "VersionMinor" "${VER_MINOR}"
|
||||
WriteRegDWORD HKLM "Software\Tomahawk" "VersionRevision" "${REVISION}"
|
||||
WriteRegDWORD HKLM "Software\Tomahawk" "VersionBuild" "${VER_BUILD}"
|
||||
|
||||
;Add or Remove Programs entry.
|
||||
WriteRegExpandStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "UninstallString" '"$INSTDIR\Uninstall.exe"'
|
||||
WriteRegExpandStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "InstallLocation" "$INSTDIR"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "DisplayName" "Tomahawk"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "Publisher" "Tomahawk-player.org"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "DisplayIcon" "$INSTDIR\Uninstall.exe,0"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "DisplayVersion" "${VERSION}"
|
||||
WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "VersionMajor" "${VER_MAJOR}"
|
||||
WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "VersionMinor" "${VER_MINOR}.${REVISION}"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "URLInfoAbout" "http://tomahawk-player.org/"
|
||||
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "HelpLink" "http://tomahawk-player.org/"
|
||||
WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "NoModify" "1"
|
||||
WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "NoRepair" "1"
|
||||
|
||||
; Register tomahawk:// protocol handler
|
||||
WriteRegStr HKCR "tomahawk" "" "URL: Tomahawk Protocol"
|
||||
WriteRegStr HKCR "tomahawk\DefaultIcon" "" $INSTDIR\tomahawk.exe,1
|
||||
WriteRegStr HKCR "tomahawk\shell" "" "open"
|
||||
WriteRegStr HKCR "tomahawk\shell\open\command" "" '"$INSTDIR\tomahawk.exe" "%1"'
|
||||
|
||||
SetDetailsPrint textonly
|
||||
DetailPrint "Finsihed."
|
||||
SectionEnd
|
||||
|
||||
##############################################################################
|
||||
# #
|
||||
# UNINSTALLER SECTION #
|
||||
# #
|
||||
##############################################################################
|
||||
|
||||
Var UnPageUserAppDataDialog
|
||||
Var UnPageUserAppDataCheckbox
|
||||
Var UnPageUserAppDataCheckbox_State
|
||||
Var UnPageUserAppDataEditBox
|
||||
|
||||
Function un.UnPageUserAppData
|
||||
!insertmacro MUI_HEADER_TEXT "Uninstall Tomahawk" "Remove Tomahawk's data folder from your computer."
|
||||
nsDialogs::Create /NOUNLOAD 1018
|
||||
Pop $UnPageUserAppDataDialog
|
||||
|
||||
${If} $UnPageUserAppDataDialog == error
|
||||
Abort
|
||||
${EndIf}
|
||||
|
||||
${NSD_CreateLabel} 0 0 100% 12u "Do you want to delete Tomahawk's data folder?"
|
||||
Pop $0
|
||||
|
||||
${NSD_CreateText} 0 13u 100% 12u "$LOCALAPPDATA\Tomahawk"
|
||||
Pop $UnPageUserAppDataEditBox
|
||||
SendMessage $UnPageUserAppDataEditBox ${EM_SETREADONLY} 1 0
|
||||
|
||||
${NSD_CreateLabel} 0 46u 100% 24u "Leave unchecked to keep the data folder for later use or check to delete the data folder."
|
||||
Pop $0
|
||||
|
||||
${NSD_CreateCheckbox} 0 71u 100% 8u "Yes, delete this data folder."
|
||||
Pop $UnPageUserAppDataCheckbox
|
||||
|
||||
nsDialogs::Show
|
||||
FunctionEnd
|
||||
|
||||
Function un.UnPageUserAppDataLeave
|
||||
${NSD_GetState} $UnPageUserAppDataCheckbox $UnPageUserAppDataCheckbox_State
|
||||
FunctionEnd
|
||||
|
||||
Section Uninstall
|
||||
IfFileExists "$INSTDIR\tomahawk.exe" tomahawk_installed
|
||||
MessageBox MB_YESNO "It does not appear that Tomahawk is installed in the directory '$INSTDIR'.$\r$\nContinue anyway (not recommended)?" IDYES tomahawk_installed
|
||||
Abort "Uninstall aborted by user"
|
||||
tomahawk_installed:
|
||||
|
||||
;Delete registry keys.
|
||||
DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk"
|
||||
DeleteRegValue HKLM "Software\Tomahawk" "VersionBuild"
|
||||
DeleteRegValue HKLM "Software\Tomahawk" "VersionMajor"
|
||||
DeleteRegValue HKLM "Software\Tomahawk" "VersionMinor"
|
||||
DeleteRegValue HKLM "Software\Tomahawk" "VersionRevision"
|
||||
DeleteRegValue HKLM "Software\Tomahawk" ""
|
||||
DeleteRegKey HKLM "Software\Tomahawk"
|
||||
|
||||
DeleteRegKey HKCR "tomahawk"
|
||||
|
||||
;Start menu shortcuts.
|
||||
!ifdef OPTION_SECTION_SC_START_MENU
|
||||
SetShellVarContext all
|
||||
RMDir /r "$SMPROGRAMS\Tomahawk"
|
||||
SetShellVarContext current
|
||||
!endif
|
||||
|
||||
;Desktop shortcut.
|
||||
!ifdef OPTION_SECTION_SC_DESKTOP
|
||||
IfFileExists "$DESKTOP\Tomahawk.lnk" 0 +2
|
||||
Delete "$DESKTOP\Tomahawk.lnk"
|
||||
!endif
|
||||
|
||||
;Quick Launch shortcut.
|
||||
!ifdef OPTION_SECTION_SC_QUICK_LAUNCH
|
||||
IfFileExists "$QUICKLAUNCH\Tomahawk.lnk" 0 +2
|
||||
Delete "$QUICKLAUNCH\Tomahawk.lnk"
|
||||
!endif
|
||||
|
||||
;Remove all the Program Files.
|
||||
RMDir /r $INSTDIR
|
||||
|
||||
;Uninstall User Data if option is checked, otherwise skip.
|
||||
${If} $UnPageUserAppDataCheckbox_State == ${BST_CHECKED}
|
||||
RMDir /r "$LOCALAPPDATA\Tomahawk"
|
||||
${EndIf}
|
||||
|
||||
SetDetailsPrint textonly
|
||||
DetailPrint "Finsihed."
|
||||
SectionEnd
|
||||
|
||||
##############################################################################
|
||||
# #
|
||||
# NSIS Installer Event Handler Functions #
|
||||
# #
|
||||
##############################################################################
|
||||
|
||||
Function .onInit
|
||||
!insertmacro INSTALLOPTIONS_EXTRACT "NSIS.InstallOptions.ini"
|
||||
|
||||
;Remove Quick Launch option from Windows 7, as no longer applicable - usually.
|
||||
${IfNot} ${AtMostWinVista}
|
||||
SectionSetText ${SEC_QUICK_LAUNCH} "Quick Launch Shortcut (N/A)"
|
||||
SectionSetFlags ${SEC_QUICK_LAUNCH} ${SF_RO}
|
||||
SectionSetInstTypes ${SEC_QUICK_LAUNCH} 0
|
||||
${EndIf}
|
||||
|
||||
${MementoSectionRestore}
|
||||
|
||||
UAC_Elevate:
|
||||
UAC::RunElevated
|
||||
StrCmp 1223 $0 UAC_ElevationAborted ; UAC dialog aborted by user?
|
||||
StrCmp 0 $0 0 UAC_Err ; Error?
|
||||
StrCmp 1 $1 0 UAC_Success ;Are we the real deal or just the wrapper?
|
||||
Quit
|
||||
|
||||
UAC_Err:
|
||||
MessageBox MB_ICONSTOP "Unable to elevate, error $0"
|
||||
Abort
|
||||
|
||||
UAC_ElevationAborted:
|
||||
Abort
|
||||
|
||||
UAC_Success:
|
||||
StrCmp 1 $3 +4 ;Admin?
|
||||
StrCmp 3 $1 0 UAC_ElevationAborted ;Try again?
|
||||
MessageBox MB_ICONSTOP "This installer requires admin access, try again"
|
||||
goto UAC_Elevate
|
||||
|
||||
;Prevent multiple instances.
|
||||
System::Call 'kernel32::CreateMutexA(i 0, i 0, t "tomahawkInstaller") i .r1 ?e'
|
||||
Pop $R0
|
||||
StrCmp $R0 0 +3
|
||||
MessageBox MB_OK|MB_ICONEXCLAMATION "The installer is already running."
|
||||
Abort
|
||||
|
||||
;Use available InstallLocation when possible. This is useful in the uninstaller
|
||||
;via re-install, which would otherwise use a default location - a bug.
|
||||
ReadRegStr $R0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "InstallLocation"
|
||||
StrCmp $R0 "" SkipSetInstDir
|
||||
StrCpy $INSTDIR $R0
|
||||
SkipSetInstDir:
|
||||
|
||||
;Shutdown Tomahawk in case Add/Remove re-installer option used.
|
||||
Call EnsureTomahawkShutdown
|
||||
FunctionEnd
|
||||
|
||||
Function .onInstSuccess
|
||||
${MementoSectionSave}
|
||||
UAC::Unload ;Must call unload!
|
||||
FunctionEnd
|
||||
|
||||
Function .onInstFailed
|
||||
UAC::Unload ;Must call unload!
|
||||
FunctionEnd
|
||||
|
||||
##############################################################################
|
||||
# #
|
||||
# NSIS Uninstaller Event Handler Functions #
|
||||
# #
|
||||
##############################################################################
|
||||
|
||||
Function un.onInit
|
||||
UAC_Elevate:
|
||||
UAC::RunElevated
|
||||
StrCmp 1223 $0 UAC_ElevationAborted ; UAC dialog aborted by user?
|
||||
StrCmp 0 $0 0 UAC_Err ; Error?
|
||||
StrCmp 1 $1 0 UAC_Success ;Are we the real deal or just the wrapper?
|
||||
Quit
|
||||
|
||||
UAC_Err:
|
||||
MessageBox MB_ICONSTOP "Unable to elevate, error $0"
|
||||
Abort
|
||||
|
||||
UAC_ElevationAborted:
|
||||
Abort
|
||||
|
||||
UAC_Success:
|
||||
StrCmp 1 $3 +4 ;Admin?
|
||||
StrCmp 3 $1 0 UAC_ElevationAborted ;Try again?
|
||||
MessageBox MB_ICONSTOP "This uninstaller requires admin access, try again"
|
||||
goto UAC_Elevate
|
||||
|
||||
;Prevent multiple instances.
|
||||
System::Call 'kernel32::CreateMutexA(i 0, i 0, t "tomahawkUninstaller") i .r1 ?e'
|
||||
Pop $R0
|
||||
StrCmp $R0 0 +3
|
||||
MessageBox MB_OK|MB_ICONEXCLAMATION "This uninstaller is already running."
|
||||
Abort
|
||||
FunctionEnd
|
||||
|
||||
Function un.onUnInstSuccess
|
||||
UAC::Unload ;Must call unload!
|
||||
FunctionEnd
|
||||
|
||||
Function un.onUnInstFailed
|
||||
UAC::Unload ;Must call unload!
|
||||
FunctionEnd
|
52
CPack.cmake
Normal file
52
CPack.cmake
Normal file
@ -0,0 +1,52 @@
|
||||
INCLUDE( InstallRequiredSystemLibraries )
|
||||
|
||||
SET( CPACK_PACKAGE_CONTACT "Dominik Schmidt <domme@tomahawk-player.org>" )
|
||||
|
||||
SET( CPACK_PACKAGE_FILE_NAME tomahawk-${TOMAHAWK_VERSION} ) # Package file name without extension. Also a directory of installer cmake-2.5.0-Linux-i686
|
||||
|
||||
# CPACK_GENERATOR CPack generator to be used STGZ;TGZ;TZ
|
||||
# CPACK_INCLUDE_TOPLEVEL_DIRECTORY Controls whether CPack adds a top-level directory, usually of the form ProjectName-Version-OS, to the top of package tree. 0 to disable, 1 to enable
|
||||
# CPACK_INSTALL_CMAKE_PROJECTS List of four values: Build directory, Project Name, Project Component, Directory in the package /home/andy/vtk/CMake-bin;CMake;ALL;/
|
||||
SET( CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_SOURCE_DIR}/README" ) # File used as a description of a project /path/to/project/ReadMe.txt
|
||||
SET( CPACK_PACKAGE_DESCRIPTION_SUMMARY ${TOMAHAWK_DESCRIPTION_SUMMARY} ) # Description summary of a project
|
||||
# CPACK_PACKAGE_EXECUTABLES List of pairs of executables and labels. Used by the NSIS generator to create Start Menu shortcuts. ccmake;CMake
|
||||
SET( CPACK_PACKAGE_INSTALL_DIRECTORY ${TOMAHAWK_APPLICATION_NAME} ) # Installation directory on the target system -> C:\Program Files\fellody
|
||||
SET( CPACK_PACKAGE_INSTALL_REGISTRY_KEY ${TOMAHAWK_APPLICATION_NAME} ) # Registry key used when installing this project CMake 2.5.0
|
||||
SET( CPACK_PACKAGE_NAME ${TOMAHAWK_APPLICATION_NAME} ) # Package name, defaults to the project name
|
||||
SET( CPACK_PACKAGE_VENDOR ${TOMAHAWK_ORGANIZATION_NAME} ) # Package vendor name
|
||||
SET( CPACK_PACKAGE_VERSION_MAJOR ${TOMAHAWK_VERSION_MAJOR} )
|
||||
SET( CPACK_PACKAGE_VERSION_MINOR ${TOMAHAWK_VERSION_MINOR} )
|
||||
SET( CPACK_PACKAGE_VERSION_PATCH ${TOMAHAWK_VERSION_PATCH} )
|
||||
|
||||
# CPACK_SOURCE_GENERATOR List of generators used for the source package TGZ;TZ
|
||||
# CPACK_SOURCE_IGNORE_FILES Pattern of files in the source tree that won't be packaged /CVS/;/\\.svn/;\\.swp$;\\.#;/#;.*~;cscope.*
|
||||
# CPACK_SOURCE_PACKAGE_FILE_NAME Name of the source package cmake-2.5.0
|
||||
# CPACK_SOURCE_STRIP_FILES List of files in the source tree that will be stripped. Starting with CMake 2.6.0 CPACK_SOURCE_STRIP_FILES will be a boolean variable which enables stripping of all files (a list of files evaluates to TRUE in CMake, so this change is compatible).
|
||||
# CPACK_STRIP_FILES List of files to be stripped. Starting with CMake 2.6.0 CPACK_STRIP_FILES will be a boolean variable which enables stripping of all files (a list of files evaluates to TRUE in CMake, so this change is compatible). bin/ccmake;bin/cmake;bin/cpack;bin/ctest
|
||||
# CPACK_SYSTEM_NAME System name, defaults to the value of ${CMAKE_SYSTEM_NAME}. Linux-i686
|
||||
|
||||
# Advanced settings
|
||||
# CPACK_CMAKE_GENERATOR What CMake generator should be used if the project is CMake project. Defaults to the value of CMAKE_GENERATOR. Unix Makefiles
|
||||
SET( CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/LICENSE.txt" ) # License file for the project, used by the STGZ, NSIS, and PackageMaker generators. /home/andy/vtk/CMake/Copyright.txt
|
||||
# CPACK_RESOURCE_FILE_README ReadMe file for the project, used by PackageMaker generator. /home/andy/vtk/CMake/Templates/CPack.GenericDescription.txt
|
||||
# CPACK_RESOURCE_FILE_WELCOME Welcome file for the project, used by PackageMaker generator. /home/andy/vtk/CMake/Templates/CPack.GenericWelcome.txt
|
||||
SET( CPACK_PACKAGE_VERSION ${TOMAHAWK_VERSION} )
|
||||
|
||||
# CPACK_TOPLEVEL_TAG Directory for the installed files. Linux-i686
|
||||
# CPACK_INSTALL_COMMANDS Extra commands to install components.
|
||||
# CPACK_INSTALL_DIRECTORIES Extra directories to install.
|
||||
# CPACK_MONOLITHIC_INSTALL When set disables the component-based installer.
|
||||
# CPACK_PACKAGING_INSTALL_PREFIX Sets the default root that the generated package installs into, '/usr' is the default for the debian and redhat generators /usr/local
|
||||
|
||||
##
|
||||
# INSTALL DEPS
|
||||
##
|
||||
|
||||
|
||||
|
||||
# Set the options file that needs to be included inside CMakeCPackOptions.cmake
|
||||
#SET(QT_DIALOG_CPACK_OPTIONS_FILE ${CMake_BINARY_DIR}/Source/QtDialog/QtDialogCPack.cmake)
|
||||
configure_file("${CMAKE_SOURCE_DIR}/CPackOptions.cmake.in"
|
||||
"${CMAKE_BINARY_DIR}/CPackOptions.cmake" @ONLY)
|
||||
set(CPACK_PROJECT_CONFIG_FILE "${CMAKE_BINARY_DIR}/CPackOptions.cmake") # File included at cpack time, once per generator after setting CPACK_GENERATOR to the actual generator being used; allows per-generator setting of CPACK_* variables at cpack time. ${PROJECT_BINARY_DIR}/CPackOptions.cmake
|
||||
include(CPack)
|
73
CPackOptions.cmake.in
Normal file
73
CPackOptions.cmake.in
Normal file
@ -0,0 +1,73 @@
|
||||
# This file is configured at cmake time, and loaded at cpack time.
|
||||
# To pass variables to cpack from cmake, they must be configured
|
||||
# in this file.
|
||||
|
||||
if(CPACK_GENERATOR MATCHES "NSIS")
|
||||
#SET(CPACK_NSIS_INSTALL_ROOT "@CPACK_NSIS_INSTALL_ROOT@")
|
||||
|
||||
# set the install/unistall icon used for the installer itself
|
||||
# There is a bug in NSI that does not handle full unix paths properly.
|
||||
#SET(CPACK_NSIS_MUI_ICON "@CMake_SOURCE_DIR@/Utilities/Release\\CMakeLogo.ico")
|
||||
#SET(CPACK_NSIS_MUI_UNIICON "@CMake_SOURCE_DIR@/Utilities/Release\\CMakeLogo.ico")
|
||||
# set the package header icon for MUI
|
||||
#SET(CPACK_PACKAGE_ICON "@CMake_SOURCE_DIR@/Utilities/Release\\CMakeInstall.bmp")
|
||||
# tell cpack to create links to the doc files
|
||||
#SET(CPACK_NSIS_MENU_LINKS
|
||||
# "doc/cmake-@CMake_VERSION_MAJOR@.@CMake_VERSION_MINOR@/cmake-gui.html" "cmake-gui Help"
|
||||
# "doc/cmake-@CMake_VERSION_MAJOR@.@CMake_VERSION_MINOR@/cmake.html" "CMake Help"
|
||||
# "doc/cmake-@CMake_VERSION_MAJOR@.@CMake_VERSION_MINOR@/cmake-properties.html"
|
||||
# "CMake Properties and Variables Help"
|
||||
# "doc/cmake-@CMake_VERSION_MAJOR@.@CMake_VERSION_MINOR@/ctest.html" "CTest Help"
|
||||
# "doc/cmake-@CMake_VERSION_MAJOR@.@CMake_VERSION_MINOR@/cmake-modules.html" "CMake Modules Help"
|
||||
# "doc/cmake-@CMake_VERSION_MAJOR@.@CMake_VERSION_MINOR@/cmake-commands.html" "CMake Commands Help"
|
||||
# "doc/cmake-@CMake_VERSION_MAJOR@.@CMake_VERSION_MINOR@/cpack.html" "CPack Help"
|
||||
# "http://www.cmake.org" "CMake Web Site"
|
||||
# )
|
||||
# Use the icon from cmake-gui for add-remove programs
|
||||
#SET(CPACK_NSIS_INSTALLED_ICON_NAME "bin\\cmake-gui.exe")
|
||||
#
|
||||
#SET(CPACK_NSIS_PACKAGE_NAME "@CPACK_NSIS_PACKAGE_NAME@")
|
||||
#SET(CPACK_NSIS_DISPLAY_NAME "@CPACK_NSIS_PACKAGE_NAME@, a cross-platform, open-source build system")
|
||||
#SET(CPACK_NSIS_HELP_LINK "http://www.cmake.org")
|
||||
#SET(CPACK_NSIS_URL_INFO_ABOUT "http://www.kitware.com")
|
||||
#SET(CPACK_NSIS_CONTACT @CPACK_PACKAGE_CONTACT@)
|
||||
#SET(CPACK_NSIS_MODIFY_PATH ON)
|
||||
|
||||
|
||||
|
||||
##### all options
|
||||
#CPACK_NSIS_MUI_ICON The icon file (.ico) for the generated install program. Both this and CPACK_NSIS_MUI_UNIICON need to set for this to have any effect. installer.ico
|
||||
#CPACK_NSIS_MUI_UNIICON The icon file (.ico) for the generated uninstall program. Both this and CPACK_NSIS_MUI_ICON need to set for this to have any effect. uninstaller.ico
|
||||
SET( CPACK_PACKAGE_ICON @CMAKE_SOURCE_DIR@/admin/win/nsi/installer.ico ) # A branding image that will be displayed on the top bar inside the installer. installer.bmp
|
||||
#CPACK_NSIS_EXTRA_INSTALL_COMMANDS Extra NSIS commands that will be added to the install Section. ExecWait '\\\"$INSTDIR\\\\vcredist_x86.exe\\\" /q:a'
|
||||
#CPACK_NSIS_EXTRA_UNINSTALL_COMMANDS Extra NSIS commands that will be added to the uninstall Section.
|
||||
SET( CPACK_NSIS_COMPRESSOR "/SOLID lzma" ) # The arguments that will be passed to the NSIS SetCompressor command. /SOLID lzma
|
||||
#CPACK_NSIS_MODIFY_PATH If this is set to "ON", then an extra page will appear in the installer that will allow the user to choose whether the program directory should be added to the system PATH variable. ON
|
||||
#CPACK_NSIS_DISPLAY_NAME Undocumented. "${CPACK_PACKAGE_INSTALL_DIRECTORY} My Famous Project"
|
||||
#CPACK_NSIS_INSTALLED_ICON_NAME Set the icon used for the Windows "Add or Remove Programs" tool. "bin\\\\MyExecutable.exe"
|
||||
#CPACK_NSIS_HELP_LINK Adds link to registry. URI. "http:\\\\\\\\www.my-project-home-page.org"
|
||||
#CPACK_NSIS_URL_INFO_ABOUT Adds link to registry and the vendor in add/remove programs' "Click here for support information" in program entry links here. "http:\\\\\\\\www.my-personal-home-page.com"
|
||||
#CPACK_NSIS_CONTACT Adds link to add/remove programs' "Click here for support information" in program entry. "me@my-personal-home-page.com"
|
||||
#CPACK_NSIS_CREATE_ICONS_EXTRA Additional NSIS commands for creating start menu shortcuts. set(CPACK_NSIS_CREATE_ICONS "CreateShortCut '\$SMPROGRAMS\\\\$STARTMENU_FOLDER\\\\${PROJECT_NAME}.lnk' '\$INSTDIR\\\\${PROJECT_NAME}.exe'")
|
||||
#CPACK_NSIS_DELETE_ICONS_EXTRA Undocumented. Possibly: Additional NSIS commands to uninstall start menu shortcuts.
|
||||
#CPACK_NSIS_MENU_LINKS Used to override the Start Menu links. "doc/cmake-@CMake_VERSION_MAJOR@.@CMake_VERSION_MINOR@/CMakeSetup.html" "CMakeSetup Help"
|
||||
#CPACK_NSIS_MUI_FINISHPAGE_RUN If used, will make it possible for user to choose (on an additional page, displayed at the end of the installation) to run intalled program. Should point to program name to run, seemingly without any sub-directories of the installation directory in case program installed in such sub-directories (but please check generated NSIS script if you can't make it work). "MyExecutable.exe"
|
||||
|
||||
endif(CPACK_GENERATOR MATCHES "NSIS")
|
||||
|
||||
## include the cpack options for qt dialog if they exisit
|
||||
## they might not if qt was not enabled for the build
|
||||
#INCLUDE("@QT_DIALOG_CPACK_OPTIONS_FILE@" OPTIONAL)
|
||||
|
||||
|
||||
#if("${CPACK_GENERATOR}" STREQUAL "PackageMaker")
|
||||
# if(CMAKE_PACKAGE_QTGUI)
|
||||
# set(CPACK_PACKAGE_DEFAULT_LOCATION "/Applications")
|
||||
# else(CMAKE_PACKAGE_QTGUI)
|
||||
# set(CPACK_PACKAGE_DEFAULT_LOCATION "/usr")
|
||||
# endif(CMAKE_PACKAGE_QTGUI)
|
||||
#endif("${CPACK_GENERATOR}" STREQUAL "PackageMaker")
|
||||
|
||||
|
||||
SET( CMAKE_SOURCE_DIR @CMAKE_SOURCE_DIR@ )
|
||||
SET( CMAKE_BINARY_DIR @CMAKE_BINARY_DIR@ )
|
Loading…
x
Reference in New Issue
Block a user