I\'ve got a windows service compiled as AnyCPU. I\'m trying to get it into our installer to distribute. However... I am unclear on the difference between the 32 bit and
According to this, you are supposed to use the 64 bit version to install 64-bit and MSIL assemblies, but it doesn't say why.
Starting with the .NET Framework version 2.0, the 32-bit version of the common language runtime (CLR) ships with only the 32-bit version of the Installer tool, but the 64-bit version of the CLR ships with both 32-bit and 64-bit versions of the Installer tool. When using the 64-bit CLR, use the 32-bit Installer tool to install 32-bit assemblies, and the 64-bit Installer tool to install 64-bit and Microsoft intermediate language (MSIL) assemblies. Both versions of the Installer tool behave the same.
I believe here explains why. If you look at the bottom of the post, it explains some differences between the two and when to use the 32-bit intallutil.
Installutil.exe is built for a specific platform, therefore it will start as a 32 or 64-bit process and the related registry hive will be updated. Note that if you have a snap-in built with the platform switch, you will only be able to register it in one of the hives (32-bit or 64-bit).
If you're installing a 64-bit only assembly, the 32-bit InstallUtil won't be able to load it. You'll need to use the 64-bit version.
I ran across this as well. The issue was my VS2008 project was set to Platform Target: Any CPU. No matter which InstallUtil.exe (32 or 64) I ran on the 64 bit OS it was installing as 64 bit.
I changed my project setting Target to x86 and then ran the 32 bit installutil.exe and everything works fine. It now shows the *32 flag in Task Manager.