August 2003
Intermediate to advanced
928 pages
32h 1m
English
GacUtil.exe — Global Assembly Cache Utility
gacutilcommand[options]
Allows you to install, uninstall, and list the contents of the Global Assembly Cache (GAC).
Create a module, generate a key-pair, build a signed manifest assembly containing the module, and install the assembly in the GAC:
C:\home>csc /t:module Example.csMicrosoft (R) Visual C# .NET Compiler version 7.10.3052.4 for Microsoft (R) .NET Framework version 1.1.4322 Copyright (C) Microsoft Corporation 2001-2002. All rights reserved. C:\home>sn -k example.keyMicrosoft (R) .NET Framework Strong Name Utility Version 1.1.4322.573 Copyright (C) Microsoft Corporation 1998-2002. All rights reserved. Key pair written to example.key C:\home>al /keyfile:example.key /out:Example.dll Example.netmoduleMicrosoft (R) Assembly Linker version 7.10.3077 for Microsoft (R) .NET Framework version 1.1.4322 Copyright (C) Microsoft Corporation 2001-2002. All rights reserved. C:\home>gacutil /i Example.dllMicrosoft (R) .NET Global Assembly Cache Utility. Version 1.1.4322.573 Copyright (C) Microsoft Corporation 1998-2002. All rights reserved. Assembly successfully added to the cache
Delete all assemblies named Example from the GAC:
C:\home>gacutil /u Example Microsoft (R) .NET Global Assembly Cache Utility. Version 1.1.4322.573 Copyright (C) Microsoft Corporation 1998-2002. All rights reserved. Assembly: Example, Version=2.0.0.0, Culture=neutral, PublicKeyToken=9a587aa1499c251f, Custom=null Uninstalled: Example, ...