我刚开始学习如何使用WiX,但是遇到了问题。我的程序包使用了一个第三方库,需要在GAC和程序包安装目录中存在某个文件。
使用WiX,我可以让这些文件出现在安装目录中或者GAC中,但不能同时出现在两者中。
有没有什么方法可以解决这个问题呢?
Assembly=".net"
属性即可。<Directory Id="ProgramFilesFolder">
<Directory Id="ProductDirectory" Name="$(var.ProductName)">
<Directory Id="GAC" Name="GAC">
<Component Id="RT_MyControl" Guid="22887611-B13E-41EE-897C-D78830E68AEB" DiskId="1">
<File Id="F_RT_MyControl" Name="MyCtrl.dll" LongName="MyControl.dll" Source="$(var.SrcPath)MyControl.dll" KeyPath="yes" Assembly=".net"/>
</Component>
</Directory>
<Component Id="DT_MyControl" Guid="FB935B7D-D2BD-4B83-A26C-A9376EBA0915" DiskId="1">
<File Id="F_DT_MyControl" Name="MyCtrl.dll" LongName="MyControl.dll" Source="$(var.SrcPath)MyControl.dll" KeyPath="yes"/>
</Component>
</Directory>
</Directory>