How to determine which application has a given assembly registered in the GAC?

When you try to remove this assembly (log4net.dll in this case, but it should apply to any such case) using gacutil.exe, the action is not performed due to the need to build the application. However, I cannot figure out how to determine which applications really require this. Since the output seems to indicate that the request is being registered in the MSI database / Windows installer, it seems that some utilities can either list all the GAC assemblies registered in the MSI database (and I could just search for entries with log4net.dll ) or let me specify a specific GAC'd assembly and it will list the dependencies (ideally, with any related dependency chains, if they exist :)

C:\ ยป gacutil /u log4net Microsoft (R) .NET Global Assembly Cache Utility. Version 4.0.30319.1 Copyright (c) Microsoft Corporation. All rights reserved. Assembly: log4net, Version=1.2.10.0, Culture=neutral, PublicKeyToken=1b44e1d426115821, processorArchitecture=MSIL Unable to uninstall: assembly is required by one or more applications Pending references: SCHEME: <WINDOWS_INSTALLER> ID: <MSI> DESCRIPTION : <Windows Installer> Number of assemblies uninstalled = 0 Number of failures = 0 

Thanks!

+4
source share
1 answer

I have never found anything good for this. What I was doing (which worked, but sucks) was to run procmon to find out what gacutil was talking to, and noticed that it got into the key HKCR \ Installer \ Products \ 098D637EEF1AFF14586E779FE4C38C4D. When I looked under this key in regedit, it showed that the product was "Plantronics Spokes Software".

I went into appwiz.cpl and uninstalled this application, after which gacutil / l log4net showed that log4net was no longer in the GAC.

I would still like to find a better answer, but I think that now "run procmon, filter to process = gacutil.exe and the path under HKCR \ Installer \ Products" is at least better than nothing.

+3
source

All Articles