Setup/Build StyleCop solution on Local machine to add Custom Rule

Oct 24, 2014 at 12:45 PM
Hi All,
I am trying to set up the latest 4.7 stylecop with VS 2010 with SP1 and VS 2010 SDK with SP1 following the article
HOWTO: Set up your dev box to build StyleCop
on my dev machine. Environment.cmd ran fine without any error.
but when i ran verifyBuild.cmd i am getting below error:
Usage:
VerifyBuild.cmd [retail] [-NoSync] [-NoNuke] [-TestOnly] [-NoBuild] [-NoTests]
-Retail] [-SkipWixBuild] [-WixBuildOnly] [-NoCodeAnalysis]

**** Uninstall product BEGIN *********************************************
The system cannot find the path specified.
**** Uninstall product END ***********************************************

**** Purge enlistment BEGIN **********************************************
Purge enlistment
Removing directories
The system cannot find the file specified.
The system cannot find the file specified.
The system cannot find the file specified.
The system cannot find the file specified.
The system cannot find the file specified.
The system cannot find the path specified.
The system cannot find the file specified.
Removing files
Could Not Find C:\dev\stylecop-main\Project\Build.debug.wrn
Could Not Find C:\dev\stylecop-main\Project\Build.Release.wrn
Could Not Find C:\dev\stylecop-main\Project\Src\AddIns\CSharp\Analyzers\StyleCo
.Cache
Could Not Find C:\dev\stylecop-main\Project\Src\AddIns\CSharp\InternalAnalyzers
StyleCop.Cache
Could Not Find C:\dev\stylecop-main\Project\Src\AddIns\CSharp\Parser\StyleCop.C
che
Could Not Find C:\dev\stylecop-main\Project\Src\SettingsEditor\StyleCop.Cache
Could Not Find C:\dev\stylecop-main\Project\Src\StyleCop\StyleCop.Cache
Could Not Find C:\dev\stylecop-main\Project\Src\VSPackage\StyleCop.Cache
Could Not Find C:\dev\stylecop-main\Project\Src\WixSetup\Build.debug.wrn
Could Not Find C:\dev\stylecop-main\Project\Src\WixSetup\Build.Release.wrn
Could Not Find C:\dev\stylecop-main\Project\Test\Harnesses\TestHarness\StyleCop
Cache

**** Sync enlistment BEGIN ***********************************************
'cpc' is not recognized as an internal or external command,
operable program or batch file.
**** Sync enlistment END *************************************************

**** Build Debug.NoReSharper BEGIN ********************************************

Microsoft (R) Build Engine version 4.0.30319.17929
[Microsoft .NET Framework, version 4.0.30319.17929]
Copyright (C) Microsoft Corporation. All rights reserved.

Building the projects in this solution one at a time. To enable parallel build,
please add the "/m" switch.
Build started 10/23/2014 6:24:44 PM.
Project "C:\dev\stylecop-main\Project\StyleCop.sln" on node 1 (default targets)
.
C:\dev\stylecop-main\Project\StyleCop.sln.metaproj : error MSB4126: The specifi
ed solution configuration "Debug.NoReSharper|Any CPU" is invalid. Please specif
y a valid solution configuration using the Configuration and Platform propertie
s (e.g. MSBuild.exe Solution.sln /p:Configuration=Debug /p:Platform="Any CPU")
or leave those properties blank to use the default solution configuration. [C:\
dev\stylecop-main\Project\StyleCop.sln]
Done Building Project "C:\dev\stylecop-main\Project\StyleCop.sln" (default targ
ets) -- FAILED.


Build FAILED.

"C:\dev\stylecop-main\Project\StyleCop.sln" (default target) (1) ->
(ValidateSolutionConfiguration target) ->
C:\dev\stylecop-main\Project\StyleCop.sln.metaproj : error MSB4126: The speci
fied solution configuration "Debug.NoReSharper|Any CPU" is invalid. Please spec
ify a valid solution configuration using the Configuration and Platform propert
ies (e.g. MSBuild.exe Solution.sln /p:Configuration=Debug /p:Platform="Any CPU"
) or leave those properties blank to use the default solution configuration. [C
:\dev\stylecop-main\Project\StyleCop.sln]
0 Warning(s)
1 Error(s)
Time Elapsed 00:00:00.03
**** Build Debug.NoReSharper END **********************************************

**** Run tests BEGIN **********************************************************


Unhandled Exception: System.IO.FileNotFoundException: Could not load file or as
embly 'Microsoft.VisualStudio.QualityTools.Common, Version=12.0.0.0, Culture=ne
tral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system c
nnot find the file specified.
at Microsoft.VisualStudio.TestTools.RunnerCommandline.Runner.Main(String[] a
gs)
**** Run tests END ************************************************************

Attempting to build package from 'StyleCop.nuspec'.
Could not find a part of the path 'C:\dev\stylecop-main\Project\BuildDrop\Debug
NoReSharper'.
The system cannot find the path specified.
The system cannot find the path specified.
Input files do not exist.
Checking Code Signing...
Done.

**** BUILD SUMMARY BEGIN *********************************************

Debug.NoReSharper build is finished with errors. See C:\dev\stylecop-main\Tools
Scripts....\Project\Build.Debug.NoReSharper.err for details


Could you please help me to resolve this?