Questions tagged [ilmerge]

ILMerge is a utility for merging multiple .NET assemblies into a single .NET assembly. It works on executables and dlls alike. It comes with several options for controlling the processing and format of the output.

353 questions
7
votes
3 answers

Merging assemblies and using internal keyword

Does merging assemblies change the scope of the internal keyword? I'm fairly certain that it wouldn't have an effect (or at least one that would matter) since anyone referencing the final assembly wouldn't be able to access internal classes…
Dustin Davis
  • 14,482
  • 13
  • 63
  • 119
7
votes
2 answers

Merging DLL's and changing managing namespaces

I want to create a single dll that is merged with a 3rd party dll. This means end consumers will only have to deal with 1 dll instead of 2. For augments sake lets say that the 3rd party dll is nLog. How do I deal with cases where the consumer of the…
vdh_ant
  • 12,720
  • 13
  • 66
  • 86
7
votes
2 answers

Failed to use use "MSBuild.ILMerge.Task" with PackageReference

When using MSBuild.ILMerge.Task referenced via packagereference the following error came up: error MSB4018: The "MSBuild.ILMerge.Task" task failed unexpectedly. error MSB4018: System.IO.FileNotFoundException: Cannot find ILMerge executable. error…
Demian
  • 81
  • 1
  • 3
7
votes
1 answer

Performance of .NET ILMerged assemblies

I have two .NET libraries: "Foo.Bar" and "Foo.Baz". "Foo.Bar" is self-contained, while "Foo.Baz" references "Foo.Bar". Assuming I do the following: Use ILMerge to merge "Foo.Bar.dll" with "Foo.Baz.dll" into "Foo1.dll". Create a new solution…
Matthew King
  • 5,114
  • 4
  • 36
  • 50
7
votes
2 answers

How to merge XML documentation files with the DLL using ILMerge?

I know I can merge PDB with a DLL file but I'm trying to do the same with an XML documentation file. It should be possible since you don't have .xml files with .NET assemblies and yet you have documentation in the IDE. How to do this?
Stécy
  • 11,951
  • 16
  • 64
  • 89
7
votes
3 answers

Nant build using .NET 4.5 (Beta) assembly references despite specifying "net-4.0"

After installing .Net 4.5 Beta, the output of my Nant build fails with: "could not load type 'System.Runtime.CompilerServices.ExtensionAttribute' from assembly 'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'." because…
DanO
  • 2,526
  • 2
  • 32
  • 38
6
votes
2 answers

ilmerge error "Unresolved assembly reference not allowed: xxxxxxx"

I am trying to merge two assemblies using ilmerge with the method described here: http://www.hanselman.com/blog/MixingLanguagesInASingleAssemblyInVisualStudioSeamlesslyWithILMergeAndMSBuild.aspx however, I am getting an error with a project…
Timmerz
  • 6,090
  • 5
  • 36
  • 49
6
votes
1 answer

Why is this ilmerge command not working?

Ive got this ilMerge command: "C:\Repositories\trunk\utilities\ILMerge\ILMerge.exe" /targetplatform:v4,C:\Windows\Microsoft.NET\Framework\v4.0.30319 /closed /target:winexe /ndebug /out:C:\TestReferences\TestReferences_Merged.exe…
Exitos
  • 29,230
  • 38
  • 123
  • 178
6
votes
2 answers

How do you sign an assembly that was generated by an ILMerge operation?

I managed to use ILMerge to merge all the assemblies I have in my project into a single assembly, but the problem is there doesn't seem to be a way to sign the merged assembly. Is there some sort of command line option or command that I can run that…
plaureano
  • 3,139
  • 6
  • 30
  • 29
6
votes
2 answers

How to merge assemblies of a WPF application?

I tried to use ILMerge on my WPF-based project (VS2010, Net4.0) but I couldn't make the merged executable to run. So I created two very simply projects just a console application which prints out hello world wpf application which shows window with…
greenoldman
  • 16,895
  • 26
  • 119
  • 185
6
votes
2 answers

Referencing assemblies created with ILMerge in Visual Studio projects

I have a solution in Visual Studio with 5 projects. They are: Foo.Core: Core functionality Foo.Api: Generated code built on top of core Foo.Web: Web-specific extensions Foo.Web.Mvc: MVC-specific extensions Newtonsoft.Json: 3rd party library I want…
Daniel Schaffer
  • 56,753
  • 31
  • 116
  • 165
6
votes
1 answer

Issue when using ILMerge to merge .NET 3.5 & .NET 2.0 assemblies

When attempting to merge several assemblies in a VS Post Build I ran into the issue: ILMerge version 2.13.307.0 Copyright (C) Microsoft Corporation 2004-2006. All rights reserved. ILMerge /out:Assembly.dll AssemblyA.dll AssemblyB.dll…
Observer
  • 755
  • 1
  • 14
  • 23
6
votes
3 answers

.NET type definitions in merged assemblies (ILMerge)

I am merging several .NET assemblies using ILMerge including some 3rd party assemblies. Since doing so, I've experienced several errors that all boil down to the fact that type definitions are tied to the assembly they are defined in. A simple…
Stefan Moser
  • 6,663
  • 9
  • 35
  • 48
6
votes
1 answer

When & How to use ILMerge with Visual Studio Project / Solution

I'm developing a medium sized enterprise application. There are many projects / solutions to this. For example: Company.Data Company.Data.LinqToSql Company.Entities (business objects) Company.BLL I then have some applications - for example a…
Alex
  • 37,502
  • 51
  • 204
  • 332
6
votes
2 answers

Are there size limitations to the .NET Assembly format?

We ran into an interesting issue that I've not experienced before. We have a large scale production ASP.NET 3.5 SP1 Web App Project in Visual Studio 2008 SP1 which gets compiled and deployed using a Website Deployment Project. Everything has…
mckamey
  • 17,359
  • 16
  • 83
  • 116
1 2
3
23 24