4

Possible Duplicate:
Determine whether .NET assemblies were built from the same source

I want to compare assemblies in .NET to check for any changes. After looking around the web, I found out that the compiler changes the build date, the version revision (if not explicitly specified) and many other things. Is there, by any chance, an option in msbuild to get exactly the same result with two different builds ?

Community
  • 1
  • 1
Nylo Andy
  • 152
  • 1
  • 9

2 Answers2

1

A Visual Studio project has a file named AssemblyInfo which contains metadata about the assembly.

You can set the version information there.

Here is an example of a section in an AssemblyInfo file:

// Version information for an assembly consists of the following four values:
//
//      Major Version
//      Minor Version 
//      Build Number
//      Revision
//
// You can specify all the values or you can default the Build and Revision Numbers 
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
DOK
  • 32,337
  • 7
  • 60
  • 92
0

Using ILDASM while ignoring specific tokens is an possible approach. Thanks to chibacity.

Nylo Andy
  • 152
  • 1
  • 9