build performance optimisations

pull/288/head
ArnoldZokas 15 years ago
parent fca5d2b6a2
commit d10c5e794d
  1. 8
      ProtocolBuffers.build
  2. 8859
      cfg/Build.log
  3. 17
      cfg/Common.targets
  4. 5
      cfg/build with diagnostics.bat
  5. 2
      cfg/build.bat
  6. 24
      cfg/build.csproj
  7. 2
      cfg/buildAll.bat

@ -271,10 +271,10 @@
<property name="Platform" value="Any CPU" />
</msbuild>
<!-- Note the deliberate lack of space in the platform name -->
<msbuild project="${src}/ProtocolBuffers/ProtocolBuffersCF.csproj">
<!--<msbuild project="${src}/ProtocolBuffers/ProtocolBuffersCF.csproj">
<property name="Configuration" value="Release" />
<property name="Platform" value="AnyCPU" />
</msbuild>
</msbuild>-->
</target>
@ -327,12 +327,12 @@
<include name="ProtocolBuffers/bin/Silverlight2/Google.ProtocolBuffers.dll" />
</fileset>
</copy>
<copy todir="${output-dir}/CompactFramework35"
<!--<copy todir="${output-dir}/CompactFramework35"
flatten="true">
<fileset basedir="${src}">
<include name="ProtocolBuffers/bin/ReleaseCF/Google.ProtocolBuffers.dll" />
</fileset>
</copy>
</copy>-->
<copy todir="${output-dir}">
<fileset basedir="${project::get-base-directory()}">
<include name="protos/**" />

File diff suppressed because it is too large Load Diff

@ -8,7 +8,7 @@
<Target Name="_Compile">
<MSBuild Projects="%(Solution.Identity)" Properties="Configuration=%(Solution.Configuration);Platform=%(Solution.Platform)"
Targets="%(Solution.BuildTarget)" BuildInParallel="true" Condition="%(Solution.CompileGroup) == $(CompileGroup)" />
Targets="%(Solution.BuildTarget)" BuildInParallel="true" Condition="%(Solution.CompileGroup) == $(CompileGroup)" ToolsVersion="4.0" />
</Target>
<Target Name="_EnsureEnvironment">
@ -16,7 +16,7 @@
<Error Text="Tool &quot;Protogen&quot; could not be found at path $(ProtogenExePath)" Condition="!Exists($(ProtogenExePath))" />
</Target>
<Target Name="_GenerateSource">
<Target Name="_GenerateSource" DependsOnTargets="_Clean;_Compile;_Compile">
<PropertyGroup>
<ProtosList>@(Protos)</ProtosList>
<Args>$(ProtosList.Replace(`;`,` `))</Args>
@ -26,20 +26,25 @@
<Exec Command="$(ProtogenExePath) compiled.pb" WorkingDirectory="$(BuildTempDirectory)" />
</Target>
<Target Name="_CopyGeneratedSource">
<Target Name="_CopyGeneratedSource" DependsOnTargets="_GenerateSource">
<Copy SourceFiles="%(GeneratedSource.Identity)" DestinationFiles="%(GeneratedSource.TargetDirectory)\%(GeneratedSource.Filename)%(GeneratedSource.Extension)" />
</Target>
<Target Name="_Test">
<Target Name="_CompileGeneratedSource" DependsOnTargets="_CopyGeneratedSource">
<MSBuild Projects="%(Solution.Identity)" Properties="Configuration=%(Solution.Configuration);Platform=%(Solution.Platform)"
Targets="%(Solution.BuildTarget)" BuildInParallel="true" Condition="%(Solution.CompileGroup) == $(CompileGroup)" />
</Target>
<Target Name="_Test" DependsOnTargets="_CompileGeneratedSource">
<Exec Command="&quot;$(NUnitExePath)&quot; %(NUnitTests.Identity) /xml=%(NUnitTests.Filename)%(NUnitTests.Extension).xml" WorkingDirectory="$(BuildTempDirectory)" />
</Target>
<Target Name="_Package">
<Target Name="_Package" DependsOnTargets="_CopyGeneratedSource">
<Copy SourceFiles="@(PackageContents)" DestinationFolder="$(PackageOutputDirectory)\%(PackageContents.TargetDirectory)\%(PackageContents.RecursiveDir)" />
</Target>
<!--
BENCHMARK - this needs optimising but it is 1 AM and I need to be up in 5 hours
BENCHMARK - this needs optimising
-->
<Target Name="_GenerateBenchmarkSource">
<PropertyGroup>

@ -0,0 +1,5 @@
@echo off
%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj /m /l:FileLogger,Microsoft.Build.Engine;logfile=Build.log;append=true;verbosity=diagnostic;encoding=utf-8
pause

@ -1,5 +1,5 @@
@echo off
%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj
%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj /m
pause

@ -26,7 +26,7 @@
<NUnitExePath>$(LibDirectory)\NUnit 2.2.8.0\nunit-console.exe</NUnitExePath>
</PropertyGroup>
<Import Project="Targets\Common.targets"/>
<Import Project="Common.targets"/>
<ItemGroup>
<WorkingDirectories Include="$(BuildTempDirectory)" />
@ -36,31 +36,31 @@
<Solution Include="$(SolutionFile)">
<Configuration>$(BuildConfiguration)</Configuration>
<Platform>Any CPU</Platform>
<BuildTarget>Rebuild</BuildTarget>
<BuildTarget>Build</BuildTarget>
<CompileGroup>Build</CompileGroup>
</Solution>
<Solution Include="$(SolutionFile)">
<Configuration>Debug</Configuration>
<Platform>Any CPU</Platform>
<BuildTarget>Rebuild</BuildTarget>
<BuildTarget>Build</BuildTarget>
<CompileGroup>BuildAll</CompileGroup>
</Solution>
<Solution Include="$(SolutionFile)">
<Configuration>Release</Configuration>
<Platform>Any CPU</Platform>
<BuildTarget>Rebuild</BuildTarget>
<BuildTarget>Build</BuildTarget>
<CompileGroup>BuildAll</CompileGroup>
</Solution>
<Solution Include="$(SolutionFile)">
<Configuration>Silverlight2</Configuration>
<Platform>Any CPU</Platform>
<BuildTarget>Rebuild</BuildTarget>
<BuildTarget>Build</BuildTarget>
<CompileGroup>BuildAll</CompileGroup>
</Solution>
<!--<Solution Include="$(ProjectDirectory)\src\ProtocolBuffers/ProtocolBuffersCF.csproj">
<Configuration>$(BuildConfiguration)</Configuration>
<Platform>AnyCPU</Platform>
<BuildTarget>Rebuild</BuildTarget>
<BuildTarget>Build</BuildTarget>
<CompileGroup>BuildAll</CompileGroup>
</Solution>-->
@ -153,16 +153,8 @@
</ItemGroup>
<!--target groups-->
<Target Name="Build" DependsOnTargets="_Clean;_Compile;_EnsureEnvironment;_GenerateSource;_CopyGeneratedSource">
<MSBuild Projects="$(MSBuildProjectFullPath)" Targets="_Clean;_Compile" Properties="ForceTargets=true" />
<CallTarget Targets="_Test" />
</Target>
<Target Name="BuildAll" DependsOnTargets="_Clean;_Compile;_EnsureEnvironment;_GenerateSource;_CopyGeneratedSource">
<MSBuild Projects="$(MSBuildProjectFullPath)" Targets="_Clean;_Compile" Properties="ForceTargets=true" />
<CallTarget Targets="_Test;_Package" />
</Target>
<Target Name="Build" DependsOnTargets="_Clean;_Compile;_EnsureEnvironment;_GenerateSource;_CopyGeneratedSource;_CompileGeneratedSource;_Test" />
<Target Name="BuildAll" DependsOnTargets="_Clean;_Compile;_EnsureEnvironment;_GenerateSource;_CopyGeneratedSource;_CompileGeneratedSource;_Test;_Package" />
<Target Name="Benchmark" DependsOnTargets="_Clean;_GenerateBenchmarkSource;_CompileBenchmarkAssembly;_PrepareBenchmarkEnvironment;_RunBenchmark" />
</Project>

@ -1,5 +1,5 @@
@echo off
%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj /t:BuildAll /p:CompileGroup=BuildAll
%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild build.csproj /t:BuildAll /p:CompileGroup=BuildAll /m
pause
Loading…
Cancel
Save