HOW TO: Deploy shared Assy to the GAC.

  • Thread starter Thread starter Jeff Ptak
  • Start date Start date
J

Jeff Ptak

Can anyone explain to me what I need to do to deploy a strong-named assembly
into the GAC? I have an assembly that I can deploy on its own into the GAC
using a Setup project. This works fine for a developer's machine.

However, when a developer makes a reference to the shared assy, it is copied
locally to the new project's output directory. Then when a setup project is
created for the new app, the shared assy ends up as a private assy instead
of being installed into the GAC on the target machine.

I have read in many places on the MSDN site about using the Windows
Installer 2.0 to "automatically" install strong-named assemblies into the
GAC. How do I set that up?

Thanks in advance!
 
Hi Jeff,
However, when a developer makes a reference to the shared assy, it is copied
locally to the new project's output directory. Then when a setup project is
created for the new app, the shared assy ends up as a private assy instead
of being installed into the GAC on the target machine.

I have fixed this by excluding the dependencies corresponding to shared
assemblies and then by adding the shared assemblies as independent project
outputs to the GAC folder in the File view of my Deployment Project.
 
Dmitry,

That worked great! Thanks for the tip!

Jeff


Dmitriy Lapshin said:
Hi Jeff,
However, when a developer makes a reference to the shared assy, it is copied
locally to the new project's output directory. Then when a setup
project
is
created for the new app, the shared assy ends up as a private assy instead
of being installed into the GAC on the target machine.

I have fixed this by excluding the dependencies corresponding to shared
assemblies and then by adding the shared assemblies as independent project
outputs to the GAC folder in the File view of my Deployment Project.

--
Dmitriy Lapshin [C# / .NET MVP]
X-Unity Test Studio
http://www.x-unity.net/teststudio.aspx
Bring the power of unit testing to VS .NET IDE

Jeff Ptak said:
Can anyone explain to me what I need to do to deploy a strong-named assembly
into the GAC? I have an assembly that I can deploy on its own into the GAC
using a Setup project. This works fine for a developer's machine.

However, when a developer makes a reference to the shared assy, it is copied
locally to the new project's output directory. Then when a setup
project
is
created for the new app, the shared assy ends up as a private assy instead
of being installed into the GAC on the target machine.

I have read in many places on the MSDN site about using the Windows
Installer 2.0 to "automatically" install strong-named assemblies into the
GAC. How do I set that up?

Thanks in advance!
 
Back
Top