Wix Toolset 打包安装包
基于visual studio(以Visual Studio 2015为例), 使用Wix Toolset打包程序
安装Wix Toolset extension
工具-》扩展和更新, 搜索Wix ,找到extension 进行安装
打包
- 创建工程
新建-》项目 -》Wix Toolset -> V3 -> Setup Project for Wix v3, 创建打包工程。将会生成工程文件和Product.wxs, 根据实际项目,修改Product.wxs。
常见错误
- Unresolved reference to symbol 'WixUI:WixUI_InstallDir' in section 'Product:*'.
原因:
解决方案:Product.wxs添加以下配置后引起的: <!-- 定义 UI 并引用安装目录选择对话框 --> <UIRef Id="WixUI_InstallDir" /> <Property Id="WIXUI_INSTALLDIR" Value="INSTALLFOLDER" />右键项目-》添加-》引用, 找到WixUIExtension.dll 进行添加 - This 32BitComponent testComponent uses 64BitDirectory INSTALLFOLDER
解决方案:
组件定义的时候,需要指定Win64, Platform="x64"
如:Component Id="testComponent" Guid="*" Win64="yes">
浙公网安备 33010602011771号