|
|
|
Sergei Dorogin
Community Member
|
|
I known, PS doesn't support .NET 4.0, but I'm trying to build a project which targets .net 3.5 under VS2010. Here's ouput log:
Error 89 Unhandled exception: PostSharp.CodeModel.BindingException: Cannot find the type 'System.IEquatable`1, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' in assembly 'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'. at PostSharp.CodeModel.AssemblyEnvelope.GetTypeDefinition(String typeName, BindingOptions bindingOptions) at PostSharp.CodeModel.TypeRefDeclaration.GetTypeDefinition(BindingOptions bindingOptions) at PostSharp.Extensibility.Tasks.IndexGenericInstancesTask.Execute() at PostSharp.Extensibility.Project.ExecutePhase(String phase) at PostSharp.Extensibility.Project.Execute() at PostSharp.Extensibility.PostSharpObject.ExecuteProjects() at PostSharp.Extensibility.PostSharpObject.InvokeProjects(ProjectInvocation[] projectInvocations) at PostSharp.MSBuild.PostSharpRemoteTask.Execute(PostSharpTaskParameters parameters, TaskLoggingHelper log) Xtensive.Core
Does any workaround exist?
|
|
|
|
|
Gael Fraiteur
SharpCrafters
|
|
I think the problem is that VS2010 hosts the CLR 4, and PostSharp needs to be hosted in the same CLR as the transformed application.
I suggest you run the command line utility. You can do this by adding the following to your project or to PostSharp-1.5.targets:
<PropertyGroup> <PostSharpUseCommandLine>True</<PostSharpUseCommandLine>> </PropertyGroup>
|
|
|
|
|
Sergei Dorogin
Community Member
|
|
|
|
|
|
Community Member
|
|
|
Note: You need to restart Visual Studio after making this change.
|
|
|
|