Jon Skeet преди 15 години
родител
ревизия
f82a09da05

+ 0 - 13
build/BuildBenchmark.ps1

@@ -1,13 +0,0 @@
-write-host `nRunning build. Please wait...
-
-$iterations = 10
-
-for ($i=1; $i -le $iterations; $i++)
-{
-	$sw = [System.Diagnostics.StopWatch]::StartNew()
-	& E:\dotnet-protobufs\build\BuildAll.bat
-	$sw.Stop()
-	$msbuildTotalRunTime += $sw.ElapsedMilliseconds
-}
-
-write-host `nMSBuild average speed over $iterations iterations: ($msbuildTotalRunTime/$iterations) milliseconds

+ 1 - 1
build/BuildSilverlight2.bat

@@ -1,5 +1,5 @@
 @echo off
 
-%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj /m /t:Build /p:BuildConfiguration=Debug_Silverlight2
+%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj /m /t:Build /p:BuildConfiguration=Debug_Silverlight2 /p:Platform="Any CPU"
 
 pause

+ 9 - 4
build/Common.targets

@@ -29,19 +29,24 @@
 		<MSBuild Projects="$(SolutionFile)" Properties="Configuration=$(BuildConfiguration)" BuildInParallel="true" />
 	</Target>
 
-	<Target Name="_Test" DependsOnTargets="_CompileGeneratedSource">
+	<Target Name="_Test" DependsOnTargets="_CompileGeneratedSource" Condition="$(BuildConfiguration)=='Debug' or $(BuildConfiguration)=='Release'">
 		<Exec Command="&quot;$(NUnitExePath)&quot; %(TestContainer.Identity) /xml:$(BuildTempDirectory)\..\%(TestContainer.Filename).$(BuildConfiguration).xml" />
 	</Target>
 	
 	<!--## Package Generation ##-->
+	<Target Name="_CleanOutputDirectory">
+		<ItemGroup><DirectoriesToDelete Include="$([System.IO.Directory]::GetDirectories('$(BuildOutputDirectory)'))" /></ItemGroup>
+		<RemoveDir Directories="@(DirectoriesToDelete)" ContinueOnError="true" />
+		
+		<ItemGroup><FilesToDelete Include="$(BuildOutputDirectory)\**\*.*" /></ItemGroup>
+		<Delete Files="@(FilesToDelete)" />
+	</Target>
+	
 	<Target Name="_PreparePackageComponent">
 		<Copy SourceFiles="@(DynamicPackageItem)" DestinationFolder="$(BuildOutputDirectory)\%(DynamicPackageItem.TargetDirectory)\%(DynamicPackageItem.RecursiveDir)" />
 	</Target>
 
 	<Target Name="_GeneratePackage">
-		<ItemGroup><ExistingArchives Include="$(BuildOutputDirectory)\*.zip" /></ItemGroup>
-		<Delete Files="@(ExistingArchives)" />
-
 		<Copy SourceFiles="@(StaticPackageItem)" DestinationFolder="$(BuildOutputDirectory)\%(StaticPackageItem.TargetDirectory)\%(StaticPackageItem.RecursiveDir)" />
 		<Exec Command="&quot;$(ZipExePath)&quot; a -tzip $(PackageName) * -r" WorkingDirectory="$(BuildOutputDirectory)" />
 

+ 3 - 0
build/GenerateCompletePackage.bat

@@ -1,4 +1,7 @@
 @ECHO OFF
+%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj /m /t:PrepareOutputDirectory
+IF ERRORLEVEL 1 GOTO END
+
 %WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj /m /t:Build;PreparePackageComponent /p:BuildConfiguration=Debug /p:Platform="Any CPU"
 IF ERRORLEVEL 1 GOTO END
 

+ 3 - 0
build/GenerateReleasePackage.bat

@@ -1,4 +1,7 @@
 @ECHO OFF
+%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj /m /t:PrepareOutputDirectory
+IF ERRORLEVEL 1 GOTO END
+
 %WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj /m /t:Build;PreparePackageComponent /p:BuildConfiguration=Release /p:Platform="Any CPU"
 IF ERRORLEVEL 1 GOTO END
 

+ 1 - 1
build/RunBenchmarks.bat

@@ -1,5 +1,5 @@
 @echo off
 
-%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj /m /t:RunBenchmarks /p:BuildConfiguration=Release
+%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj /m /t:RunBenchmarks /p:BuildConfiguration=Release /p:Platform="Any CPU"
 
 pause

+ 1 - 0
build/build.csproj

@@ -95,6 +95,7 @@
 
 	<!-- targets -->
 	<Target Name="Build" DependsOnTargets="_Compile;_Test" />
+	<Target Name="PrepareOutputDirectory" DependsOnTargets="_CleanOutputDirectory" />
 	<Target Name="PreparePackageComponent" DependsOnTargets="_PreparePackageComponent" />
 	<Target Name="GeneratePackage" DependsOnTargets="_GeneratePackage" />
 	<Target Name="RunBenchmarks" DependsOnTargets="_RunBenchmarks" />

+ 0 - 21
src/AddressBook/AddressBook.csproj

@@ -53,27 +53,6 @@
     <WarningLevel>4</WarningLevel>
     <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
   </PropertyGroup>
-	<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug_Silverlight2|AnyCPU'">
-		<DebugSymbols>true</DebugSymbols>
-		<DebugType>full</DebugType>
-		<Optimize>false</Optimize>
-		<OutputPath>bin\Debug_Silverlight2\</OutputPath>
-		<DefineConstants>DEBUG;TRACE;SILVERLIGHT2</DefineConstants>
-		<ErrorReport>prompt</ErrorReport>
-		<WarningLevel>4</WarningLevel>
-		<NoStdLib>true</NoStdLib>
-		<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-	</PropertyGroup>
-	<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release_Silverlight2|AnyCPU'">
-		<DebugType>pdbonly</DebugType>
-		<Optimize>true</Optimize>
-		<OutputPath>bin\Release_Silverlight2\</OutputPath>
-		<DefineConstants>TRACE;SILVERLIGHT2</DefineConstants>
-		<ErrorReport>prompt</ErrorReport>
-		<WarningLevel>4</WarningLevel>
-		<NoStdLib>true</NoStdLib>
-		<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-	</PropertyGroup>
   <ItemGroup>
 	  <Reference Include="mscorlib" />
     <Reference Include="System" />

+ 0 - 21
src/ProtoBench/ProtoBench.csproj

@@ -53,27 +53,6 @@
     <WarningLevel>4</WarningLevel>
     <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
   </PropertyGroup>
-  <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug_Silverlight2|AnyCPU'">
-    <DebugSymbols>true</DebugSymbols>
-    <DebugType>full</DebugType>
-    <Optimize>false</Optimize>
-    <OutputPath>bin\Debug_Silverlight2\</OutputPath>
-    <DefineConstants>DEBUG;TRACE;SILVERLIGHT2</DefineConstants>
-    <ErrorReport>prompt</ErrorReport>
-    <WarningLevel>4</WarningLevel>
-    <NoStdLib>true</NoStdLib>
-    <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-  </PropertyGroup>
-  <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release_Silverlight2|AnyCPU'">
-    <DebugType>pdbonly</DebugType>
-    <Optimize>true</Optimize>
-    <OutputPath>bin\Release_Silverlight2\</OutputPath>
-    <DefineConstants>TRACE;SILVERLIGHT2</DefineConstants>
-    <ErrorReport>prompt</ErrorReport>
-    <WarningLevel>4</WarningLevel>
-    <NoStdLib>true</NoStdLib>
-    <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-  </PropertyGroup>
   <ItemGroup>
     <Reference Include="mscorlib" />
     <Reference Include="System" />

+ 0 - 21
src/ProtoDump/ProtoDump.csproj

@@ -52,27 +52,6 @@
     <WarningLevel>4</WarningLevel>
     <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
   </PropertyGroup>
-	<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug_Silverlight2|AnyCPU'">
-		<DebugSymbols>true</DebugSymbols>
-		<DebugType>full</DebugType>
-		<Optimize>false</Optimize>
-		<OutputPath>bin\Debug_Silverlight2\</OutputPath>
-		<DefineConstants>DEBUG;TRACE;SILVERLIGHT2</DefineConstants>
-		<ErrorReport>prompt</ErrorReport>
-		<WarningLevel>4</WarningLevel>
-		<NoStdLib>true</NoStdLib>
-		<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-	</PropertyGroup>
-	<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release_Silverlight2|AnyCPU'">
-		<DebugType>pdbonly</DebugType>
-		<Optimize>true</Optimize>
-		<OutputPath>bin\Release_Silverlight2\</OutputPath>
-		<DefineConstants>TRACE;SILVERLIGHT2</DefineConstants>
-		<ErrorReport>prompt</ErrorReport>
-		<WarningLevel>4</WarningLevel>
-		<NoStdLib>true</NoStdLib>
-		<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-	</PropertyGroup>
   <ItemGroup>
 	  <Reference Include="mscorlib" />
     <Reference Include="System" />

+ 0 - 21
src/ProtoGen.Test/ProtoGen.Test.csproj

@@ -54,27 +54,6 @@
     <WarningLevel>4</WarningLevel>
     <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
   </PropertyGroup>
-	<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug_Silverlight2|AnyCPU'">
-		<DebugSymbols>true</DebugSymbols>
-		<DebugType>full</DebugType>
-		<Optimize>false</Optimize>
-		<OutputPath>bin\Debug_Silverlight2\</OutputPath>
-		<DefineConstants>DEBUG;TRACE;SILVERLIGHT2</DefineConstants>
-		<ErrorReport>prompt</ErrorReport>
-		<WarningLevel>4</WarningLevel>
-		<NoStdLib>true</NoStdLib>
-		<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-	</PropertyGroup>
-	<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release_Silverlight2|AnyCPU'">
-		<DebugType>pdbonly</DebugType>
-		<Optimize>true</Optimize>
-		<OutputPath>bin\Release_Silverlight2\</OutputPath>
-		<DefineConstants>TRACE;SILVERLIGHT2</DefineConstants>
-		<ErrorReport>prompt</ErrorReport>
-		<WarningLevel>4</WarningLevel>
-		<NoStdLib>true</NoStdLib>
-		<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-	</PropertyGroup>
   <ItemGroup>
     <Reference Include="nunit.framework, Version=2.2.8.0, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77">
       <SpecificVersion>False</SpecificVersion>

+ 0 - 21
src/ProtoGen/ProtoGen.csproj

@@ -55,27 +55,6 @@
     <WarningLevel>4</WarningLevel>
     <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
   </PropertyGroup>
-	<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug_Silverlight2|AnyCPU'">
-		<DebugSymbols>true</DebugSymbols>
-		<DebugType>full</DebugType>
-		<Optimize>false</Optimize>
-		<OutputPath>bin\Debug_Silverlight2\</OutputPath>
-		<DefineConstants>DEBUG;TRACE;SILVERLIGHT2</DefineConstants>
-		<ErrorReport>prompt</ErrorReport>
-		<WarningLevel>4</WarningLevel>
-		<NoStdLib>true</NoStdLib>
-		<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-	</PropertyGroup>
-	<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release_Silverlight2|AnyCPU'">
-		<DebugType>pdbonly</DebugType>
-		<Optimize>true</Optimize>
-		<OutputPath>bin\Release_Silverlight2\</OutputPath>
-		<DefineConstants>TRACE;SILVERLIGHT2</DefineConstants>
-		<ErrorReport>prompt</ErrorReport>
-		<WarningLevel>4</WarningLevel>
-		<NoStdLib>true</NoStdLib>
-		<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-	</PropertyGroup>
   <ItemGroup>
 	  <Reference Include="mscorlib" />
     <Reference Include="System" />

+ 0 - 21
src/ProtoMunge/ProtoMunge.csproj

@@ -52,27 +52,6 @@
     <WarningLevel>4</WarningLevel>
     <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
   </PropertyGroup>
-	<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug_Silverlight2|AnyCPU'">
-		<DebugSymbols>true</DebugSymbols>
-		<DebugType>full</DebugType>
-		<Optimize>false</Optimize>
-		<OutputPath>bin\Debug_Silverlight2\</OutputPath>
-		<DefineConstants>DEBUG;TRACE;SILVERLIGHT2</DefineConstants>
-		<ErrorReport>prompt</ErrorReport>
-		<WarningLevel>4</WarningLevel>
-		<NoStdLib>true</NoStdLib>
-		<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-	</PropertyGroup>
-	<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release_Silverlight2|AnyCPU'">
-		<DebugType>pdbonly</DebugType>
-		<Optimize>true</Optimize>
-		<OutputPath>bin\Release_Silverlight2\</OutputPath>
-		<DefineConstants>TRACE;SILVERLIGHT2</DefineConstants>
-		<ErrorReport>prompt</ErrorReport>
-		<WarningLevel>4</WarningLevel>
-		<NoStdLib>true</NoStdLib>
-		<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-	</PropertyGroup>
   <ItemGroup>
     <Reference Include="mscorlib" />
     <Reference Include="System" />

+ 2 - 22
src/ProtocolBuffers.Test/ProtocolBuffers.Test.csproj

@@ -54,27 +54,6 @@
     <WarningLevel>4</WarningLevel>
     <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
   </PropertyGroup>
-  <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug_Silverlight2|AnyCPU'">
-    <DebugSymbols>true</DebugSymbols>
-    <DebugType>full</DebugType>
-    <Optimize>false</Optimize>
-    <OutputPath>bin\Debug_Silverlight2\</OutputPath>
-    <DefineConstants>DEBUG;TRACE;SILVERLIGHT2</DefineConstants>
-    <ErrorReport>prompt</ErrorReport>
-    <WarningLevel>4</WarningLevel>
-    <NoStdLib>true</NoStdLib>
-    <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-  </PropertyGroup>
-  <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release_Silverlight2|AnyCPU'">
-    <DebugType>pdbonly</DebugType>
-    <Optimize>true</Optimize>
-    <OutputPath>bin\Release_Silverlight2\</OutputPath>
-    <DefineConstants>TRACE;SILVERLIGHT2</DefineConstants>
-    <ErrorReport>prompt</ErrorReport>
-    <WarningLevel>4</WarningLevel>
-    <NoStdLib>true</NoStdLib>
-    <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-  </PropertyGroup>
   <ItemGroup>
     <Reference Include="nunit.framework, Version=2.2.8.0, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77">
       <SpecificVersion>False</SpecificVersion>
@@ -150,7 +129,8 @@
       <Install>true</Install>
     </BootstrapperPackage>
   </ItemGroup>
-  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" Condition=" '$(Configuration)' == 'Debug' " />  
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" Condition=" '$(Configuration)' == 'Release' " />
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
        Other similar extension points exist, see Microsoft.Common.targets.
   <Target Name="BeforeBuild">

+ 28 - 28
src/ProtocolBuffers.sln

@@ -67,60 +67,60 @@ Global
 		{6908BDCE-D925-43F3-94AC-A531E6DF2591}.Release_Silverlight2|Any CPU.Build.0 = Release_Silverlight2|Any CPU
 		{6908BDCE-D925-43F3-94AC-A531E6DF2591}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{6908BDCE-D925-43F3-94AC-A531E6DF2591}.Release|Any CPU.Build.0 = Release|Any CPU
-		{DD01ED24-3750-4567-9A23-1DB676A15610}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug_Silverlight2|Any CPU
-		{DD01ED24-3750-4567-9A23-1DB676A15610}.Debug_Silverlight2|Any CPU.Build.0 = Debug_Silverlight2|Any CPU
+		{DD01ED24-3750-4567-9A23-1DB676A15610}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug|Any CPU
+		{DD01ED24-3750-4567-9A23-1DB676A15610}.Debug_Silverlight2|Any CPU.Build.0 = Debug|Any CPU
 		{DD01ED24-3750-4567-9A23-1DB676A15610}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{DD01ED24-3750-4567-9A23-1DB676A15610}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{DD01ED24-3750-4567-9A23-1DB676A15610}.Release_Silverlight2|Any CPU.ActiveCfg = Release_Silverlight2|Any CPU
-		{DD01ED24-3750-4567-9A23-1DB676A15610}.Release_Silverlight2|Any CPU.Build.0 = Release_Silverlight2|Any CPU
+		{DD01ED24-3750-4567-9A23-1DB676A15610}.Release_Silverlight2|Any CPU.ActiveCfg = Release|Any CPU
+		{DD01ED24-3750-4567-9A23-1DB676A15610}.Release_Silverlight2|Any CPU.Build.0 = Release|Any CPU
 		{DD01ED24-3750-4567-9A23-1DB676A15610}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{DD01ED24-3750-4567-9A23-1DB676A15610}.Release|Any CPU.Build.0 = Release|Any CPU
-		{250ADE34-82FD-4BAE-86D5-985FBE589C4A}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug_Silverlight2|Any CPU
-		{250ADE34-82FD-4BAE-86D5-985FBE589C4A}.Debug_Silverlight2|Any CPU.Build.0 = Debug_Silverlight2|Any CPU
+		{250ADE34-82FD-4BAE-86D5-985FBE589C4A}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug|Any CPU
+		{250ADE34-82FD-4BAE-86D5-985FBE589C4A}.Debug_Silverlight2|Any CPU.Build.0 = Debug|Any CPU
 		{250ADE34-82FD-4BAE-86D5-985FBE589C4A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{250ADE34-82FD-4BAE-86D5-985FBE589C4A}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{250ADE34-82FD-4BAE-86D5-985FBE589C4A}.Release_Silverlight2|Any CPU.ActiveCfg = Release_Silverlight2|Any CPU
-		{250ADE34-82FD-4BAE-86D5-985FBE589C4A}.Release_Silverlight2|Any CPU.Build.0 = Release_Silverlight2|Any CPU
+		{250ADE34-82FD-4BAE-86D5-985FBE589C4A}.Release_Silverlight2|Any CPU.ActiveCfg = Release|Any CPU
+		{250ADE34-82FD-4BAE-86D5-985FBE589C4A}.Release_Silverlight2|Any CPU.Build.0 = Release|Any CPU
 		{250ADE34-82FD-4BAE-86D5-985FBE589C4A}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{250ADE34-82FD-4BAE-86D5-985FBE589C4A}.Release|Any CPU.Build.0 = Release|Any CPU
-		{C268DA4C-4004-47DA-AF23-44C983281A68}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug_Silverlight2|Any CPU
-		{C268DA4C-4004-47DA-AF23-44C983281A68}.Debug_Silverlight2|Any CPU.Build.0 = Debug_Silverlight2|Any CPU
+		{C268DA4C-4004-47DA-AF23-44C983281A68}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug|Any CPU
+		{C268DA4C-4004-47DA-AF23-44C983281A68}.Debug_Silverlight2|Any CPU.Build.0 = Debug|Any CPU
 		{C268DA4C-4004-47DA-AF23-44C983281A68}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{C268DA4C-4004-47DA-AF23-44C983281A68}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{C268DA4C-4004-47DA-AF23-44C983281A68}.Release_Silverlight2|Any CPU.ActiveCfg = Release_Silverlight2|Any CPU
-		{C268DA4C-4004-47DA-AF23-44C983281A68}.Release_Silverlight2|Any CPU.Build.0 = Release_Silverlight2|Any CPU
+		{C268DA4C-4004-47DA-AF23-44C983281A68}.Release_Silverlight2|Any CPU.ActiveCfg = Release|Any CPU
+		{C268DA4C-4004-47DA-AF23-44C983281A68}.Release_Silverlight2|Any CPU.Build.0 = Release|Any CPU
 		{C268DA4C-4004-47DA-AF23-44C983281A68}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{C268DA4C-4004-47DA-AF23-44C983281A68}.Release|Any CPU.Build.0 = Release|Any CPU
-		{A31F5FB2-4FF3-432A-B35B-5CD203606311}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug_Silverlight2|Any CPU
-		{A31F5FB2-4FF3-432A-B35B-5CD203606311}.Debug_Silverlight2|Any CPU.Build.0 = Debug_Silverlight2|Any CPU
+		{A31F5FB2-4FF3-432A-B35B-5CD203606311}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug|Any CPU
+		{A31F5FB2-4FF3-432A-B35B-5CD203606311}.Debug_Silverlight2|Any CPU.Build.0 = Debug|Any CPU
 		{A31F5FB2-4FF3-432A-B35B-5CD203606311}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{A31F5FB2-4FF3-432A-B35B-5CD203606311}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{A31F5FB2-4FF3-432A-B35B-5CD203606311}.Release_Silverlight2|Any CPU.ActiveCfg = Release_Silverlight2|Any CPU
-		{A31F5FB2-4FF3-432A-B35B-5CD203606311}.Release_Silverlight2|Any CPU.Build.0 = Release_Silverlight2|Any CPU
+		{A31F5FB2-4FF3-432A-B35B-5CD203606311}.Release_Silverlight2|Any CPU.ActiveCfg = Release|Any CPU
+		{A31F5FB2-4FF3-432A-B35B-5CD203606311}.Release_Silverlight2|Any CPU.Build.0 = Release|Any CPU
 		{A31F5FB2-4FF3-432A-B35B-5CD203606311}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{A31F5FB2-4FF3-432A-B35B-5CD203606311}.Release|Any CPU.Build.0 = Release|Any CPU
-		{8F09AF72-3327-4FA7-BC09-070B80221AB9}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug_Silverlight2|Any CPU
-		{8F09AF72-3327-4FA7-BC09-070B80221AB9}.Debug_Silverlight2|Any CPU.Build.0 = Debug_Silverlight2|Any CPU
+		{8F09AF72-3327-4FA7-BC09-070B80221AB9}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug|Any CPU
+		{8F09AF72-3327-4FA7-BC09-070B80221AB9}.Debug_Silverlight2|Any CPU.Build.0 = Debug|Any CPU
 		{8F09AF72-3327-4FA7-BC09-070B80221AB9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{8F09AF72-3327-4FA7-BC09-070B80221AB9}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{8F09AF72-3327-4FA7-BC09-070B80221AB9}.Release_Silverlight2|Any CPU.ActiveCfg = Release_Silverlight2|Any CPU
-		{8F09AF72-3327-4FA7-BC09-070B80221AB9}.Release_Silverlight2|Any CPU.Build.0 = Release_Silverlight2|Any CPU
+		{8F09AF72-3327-4FA7-BC09-070B80221AB9}.Release_Silverlight2|Any CPU.ActiveCfg = Release|Any CPU
+		{8F09AF72-3327-4FA7-BC09-070B80221AB9}.Release_Silverlight2|Any CPU.Build.0 = Release|Any CPU
 		{8F09AF72-3327-4FA7-BC09-070B80221AB9}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{8F09AF72-3327-4FA7-BC09-070B80221AB9}.Release|Any CPU.Build.0 = Release|Any CPU
-		{C7A4A435-2813-41C8-AA87-BD914BA5223D}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug_Silverlight2|Any CPU
-		{C7A4A435-2813-41C8-AA87-BD914BA5223D}.Debug_Silverlight2|Any CPU.Build.0 = Debug_Silverlight2|Any CPU
+		{C7A4A435-2813-41C8-AA87-BD914BA5223D}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug|Any CPU
+		{C7A4A435-2813-41C8-AA87-BD914BA5223D}.Debug_Silverlight2|Any CPU.Build.0 = Debug|Any CPU
 		{C7A4A435-2813-41C8-AA87-BD914BA5223D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{C7A4A435-2813-41C8-AA87-BD914BA5223D}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{C7A4A435-2813-41C8-AA87-BD914BA5223D}.Release_Silverlight2|Any CPU.ActiveCfg = Release_Silverlight2|Any CPU
-		{C7A4A435-2813-41C8-AA87-BD914BA5223D}.Release_Silverlight2|Any CPU.Build.0 = Release_Silverlight2|Any CPU
+		{C7A4A435-2813-41C8-AA87-BD914BA5223D}.Release_Silverlight2|Any CPU.ActiveCfg = Release|Any CPU
+		{C7A4A435-2813-41C8-AA87-BD914BA5223D}.Release_Silverlight2|Any CPU.Build.0 = Release|Any CPU
 		{C7A4A435-2813-41C8-AA87-BD914BA5223D}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{C7A4A435-2813-41C8-AA87-BD914BA5223D}.Release|Any CPU.Build.0 = Release|Any CPU
-		{D7282E99-2DC3-405B-946F-177DB2FD2AE2}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug_Silverlight2|Any CPU
-		{D7282E99-2DC3-405B-946F-177DB2FD2AE2}.Debug_Silverlight2|Any CPU.Build.0 = Debug_Silverlight2|Any CPU
+		{D7282E99-2DC3-405B-946F-177DB2FD2AE2}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug|Any CPU
+		{D7282E99-2DC3-405B-946F-177DB2FD2AE2}.Debug_Silverlight2|Any CPU.Build.0 = Debug|Any CPU
 		{D7282E99-2DC3-405B-946F-177DB2FD2AE2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{D7282E99-2DC3-405B-946F-177DB2FD2AE2}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{D7282E99-2DC3-405B-946F-177DB2FD2AE2}.Release_Silverlight2|Any CPU.ActiveCfg = Release_Silverlight2|Any CPU
-		{D7282E99-2DC3-405B-946F-177DB2FD2AE2}.Release_Silverlight2|Any CPU.Build.0 = Release_Silverlight2|Any CPU
+		{D7282E99-2DC3-405B-946F-177DB2FD2AE2}.Release_Silverlight2|Any CPU.ActiveCfg = Release|Any CPU
+		{D7282E99-2DC3-405B-946F-177DB2FD2AE2}.Release_Silverlight2|Any CPU.Build.0 = Release|Any CPU
 		{D7282E99-2DC3-405B-946F-177DB2FD2AE2}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{D7282E99-2DC3-405B-946F-177DB2FD2AE2}.Release|Any CPU.Build.0 = Release|Any CPU
 		{6969BDCE-D925-43F3-94AC-A531E6DF2591}.Debug_Silverlight2|Any CPU.ActiveCfg = Debug_Silverlight2|Any CPU

+ 4 - 2
src/ProtocolBuffers/ProtocolBuffers.csproj

@@ -199,8 +199,10 @@
       <Install>true</Install>
     </BootstrapperPackage>
   </ItemGroup>
-  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" Condition=" '$(Configuration)' != 'Silverlight2' " />
-  <Import Project="$(MSBuildExtensionsPath)\Microsoft\Silverlight\v2.0\Microsoft.Silverlight.CSharp.targets" Condition=" '$(Configuration)' == 'Silverlight2' " />
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" Condition=" '$(Configuration)' == 'Debug' " />  
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" Condition=" '$(Configuration)' == 'Release' " />
+  <Import Project="$(MSBuildExtensionsPath)\Microsoft\Silverlight\v2.0\Microsoft.Silverlight.CSharp.targets" Condition=" '$(Configuration)' == 'Debug_Silverlight2' " />
+  <Import Project="$(MSBuildExtensionsPath)\Microsoft\Silverlight\v2.0\Microsoft.Silverlight.CSharp.targets" Condition=" '$(Configuration)' == 'Release_Silverlight2' " />
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
        Other similar extension points exist, see Microsoft.Common.targets.
   <Target Name="BeforeBuild">