[wix-users] ExePackage removed on upgrade

Parkes, Kevin kevin.parkes at wacom.com
Fri Feb 11 09:54:37 PST 2022


No, not a custom BA

Authoring is as follows:

      <?define NotNewerCond  = "(DriverVersionInstalled = "" OR DriverVersionInstalled = DriverVersionBundle)"?>
      <?define DetectCondUninstall = "((WixBundleAction = $(var.ACTION_UNINSTALL)) AND $(var.NotNewerCond))"?>
      <?define DetectCondInstall   = "((WixBundleAction = $(var.ACTION_INSTALL)) AND (DriverVersionInstalled > DriverVersionBundle))" ?>
      <ExePackage  Id="driver.EXE"
                    SourceFile="$(var.StuDriverPath)"
                    DisplayName="STU Driver"
                    SuppressSignatureVerification="yes"
                    InstallCondition="DRIVER"
                    InstallCommand="/quiet NO_STU_CHECK=[NO_STU_CHECK]"
                    UninstallCommand="/quiet /uninstall NO_STU_CHECK=[NO_STU_CHECK]"
                    DetectCondition="$(var.DetectCondUninstall) OR $(var.DetectCondInstall)"
                    Protocol="burn"
                  />

DriverVersionInstalled comes from a registry search and is "v5.4.5"
DriverVersionBundle is a variable of type version and is 5.4.5.0

I can see in the new version install log: DetectCondition evaluates to false and the package is installed. Actually, that's incorrect because the condition should be true but I don't see how the package being unnecessarily reinstalled leads to it being subsequently uninstalled.

In the old version uninstall log: DetectCondition evaluates to true (which is correct because it's just been (re)installed)

I guess a <dep:Provides> would be a good idea in general, but I'm less sure it should be needed here? Could you give me an example of its use?

Thanks 

-----Original Message-----
From: wix-users <wix-users-bounces at lists.wixtoolset.org> On Behalf Of Sean Hall via wix-users
Sent: 11 February 2022 17:12
To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>
Cc: Sean Hall <r.sean.hall at gmail.com>
Subject: Re: [wix-users] ExePackage removed on upgrade

[EXTERNAL]

I assume that you are wanting the bundle to do ref-counting on the ExePackage. In other words when the newer bundle installs the exact same ExePackage, the older bundle doesn't uninstall it as part of the upgrade.
You have to use the dep:Provides element to enable the ref-counting:
https://wixtoolset.org/documentation/manual/v3/xsd/dependency/provides.html.

On Fri, Feb 11, 2022 at 11:04 AM Hoover, Jacob via wix-users < wix-users at lists.wixtoolset.org> wrote:

> The bundle authoring w/ conditions would also be helpful. I assume you 
> aren't using a custom BA.
>
> From: wix-users <wix-users-bounces at lists.wixtoolset.org> On Behalf Of 
> Rob Mensching via wix-users
> Sent: Friday, February 11, 2022 11:00 AM
> To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>
> Cc: Rob Mensching <rob at firegiant.com>
> Subject: Re: [wix-users] ExePackage removed on upgrade
>
> > However, State of the ExePackage is "Present" and "ba requested: Absent"
> (so it gets uninstalled)
>
> That pretty much answers your question. The ExePackage was requested 
> to be removed so it gets uninstalled. It'd (most likely) be a bug if 
> the ExePackage wasn't being uninstalled.
>
> Probably need more information about why you think the ExePackage 
> should not be removed.
>
>
>
> - - - - - - - - - - - - - - -
> I provide short answers on wix-users. Full commercial support is 
> offered by FireGiant at http://www.firegiant.com/services<
> http://www.firegiant.com/services>
>
>
>
> -----Original Message-----
> From: wix-users <wix-users-bounces at lists.wixtoolset.org<mailto:
> wix-users-bounces at lists.wixtoolset.org>> On Behalf Of Parkes, Kevin 
> via wix-users
> Sent: Friday, February 11, 2022 8:49 AM
> To: 'wix-users at lists.wixtoolset.org' <wix-users at lists.wixtoolset.org 
> <mailto:wix-users at lists.wixtoolset.org>>
> Cc: Parkes, Kevin 
> <kevin.parkes at wacom.com<mailto:kevin.parkes at wacom.com>>
> Subject: [wix-users] ExePackage removed on upgrade
>
> I have a bundle which includes an ExePackage plus a number of MsiPackages.
> On upgrade, the ExePackage is being removed.
>
> The install log for new installer shows the cached old installer being 
> called, with "-uninstall" towards the end of the process.
> The log of the uninstall from the old installer shows State of 
> MsiPackages as "Obsolete" and "uncache: Yes" (so they are just removed from the cache).
> However, State of the ExePackage is "Present" and "ba requested: Absent"
> (so it gets uninstalled)
>
> Any ideas why this is happening?
> More importantly, any suggestions for how to fix it?
>
> Thanks
> Kevin Parkes
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant 
> http://www.firegiant.com/<http://www.firegiant.com>
> NOTE: This email was received from an external source. Please use 
> caution when opening links or attachments in the message.
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant 
> http://www.firegiant.com/
>

____________________________________________________________________
WiX Toolset Users Mailing List provided by FireGiant http://www.firegiant.com/



More information about the wix-users mailing list