0

Background:

I'm making a setup for an application with three Configurations/SKUs (Basic, Standard, Enterprise, say) and two platforms (x86, x64). The different configurations use different upgradecodes.

That gives you a matrix of six different configurations. We currently have separate wxs scripts for each configuration, but when a file is added by hand to the setup it's nearly impossible to remember to do correctly in all of them etc. Most of the files are shared (by name, not content) so there is a file SomeNamespace.SomeLibrary.dll in all six setup packages, but all six are potentially different (by platform and sometimes by Configuration as well).

So my first question is: how can I avoid having to keep several large but almost identical setup scripts?

Second issue: component ID's:

If I manage to re-use a lot of the wxs scripts through fragments created by a custom harvester or template, what do I do about Component ID's? Can I use the generated (*) GUIDs for my components, given that no component is shared between products, and I use MajorUpgrade only? The other option for component ID generation would be using heat, or manually making a deterministic hash such as SHA1(relative install path + configuration + platform)`.

Is there a good example somewhere of a large multi-configuration multi-platform WiX project?

Anders Forsgren
  • 10,827
  • 4
  • 40
  • 77

1 Answers1

0

Well, have you learned WHY it's good idea to have seperate component ID's for each file of your setup?

Here are links to understand what is going on:

What is the wix 'KeyPath' attribute?

Wix: one file per component or several files per component?

Wix: Using KeyPath on Components, Directories, Files, Registry, etc, etc

As for your question, I would say that it makes sense to have each file have it's own component identifier(and putting them to seperate products does not change that).

ComponentSearch doesn't even need ProductCode in order to search for specific component - think about what would happen if you have two Products installed and they both have same GUIDS for some Component - it's going to explode.

Community
  • 1
  • 1
Erti-Chris Eelmaa
  • 25,338
  • 6
  • 61
  • 78
  • OK, so if I understand you correctly, you suggest that for both platforms and SKU's the same file(name) should have a different ID? The reason I'm asking is because I'd like to increase re-use using includes of the common files which are 100% equal (in name) between different platform and 90% equal (in name) between SKU's, even though their binary content is different. Will I need NxM .wxs files for N platforms and M sku's? The issue is of course that even with only 2 differnt SKU wxs-files we forget adding a common file to both. Is wxi includes then usually a bad idea for re-use across SKU's? – Anders Forsgren Nov 08 '13 at 12:33
  • I am afraid that the information you've provided is not enough for me. If you would be updating your post a little more, then I would be able to provide more info. For ex; how are your wxs files currently set up, and which parts do you want to reuse, and SKU definition. – Erti-Chris Eelmaa Nov 11 '13 at 19:26