Problem solve Get help with specific problems with your technologies, process and projects.

How do I deploy a class library to the global assembly cache?

What's the best way to properly deploy a class library to the global assembly cache and reference in other applications?
The handy command line utility, GACUTIL.EXE takes care of adding and removing .NET libraries from the Global Assembly Cache (GAC). You'll have to ensure the .NET Framework library directories are in your path to use it, which you can do by executing VSVARS.BAT in the VS.NET Install Dir>COMMON7TOOLS directory from inside shell window.

Before you go off hither and yon adding library files to the GAC, you need to make sure you really need it there. Just because you think a library is special doesn't mean that it will be used by any other applications. If only one application or family of applications is going to use a library, there's no need to put it in the GAC; use a private shared directory instead. Only put libraries in the GAC that are truly global.

Dig Deeper on .NET tutorials, guides and quizzes

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.