如何在 Wix 安装项目中引用 GAC 的 dll 文件? [英] How to reference GAC'd dll files in Wix setup project?

查看:17
本文介绍了如何在 Wix 安装项目中引用 GAC 的 dll 文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们在开发机器上有几个 GAC 的第三方控件.这些在 Visual Studio 项目中被引用.当我们使用 VS 设置项目时,它知道如何找到引用的文件并将它们包含在 MSI 中.但是,我不知道如何将 GAc 中引用的 DLL 文件包含在我们的新 WIX 设置中.我将什么作为 Source?

We have several 3rd party controls which are GAC'd on the development machines. These are referenced in the Visual Studio projects. When we were using VS setup projects, it knew how to find the referenced files and include them in the MSI. However, I can't figure out how to include the referenced DLL files from the GAc in our new WIX setup. What do I put as the Source?

<File Id="MyFile" Name="MyFile" Source="在这里放什么?"DiskId="1" Vital="yes" KeyPath="no"/>

还有一个额外的问题:如何通过加热或其他方式自动收获这些?

Also a bonus question: how to harvest these automatically with heat or by other means?

推荐答案

对两者的简短回答:你不能,你也不应该.您应该将您的工具签入您的源代码控制系统,并在结帐时将其加载到您的安装程序中.这样您就可以控制您分发的版本,而不是从 GAC 获取任意版本.

Short answer to both: You can't and you shouldn't anyway. You should check your tools into your source-control system and load it into your installers from a checkout. That way you have control over the versions you're distributing instead of picking up arbitrary versions from the GAC.

注意:DiskId 和 Vital 都默认为您提供的值,因此您可以通过省略它们来节省一些输入.

Note: DiskId and Vital both default to the values you give, so you can save some typing by just omitting them.

这篇关于如何在 Wix 安装项目中引用 GAC 的 dll 文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆