alexk
Posts: 13
Joined: Sat Jan 07, 2012 4:39 pm

How to make Mixed 64/32 Bit Installer

Hi,

when i set the package type to "Mixed 64/32 matching the Platform" i cannot build to plain .msi target. It forces me to
build to an exe setup without CAB inside.
This is a problem since we must deploy installations trough an windows-update server, that can handle only *.msi
packages.

I need this mixed mode installer, because we have to deploy to Windows-XP and Windows 7 using the same installer. As a workaround
i build to normal 32-bit package and use the "VersionNT64" conditional to decide which binarys go to APPDIR. This works, but
APPDIR resolves to "Program Files (x86)" under Windows 7 (because of the 32-bit installer), which violates things in certain circumstances.

is there a better way around this?

sincerely, alex
Daniel
Posts: 8276
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: How to make Mixed 64/32 Bit Installer

Hi,

If you want to use the msi files from a "Mixed 64/32 matching the Platform" package application, then you should enable "Build separated install databases" and "Do not make any changes to package organization" options from the Mixed 32/64 Package Organization Wizard. After you build your project you can extract the msi files from the EXE by using the /extract command and distribute them.

If you have any questions let me know.

Regards,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
alexk
Posts: 13
Joined: Sat Jan 07, 2012 4:39 pm

Re: How to make Mixed 64/32 Bit Installer

Hi Daniel,

thank you for helping. I tried this already but it gives me two msi´s one for 32 and one for 64-bit. The problem is, i need
one msi that contains both and decides during install on the target machine, which platform to use. The build creates 4 files:

- xxx.exe
- xxx.msi
- xxx.x64.msi
- xxx.cab

This is just not possible in the windows-install system, right? Because i cannot start the xxx.x64.msi on a 32-bit machine
i guess the platform signature of an msi has to be unique...

PS: how does exactly the /extract command work? Is this an Advanced Installer Tool? I tried "xxx.exe /extract" with no effect.

regards,
Alex
alexk
Posts: 13
Joined: Sat Jan 07, 2012 4:39 pm

Re: How to make Mixed 64/32 Bit Installer

Hi again,

i just tried to install the x64.msi on a Win 7 machine. There seems to be another problem. It will install to "Program Files (x86)"
an not to "Program Files" as expected. Schould [ProgramFilesFolder] not resolve to "Program Files" on Win 7? Or can i do something wrong here?

regards, alex
Bogdan
Posts: 2794
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: How to make Mixed 64/32 Bit Installer

Hi Alex,
This is just not possible in the windows-install system, right? Because i cannot start the xxx.x64.msi on a 32-bit machine
i guess the platform signature of an msi has to be unique...
The EXE file built by Advanced Installer is a 32 bit one, this contains the x86 and x64 MSI files as well as the files to be installed from the CAB. When launched the EXE checks for the OS architecture and it launches the correct MSI, thus x64 MSI will never be launched on a x86 machine.
PS: how does exactly the /extract command work? Is this an Advanced Installer Tool?
Yes, this is a command line available for all EXE packages created by Advanced Installer.
i just tried to install the x64.msi on a Win 7 machine. There seems to be another problem. It will install to "Program Files (x86)"
an not to "Program Files" as expected. Schould [ProgramFilesFolder] not resolve to "Program Files" on Win 7? Or can i do something wrong here?
Please note that the default path used by Advanced Installer is "[AI_ProgramFiles][Manufacturer]\[ProductName]", not "[ProgramFilesFolder][Manufacturer]\[ProductName]". Maybe you changed this accidentally, can you please check this in your project?

AI_ProgramFiles property is resolved by us depending on the OS architecture also, so it should always point to the correct "Program Files" folder.

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
alexk
Posts: 13
Joined: Sat Jan 07, 2012 4:39 pm

Re: How to make Mixed 64/32 Bit Installer

Much thanks..

i was not aware of "AI_ProgramFiles" that works just fine!
i now can sucessfully build x86 and x64 packages.

regarding my initial question, i still search for a way to have only one msi for both platforms.
the "AI_ProgramFiles" is not avaiable under the "32-bit package" type right (i get an empty string there)?
If there where something that could resolve to the correct "Program Files" folder, i could build to that target
only and use one package for x64 too..

regards,
alex
Bogdan
Posts: 2794
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: How to make Mixed 64/32 Bit Installer

Hi Alex,
the "AI_ProgramFiles" is not avaiable under the "32-bit package" type right (i get an empty string there)?
Yes, this is correct. The property is set by us only for mixed packages, based on the OS architecture.

You could try the following solution, but its not a very clean one. Here is what I was thinking:
-- create a mixed EXE setup file using Advanced Installer, as you already did
-- now create a new project in Advanced Installer, project template "MSI from EXE", available under "Import" area of our new project page.

This will require for you to maintain two aip files for actually creating a single MSI package.

The MSI package created by the second project is actually a 32 bit wrapper, so it works on x86 and x64, over the mixed EXE, which will actually handled the resource installation, thus always installing into the correct "Program Files" folder.

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
alexk
Posts: 13
Joined: Sat Jan 07, 2012 4:39 pm

Re: How to make Mixed 64/32 Bit Installer

Hi Bogdan,

thats it!

always a pragmatic solution for our daily problems at hand.... :-)

thank you very much, keep it on!
Alex
mdaly
Posts: 3
Joined: Fri Nov 02, 2012 7:04 pm

Re: How to make Mixed 64/32 Bit Installer

Bogdan wrote:Hi Alex,
This is just not possible in the windows-install system, right? Because i cannot start the xxx.x64.msi on a 32-bit machine
i guess the platform signature of an msi has to be unique...
The EXE file built by Advanced Installer is a 32 bit one, this contains the x86 and x64 MSI files as well as the files to be installed from the CAB. When launched the EXE checks for the OS architecture and it launches the correct MSI, thus x64 MSI will never be launched on a x86 machine.
The EXE file built by Advanced Installer is a 32 bit one, this contains the x86 and x64 MSI files as well as the files to be installed from the CAB. When launched the EXE checks for the OS architecture and it launches the correct MSI, thus x64 MSI will never be launched on a x86 machine.

Why would you need to use the "extract" option if the setup directory contains the 2 .MSI files and the .CAB file. I need to have one file only. Did I create the "mixed package" incorrectly? I was expecting one .exe file that installed on both 32 and 64 bit machines. Is it possible to have one .exe file that contains both .MSI and .CAB file?
PS: how does exactly the /extract command work? Is this an Advanced Installer Tool?
Yes, this is a command line available for all EXE packages created by Advanced Installer.
i just tried to install the x64.msi on a Win 7 machine. There seems to be another problem. It will install to "Program Files (x86)"
an not to "Program Files" as expected. Schould [ProgramFilesFolder] not resolve to "Program Files" on Win 7? Or can i do something wrong here?
Please note that the default path used by Advanced Installer is "[AI_ProgramFiles][Manufacturer]\[ProductName]", not "[ProgramFilesFolder][Manufacturer]\[ProductName]". Maybe you changed this accidentally, can you please check this in your project?

AI_ProgramFiles property is resolved by us depending on the OS architecture also, so it should always point to the correct "Program Files" folder.

Regards,
Bogdan
mdaly
Posts: 3
Joined: Fri Nov 02, 2012 7:04 pm

Re: How to make Mixed 64/32 Bit Installer

Hi,

I created a mixed project and in the setup directory there are 2 .MSI files, 1 .CAB and an .EXE file. I was hoping that I would have one file to send out for installation. Did I create the install package incorrectly? Is there a way to use the Professional version to create one install file for both 32 and 64 bit systems?

Thank you,

mdaly
mihai.petcu
Posts: 3860
Joined: Thu Aug 05, 2010 8:01 am

Re: How to make Mixed 64/32 Bit Installer

Hello,

To have a single package you can set "Single EXE setup (resources inside)" option from the Media page -> Configuration tab.

All the best,
Mihai
Mihai Petcu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
mdaly
Posts: 3
Joined: Fri Nov 02, 2012 7:04 pm

Re: How to make Mixed 64/32 Bit Installer

Thank You! This worked, but now I'm receiving DEP errors; where I never had an issue with just AMD 64 or 32 test projects. Any suggestions?

mdaly
mihai.petcu
Posts: 3860
Joined: Thu Aug 05, 2010 8:01 am

Re: How to make Mixed 64/32 Bit Installer

What kind of DEP errors, can you give us some examples?

All the best,
Mihai
Mihai Petcu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”