]> granicus.if.org Git - libjpeg-turbo/commitdiff
We want to keep the same name for the install directory, even though the installer...
authorDRC <dcommander@users.sourceforge.net>
Tue, 22 Mar 2011 06:49:31 +0000 (06:49 +0000)
committerDRC <dcommander@users.sourceforge.net>
Tue, 22 Mar 2011 06:49:31 +0000 (06:49 +0000)
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/branches/1.1.x@535 632fc199-4ca6-4c93-a231-07263d6284db

CMakeLists.txt
release/libjpeg-turbo.nsi.in

index 73dffb02032a25971f15137700aedce04fc600b3..74d9b5536b7d0354c7def34d76684748ca5a28c5 100644 (file)
@@ -301,20 +301,21 @@ add_test(jpegtran-static-crop-cmp ${CMAKE_COMMAND} -E compare_files ${CMAKE_SOUR
 # Installer
 #
 
-set(INST_NAME ${CMAKE_PROJECT_NAME}-${VERSION})
-
 if(MSVC)
   set(INST_PLATFORM "Visual C++")
-  set(INST_NAME ${INST_NAME}-vc)
+  set(INST_NAME ${CMAKE_PROJECT_NAME}-${VERSION}-vc)
+  set(INST_DIR ${CMAKE_PROJECT_NAME})
 elseif(MINGW)
   set(INST_PLATFORM GCC)
-  set(INST_NAME ${INST_NAME}-gcc)
+  set(INST_NAME ${CMAKE_PROJECT_NAME}-${VERSION}-gcc)
+  set(INST_DIR ${CMAKE_PROJECT_NAME}-gcc)
   set(INST_DEFS -DGCC)
 endif()
 
 if(64BIT)
   set(INST_PLATFORM "${INST_PLATFORM} 64-bit")
   set(INST_NAME ${INST_NAME}64)
+  set(INST_DIR ${INST_DIR}64)
   set(INST_DEFS ${INST_DEFS} -DWIN64)
 endif()
 
index de71153718524dd692ae1680deebaf6163277282..73e0e003ac14686ce55c830b27b06c879afcfd67 100755 (executable)
@@ -1,7 +1,7 @@
 !include x64.nsh
 Name "@CMAKE_PROJECT_NAME@ SDK for @INST_PLATFORM@"
 OutFile "@CMAKE_BINARY_DIR@\${BUILDDIR}@INST_NAME@.exe"
-InstallDir c:\@INST_NAME@
+InstallDir c:\@INST_DIR@
 
 SetCompressor bzip2
 
@@ -77,12 +77,12 @@ Section "@CMAKE_PROJECT_NAME@ SDK for @INST_PLATFORM@ (required)"
        File "@CMAKE_SOURCE_DIR@\LICENSE.txt"
        File "@CMAKE_SOURCE_DIR@\usage.txt"
 
-       WriteRegStr HKLM "SOFTWARE\@INST_NAME@ @VERSION@" "Install_Dir" "$INSTDIR"
+       WriteRegStr HKLM "SOFTWARE\@INST_DIR@ @VERSION@" "Install_Dir" "$INSTDIR"
 
-       WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_NAME@ @VERSION@" "DisplayName" "@CMAKE_PROJECT_NAME@ SDK v@VERSION@ for @INST_PLATFORM@"
-       WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_NAME@ @VERSION@" "UninstallString" '"$INSTDIR\uninstall_@VERSION@.exe"'
-       WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_NAME@ @VERSION@" "NoModify" 1
-       WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_NAME@ @VERSION@" "NoRepair" 1
+       WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_DIR@ @VERSION@" "DisplayName" "@CMAKE_PROJECT_NAME@ SDK v@VERSION@ for @INST_PLATFORM@"
+       WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_DIR@ @VERSION@" "UninstallString" '"$INSTDIR\uninstall_@VERSION@.exe"'
+       WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_DIR@ @VERSION@" "NoModify" 1
+       WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_DIR@ @VERSION@" "NoRepair" 1
        WriteUninstaller "uninstall_@VERSION@.exe"
 SectionEnd
 
@@ -95,8 +95,8 @@ Section "Uninstall"
 
        SetShellVarContext all
 
-       DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_NAME@ @VERSION@"
-       DeleteRegKey HKLM "SOFTWARE\@INST_NAME@ @VERSION@"
+       DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_DIR@ @VERSION@"
+       DeleteRegKey HKLM "SOFTWARE\@INST_DIR@ @VERSION@"
 
 !ifdef GCC
        Delete $INSTDIR\bin\libjpeg-@DLL_VERSION@.dll