3

I need to add an dll to GAC on Windows 2003 server. The server doesn't have Visual Studio installed. I didnt find Gacutil.exe in Windows 2003 Server. Where can I find Gacutil in Windows 2003 Server. Is there any other way I can add a dll to GAC . Any help will be highly appreciated.

Thanks in Advance,

starblue
  • 55,348
  • 14
  • 97
  • 151
Henry
  • 847
  • 6
  • 24
  • 53
  • It is a Windows SDK tool, not available with .NET. It is the job of a setup program to put assemblies in the GAC, quite easy to do with a Setup and Deployment project. Writing your own gacutil is possible: http://stackoverflow.com/questions/2611108/register-a-dll-into-the-gac-but-then-it-doesnt-show-up-in-the-assembly-window/2611435#2611435 – Hans Passant Aug 02 '11 at 00:10
  • You don't have to have VS installed. Only the .net framework is enough. – wonde Aug 02 '11 at 00:51
  • There is an old gacutil.exe in .net framework 1.1 that is dangerous. – Joshua Aug 03 '11 at 19:04

2 Answers2

2

You cannot call gacutil. There are some fusion APIs you can P/Invoke.

Instructions: http://support.microsoft.com/default.aspx?scid=kb;en-us;317540

Joshua
  • 40,822
  • 8
  • 72
  • 132
2

While you can't (re: shouldn't) use GACUtil.exe, there are 2 other ways, outlined in the following link from msdn:

http://msdn.microsoft.com/en-us/library/dkkx7f79.aspx

What you're looking for is probably Mscorcfg.msc, but is only good for Framework version 3.5 and earlier

http://msdn.microsoft.com/en-us/library/2bc0cxhc.aspx

Tom Studee
  • 10,316
  • 4
  • 38
  • 42