The "AddIns" parameter is not supported by the "PostSharp21" task.
I have the same error that was reported in
http://support.sharpcrafters.com/discussions/problems/242-postsharp...
C:\Program Files\PostSharp 2.1\PostSharp.targets(321,17): error
MSB4064: The "AddIns" parameter is not supported by the
"PostSharp21" task. Verify the parameter exists on the task, and it
is a settable public instance property.
C:\Program Files\PostSharp 2.1\PostSharp.targets(303,5): error
MSB4063: The "PostSharp21" task could not be initialized with its
input parameters.
But the error happens on build machine, where we don't have VS
running.
The errors start to happened after PostSharp was installed on the
build server
The errors reported only for some(not all) projects in the
solution. I've tried to disable PostSharp for these projects, but
it didn't help.
Any more details about possible reasons will be appreciated.
Is it save to delete AddIns="@(PostSharpAddIn)" from in C:\Program
Files\PostSharp 2.1\PostSharp.targets?
Comments are currently closed for this discussion. You can start a new one.
2 Posted by michael.freidgeim on 08 Aug, 2012 02:01 AM
To workaround the issue I've started to add (I am using [ instead of angle brackets, stripped by the editor)
[PropertyGroup] [dontImportPostSharp]True[/dontImportPostSharp] [/PropertyGroup] for each failing project(all of them not using PostSharp), but next build shows new failing projects. Update more than 50 projects in the solution didn't attract me, so I updated C:\Program Files\PostSharp 2.1\PostSharp.targets to remove AddIns="@(PostSharpAddIn)"
(Changing to AddIns="$(PostSharpAddIn)" instead of @, as suggested in http://support.sharpcrafters.com/discussions/problems/194-error-in-... didn't help). I had to remove AddIns in relative to solution [Import Project="........\packages\PostSharp.2.1.7.6\tools\PostSharp.targets" ] for projects that are using PostSharp
I now have successful builds, but I prefer to have correct fix, rather than workaround.
Support Staff 3 Posted by PostSharp Support on 09 Aug, 2012 11:55 AM
Hi Michael,
we will be looking into the issue and get back to you as soon as possible.
Support Staff 4 Posted by PostSharp Support on 13 Aug, 2012 12:46 PM
The problem is typically due to a version conflict between PostSharp.targets and PostSharp.MSbuild.dll. Typically, Visual Studio would cache PostSharp.MSbuild.dll so you need to restart Visual Studio after upgrade. It can also happen that you are using several versions of PostSharp on the same machine (for instance through NuGet), and Visual Studio would load and cache only the version that has been loaded first. This issue has been solved in Visual Studio 2012.
PostSharp Support closed this discussion on 13 Aug, 2012 12:46 PM.