我需要安装嵌入在名为的安装程序中的第三方软件,thirdparty-installer.exe
并安装我的应用程序Instruct.exe
。我的应用程序将位于c:\MyAPP
文件夹中,并且我的所有第三方文件都必须位于c:\windows\system32
(所有文件都将被扔在那里,在 system32 根目录中)。我做了以下事情:
#define OutputDirectory_MPP "c:\myAPP"
[setup]
DefaultDirName=c:\MyAPP
DisableDirPage=yes
[dirs]
Name: {#OutputDirectory_MPP}; Attribs: system
[files]
Source: "g:\application\Instruct.exe"; DestDir: {#OutputDirectory_MPP}
Source: "g:\applicationr\thirdparty-installer.exe"; DestDir: "{cf}"; Flags: ignoreversion recursesubdirs createallsubdirs promptifolder; Permissions: system-full;
[Run]
Filename: "{cf}\thirdparty-installer.exe"; Flags: shellexec waituntilterminated
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent
(...)
我的 Instruct.exe 安装正常,完成后,第三方安装程序会提示并向用户显示更改安装目录的选项。他们的默认值是c:\program files\Thirdparty2020\
我怎样才能将他们的安装强加在c:\windows\system32
文件夹上,而不给用户留下任何选择?(甚至可能与静默安装相结合)。