If you are using SolidCompression
(which I assume you do), and you listed any of the temporary files (ISSkin.dll
and/or Office2007.cjstyles
) after those big files in the [Files]
section, then the initialization takes so long, because the installer is extracting all the files listed prior those temporary files.
That might be caused by the ISSkin.dll
library, which is extracted for loading by the scripting engine (if you didn't use delayload
flag), or by manual extracting of the Office2007.cjstyles
skin file by the ExtractTemporaryFile
function. There's even warning in the reference for this function:
When solid compression is enabled, be sure to list your temporary files at (or near) the top of the [Files] section. In order to extract an arbitrary file in a solid-compressed installation, Setup must first decompress all prior files (to a temporary buffer in memory). This can result in a substantial delay if a number of other files are listed above the specified file in the [Files] section.
If I was right with my assumptions and you have enabled SolidCompression
and temporary files listed below those huge data files, then we can reconstruct your script to something like this:
[Setup]
AppName=My Program
AppVersion=1.5
DefaultDirName={pf}\My Program
SolidCompression=yes
[Files]
; first are listed huge files
Source: "Setup_1.0.121.exe"; DestDir: "{app}"
Source: "Setup_1.0.121-1a.bin"; DestDir: "{app}"
Source: "Setup_1.0.121-1b.bin"; DestDir: "{app}"
Source: "Setup_1.0.121-1c.bin"; DestDir: "{app}"
; if SolidCompression is enabled, all the prior files are extracted
; when any of the the following files is extracted
Source: "ISSkin.dll"; DestDir: "{tmp}"; Flags: dontcopy
Source: "Office2007.cjstyles"; DestDir: "{tmp}"; Flags: dontcopy
...
If you read this post carefully, you already know that the answer was in the quote from the reference. All you need to do is list all the temporary files on top of the [Files]
section to avoid decompressing the huge ones. So the above script would become:
[Setup]
AppName=My Program
AppVersion=1.5
DefaultDirName={pf}\My Program
SolidCompression=yes
[Files]
; first are listed temporary files
Source: "ISSkin.dll"; DestDir: "{tmp}"; Flags: dontcopy
Source: "Office2007.cjstyles"; DestDir: "{tmp}"; Flags: dontcopy
; the huge files are now extracted just when they are needed
Source: "Setup_1.0.121.exe"; DestDir: "{app}"
Source: "Setup_1.0.121-1a.bin"; DestDir: "{app}"
Source: "Setup_1.0.121-1b.bin"; DestDir: "{app}"
Source: "Setup_1.0.121-1c.bin"; DestDir: "{app}"
...