-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathv1 installer.iss
98 lines (89 loc) · 6.06 KB
/
v1 installer.iss
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
#define MyAppName "PDFEncrypt"
#define MyAppVersion "1"
#define MyAppPublisher "Ryan Griggs"
#define MyAppURL "https://pdfencrypt.net"
#define MyAppExeName "PDFEncrypt.exe"
[Setup]
; NOTE: The value of AppId uniquely identifies this application. Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppId={{D27D4A17-D4AB-4DAA-B655-79C473EE7E58}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
;AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={autopf}\{#MyAppName}
DisableProgramGroupPage=yes
LicenseFile=C:\temp\pdfencrypt1\PDFEncrypt\agpl.txt
; Remove the following line to run in administrative install mode (install for all users.)
PrivilegesRequired=lowest
PrivilegesRequiredOverridesAllowed=dialog
OutputBaseFilename=PDFEncrypt_Setup
SetupIconFile=D:\My Documents\Programming\PDFEncrypt\logo2.ico
UninstallDisplayIcon={app}\pdfencrypt.exe
UninstallDisplayName=PDFEncrypt V1
Compression=lzma
SolidCompression=yes
WizardStyle=modern
[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"
[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked
[Files]
Source: "c:\temp\pdfencrypt1\dotnet4.7.2.exe"; DestDir: "{tmp}"; Flags: deleteafterinstall; Check: IsDotNetMissing
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\{#MyAppExeName}"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\BouncyCastle.Crypto.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\BouncyCastle.Crypto.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\CommandLine.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\CommandLine.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\Common.Logging.Core.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\Common.Logging.Core.pdb"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\Common.Logging.Core.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\Common.Logging.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\Common.Logging.pdb"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\Common.Logging.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.barcodes.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.barcodes.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.forms.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.forms.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.io.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.io.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.kernel.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.kernel.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.layout.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.layout.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.pdfa.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.pdfa.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.sign.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.sign.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.styledxmlparser.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.styledxmlparser.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.svg.dll"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\itext.svg.xml"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\PDFEncrypt.exe.config"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\temp\pdfencrypt1\PDFEncrypt\bin\Release\PDFEncrypt.pdb"; DestDir: "{app}"; Flags: ignoreversion
; NOTE: Don't use "Flags: ignoreversion" on any shared system files
[Icons]
Name: "{autoprograms}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"
Name: "{autodesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon
[Run]
Filename: "{tmp}\dotnet4.7.2.exe"; Parameters:"/q /norestart"; StatusMsg: "Installing Microsoft .NET framework 4.7.2..."; Check: IsDotNetMissing
Filename: "{app}\{#MyAppExeName}"; StatusMsg:"Starting PDFEncrypt..."; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent
[Code]
function IsDotNetMissing(): boolean;
// https://stackoverflow.com/a/4104226/1502289
// See also https://stackoverflow.com/a/4104226/1502289
var
release: cardinal;
success: boolean;
key: string;
begin
key := 'SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Full';
success := RegQueryDWordValue(HKLM, key, 'Release', release);
success := success and (release >= 461808); // Version 4.7.2
result := not success; // True if missing: need to run installer
end;