MGS
Posts: 128
Joined: Tue Oct 04, 2022 9:52 am

Best practice - installer for multiple products

Hi there,

We have the need to create installers for multiple products. These products have a lot of common files, but also their own additional files. Our build system puts all the files needed for a particular product in the build folder, and then the .aip build command is run. Each of the products is supposed to be installed in its own directory. So, in effect, the products do not share files on disk, otherwise we would not be able to use different versions of files per product. When a product is updated, only the files that belong to that product should be touched. Each product should have its own product name and product version.

What is the common practice/how would you tackle this?

My take on this would be:
1) To make it easier maintainable, packing everything into a single .aip file. They should share e.g. all the custom actions anyways. Otherwise, we would need an .aip file per product and thus maintain all the dialogs and custom actions that they share which would add a lot of overhead to maintain all our products.
2) Put all the shared files in a shared Feature.
3) To differentiate between the products, add a feature per product and assign all the files that are product-specific to this feature.
4) Add a build config per product which decides which features are added to the installer when it is built. This way our executable per product just contains the needed files. Furthermore, a command line argument OR the build config (whatever is possible) should also decide which product name and version is used. On our build system we provide the build config as command line parameter. For the sake of completeness, I asked if it's even possible to change the product details via command line here: viewtopic.php?f=2&t=51272

I don't know if that is a good way to tackle this or if another solution makes more sense.

All the best,
Johannes
Catalin
Posts: 7269
Joined: Wed Jun 13, 2018 7:49 am

Re: Best practice - installer for multiple products

Hello Johannes,

One of the best ways to achieve what you want would be through the "Save as Template" option.

You can then use the template to create a new project.

Please note that these two projects are completely different from one another - the GUIDS of the components will be changed so we do not face issues during uninstall.

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
MGS
Posts: 128
Joined: Tue Oct 04, 2022 9:52 am

Re: Best practice - installer for multiple products

Hi Catalin,

Thanks for the reply here. We decided against the Save As Template due to the reasoning in 1) from my previous post. It is just not a feasible option if most of the UI dialogs that are used from the different installers are basically the same and thus "shared" between the products. We don't want to manually keep the UI from e.g. 10 different projects in-sync. Making a change in dialog A, which is used in installer X, Y, and Z would require me then to adapt dialog A in three different projects. Having 10 installers will increase the workload 10-fold. This is simply not feasible. I went with the aforementioned solution instead and although it is probably not intended this way, it requires a lot less work to keep the UI of every installer up-to-date.

Best regards,
Johannes
Catalin
Posts: 7269
Joined: Wed Jun 13, 2018 7:49 am

Re: Best practice - installer for multiple products

Hello,

You're always welcome!

Thank you for your followup here and for sharing your solution with us.

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”