zura
Posts: 14
Joined: Tue Aug 19, 2014 10:19 pm

Two installers with shared functionality

Hello,

I'm trying to build installers for two products that have big common part but are different enough so that I do need two installers.
The two products are kind of 'server' and 'client', installed on windows server and desktop versions, deploying different binaries, but have similar setup of installing a local data storage service(s), checking available ports for communication etc. So from the point of view of the installer, I'd say they have 70-80 percent common logic.

Is there a way to organize the AI project creation process so that there is a single shared part where I develop the common logic and then two, product-specific parts will implement the UI, pre-requisites, parameters etc? or at least a robust way to copy-paste parts of the xml sections from one project to another?

Any advice would be much appreciated!
Thanks,
Zura
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Two installers with shared functionality

Hi Zura,

In order to achieve this, you can go to the "Builds" page, create two builds then configure them as you need.

For more details you can take a look on the "Multiple Builds Configuration" article, "Branding of the installer" thread and watch the "Multiple Builds Configuration" video.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
zura
Posts: 14
Joined: Tue Aug 19, 2014 10:19 pm

Re: Two installers with shared functionality

Hi Eusebiu,

Thanks a lot for the tip, I had looked at that approach but somehow was thinking that it's not how builds feature was intended to be used...although what matters the most, it works!

I have a related issue now, I have a custom action that uses executable that can come from two different locations, i.e. I have a structure:
appfolder
folder_1 \ file.exe
folder_2 \ file.exe

This two folders have option 'install content to the parent folder' depending on the build (can be 32 and 64 bit executable)
Then I want to run a custom action 'launch installed file', but the executable path must be appfolder\file.exe, which I'm unable to do since at the moment of designing, I don't have any file.exe in the appfolder.

Do you think I'm doing something wrong?
Thanks,
zura
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Two installers with shared functionality

Hi Zura,

To achieve this, you can use the "Launch file" custom action and write the "[APPDIR]file.exe" path in the "File to launch" field.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
zura
Posts: 14
Joined: Tue Aug 19, 2014 10:19 pm

Re: Two installers with shared functionality

Once again, thanks Eusebiu for your help!

I seem to hit yet another problem now, I call an executable with command line parameters. These params may contain spaces (paths etc) so I use certain combination of quotes. I take the command line that worked with 'launch installed file' and put in 'launch file' and it fails. Is there any difference how these two custom actions parse parameters and pass them to the executable files?

Best,
Zura
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Two installers with shared functionality

Hi Zura,

There should be no difference between the ways these two custom actions works with command line parameters and I'm not sure why you encounter this problem.

Can you please send me the .AIP (project file) and a verbose log of the installation to support at advancedinstaller dot com, so I can investigate them?

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”