[wix-users] "Product configuration" - possible with WiX?

Edwin Castro egcastr at gmail.com
Mon Jun 18 07:18:01 PDT 2018


I currently have a codebase that does this.

I define a default BuildMode property in my wixproj and pass it in with
DefineConstants. Then in my wix source I use <?if $(var.BuildMode) =
"..."?> to select different defines and/or sections of code that only apply
for that BuildMode. For example, I set defines for all attributes for the
Product elements depending on the BuildMode and in my Product.wxs I set
<Product Id="*" Name="$(var.ProductName) Version="$(var.ProductVersion)
.../> and so on.

I have found that this approach is a little hard to maintain. It is hard to
keep track which bits are supposed to be in and what their values actually
are.

I've been considering changing my codebase to use wixlibs instead where I
define all components and other resources uniquely in one or more wixlibs
and then have one .wixproj and Product.wxs per physical MSI I need. Then
each Product can simply reference the components and other bits it needs.

--
Edwin G. Castro


On Mon, Jun 18, 2018, 06:42 Douglas, Keith (STATCAN) via wix-users <
wix-users at lists.wixtoolset.org> wrote:

> You can perhaps use the preprocessor to do some of that.
>
>
> Keith Douglas
>
> Programmer Analyst, Information Technology Operations Divison
> Statistics Canada / Government of Canada
> keith.douglas at canada.ca / 613-854-5589
>
> Programmeur Analyste, Division des opérations des technologies de
> l'information
> Statistiques Canada / Gouvernement du Canada
> keith.douglas at canada.ca / 613-854-5589
>
> -----Original Message-----
> From: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] On Behalf
> Of Reuss, Matthias via wix-users
> Sent: June-18-18 8:59 AM
> To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>
> Cc: Reuss, Matthias <matthias.mr.reuss at sivantos.com>
> Subject: [wix-users] "Product configuration" - possible with WiX?
>
> Hello,
>
> does WiX support something like a "product configuration"?
>
>
> Here I do not mean Debug/Release configurations, but configurations that
>
>
>   *   Include/exclude some features
>   *   Have a different product name, product version, product GUID
>
> Do I need some separate "main" wxs file with a separate <product> tag to
> accomplish that, or is there some other way?
>
> Best regards
>
> Matthias Reuss
>
> ____________________________________________________________________
> 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