在我的程序vcredist_x86_2008.exe和vcredist_x86_2010.exe尝试安装程序本身之前,我正在尝试从msi安装该程序的依赖项。我有下面的代码。
<Binary Id="SetupCA" SourceFile="..\..\ext_library\SetupCA\SetupCA\bin\Release\SetupCA.CA.dll"/>
<Binary Id="VCREDIST_2008_FILE" SourceFile="..\..\ext_library\vcredist_x86_2008.exe" />
<Binary Id="VCREDIST_2010_FILE" SourceFile="..\..\ext_library\vcredist_x86_2010.exe" />
<CustomAction Id="VCREDIST_2008" BinaryKey="VCREDIST_2008_FILE" ExeCommand="/q:a" Execute="immediate" Return="check" />
<CustomAction Id="VCREDIST_2010" BinaryKey="VCREDIST_2010_FILE" ExeCommand="/q /norestart" Execute="immediate" Return="check" />
<CustomAction Id="WRITEFILETODISK" Execute="immediate" BinaryKey="SetupCA" DllEntry="WriteFileToDisk" />
<CustomAction Id="ResidueRemove" Execute="immediate" BinaryKey="SetupCA" DllEntry="DeleteResidue" />
<InstallExecuteSequence>
<Custom Action="WRITEFILETODISK" Before="InstallFinalize">NOT Installed</Custom>
<Custom Action="ResidueRemove" After="InstallFinalize">Installed</Custom>
<Custom Action="VCREDIST_2008" Before="CostInitialize">NOT Installed</Custom>
<Custom Action="VCREDIST_2010" Before="CostInitialize">NOT Installed</Custom>
</InstallExecuteSequence>我还有另外两个自定义操作WRITEFILETODISK,,它将把参数传递给安装程序并在文件中写入配置,以及在卸载时运行的ResidueRemove,如果有的话,它必须删除剩余的文件。使用/l*v模式安装msi,我得到以下信息:
Error 1721. There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: VCREDIST_2008, location: C:\Windows\Installer\MSIA422.tmp, command: /q:a
MSI (s) (D8:30) [10:14:20:867]: Note: 1: 2205 2: 3: Error
MSI (s) (D8:30) [10:14:20:867]: Note: 1: 2228 2: 3: Error 4: SELECT `Message` FROM `Error` WHERE `Error` = 1709
MSI (s) (D8:30) [10:14:20:867]: Product: LogPointAgent -- Error 1721. There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: VCREDIST_2008, location: C:\Windows\Installer\MSIA422.tmp, command: /q:a 这不是从msi安装另一个exe的正确方式吗?如果我错了,请改正。
发布于 2015-02-25 13:25:12
EXE是一个自解压缩的MSI。Windows有一个互斥锁,可以阻止两个并发的MSI事务,因此不可能让一个MSI调用另一个MSI。您需要研究如何使用WiX的Burn引导程序来序列化这两个MSI的安装。
https://stackoverflow.com/questions/28711270
复制相似问题