fxcoptask.dll not found when running build.cmd

Jan 13, 2011 at 5:03 AM

I'm getting this error message when I run build.cmd:


"C:\Users\justin\Projects\CodePlex\metasharpnupack\Build\Build.proj" (default t
arget) (1) ->
(CheckFxCop target) ->
  C:\Users\justin\Projects\CodePlex\metasharpnupack\Build\Build.proj(61,9): err
or : FxCop not found at C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v
10.0\CodeAnalysis\fxcoptask.dll. Cannot proceed

    0 Warning(s)
    1 Error(s)

I have installed the vs2010 sdk and even installed manually the fxcop intaller that comes with it. I still don't have this task. How is one supposed to acquire this? I have vs2010 professional btw.

Mar 4, 2011 at 7:44 AM

It seems you need Visual Studio 2010 Premium or Ultimate editions with code-analysis support.

Mar 4, 2011 at 7:50 AM

You could edit build\Build.proj and comment out the Error task inside of CheckFxCop to build without code analysis.

We should make this a warning instead of a fatal error.

Mar 4, 2011 at 8:11 AM

I wonder if it's possible to copy the fxtcoptask.dll and all depedency assemblies into nuget source tree?

Mar 4, 2011 at 8:50 AM

Possible or legal :)

Mar 4, 2011 at 2:00 PM

Man, external dependencies can be a real drag. I wish someone would make a tool that made it easy to download those external dependencies and apply them to your project!

I smell a new NuGet package coming on! Static analysis that everyone can actually use. I actually have access to VS Ultimate and will have to force myself go through the long and annoying process of re-installing VS in the meantime.