mirror of https://github.com/odrling/Aegisub
More updates to installer, updates #863.
* Use a simple but (hopefully) very reliable way of detecting whether runtimes need to be installed: Check for an uninstaller entry for the runtimes. * Clean up from most, hopefully all, 2.x alpha and pre-release installers we have previously put out. * Also clean combinations of 1.x and 2.x pre-rel versions installed on top of each other. * TODO: List all completed translation files for installation. Originally committed to SVN as r3058.
This commit is contained in:
parent
9aaa1ed903
commit
766dcf3c3f
|
@ -34,11 +34,14 @@
|
||||||
|
|
||||||
|
|
||||||
[Setup]
|
[Setup]
|
||||||
|
AppID={{24BC8B57-716C-444F-B46B-A3349B9164C5}
|
||||||
AppName=Aegisub
|
AppName=Aegisub
|
||||||
AppVerName=Aegisub 2.1.7
|
AppVerName=Aegisub 2.1.7
|
||||||
|
AppVersion=2.1.7
|
||||||
AppPublisher=Aegisub Team
|
AppPublisher=Aegisub Team
|
||||||
AppPublisherURL=http://www.aegisub.org/
|
AppPublisherURL=http://www.aegisub.org/
|
||||||
AppSupportURL=http://forum.aegisub.org/
|
AppSupportURL=http://forum.aegisub.org/
|
||||||
|
AppCopyright=© 2005-2009 The Aegisub Team
|
||||||
DefaultDirName={pf}\Aegisub
|
DefaultDirName={pf}\Aegisub
|
||||||
DefaultGroupName=Aegisub
|
DefaultGroupName=Aegisub
|
||||||
AllowNoIcons=true
|
AllowNoIcons=true
|
||||||
|
@ -51,26 +54,29 @@ ShowLanguageDialog=no
|
||||||
LanguageDetectionMethod=none
|
LanguageDetectionMethod=none
|
||||||
WizardImageFile=welcome.bmp
|
WizardImageFile=welcome.bmp
|
||||||
WizardSmallImageFile=aegisub.bmp
|
WizardSmallImageFile=aegisub.bmp
|
||||||
AppCopyright=© 2005-2009 The Aegisub Team
|
|
||||||
PrivilegesRequired=poweruser
|
PrivilegesRequired=poweruser
|
||||||
DisableProgramGroupPage=true
|
DisableProgramGroupPage=yes
|
||||||
UsePreviousGroup=false
|
UsePreviousGroup=yes
|
||||||
AlwaysShowComponentsList=true
|
UsePreviousSetupType=no
|
||||||
AppVersion=2.1.7
|
UsePreviousAppDir=yes
|
||||||
AppID={{24BC8B57-716C-444F-B46B-A3349B9164C5}
|
UsePreviousTasks=no
|
||||||
UninstallDisplayIcon={app}\aegisub32.exe
|
UninstallDisplayIcon={app}\aegisub32.exe
|
||||||
|
|
||||||
[Languages]
|
[Languages]
|
||||||
Name: english; MessagesFile: compiler:Default.isl
|
Name: english; MessagesFile: compiler:Default.isl
|
||||||
|
|
||||||
[Files]
|
[Files]
|
||||||
; Legacy uninstall data
|
; uninstall data
|
||||||
DestDir: {tmp}; Flags: dontcopy; Source: legacy_filelist.txt
|
DestDir: {tmp}; Flags: dontcopy; Source: legacy_filelist.txt
|
||||||
DestDir: {tmp}; Flags: dontcopy; Source: legacy_dirlist.txt
|
DestDir: {tmp}; Flags: dontcopy; Source: legacy_dirlist.txt
|
||||||
DestDir: {tmp}; Flags: dontcopy; Source: legacy_locales.txt
|
DestDir: {tmp}; Flags: dontcopy; Source: legacy_locales.txt
|
||||||
DestDir: {tmp}; Flags: dontcopy; Source: legacy_shortcutlist.txt
|
DestDir: {tmp}; Flags: dontcopy; Source: legacy_shortcutlist.txt
|
||||||
|
DestDir: {tmp}; Flags: dontcopy; Source: old_filelist.txt
|
||||||
|
DestDir: {tmp}; Flags: dontcopy; Source: old_dirlist.txt
|
||||||
|
DestDir: {tmp}; Flags: dontcopy; Source: old_locales.txt
|
||||||
|
DestDir: {tmp}; Flags: dontcopy; Source: old_shortcutlist.txt
|
||||||
; redist
|
; redist
|
||||||
DestDir: {tmp}; Source: src\vcredist_x86.exe; Flags: nocompression deleteafterinstall
|
DestDir: {tmp}; Source: src\vcredist_x86.exe; Flags: nocompression deleteafterinstall; Check: RuntimesRequired
|
||||||
; main
|
; main
|
||||||
DestDir: {app}; Source: src\aegisub32.exe; Flags: ignoreversion; Components: main
|
DestDir: {app}; Source: src\aegisub32.exe; Flags: ignoreversion; Components: main
|
||||||
DestDir: {app}; Source: src\aegisub32.pdb; Flags: ignoreversion; Components: main/pdb
|
DestDir: {app}; Source: src\aegisub32.pdb; Flags: ignoreversion; Components: main/pdb
|
||||||
|
@ -175,12 +181,12 @@ Root: HKLM; Subkey: "SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\aegisub
|
||||||
|
|
||||||
[Run]
|
[Run]
|
||||||
Filename: {app}\aegisub32.exe; Description: {cm:LaunchProgram,Aegisub}; Flags: nowait postinstall skipifsilent
|
Filename: {app}\aegisub32.exe; Description: {cm:LaunchProgram,Aegisub}; Flags: nowait postinstall skipifsilent
|
||||||
Filename: {tmp}\vcredist_x86.exe; StatusMsg: Installing runtime libraries...; Components: main/runtime; Parameters: "/q"
|
Filename: {tmp}\vcredist_x86.exe; StatusMsg: Installing runtime libraries...; Check: RuntimesRequired; Components: main/runtime; Parameters: "/q"
|
||||||
|
|
||||||
[Components]
|
[Components]
|
||||||
; Actual program
|
; Actual program
|
||||||
Name: main; Description: Aegisub; Types: compact full custom; Languages: ; Flags: fixed
|
Name: main; Description: Aegisub; Types: compact full custom; Languages: ; Flags: fixed
|
||||||
Name: main/runtime; Description: Runtime libraries; Flags: fixed; Types: custom compact full; ExtraDiskSpaceRequired: 4630528
|
Name: main/runtime; Description: Runtime libraries; Check: RuntimesRequired; Flags: fixed; Types: custom compact full; ExtraDiskSpaceRequired: 4630528
|
||||||
Name: main/pdb; Description: Debug database (helps diagnose crashes); Types: full
|
Name: main/pdb; Description: Debug database (helps diagnose crashes); Types: full
|
||||||
Name: main/icons; Description: Programs menu icons; Types: custom compact full
|
Name: main/icons; Description: Programs menu icons; Types: custom compact full
|
||||||
Name: main/qcklnch; Description: Quick launch icon; Types: custom compact full
|
Name: main/qcklnch; Description: Quick launch icon; Types: custom compact full
|
||||||
|
@ -254,6 +260,22 @@ begin
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
function RuntimesRequired: Boolean;
|
||||||
|
var
|
||||||
|
DisplayVersion: string;
|
||||||
|
begin
|
||||||
|
// Check for uninstall entry for runtimes, don't bother installing if it can be uninstalled now
|
||||||
|
// HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{9A25302D-30C0-39D9-BD6F-21E6EC160475}
|
||||||
|
// Check: DisplayVersion = "9.0.30729"
|
||||||
|
DisplayVersion := '';
|
||||||
|
Result := RegQueryStringValue(HKLM, 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{9A25302D-30C0-39D9-BD6F-21E6EC160475}',
|
||||||
|
'DisplayVersion', DisplayVersion);
|
||||||
|
Result := Result and (DisplayVersion = '9.0.30729');
|
||||||
|
|
||||||
|
Result := not Result;
|
||||||
|
end;
|
||||||
|
|
||||||
|
|
||||||
function BoolToStr(x: Boolean): string;
|
function BoolToStr(x: Boolean): string;
|
||||||
begin
|
begin
|
||||||
if x then Result := 'Yes' else Result := 'No';
|
if x then Result := 'Yes' else Result := 'No';
|
||||||
|
@ -331,7 +353,7 @@ var
|
||||||
begin
|
begin
|
||||||
// Uninstall Aegisub 1.x
|
// Uninstall Aegisub 1.x
|
||||||
Log('-- Uninstall legacy version --');
|
Log('-- Uninstall legacy version --');
|
||||||
page := CreateOutputProgressPage('Uninstalling old version', Format('Your old installation of Aegisub %s is being removed', [LegacyVersionNumber]));
|
page := CreateOutputProgressPage('Uninstalling old version', 'Your old installation of Aegisub is being removed');
|
||||||
try
|
try
|
||||||
page.SetText('Preparing list of files', '');
|
page.SetText('Preparing list of files', '');
|
||||||
page.Show;
|
page.Show;
|
||||||
|
@ -381,9 +403,9 @@ begin
|
||||||
for i := 0 to locale_list.Count-1 do
|
for i := 0 to locale_list.Count-1 do
|
||||||
begin
|
begin
|
||||||
curname := LegacyInstallFolder + '\' + locale_list.Strings[i];
|
curname := LegacyInstallFolder + '\' + locale_list.Strings[i];
|
||||||
page.SetText('Removing locales', curname);
|
page.SetText('Removing folders', curname);
|
||||||
page.SetProgress(itemsdone, totalitems);
|
page.SetProgress(itemsdone, totalitems);
|
||||||
Log('Remove locale: ' + curname);
|
Log('Remove directory recursively: ' + curname);
|
||||||
if not DelTree(curname, True, True, True) then Log('* Tree deletion failed');
|
if not DelTree(curname, True, True, True) then Log('* Tree deletion failed');
|
||||||
itemsdone := itemsdone + 1;
|
itemsdone := itemsdone + 1;
|
||||||
end;
|
end;
|
||||||
|
@ -423,9 +445,102 @@ begin
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
function SetFileAttributes(lpFileName: PChar; dwFileAttributes: Longint): Boolean;
|
||||||
|
external 'SetFileAttributesA@kernel32.dll stdcall';
|
||||||
|
|
||||||
procedure CleanUpOldVersion;
|
procedure CleanUpOldVersion;
|
||||||
|
var
|
||||||
|
StartMenuFolder, InstallFolder: string;
|
||||||
|
page: TOutputProgressWizardPage;
|
||||||
|
file_list: TStringList;
|
||||||
|
dir_list: TStringList;
|
||||||
|
shortcut_list: TStringList;
|
||||||
|
locale_list: TStringList;
|
||||||
|
itemsdone, totalitems, i: Integer;
|
||||||
|
curname: string;
|
||||||
begin
|
begin
|
||||||
Log('-- Cleaning up from old version --');
|
// Clean up from previous Aegisub 2.x installs
|
||||||
|
Log('-- Clean up old versions --');
|
||||||
|
page := CreateOutputProgressPage('Cleaning old versions', 'Cleaning up from older versions of Aegisub 2');
|
||||||
|
try
|
||||||
|
page.SetText('Preparing list of files', '');
|
||||||
|
page.Show;
|
||||||
|
|
||||||
|
Log('Load file lists');
|
||||||
|
ExtractTemporaryFile('old_shortcutlist.txt');
|
||||||
|
ExtractTemporaryFile('old_filelist.txt');
|
||||||
|
ExtractTemporaryFile('old_locales.txt');
|
||||||
|
ExtractTemporaryFile('old_dirlist.txt');
|
||||||
|
shortcut_list := TStringList.Create;
|
||||||
|
shortcut_list.LoadFromFile(ExpandConstant('{tmp}\old_shortcutlist.txt'));
|
||||||
|
file_list := TStringList.Create;
|
||||||
|
file_list.LoadFromFile(ExpandConstant('{tmp}\old_filelist.txt'));
|
||||||
|
locale_list := TStringList.Create;
|
||||||
|
locale_list.LoadFromFile(ExpandConstant('{tmp}\old_locales.txt'));
|
||||||
|
dir_list := TStringList.Create;
|
||||||
|
dir_list.LoadFromFile(ExpandConstant('{tmp}\old_dirlist.txt'));
|
||||||
|
itemsdone := 0;
|
||||||
|
totalitems := file_list.Count + dir_list.Count + shortcut_list.Count + locale_list.Count + 1;
|
||||||
|
// One extra for the start menu folder
|
||||||
|
|
||||||
|
StartMenuFolder := ExpandConstant('{commonprograms}\Aegisub\');
|
||||||
|
for i := 0 to shortcut_list.Count-1 do
|
||||||
|
begin
|
||||||
|
curname := StartMenuFolder + shortcut_list.Strings[i];
|
||||||
|
page.SetText('Removing shortcuts', curname);
|
||||||
|
page.SetProgress(itemsdone, totalitems);
|
||||||
|
Log('Remove shortcut: ' + curname);
|
||||||
|
if not DeleteFile(curname) then Log('* Deletion failed');
|
||||||
|
itemsdone := itemsdone + 1;
|
||||||
|
end;
|
||||||
|
page.SetText('Removing Start menu folder', StartMenuFolder);
|
||||||
|
page.SetProgress(itemsdone, totalitems);
|
||||||
|
Log('Remove directory: ' + StartMenuFolder);
|
||||||
|
if not RemoveDir(StartMenuFolder) then Log('* Directory deletion failed');
|
||||||
|
itemsdone := itemsdone + 1;
|
||||||
|
|
||||||
|
InstallFolder := ExpandConstant('{app}\');
|
||||||
|
for i := 0 to file_list.Count-1 do
|
||||||
|
begin
|
||||||
|
curname := InstallFolder + file_list.Strings[i];
|
||||||
|
page.SetText('Removing files', curname);
|
||||||
|
page.SetProgress(itemsdone, totalitems);
|
||||||
|
Log('Remove file: ' + curname);
|
||||||
|
SetFileAttributes(curname, 128); // 128 = FILE_ATTRIBUTE_NORMAL
|
||||||
|
if not DeleteFile(curname) then Log('* Deletion failed');
|
||||||
|
itemsdone := itemsdone + 1;
|
||||||
|
end;
|
||||||
|
|
||||||
|
for i := 0 to locale_list.Count-1 do
|
||||||
|
begin
|
||||||
|
curname := InstallFolder + locale_list.Strings[i];
|
||||||
|
page.SetText('Removing folders', curname);
|
||||||
|
page.SetProgress(itemsdone, totalitems);
|
||||||
|
Log('Remove directory recursively: ' + curname);
|
||||||
|
if not DelTree(curname, True, True, True) then Log('* Tree deletion failed');
|
||||||
|
itemsdone := itemsdone + 1;
|
||||||
|
end;
|
||||||
|
|
||||||
|
for i := 0 to dir_list.Count-1 do
|
||||||
|
begin
|
||||||
|
curname := InstallFolder + dir_list.Strings[i];
|
||||||
|
page.SetText('Removing folders', curname);
|
||||||
|
page.SetProgress(itemsdone, totalitems);
|
||||||
|
Log('Remove directory: ' + curname);
|
||||||
|
if not RemoveDir(curname) then Log('* Directory deletion failed');
|
||||||
|
itemsdone := itemsdone + 1;
|
||||||
|
end;
|
||||||
|
|
||||||
|
page.SetText('Uninstallation complete', '');
|
||||||
|
page.SetProgress(totalitems, totalitems);
|
||||||
|
|
||||||
|
finally
|
||||||
|
shortcut_list.Free;
|
||||||
|
file_list.Free;
|
||||||
|
locale_list.Free;
|
||||||
|
dir_list.Free;
|
||||||
|
page.Hide;
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
@ -438,10 +553,7 @@ begin
|
||||||
MigrateStyleCatalogs;
|
MigrateStyleCatalogs;
|
||||||
UninstallLegacyVersion;
|
UninstallLegacyVersion;
|
||||||
end
|
end
|
||||||
else
|
|
||||||
begin
|
|
||||||
CleanUpOldVersion;
|
CleanUpOldVersion;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
automation\include\Aegisub\
|
|
@ -0,0 +1,49 @@
|
||||||
|
Aegisub.exe
|
||||||
|
Aegisub.pdb
|
||||||
|
aegisub-auto3.dll
|
||||||
|
changelog.txt
|
||||||
|
ffms2.html
|
||||||
|
FFMS2.dll
|
||||||
|
avcodec-51.dll
|
||||||
|
avformat-51.dll
|
||||||
|
avutil-49.dll
|
||||||
|
FFMpegSource.dll
|
||||||
|
ffmpegsource.html
|
||||||
|
postproc-51.dll
|
||||||
|
swscale-0.dll
|
||||||
|
ASSDraw3.exe
|
||||||
|
ASSDraw3.chm
|
||||||
|
automation\include\Aegisub\PerlConsole.pm
|
||||||
|
automation\include\Aegisub\Progress.pm
|
||||||
|
automation\include\Aegisub\Script.pm
|
||||||
|
automation\include\Aegisub.pm
|
||||||
|
automation\include\Auto4Utils.pm
|
||||||
|
automation\include\cleantags.lua
|
||||||
|
automation\include\karaskel.auto3
|
||||||
|
automation\include\karaskel.lua
|
||||||
|
automation\include\karaskel-adv.auto3
|
||||||
|
automation\include\karaskel-adv.lua
|
||||||
|
automation\include\karaskel-auto4.lua
|
||||||
|
automation\include\karaskel-base.auto3
|
||||||
|
automation\include\karaskel-base.lua
|
||||||
|
automation\include\unicode.lua
|
||||||
|
automation\include\utils.auto3
|
||||||
|
automation\include\utils.lua
|
||||||
|
automation\include\utils-auto4.lua
|
||||||
|
automation\demos\future-windy-blur.lua
|
||||||
|
automation\demos\kara-templater-retime.ass
|
||||||
|
automation\demos\perl-console.pl
|
||||||
|
automation\docs\automation3.txt
|
||||||
|
automation\docs\perl-api.txt
|
||||||
|
automation\autoload\macro-1p-edgeblur.pl
|
||||||
|
automation\autoload\cleantags.lua
|
||||||
|
automation\autoload\cleantags-autoload.lua
|
||||||
|
automation\autoload\kara-templater.lua
|
||||||
|
automation\autoload\macro-1-edgeblur.lua
|
||||||
|
automation\autoload\macro-2-mkfullwitdh.lua
|
||||||
|
automation\auto3\line-per-syllable.auto3
|
||||||
|
automation\auto3\multi-template.auto3
|
||||||
|
automation\auto3\simple-k-replacer.auto3
|
||||||
|
automation\autoload\line-per-syllable.auto3
|
||||||
|
automation\autoload\multi-template.auto3
|
||||||
|
automation\autoload\simple-k-replacer.auto3
|
|
@ -0,0 +1 @@
|
||||||
|
docs\
|
|
@ -0,0 +1,3 @@
|
||||||
|
Aegisub.lnk
|
||||||
|
ASSDraw3.lnk
|
||||||
|
Uninstall.lnk
|
Loading…
Reference in New Issue