Mercurial > mxe-octave
comparison tools/makeinst-script.sh.in @ 6939:4f25eb25a80b release
Installer: Check for default console and show advice for new Terminal
* tools/makeinst-script.sh.in: Octave doesn't work correctly when the default
console on Windows is set to the new Terminal app. Check if the default is set
to the Windows Console Host and show advice if it is not.
author | John Donoghue <john.donoghue@ieee.org> |
---|---|
date | Fri, 27 Oct 2023 20:19:02 -0400 |
parents | 9eff743a7de0 |
children | c9c411f5db86 |
comparison
equal
deleted
inserted
replaced
6937:4799220fcf78 | 6939:4f25eb25a80b |
---|---|
162 !define MUI_PAGE_CUSTOMFUNCTION_LEAVE CheckPrevInstallAndDest | 162 !define MUI_PAGE_CUSTOMFUNCTION_LEAVE CheckPrevInstallAndDest |
163 !insertmacro MUI_PAGE_DIRECTORY | 163 !insertmacro MUI_PAGE_DIRECTORY |
164 | 164 |
165 !insertmacro MUI_PAGE_INSTFILES | 165 !insertmacro MUI_PAGE_INSTFILES |
166 | 166 |
167 !define MUI_PAGE_CUSTOMFUNCTION_SHOW CheckConsole | |
167 !define MUI_FINISHPAGE_RUN "\$WINDIR\\explorer.exe" | 168 !define MUI_FINISHPAGE_RUN "\$WINDIR\\explorer.exe" |
168 !define MUI_FINISHPAGE_RUN_PARAMETERS "\$INSTDIR\\\${MAIN_APP_EXE}" | 169 !define MUI_FINISHPAGE_RUN_PARAMETERS "\$INSTDIR\\\${MAIN_APP_EXE}" |
169 !define MUI_FINISHPAGE_SHOWREADME "\$INSTDIR\\README.html" | 170 !define MUI_FINISHPAGE_SHOWREADME "\$INSTDIR\\README.html" |
170 !insertmacro MUI_PAGE_FINISH | 171 !insertmacro MUI_PAGE_FINISH |
171 | 172 |
1124 | 1125 |
1125 inst_end: | 1126 inst_end: |
1126 | 1127 |
1127 FunctionEnd | 1128 FunctionEnd |
1128 | 1129 |
1130 ; Function to check Console Settings and show a warn | |
1131 Function CheckConsole | |
1132 Push \$R0 | |
1133 Push \$R1 | |
1134 | |
1135 ClearErrors | |
1136 | |
1137 ReadRegStr \$R1 HKCU "Console\\%%Startup" "DelegationConsole" | |
1138 IfErrors ignore_console 0 | |
1139 | |
1140 StrCmp \$R1 "" ignore_console 0 | |
1141 # already set for console host | |
1142 StrCmp \$R1 "{B23D10C0-E52E-411E-9D5B-C09FDF709C7D}" ignore_console 0 | |
1143 | |
1144 # display message | |
1145 MessageBox MB_ICONEXCLAMATION|MB_YESNO|MB_DEFBUTTON2 "Using Octave with the Windows Terminal app could lead to issues with the command window. Please, set the default to the “Windows Console Host”.$\r$\n$\r$\nWould you like to get instructions on how to change the default console?" /SD IDNO IDNO ignore_console | |
1146 | |
1147 ExecShell open "https://devblogs.microsoft.com/commandline/windows-terminal-as-your-default-command-line-experience/" | |
1148 | |
1149 ignore_console: | |
1150 Pop \$R1 | |
1151 Pop \$R0 | |
1152 FunctionEnd | |
1153 | |
1129 ; Function to check Java Runtime Environment | 1154 ; Function to check Java Runtime Environment |
1130 Function CheckJRE | 1155 Function CheckJRE |
1131 ; looks in: | 1156 ; looks in: |
1132 ; 1 - JAVA_HOME environment variable | 1157 ; 1 - JAVA_HOME environment variable |
1133 ; 2 - the registry | 1158 ; 2 - the registry |