Skip to content

Commit

Permalink
Only build applicable build Tasks when building the repo (#104226)
Browse files Browse the repository at this point in the history
We're starting to build too many tasks unconditionally.
  • Loading branch information
MichalStrehovsky committed Jul 10, 2024
1 parent ed9642e commit 61050ae
Showing 1 changed file with 21 additions and 6 deletions.
27 changes: 21 additions & 6 deletions src/tasks/tasks.proj
Original file line number Diff line number Diff line change
@@ -1,12 +1,27 @@
<Project Sdk="Microsoft.Build.Traversal">
<ItemGroup Condition="'$(TargetsMobile)' == 'true'">
<ProjectReference Include="AndroidAppBuilder\AndroidAppBuilder.csproj" />
<ProjectReference Include="AotCompilerTask\MonoAOTCompiler.csproj" />
<ProjectReference Include="AppleAppBuilder\AppleAppBuilder.csproj" />
<ProjectReference Include="LibraryBuilder\LibraryBuilder.csproj" />
<ProjectReference Include="Microsoft.NET.Sdk.WebAssembly.Pack.Tasks\Microsoft.NET.Sdk.WebAssembly.Pack.Tasks.csproj" />
<ProjectReference Include="Microsoft.NET.WebAssembly.Webcil\Microsoft.NET.WebAssembly.Webcil.csproj" />
<ProjectReference Include="MobileBuildTasks\MobileBuildTasks.csproj" />
<ProjectReference Include="MonoTargetsTasks\MonoTargetsTasks.csproj" Condition="'$(DotNetBuildSourceOnly)' != 'true'" />
<ProjectReference Include="MonoTargetsTasks\ILStrip\AssemblyStripper\AssemblyStripper.csproj" Condition="'$(DotNetBuildSourceOnly)' != 'true'" />
<ProjectReference Include="TestExclusionListTasks\TestExclusionListTasks.csproj" />
<ProjectReference Include="WasmAppBuilder\WasmAppBuilder.csproj" />
<ProjectReference Include="WasmBuildTasks\WasmBuildTasks.csproj" />

<!-- For WasmBuildTests or any other configuration that tests against workloads -->
<ProjectReference Include="WorkloadBuildTasks\WorkloadBuildTasks.csproj" />
</ItemGroup>

<ItemGroup>
<ProjectReference Include="$(MSBuildThisFileDirectory)**\*.csproj" />
<!-- This could be conditioned on '$(RuntimeFlavor)' == 'CoreCLR' but Mono legs still need it right now -->
<ProjectReference Include="Crossgen2Tasks\Crossgen2Tasks.csproj" />

<!-- These projects do not need to be built during source-build. -->
<!-- For example, they may take dependencies on pre-built packages that aren't build-from-source. e.g. 'Microsoft.DotNet.CilStrip.Sources' -->
<ProjectReference Remove="MonoTargetsTasks\MonoTargetsTasks.csproj;
MonoTargetsTasks\ILStrip\AssemblyStripper\AssemblyStripper.csproj"
Condition="'$(DotNetBuildSourceOnly)' == 'true'" />
<ProjectReference Include="installer.tasks\installer.tasks.csproj" />
</ItemGroup>

<!--
Expand Down

0 comments on commit 61050ae

Please sign in to comment.