]> granicus.if.org Git - handbrake/commitdiff
WinGui: Block Installation on 32bit systems.
authorsr55 <sr55.hb@outlook.com>
Fri, 20 Apr 2018 20:54:02 +0000 (21:54 +0100)
committersr55 <sr55.hb@outlook.com>
Tue, 1 May 2018 17:45:41 +0000 (18:45 +0100)
win/CS/HandBrakeWPF/Installer/Installer64.nsi
win/CS/HandBrakeWPF/Installer/MakeNightly64.nsi

index 5b7538528d8d229114f3609e5864228f74bfb441..6f824704c3e6a424f7e6106e90f63b83187dc294 100644 (file)
@@ -56,6 +56,7 @@ OutFile "HandBrake-${PRODUCT_VERSION_NUMBER}-Win_GUI.exe"
 !include WordFunc.nsh\r
 !insertmacro VersionCompare\r
 !include LogicLib.nsh\r
+!include x64.nsh\r
 \r
 InstallDir "$PROGRAMFILES64\HandBrake"\r
 InstallDirRegKey HKLM "${PRODUCT_DIR_REGKEY}" ""\r
@@ -84,6 +85,11 @@ Function .onInit
     Quit\r
   ${EndIf}\r
 \r
+  ${IfNot} ${RunningX64}\r
+    MessageBox MB_OK "HandBrake requires a 64bit version of Windows 7 SP1 or later to install. Your system has a 32bit version of Windows."\r
+    Quit\r
+  ${EndIf}\r
+\r
   ;Remove previous version\r
   ReadRegStr $R0 HKLM \\r
   "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}\" \\r
@@ -114,18 +120,18 @@ Section "HandBrake" SEC01
   Call CheckFramework\r
      StrCmp $0 "1" +3\r
         StrCpy $InstallDotNET "Yes"\r
-      MessageBox MB_OK|MB_ICONINFORMATION "${PRODUCT_NAME} requires that the Microsoft .NET Framework 4.6 Client Profile is installed. The latest .NET Framework will be downloaded and installed automatically during installation of ${PRODUCT_NAME}." /SD IDOK\r
+      MessageBox MB_OK|MB_ICONINFORMATION "${PRODUCT_NAME} requires that the Microsoft .NET Framework 4.6.2 is installed. The latest .NET Framework will be downloaded and installed automatically during installation of ${PRODUCT_NAME}." /SD IDOK\r
      Pop $0\r
 \r
   ; Get .NET if required\r
   ${If} $InstallDotNET == "Yes"\r
      SetDetailsView hide\r
-     inetc::get /caption "Downloading Microsoft .NET Framework 4.6" /canceltext "Cancel" "https://www.microsoft.com/en-us/download/confirmation.aspx?id=49982" "$INSTDIR\dotnetfx.exe" /end\r
+     inetc::get /caption "Downloading Microsoft .NET Framework 4.6.2" /canceltext "Cancel" "https://www.microsoft.com/en-us/download/confirmation.aspx?id=53344" "$INSTDIR\dotnetfx.exe" /end\r
      Pop $1\r
 \r
      ${If} $1 != "OK"\r
            Delete "$INSTDIR\dotnetfx.exe"\r
-           Abort "Installation cancelled, ${PRODUCT_NAME} requires the Microsoft .NET 4.6 Framework"\r
+           Abort "Installation cancelled, ${PRODUCT_NAME} requires the Microsoft .NET 4.6.2 Framework"\r
      ${EndIf}\r
 \r
      ExecWait "$INSTDIR\dotnetfx.exe"\r
index 0c10bd7d3e8a9b7748b7c8854886236c21f1764f..71ba7f8ab6837d8539fa4d6a848f9f8efa85538e 100644 (file)
@@ -56,6 +56,7 @@ OutFile "HandBrake-${PRODUCT_VERSION_NUMBER}_x86_64-Win_GUI.exe"
 !include WordFunc.nsh\r
 !insertmacro VersionCompare\r
 !include LogicLib.nsh\r
+!include x64.nsh\r
 \r
 InstallDir "$PROGRAMFILES64\HandBrake Nightly"\r
 InstallDirRegKey HKLM "${PRODUCT_DIR_REGKEY}" ""\r
@@ -83,6 +84,11 @@ Function .onInit
     Quit\r
   ${EndIf}\r
 \r
+  ${IfNot} ${RunningX64}\r
+    MessageBox MB_OK "HandBrake requires a 64bit version of Windows 7 SP1 or later to install. Your system has a 32bit version of Windows."\r
+    Quit\r
+  ${EndIf}\r
+\r
   ;Remove previous version\r
   ReadRegStr $R0 HKLM \\r
   "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}\" \\r
@@ -113,18 +119,18 @@ Section "HandBrake" SEC01
   Call CheckFramework\r
      StrCmp $0 "1" +3\r
         StrCpy $InstallDotNET "Yes"\r
-      MessageBox MB_OK|MB_ICONINFORMATION "${PRODUCT_NAME} requires that the Microsoft .NET Framework 4.6 is installed. The latest .NET Framework will be downloaded and installed automatically during installation of ${PRODUCT_NAME}." /SD IDOK\r
+      MessageBox MB_OK|MB_ICONINFORMATION "${PRODUCT_NAME} requires that the Microsoft .NET Framework 4.6.2 is installed. The latest .NET Framework will be downloaded and installed automatically during installation of ${PRODUCT_NAME}." /SD IDOK\r
      Pop $0\r
 \r
   ; Get .NET if required\r
   ${If} $InstallDotNET == "Yes"\r
      SetDetailsView hide\r
-     inetc::get /caption "Downloading Microsoft .NET Framework 4.6" /canceltext "Cancel" "https://www.microsoft.com/en-us/download/confirmation.aspx?id=49982" "$INSTDIR\dotnetfx.exe" /end\r
+     inetc::get /caption "Downloading Microsoft .NET Framework 4.6.2" /canceltext "Cancel" "https://www.microsoft.com/en-us/download/confirmation.aspx?id=53344" "$INSTDIR\dotnetfx.exe" /end\r
      Pop $1\r
 \r
      ${If} $1 != "OK"\r
            Delete "$INSTDIR\dotnetfx.exe"\r
-           Abort "Installation cancelled, ${PRODUCT_NAME} requires the Microsoft .NET 4.6 Framework"\r
+           Abort "Installation cancelled, ${PRODUCT_NAME} requires the Microsoft .NET 4.6.2 Framework"\r
      ${EndIf}\r
 \r
      ExecWait "$INSTDIR\dotnetfx.exe"\r