mmr*_*mmr 7 wix .net-4.0 visual-studio-2010
继续我在这里提出的上一个问题,我现在需要转到vs2010.
我已经获得了2010年6月5日版WiX 3.5的最新每周版本.
这是我的安装程序的相关行:
      <ItemGroup>
        <BootstrapperFile Include="Microsoft.Net.Framework.4.0">
          <ProductName>.NET Framework 4.0</ProductName>
        </BootstrapperFile>
        <BootstrapperFile Include="Microsoft.Windows.Installer.4.5">
         <ProductName>Windows Installer 4.5</ProductName>
       </BootstrapperFile>
      </ItemGroup>
和
<GenerateBootstrapper ApplicationFile="MySetup.msi" ApplicationName="MyProgram" BootstrapperItems="@(BootstrapperFile)" Path="C:\Program Files\Microsoft SDKs\Windows\v7.0A\Bootstrapper\" ComponentsLocation="Relative" OutputPath="$(OutputPath)" Culture="en" />
但是,它只是不起作用.在vs2010中,.NET Framework 4.0和Windows Installer 4.5文件旁边有感叹号,属性页面将它们列为"Unknown BuildAction BootstrapperFile",而构建似乎根本不会安装.NET 4.0.相关警告是:
C:\source\depot\project\vs2010\WiXSetup\WiXSetup.wixproj(68,5): warning MSB3155: Item 'Microsoft.Net.Framework.4.0' could not be located in 'C:\Program Files\Microsoft SDKs\Windows\v7.0A\Bootstrapper\'.
Jon*_*Jon 12
简短的回答是改变
<ItemGroup>
    <BootstrapperFile Include="Microsoft.Net.Framework.3.5.SP1" >
       <ProductName>.NET Framework 3.5 SP1</ProductName>
    </BootstrapperFile>
    <BootstrapperFile Include="Microsoft.Windows.Installer.3.1" >
       <ProductName>Windows Installer 3.1</ProductName>
    </BootstrapperFile>
</ItemGroup>
<Target Name="setup">
    <GenerateBootstrapper
        ApplicationFile="myproduct.msi"
        ApplicationName="myproduct"
        BootstrapperItems="@(BootstrapperFile)"
        Path="C:\Program Files\Microsoft SDKs\Windows\v7.0A\Bootstrapper\"
        ComponentsLocation="Relative"
        OutputPath="$(cddir)"
        Culture="en"/>
</Target>
至
<ItemGroup>
    <BootstrapperFile Include=".NETFramework,Version=v4.0" >
       <ProductName>.NET Framework 4.0</ProductName>
    </BootstrapperFile>
    <BootstrapperFile Include="Microsoft.Windows.Installer.3.1" >
       <ProductName>Windows Installer 3.1</ProductName>
    </BootstrapperFile>
</ItemGroup>
<Target Name="setup">
    <GenerateBootstrapper
        ApplicationFile="myproduct.msi"
        ApplicationName="myproduct"
        BootstrapperItems="@(BootstrapperFile)"
        Path="C:\Program Files\Microsoft SDKs\Windows\v7.0A\Bootstrapper\"
        ComponentsLocation="Relative"
        OutputPath="$(cddir)"
        Culture="en"/>
</Target>
我通过进入我的机器上的SDK引导程序目录(C:\ Program Files\Microsoft SDKs\Windows\v7.0A\Bootstrapper),为Visual Studios 2010找到了这个.在下面有一个可以读取的项目列表Wix并包含在bootstrapping中.在每个文件夹中都有一个名为Product.xml的文件.在帮助寻找后在这里创建一个.NET 3.5的安装,我发现,在产品标签中的产品代码属性似乎识别自举元素的名称,所以当我改变了值,在C引用:\ Program Files文件\微软它运行的SDK\Windows\v7.0A\Bootstrapper\Packages\DotNetFX40\Product.xml.
| 归档时间: | 
 | 
| 查看次数: | 5901 次 | 
| 最近记录: |