如何使用wix boostrap安装先决条件但输出必须是msi

问题描述:

HI

我是Wix的新手,我创建了一个简单的bootstrap来安装.net framework.Check我的bundle.wxs





但是输出是exe,如果我想要输出msi,我该怎么办? (更改项目的输出会产生错误)。请详细分享步骤



也让我知道如何以这种方式安装sybase



我尝试了什么:



<?xml version =1.0encoding =UTF-8?>

< Wix xmlns =http://schemas.microsoft.com/wix/2006/wixmlns:util =http://schemas.microsoft.com/wix/UtilExtension>

< Bundle Name =WIXBoostrapVersion =1.0.0.0Manufacturer =MicrosoftUpgradeCode =6751ee3a-4fd1-4136-a134-9ff66dc41213>

&lt ; BootstrapperApplicationRef Id =WixStandardBootstrapperApplication.RtfLicense/>



< chain>



< PackageGroupRef Id =Netfx45/>

<! - < MsiPackage Id =SetupCompressed =yesSourceFile =$(var.Installer.TargetPath)

Vital =是> - >

<! - < MsiProperty Name =INSTALLLOCATIONValue =[InstallFolder]/> - &gt ;

<! ---->

<! - TODO:定义链式包列表。 - >

<! - < MsiPackage SourceFile =$(var.AppInstaller.TargetPath)/> - >

<! - < MsiPackage SourceFile =path \to\your.msi/> - >







< fragment>

< ! - 检查.NET 4.5 - >

< util:RegistrySearch Root =HKLMKey =SOFTWARE\Microsoft\Net Framework Setup\NDP\v4 \完整的Value =版本Variable =Netfx4FullVersion/>

< util:RegistrySearch Root =HKLMKey =SOFTWARE \ Microsoft \ NET

Framework Setup \NDP\v4 \FullValue =VersionVariable =Netfx4x64FullVersionWin64 =yes/>



< PackageGroup Id =Netfx45>

<! - < MsiPackage

可见=是

缓存=否

压缩=否

ForcePerMachine =是

永久=是

Vital =是

SourceFile =。\ dotnetfx45_full_x86_x64.msi

InstallCondition =(VersionNT< v6.0 OR VersionNT64< v6.0)A ND(NOT(Netfx4FullVersion或Netfx4x64FullVersion))/> - >

< ExePackage Id =Netfx45Cache =noCompressed =yesPerMachine =yesProtocol = netfx4Permanent =yesVital =yesInstallCommand =/ norestart / passive / showrmui

SourceFile =。\ dotnetfx45_full_x86_x64.exe

DetectCondition =(Netfx4FullVersion =4.5.50709)AND(NOT VersionNT64 OR(Netfx4x64FullVersion =4.5.50709))

InstallCondition =(VersionNT< v6.0或VersionNT64< v6.0)AND(NOT(Netfx4FullVersion或Netfx4x64FullVersion))/>

HI
I am new to Wix and i have created a simple bootstrap to install .net framework.Check my bundle.wxs


but the output is exe, What i have to do if i want the output in msi . (Changing output of the project gives error). Please share the steps in detail

Also let me know how to install sybase also in this way

What I have tried:

<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" xmlns:util="http://schemas.microsoft.com/wix/UtilExtension">
<Bundle Name="WIXBoostrap" Version="1.0.0.0" Manufacturer="Microsoft" UpgradeCode="6751ee3a-4fd1-4136-a134-9ff66dc41213">
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.RtfLicense" />

<chain>

<PackageGroupRef Id="Netfx45"/>
<!--<MsiPackage Id="Setup" Compressed="yes" SourceFile="$(var.Installer.TargetPath)"
Vital="yes">-->
<!--<MsiProperty Name="INSTALLLOCATION" Value="[InstallFolder]" />-->
<!---->
<!-- TODO: Define the list of chained packages. -->
<!--<MsiPackage SourceFile="$(var.AppInstaller.TargetPath)" />-->
<!-- <MsiPackage SourceFile="path\to\your.msi" /> -->



<fragment>
<!-- Check for .NET 4.5 -->
<util:RegistrySearch Root="HKLM" Key="SOFTWARE\Microsoft\Net Framework Setup\NDP\v4\Full" Value="Version" Variable="Netfx4FullVersion" />
<util:RegistrySearch Root="HKLM" Key="SOFTWARE\Microsoft\Net
Framework Setup\NDP\v4\Full" Value="Version" Variable="Netfx4x64FullVersion" Win64="yes" />

<PackageGroup Id="Netfx45">
<!--<MsiPackage
Visible="yes"
Cache="no"
Compressed="no"
ForcePerMachine="yes"
Permanent="yes"
Vital="yes"
SourceFile=".\dotnetfx45_full_x86_x64.msi"
InstallCondition="(VersionNT < v6.0 OR VersionNT64 < v6.0) AND (NOT (Netfx4FullVersion OR Netfx4x64FullVersion))" />-->
<ExePackage Id="Netfx45" Cache="no" Compressed="yes" PerMachine="yes" Protocol="netfx4" Permanent="yes" Vital="yes" InstallCommand="/norestart /passive /showrmui"
SourceFile=".\dotnetfx45_full_x86_x64.exe"
DetectCondition="(Netfx4FullVersion="4.5.50709") AND (NOT VersionNT64 OR (Netfx4x64FullVersion="4.5.50709"))"
InstallCondition="(VersionNT < v6.0 OR VersionNT64 < v6.0) AND (NOT (Netfx4FullVersion OR Netfx4x64FullVersion))"/>

(var.Installer.TargetPath)

Vital =是> - >

<! - < MsiProperty Name =INSTALLLOCATIONValue =[InstallFolder]/> - >

<!---->

<! - TODO:定义链式包列表。 - >

<! - < MsiPackage SourceFile =
(var.Installer.TargetPath)"
Vital="yes">-->
<!--<MsiProperty Name="INSTALLLOCATION" Value="[InstallFolder]" />-->
<!---->
<!-- TODO: Define the list of chained packages. -->
<!--<MsiPackage SourceFile="


(var.AppInstaller.TargetPath)/> - >

<! - < MsiPackage SourceFile =path \to\your.msi/> - >







< fragment>

< ! - 检查.NET 4.5 - >

< util:RegistrySearch Root =HKLMKey =SOFTWARE\Microsoft\Net Framework Setup\NDP\v4 \完整的Value =版本Variable =Netfx4FullVersion/>

< util:RegistrySearch Root =HKLMKey =SOFTWARE \ Microsoft \ NET

Framework Setup \NDP\v4 \FullValue =VersionVariable =Netfx4x64FullVersionWin64 =yes/>



< PackageGroup Id =Netfx45>

<! - < MsiPackage

可见=是

缓存=否

压缩=否

ForcePerMachine =是

永久=是

Vital =是

SourceFile =。\ dotnetfx45_full_x86_x64.msi

InstallCondition =(VersionNT< v6.0 OR VersionNT64< v6.0)A ND(NOT(Netfx4FullVersion或Netfx4x64FullVersion))/> - >

< ExePackage Id =Netfx45Cache =noCompressed =yesPerMachine =yesProtocol = netfx4Permanent =yesVital =yesInstallCommand =/ norestart / passive / showrmui

SourceFile =。\ dotnetfx45_full_x86_x64.exe

DetectCondition =(Netfx4FullVersion =4.5.50709)AND(NOT VersionNT64 OR(Netfx4x64FullVersion =4.5.50709))

InstallCondition =(VersionNT< v6.0或VersionNT64< v6.0)AND(NOT(Netfx4FullVersion或Netfx4x64FullVersion))/>
(var.AppInstaller.TargetPath)" />-->
<!-- <MsiPackage SourceFile="path\to\your.msi" /> -->



<fragment>
<!-- Check for .NET 4.5 -->
<util:RegistrySearch Root="HKLM" Key="SOFTWARE\Microsoft\Net Framework Setup\NDP\v4\Full" Value="Version" Variable="Netfx4FullVersion" />
<util:RegistrySearch Root="HKLM" Key="SOFTWARE\Microsoft\Net
Framework Setup\NDP\v4\Full" Value="Version" Variable="Netfx4x64FullVersion" Win64="yes" />

<PackageGroup Id="Netfx45">
<!--<MsiPackage
Visible="yes"
Cache="no"
Compressed="no"
ForcePerMachine="yes"
Permanent="yes"
Vital="yes"
SourceFile=".\dotnetfx45_full_x86_x64.msi"
InstallCondition="(VersionNT < v6.0 OR VersionNT64 < v6.0) AND (NOT (Netfx4FullVersion OR Netfx4x64FullVersion))" />-->
<ExePackage Id="Netfx45" Cache="no" Compressed="yes" PerMachine="yes" Protocol="netfx4" Permanent="yes" Vital="yes" InstallCommand="/norestart /passive /showrmui"
SourceFile=".\dotnetfx45_full_x86_x64.exe"
DetectCondition="(Netfx4FullVersion="4.5.50709") AND (NOT VersionNT64 OR (Netfx4x64FullVersion="4.5.50709"))"
InstallCondition="(VersionNT < v6.0 OR VersionNT64 < v6.0) AND (NOT (Netfx4FullVersion OR Netfx4x64FullVersion))"/>