views:

314

answers:

6

is there a best way to deploy to the GAC?

is dragging the dll to the GAC sufficient?

+1  A: 

Use gacutil.

Matthew Flaschen
+3  A: 

Read How to install an assembly into the Global Assembly Cache in Visual C#.
Your assembly needs a strong name, but basically dragging the DLL to the GAC is sufficient.

A: 

I highly recommend you to use GacBrowser (open-source). This gives very good control over your GAC.

Gacutil is NOT for deployment. This is a developertool and has been moved to the SDK. Dragging and dropping could produce unexpected results.

Ropstah
What "unexpected results"? I'm intrigued.
Kev
Well, libraries not being installed for example :)
Ropstah
+3  A: 

The way to deploy to the GAC is to use a Setup project.

Steven Sudit
A: 

Hi,

I suggest using GACUtil, which ships with the .Net Framework.
Although as weiqure has already mentioned, dragging and dropping to the Assembly folder is adequate.

SharePoint Newbie
A: 

Hi raklos

The best deploynet tool is WiX

The standard setup and deployment projects in VS have difficulties installing assemblies in the GAC when they have mutual dependencies. A solution to that is WiX. In the WiX source XML you just specify the assemblies you want to install. The drawback of specifying every file is that, if the files to be installed vary a lot, You have to update the XML code frequently. Therefore you should not use WiX projects for deploying web applications.

More about WiX: http://www.wixwiki.com/index.php?title=Main_Page

Muse VSExtensions