WiX differences on 64-bit? - wix

What are all the things we should take care of while writing a WiX installer for 64-bit software?
What if I want to support both 32- and 64-bit versions?
I want to release one version of the installer, that will be possible to install softwares for both platforms, according to the host OS.

Separate MSIs for separate architectures:
http://blogs.msdn.com/b/heaths/archive/2008/01/15/different-packages-are-required-for-different-processor-architectures.aspx
and people use a WiX bundle to choose which depending on the system.
You can have a common source file for both MSIs, this kind of thing:
http://blogs.msdn.com/b/astebner/archive/2007/08/09/4317654.aspx
http://alekdavis.blogspot.com/2011/05/build-32-and-64-bit-installers-using.html

Related

MSI : Upgrading 32-Bit application to 64-Bit

Our company uses WIX for its installers, and we are now upgrading our application from 32-Bit to 64-Bit. For every new version, we always provide an upgrade path from the previous ones.
TODO list :
Binaries should now reside in the "C:\Program Files" folder instead of "C:\Program Files (x86)".
Registry entries should now reside in HKEY_LOCAL_MACHINE\SOFTWARE\%COMPANY% instead of HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\%COMPANY%
Log files, configuration files, and any custom files/registry entries needs to be moved over to their new 64-Bit locations.
Considered the special aspect of this upgrade, we are inquiring the community regarding its know-how.
Presumably you'll continue to have a 32bit MSI for 32bit customers. So I'd approach this was another MSI and reuse as many fragments as possible. Your directory table and ComponentIDs will be different and I'd also give it a different UpgradeCode GUID. In your MajorUpgrade I'd search for products having the 32bit UpgradeCode and the 62bit UpgradeCode and remove both when found.
I'd also make sure that you need to even do this. For example if I deploy a .NET app with no native dependencies ( say IIS, Winforms, WPF, Windows Service ) it'll JIT up 64bit no problem when possible even though I installed it using a 32bit MSI to 64bit locations. No harm no foul.

In install4j, can you include both 32 and 64 bit version of an application in one install package and let the user decide which to install?

In install4j, can you include both 32 and 64 bit versions of an application in one install package and let the user decide which to install if the OS is 64-bit? Would the easiest/best solution be to create three projects? i.e. one parent/two children? I'm hesitant to do this because the majority of the included files are not architecture-specific and I'd like to keep everything in one project.
I'm also not tied to install4j if another installer can accomplish this, especially WiX, which is used by other groups in our company.
Currently install4j cannot create a single media file for 32-bit and 64-bit. Since the 32-bit media file works on 64-bit Windows as well, this is usually not a big problem. Common 32-bit/64-bit media files may be implemented for install4j 6.
In any case, you do not need separate projects for 32-bit and 64-bit installers. You just add two media files in the "Media" step of the install4j IDE, one for the 32-bit installer and another one for the 64-bit installer, with different settings on the "32-bit or 64-bit" step of the media wizard.
As for platform specific files, just add two file sets and exclude them as appropriate in the "Customize project defaults->Exclude files" step of the media wizard.

Including 32- and 64-bit merge modules in one WiX installer

I'm writing merge modules for a project I'm working on.
I build two merge modules, one for 32-bit and one for 64-bit. I want to include them in a WiX installer but it tells me I can't:
error LGHT0345: 'installer\bin\x64\Release\en-us\myproject.msm' is a 64-bit merge module but the product consuming it is 32-bit. 32-bit products can consume only 32-bit merge modules.
Is there a way to make a dual CPU project so I can include both?
WiX version is 3.6.
Windows Installer doesn't support multi-platform packages. If you need to write to the 64-bit portion of the file system or registry, you need a 64-bit package.

Disable registry redirection in WiX

I'm using WiX to deploy my application. This application uses a registry key which is shared between x64 and x86 processes. Thus it must not use the Wow64Node. The application uses the KEY_WOW64_64KEY flag to achieve this.
But how can this be done using an MSI build with WiX? Currently I use an x86 and an x64 version of the installer, but that gives me a large overhead. Is it possible to disable registry redirection in WiX? I found the DisableRegistryReflection attribute, but that does not seem to have influence on redirection. Another idea would be to merge the two installers into a single file, like it is possible with languages. But I have in mind that that's not supported.
This could be done with an unified 32/64-bit package, but WiX doesn't support it. Some commercial setup authoring tools support it.
When using separate packages, 32-bit installers will use the 32-bit location on 64-bit systems. So to avoid registry redirection you should distribute a 32-bit package for 32-bit systems and a 64-bit package for 64-bit systems.
In 64-bit installers the registry entry component needs to be marked as 64-bit. In WiX you can do this by setting Win64 to "yes" for your registry components.

Wix 3 driver package installation problem

I am trying to create a .msi database using Wix to install a driver package.
Now this driver package is made to run on all platforms and can be installed on any platform (any version of windows, 2k and later, x86 or x64) by right clicking on the .inf file and selecting the "Install" option. Because the package doesn't need multiple versions for different platforms out there, I want to create a single msi file for all platforms.
All went fine until I hit this bottleneck: I am suppose to link with either dfxapp_x86.wixlib or dfxapp_x64.wixlib depending on the platform I wish to install on. This will lead to having two different installers, one for each platform, which I don't want. Including both library files won't work, since they link with dlls that contain the same symbols.
What can I do to have a single installation package for all platforms in this case?
Thanks.
Neither MSI nor DIfxApp support a single package for multiple platforms. You need one per platform.