Follow up - I implemented a custom action that uses gacUtil.exe to
uninstall the old assemblies and scheduled it just after CostFinalize in
the InstallExecuteSequence.

-----Original Message-----
From: Gregory Swanson [mailto:gswan...@athoc.com] 
Sent: Thursday, October 13, 2011 3:50 PM
To: wix-users@lists.sourceforge.net
Subject: [WiX-users] Replacing .Net v.3 Assemblies with .Net v.4
Assembliesduring Major Upgrade

Hello:

 

I have an MSI developed with WIX, which packages (among other things) a
few .Net DLLs.  Recently, these .Net v.3 DLLs have been updated to .Net
v.4.

 

I noticed that after running an upgrade, the .Net v.3 Assemblies remain
in the .Net 2 GAC (I noticed this after upgrades on Windows Server 2003
R2 and Windows Server 2008 R2).  What I don't understand is: since I am
installing .Net v.4 Assemblies, should the .Net 3 Assemblies be removed
by the MSI or not?  The .Net v.4 Assemblies are installed in the .Net 4
GAC and the application seems to work fine, but I would like to remove
the old v.3 Assemblies during upgrade.

While investigating how to do this, I found a reference to Bob Arnson's
blog ( http://www.joyofsetup.com/2008/12/30/paying-for-upgrades/ ) and
followed his advice by setting RemoveExistingProducts to execute Before
InstallInitialize.  It was set to After InstallFinalize previously.
Checking the verbose log, I do see that RemoveExistingProducts now
executes just before InstallInitialize, but the v.3 Assemblies were not
removed.  The DLLs are authored one per component.

 

So I thought that maybe the scheduling of RemoveExistingProducts is not
the reason, maybe something else like file versioning (we have a build
engineer who manages that, and since the builds are automated I don't
usually notice a problem right away).  I checked the file versions, and
one .Net v.3 DLL has a File Version of 2.3.0.0, while the .Net v.4 copy
has a File Version of 2.10.0.0.  The Assembly version is the same for
both DLLs.  I think this is the correct versioning to prevent a
side-by-side deployment when the DLLs are created with the same, or even
with different versions of .Net.

 

I'm pretty sure I could remove the .Net v.3 Assemblies with a simple
Custom Action, but I don't want to do that if there is a better
approach.

 

Thanks in advance for any help.

Greg

------------------------------------------------------------------------
------
All the data continuously generated in your IT infrastructure contains a
definitive record of customers, application performance, security
threats, fraudulent activity and more. Splunk takes this data and makes
sense of it. Business sense. IT sense. Common sense.
http://p.sf.net/sfu/splunk-d2d-oct
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure contains a
definitive record of customers, application performance, security
threats, fraudulent activity and more. Splunk takes this data and makes
sense of it. Business sense. IT sense. Common sense.
http://p.sf.net/sfu/splunk-d2d-oct
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to