1
0
mirror of https://github.com/unrealircd/unrealircd.git synced 2026-07-07 11:23:12 +02:00

win32 installer changes

This commit is contained in:
codemastr
2004-03-26 23:12:22 +00:00
parent ec12bd4c05
commit 1ac0936d8a
2 changed files with 30 additions and 19 deletions
+2
View File
@@ -3055,3 +3055,5 @@ seen. gmtime warning still there
systems
- Fixed a problem where the win32 GUI's "rehash all" option did not reload motd/rules
(#0001678) reported by w00t
- Made some changes to the win32 setup script to make it work with the latest version
of Inno Setup (4.2.0)
+28 -19
View File
@@ -91,28 +91,35 @@ external 'isxdl_Download@files:isxdl.dll stdcall';
function isxdl_SetOption(Option, Value: PChar): Integer;
external 'isxdl_SetOption@files:isxdl.dll stdcall';
const url = 'http://www.unrealircd.com/downloads/DbgHelp.Dll';
var didDl: Boolean;
function NextButtonClick(CurPage: Integer): Boolean;
var
dbghelp,tmp,output: String;
m: String;
hWnd,answer: Integer;
begin
dbghelp := ExpandConstant('{sys}\DbgHelp.Dll');
output := ExpandConstant('{app}\DbgHelp.Dll');
GetVersionNumbersString(dbghelp,m);
if ((CurPage = wpReady) AND NOT FileExists(output)) then begin
if (NOT FileExists(dbghelp)) then
m := StringOfChar('0',1);
if (StrToInt(m[1]) < 5) then begin
answer := MsgBox('DbgHelp.dll version 5.0 or higher is required to install Unreal, do you wish to install it now?', mbConfirmation, MB_YESNO);
if answer = IDYES then begin
tmp := ExpandConstant('{tmp}\dbghelp.dll');
isxdl_SetOption('title', 'Downloading DbgHelp.dll');
hWnd := StrToInt(ExpandConstant('{wizardhwnd}'));
if isxdl_Download(hWnd, url, tmp) = 0 then
MsgBox('Download and installation of DbgHelp.Dll failed, the file must be manually installed. The file can be downloaded at http://www.unrealircd.com/downloads/DbgHelp.Dll', mbInformation, MB_OK);
end else
MsgBox('In order for Unreal to properly function you must manually install this dll. The dll can be downloaded from http://www.unrealircd.com/downloads/DbgHelp.Dll', mbInformation, MB_OK);
if ((CurPage = wpReady)) then begin
dbghelp := ExpandConstant('{sys}\DbgHelp.Dll');
output := ExpandConstant('{app}\DbgHelp.Dll');
GetVersionNumbersString(dbghelp,m);
if (NOT FileExists(output)) then begin
if (NOT FileExists(dbghelp)) then
m := StringOfChar('0',1);
if (StrToInt(m[1]) < 5) then begin
answer := MsgBox('DbgHelp.dll version 5.0 or higher is required to install Unreal, do you wish to install it now?', mbConfirmation, MB_YESNO);
if answer = IDYES then begin
tmp := ExpandConstant('{tmp}\dbghelp.dll');
isxdl_SetOption('title', 'Downloading DbgHelp.dll');
hWnd := StrToInt(ExpandConstant('{wizardhwnd}'));
if isxdl_Download(hWnd, url, tmp) = 0 then begin
MsgBox('Download and installation of DbgHelp.Dll failed, the file must be manually installed. The file can be downloaded at http://www.unrealircd.com/downloads/DbgHelp.Dll', mbInformation, MB_OK);
end else
didDl := true;
end else
MsgBox('In order for Unreal to properly function you must manually install this dll. The dll can be downloaded from http://www.unrealircd.com/downloads/DbgHelp.Dll', mbInformation, MB_OK);
end;
end;
end;
Result := true;
@@ -122,9 +129,11 @@ procedure DeInitializeSetup();
var
input,output: String;
begin
input := ExpandConstant('{tmp}\dbghelp.dll');
output := ExpandConstant('{app}\dbghelp.dll');
FileCopy(input, output, true);
if (didDl) then begin
input := ExpandConstant('{tmp}\dbghelp.dll');
output := ExpandConstant('{app}\dbghelp.dll');
FileCopy(input, output, true);
end;
end;
[Icons]