Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Include 3rd party dll in the Sharepoint project while packaging the wsp

In one of my projects I am using a 3rd party dll which is from Codeplex. While I was developing my code in my development box I had used gacutil command to get it added into GAC.

Now, I need to send the wsp for the project to teh Test Team for deployment on our Test box and they do not take individual dll.

How can I package the third party dll along with the wsp that I am sending so that it gets deployed into GAC and is used by the code.

Please let me know.

like image 358
Janet Avatar asked Sep 22 '11 21:09

Janet


People also ask

How do I create a WSP package in SharePoint?

Under System settings click Manage Farm solutions. Click on the solution “registration. wsp” and click Deploy solution, then click OK. Now the solution has been deployed successfully.

How do I deploy a WSP file in SharePoint online?

On the solutions page, Click on the “upload solution” button from the ribbon. Browse and select the WSP file from your local disk and Upload the solution. After clicking on the “OK” button, SharePoint Uploads the WSP file and presents you a page from which you can activate the solution, as shown below.

What is WSP mean in SharePoint?

Next, you can create a SharePoint solution package (. wsp) to bundle multiple features, site definitions, assemblies, and other files into a single package, which stores the files in a format needed by SharePoint to deploy the files to the server.


1 Answers

why are you locally using gacutil.exe?

To include external assemblies in your SharePoint project, for example lets take the Ninject.dll, you just add the assembly as reference to your project as you would do in any other CLR project.

To ensure that the Ninject.dll is included in your WSP you have to open the Package Configuration - just open the "Package" node in your SharePoint project and dbl. click the given entry. Scroll down to the end of the screen and open the advanced mode. There you can add an assembly for deployment. Just simply use the "Add Assembly -> Add Assembly from Project Output" Action and select Ninject.dll.

When packaging the next time your custom assembly will be included in your WSP.

Cheers

like image 151
Thorsten Hans Avatar answered Nov 15 '22 20:11

Thorsten Hans