Code Contracts & Native .Net45 support

Includes build procedure to pack the contracts assemblies.
Includes support for .Net45
Fixed a couple of code contracts flagged potential issues.