Random Musings

June 18, 2009

ILMerge : A tool to merge your multiple assemblies into one assembly

Filed under: Dynamics CRM — haditeo @ 11:48 pm
Tags:

This ILMerge has rescued me once more.

I was developing a Dynamics CRM Custom Workflow activity. As usual, the assembly needs to be signed correctly and there is one problem though. Only one assembly can be registered using the Plugin Registration Tool.

Currently i like to have a minimum 4 assemblies in my custom solution. Here are they :
1) Domain
2) Repository
3) Utilities or Helper
4) Either web, workflow or plugin dll anything
5) Usually i have a test library to be tested using NUnit

The ILMerge has a GUI tool to automate the merging of all your assemblies, but you can still use the command line. Anyway the GUI tool will execute the ILMerge command line to merge your assemblies

Here is the sample of using ILMerge

ILMerge /t:library /out:CustomLibrary.dll DomainLibrary.dll RepositoryLibrary.dll Utilities.dll Workflow.dll

/t option means we are emitting a dll library. We can also emit an executable file
/out option means we are specifying CustomLibrary.dll as the name of the one dll to be produced by the ILMerge
All the libraries that we would like to be merged should be specified individually with the space between them

Advertisements

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Blog at WordPress.com.

%d bloggers like this: