[wix-users] Antwort: Bundle: DetectCondition with semantic versioning

Phill Hogland phill.hogland at rimage.com
Fri Aug 28 05:45:24 PDT 2015


I seem to recall a Feature request for this issue:
http://wixtoolset.org/issues/4666/

Since semantic versioning is not supported in the current Burn vx.x.x.x version comparison, to my knowledge, as others indicated you need to process the version in a custom BA (or the WixStdBA with a bafunctions.dll) and then set a variable that you can use in the DetectCondition (or implement logic in one of the Plan handlers.  There are examples of both bafunctions.dll and custom BA and PlandPackageBegin in the wixtoolset source.

-----Original Message-----
From: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] On Behalf Of Thomas.Deboben.ext at rohde-schwarz.com
Sent: Friday, August 28, 2015 4:00 AM
To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>
Cc: wix-users <wix-users-bounces at lists.wixtoolset.org>
Subject: [wix-users] Antwort: Bundle: DetectCondition with semantic versioning

Hi,

does no one has an idea?

Thanks,
  Thomas



Von:    Thomas.Deboben.ext at rohde-schwarz.com
An:     wix-users at lists.wixtoolset.org, 
Datum:  24.08.2015 11:46
Betreff:        [wix-users] Bundle: DetectCondition with semantic 
versioning
Gesendet von:   "wix-users" <wix-users-bounces at lists.wixtoolset.org>


Hi all, 

I have a bootstrapper installer including an ExePackage of PostgreSQL installer. 
So long I had a RegistrySearch for the Version value 

    <util:RegistrySearch Id="FindPostgreSQLx64" 
                         Root="HKLM" 
 
 Key="SOFTWARE\PostgreSQL\Installations\$(var.POSTGRESQLX64)" 
                         Value="Version" 
                         Variable="PostgreSQLx64" 
                         Win64="yes"/>

and a DetectCondition in the ExePackage 

DetectCondition="(PostgreSQLx64= v$(var.POSTGRESQLFULLVERSION))" 

with <?define POSTGRESQLFULLVERSION="9.3.6.1" ?> 

This has worked fine so far, but with version 9.4.4.3 PostgreSQL has changed the format of the Version value in the registry to semantic versioning like 9.4.4-3. 

With a new define 

  <?define POSTGRESQLSEMANTICVERSION="9.4.4-3" ?> 

the DetectCondition 

DetectCondition="(PostgreSQLx64= v$(var.POSTGRESQLSEMANTICVERSION))" 

will cause the error 

Error 0x8007000d: Failed to parse condition '(PostgreSQLx64= v9.4.4-3)' at 

position: 22 

So I thought the v before the $ will handle the compare as a Version compare but when I remove it I will get the error ... 
Setting string variable 'PostgreSQLx64' to value '9.4.4-3' 
... 
Error 0x8007000d: Failed to parse condition "(PostgreSQLx64= 9.4.4-3)". 
Unexpected character at position 17. 


How do I have to change my detect condition to get it working? 

Many thanks,
  Thomas

____________________________________________________________________
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