2014-10-30 2 views
0

사용자가 세 가지 다른 설정 유형 (워크 스테이션, 클라이언트 및 서버) 중에서 선택할 수있는 부스트 래퍼 응용 프로그램을 WiX 3.8으로 만들었습니다. bootstrapper-engine-method 계획과 적절한 LaunchAction (설치, 복구, 제거)을 사용하여 설치, 복구 및 제거가 정상적으로 수행되었습니다.WiX 번들의 majorupgrade에 대한 잘못된 패키지 유형

이제 majorupgrade-method를 구현하고 싶습니다. 로모그래퍼

Plan(LaunchAction.UpdateReplace); 

내가 내 설치의 이전 버전을 설치 한 다음 내가 설정의 최신 버전을 시작 (다음 UI 프로젝트 (설치면)에서 는 내가 다음 줄을 포함하는 새로운 방법을 추가 높은 버전 번호). 새 설치 프로그램은 이전 버전을 검색하고 이전 설치가 있으며 사용자가 단추를 눌러 업그레이드를 알릴 수 있음을 사용자에게 알립니다. LaunchAction.UpdateReplace를 사용하여 계획 메서드를 호출 할 때의 요점입니다. 그러나 업그레이드가 실패하고 난 다음 로그 얻을 : 항상 생성 새로운 GUID 빌드 타임에 그래서, 별표가있는 제품 ID를 살고 있고 번들 자체에서

Burn v3.8.1128.0, Windows v6.3 (Build 9600: Service Pack 0), path: C:\experimente\Staffdirector\v4.81.1.0\ProsoftSetup.exe, cmdline: '' 
Initializing string variable 'INSTALLFOLDER' to value '[ProgramFilesFolder]' 
Setting string variable 'WixBundleLog' to value 'C:\Users\PATRIC~1.PRO\AppData\Local\Temp\Staffdirector_20141030102104.log' 
Setting string variable 'WixBundleOriginalSource' to value 'C:\experimente\Staffdirector\v4.81.1.0\ProsoftSetup.exe' 
Setting string variable 'WixBundleName' to value 'Staffdirector' 
Loading managed bootstrapper application. 
Creating BA thread to run asynchronously. 
Detect begin, 9 packages 
Registry key not found. Key = 'SOFTWARE\Microsoft\Microsoft Sync Framework\v2.0\Setup\SynchronizationX64' 
Setting string variable 'Netfx4FullVersion' to value '4.5.51641' 
Setting string variable 'Netfx4x64FullVersion' to value '4.5.51641' 
Setting string variable 'SyncX86' to value '1' 
Detected related bundle: {b7d055e3-3c85-477c-ab04-206e964536f8}, type: Upgrade, scope: PerMachine, version: 4.80.1.0, operation: MajorUpgrade 
Condition 'Netfx4FullVersion AND (NOT VersionNT64 OR Netfx4x64FullVersion)' evaluates to true. 
Detected package: DotNetFramework_4_5_1, state: Present, cached: None 
Detected package: WindowsInstaller45_WinXP_x86, state: Absent, cached: None 
Detected package: WindowsInstaller45_WinServer2003_x86, state: Absent, cached: None 
Detected package: WindowsInstaller45_WinServer2003_x64, state: Absent, cached: None 
Detected package: WindowsInstaller45_Win6_x86, state: Absent, cached: None 
Detected package: WindowsInstaller45_Win6_x64, state: Absent, cached: None 
Detected package: SynchronizationX64, state: Absent, cached: None 
Detected package: SynchronizationX86, state: Absent, cached: None 
Detected package: SetupPackage, state: Absent, cached: None 
Detect complete, result: 0x0 
Setting string variable 'IsWorkstationSetup' to value 'true' 
Setting string variable 'INSTALLFOLDER' to value 'C:\Program Files (x86)' 
Detect begin, 9 packages 
Registry key not found. Key = 'SOFTWARE\Microsoft\Microsoft Sync Framework\v2.0\Setup\SynchronizationX64' 
Setting string variable 'Netfx4FullVersion' to value '4.5.51641' 
Setting string variable 'Netfx4x64FullVersion' to value '4.5.51641' 
Setting string variable 'SyncX86' to value '1' 
Detected related bundle: {b7d055e3-3c85-477c-ab04-206e964536f8}, type: Upgrade, scope: PerMachine, version: 4.80.1.0, operation: MajorUpgrade 
RelatedBundleProductCode is {b7d055e3-3c85-477c-ab04-206e964536f8} 
Condition 'Netfx4FullVersion AND (NOT VersionNT64 OR Netfx4x64FullVersion)' evaluates to true. 
Detected package: DotNetFramework_4_5_1, state: Present, cached: None 
Detected package: WindowsInstaller45_WinXP_x86, state: Absent, cached: None 
Detected package: WindowsInstaller45_WinServer2003_x86, state: Absent, cached: None 
Detected package: WindowsInstaller45_WinServer2003_x64, state: Absent, cached: None 
Detected package: WindowsInstaller45_Win6_x86, state: Absent, cached: None 
Detected package: WindowsInstaller45_Win6_x64, state: Absent, cached: None 
Detected package: SynchronizationX64, state: Absent, cached: None 
Detected package: SynchronizationX86, state: Absent, cached: None 
Detected package: SetupPackage, state: Absent, cached: None 
Detect complete, result: 0x0 
Plan: method begins 
Plan: Test UI.View == null is False 
Plan: Do action UpdateReplace 
Plan begin, 9 packages, action: UpdateReplace 
OnPlanPackageBegin: method begins 
OnPlanPackageBegin: PackageId = 
Invalid package type. 
Error 0x8000ffff: Failed to plan execute package. 
Error 0x8000ffff: Failed to process update package. 
Error 0x8000ffff: Failed to plan update. 
OnPlanComplete: method begins 
OnPlanComplete: CurrentInstallationState = DetectedOlder 
OnPlanComplete: Installation failed 
OnPlanComplete: CurrentInstallationState = Failed 
Plan complete, result: 0x8000ffff 
Shutting down, exit code: 0x0 
Variable: INSTALLFOLDER = C:\Program Files (x86) 
Variable: IsWorkstationSetup = true 
Variable: Netfx4FullVersion = 4.5.51641 
Variable: Netfx4x64FullVersion = 4.5.51641 
Variable: SyncX86 = 1 
Variable: VersionNT64 = 6.3.0.0 
Variable: WixBundleAction = 7 
Variable: WixBundleElevated = 0 

합니다. 당신은 여기에서 볼 수 있습니다 과 같이 워크 스테이션 (Product.wxs)에 대한 설정이다

<?xml version="1.0" encoding="UTF-8"?> 
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" 
    xmlns:bal="http://schemas.microsoft.com/wix/BalExtension"> 
    <Bundle Name="Staffdirector" 
      Version="$(var.BuildVersion)" 
      Manufacturer="MyFirm" 
      UpgradeCode="DF43F081-B375-42EE-8139-0488254624E6" 
      IconSourceFile="Images\icon.ico"> 

     <!-- Variables for the different setuptypes. These will be filled by the UI. --> 
     <?define IsWorkstationSetup = "true" ?> 
     <?define IsClientSetup = "false" ?> 
     <?define IsServerSetup = "false" ?> 

     <!-- Variable for the installerlocation. Can be filled by the UI. --> 
     <Variable Name="INSTALLFOLDER" 
        bal:Overridable="yes" 
        Type="string" 
        Value="[ProgramFilesFolder]"/> 

     <BootstrapperApplicationRef Id="ManagedBootstrapperApplicationHost" > 
      <Payload Name='BootstrapperCore.config' 
        SourceFile='..\..\..\Prosoft.Setup.Installer.UI\bin\Debug\BootstrapperCore.config' /> 
      <Payload SourceFile='..\..\..\Prosoft.Setup.Installer.UI\bin\Debug\SetupInstallerUI.dll'/> 

      <Payload SourceFile='..\..\..\Prosoft.Setup.UI\bin\Debug\Telerik.Windows.Controls.dll' /> 
      <Payload SourceFile='..\..\..\Prosoft.Setup.UI\bin\Debug\Telerik.Windows.Controls.Docking.dll' /> 
      <Payload SourceFile='..\..\..\Prosoft.Setup.UI\bin\Debug\Telerik.Windows.Controls.GridView.dll' /> 
      <Payload SourceFile='..\..\..\Prosoft.Setup.UI\bin\Debug\Telerik.Windows.Controls.Input.dll' /> 
      <Payload SourceFile='..\..\..\Prosoft.Setup.UI\bin\Debug\Telerik.Windows.Controls.Navigation.dll' /> 
      <Payload SourceFile='..\..\..\Prosoft.Setup.UI\bin\Debug\Telerik.Windows.Controls.RibbonView.dll' /> 
      <Payload SourceFile='..\..\..\Prosoft.Setup.UI\bin\Debug\Telerik.Windows.Data.dll' /> 
     </BootstrapperApplicationRef> 

     <Chain> 
      <!-- In this package the variable WixMbaPrereqPackageId is defined. --> 
      <PackageGroupRef Id='Ndp451Aiios' /> 

      <PackageGroupRef Id='WindowsInstaller45' /> 

      <!--<PackageGroupRef Id='Netfx4Full' />--> 

      <PackageGroupRef Id='SyncFramework' /> 

      <?if $(var.IsServerSetup) = "true"?> 
       <PackageGroupRef Id='SqlServerExpress' /> 
      <?endif?> 

      <!-- Workstation-Setup --> 
      <?if $(var.IsWorkstationSetup) = "true"?> 
       <MsiPackage Id='SetupPackage' 
          SourceFile='.\Resources\Setup.msi' 
          Permanent='no' 
          Cache='yes' 
          DisplayInternalUI='no' 
          Vital='yes' 
          Compressed='yes' 
          EnableFeatureSelection='no' 
          DisplayName='ProsoftSetup'> 
        <MsiProperty Name="INSTALLLOCATION" 
           Value="[INSTALLFOLDER]" /> 
       </MsiPackage> 
      <?endif?> 

      <!-- TODO Client-Setup --> 
      <?if $(var.IsClientSetup) = "true"?> 
       <MsiPackage Id='SetupPackage' 
          SourceFile='.\Resources\Setup.msi' 
          Permanent='no' 
          Cache='yes' 
          DisplayInternalUI='no' 
          Vital='yes' 
          Compressed='yes' 
          EnableFeatureSelection='no' 
          DisplayName='ProsoftSetup'> 
        <MsiProperty Name="INSTALLLOCATION" 
           Value="[INSTALLFOLDER]" /> 
       </MsiPackage> 
      <?endif?> 

      <!-- TODO Server-Setup --> 
      <?if $(var.IsServerSetup) = "true"?> 
       <MsiPackage Id='SetupPackage' 
          SourceFile='.\Resources\Setup.msi' 
          Permanent='no' 
          Cache='yes' 
          DisplayInternalUI='no' 
          Vital='yes' 
          Compressed='yes'`enter code here` 
          EnableFeatureSelection='no' 
          DisplayName='ProsoftSetup'> 
        <MsiProperty Name="INSTALLLOCATION" 
           Value="[INSTALLFOLDER]" /> 
       </MsiPackage> 
      <?endif?> 
     </Chain> 
    </Bundle> 
</Wix> 

을 :

<?xml version="1.0" encoding="UTF-8"?> 
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" 
    xmlns:util="http://schemas.microsoft.com/wix/UtilExtension"> 
    <?define Manufactor = "MyFirm"?> 
    <?define UpgradeGuid = "694926FB-81DD-4531-93BE-EE227859584C"?> 

    <Product Id="*" 
      Name="MyApplication" 
      Language="1031" 
      Version="$(var.BuildVersion)" 
      Manufacturer="$(var.Manufactor)" 
      UpgradeCode="$(var.UpgradeGuid)" 
      Codepage="UTF-8"> 

     <Package InstallerVersion="405" 
       Compressed="yes" 
       InstallScope="perMachine"/> 

     <MediaTemplate EmbedCab="yes"/> 

     <Feature Id="ProductFeature" 
       Title="Prosoft.Setup.Msi" 
       Level="1" > 
      <ComponentGroupRef Id="SourceComponentGroup"/> 
      <ComponentRef Id="ApplicationShortcut"/> 
     </Feature> 

     <Property Id="ARPPRODUCTICON" 
        Value="Icon.exe"/> 
     <Icon Id="Icon.exe" 
       SourceFile="..\..\..\Bootstrapper\Images\icon.ico" /> 

    </Product> 
    <Fragment Id="ClientFragment"> 
     <!-- Here the variable from the bootstrapper will be setted into INSTALLDIR. --> 
     <Directory Id="TARGETDIR" 
        Name="SourceDir"> 
      <Directory Id="ProgramFilesFolder"> 
       <Directory Id="INSTALLLOCATION" 
          Name="InstallLocation"> 
        <Directory Id="CompanyFolder" 
           Name="prosoft"> 
         <Directory Id="INSTALLDIR" 
            Name="staffdirector" /> 
        </Directory> 
       </Directory> 
      </Directory> 

      <Directory Id="DesktopFolder" 
         Name="Desktop"/> 

      <Directory Id="ProgramMenuFolder"> 
       <Directory Id="ApplicationProgramsFolder" 
          Name="staffdirector"> 

        <Component Id="ApplicationShortcut" 
           Guid="F8EE48A5-5264-4180-A35C-5CB7E8A0D58C"> 

         <Shortcut Id="ApplicationStartMenuShortcut" 
            Name="staffdirector" 
            Target="[INSTALLDIR]staffdirector.exe" 
            WorkingDirectory="ProgramFolder" 
            Icon="Icon.exe"/> 

         <Shortcut Id="StaffdirectorDesktopShortCut" 
            Directory="DesktopFolder" 
            Name="staffdirector" 
            Target="[INSTALLDIR]staffdirector.exe" 
            WorkingDirectory="InstallDirectory" 
            Description="Startet den staffdirector" 
            Icon="Icon.exe"> 
         </Shortcut> 

         <RemoveFolder Id="INSTALLLOCATION" 
             On="uninstall"/> 

         <RegistryValue Root="HKCU" 
             Key="Software\Prosoft\staffdirector" 
             Name="installed" 
             Type="integer" 
             Value="1" 
             KeyPath="yes" /> 
        </Component> 
       </Directory> 
      </Directory> 
     </Directory> 
    </Fragment> 
</Wix> 

아무도 말해 줄 수

, 무엇이 잘못이야? 제발 대답하지 마십시오. LauchAction.Install을 대신 사용하겠습니다. 나는 그랬고 그 결과는 installerwindows의 무한 루프 였고 응용 프로그램을 제거하려고했습니다.

도움을 주시면 감사하겠습니다. 미리 감사드립니다.

답변

3

올바른 작업은 Install 아니요, UpdateReplace입니다. UpdateReplace은 번들이 사용 가능한 번들의 최신 버전이 있음을 인식하고 종료하고 새 버전을 실행하려고 할 때입니다. 로그의 오류는 사용자 정의 부트 스트 래퍼 응용 프로그램이 최신 버전의 위치를 ​​엔진에 알려주지 않았기 때문입니다.

this issue으로 실행 중이며 v3.9에서 수정 된 것 같습니다. 그 중 하나 또는 사용자 지정 BA가 자동 제거를 올바르게 처리하지 못합니다.

관련 문제