dotnet-installer/src/SourceBuild/content/repo-projects/fsharp.proj

32 lines
1.2 KiB
Text
Raw Normal View History

<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<LogVerbosityOptOut>true</LogVerbosityOptOut>
<!-- Use the repo root build script -->
<BuildScript>$(ProjectDirectory)build$(ShellExtension)</BuildScript>
<!-- Restore and Build actions are already passed in by the root script. -->
<BuildActions>$(FlagParameterPrefix)pack $(FlagParameterPrefix)publish</BuildActions>
<BuildArgs>$(BuildArgs) /p:TreatWarningsAsErrors=false</BuildArgs>
<!--
dotnet/fsharp has a custom eng/build.sh script that handles its own sourcebuild arg
differently from the ArcadeBuildFromSource MSBuild arg. Including both args is fine, but the
custom sourcebuild arg is the one that's required. This avoids running bootstrapping twice.
-->
<BuildArgs>$(BuildArgs) $(FlagParameterPrefix)sourcebuild $(FlagParameterPrefix)tfm $(NetCurrent) /p:SourceBuildBootstrapTfm=$(NetCurrent)</BuildArgs>
</PropertyGroup>
<ItemGroup>
<RepositoryReference Include="arcade" />
Isolate package flow between repos (#18557) As a prerequisite to enabling parallel builds of the repos in the VMR, it's necessary to isolate the package flow between repos. This ensures that repo dependencies are defined correctly. Prior to these changes, the packages outputted by repos went to the same directory (Shipping or NonShipping) and those two directories were used as the package feed inputs to dependent repos. This would be dangerous in the context of running builds in parallel across repos because any ill-defined dependencies could lead to race conditions. For example, consider the msbuild repo's dependency on System.Text.Json from the runtime repo. If runtime was not defined as a dependency of msbuild, then there's no guarantee that System.Text.Json will exist when it restores it. Based on timing, it may exist in one build and then not exist in another build. To solve this problem, the packages output from a repos build are placed in a repo-specific package location as a sub-directory of the package location (Shipping or NonShipping). Previously, all repos would output their packages to `artifacts/packages/Release/[NonShipping|Shipping]`. With these changes, they output to `artifacts/packages/Release/[NonShipping|Shipping]/<repo-name>`. This isolates all packages on a per-repo basis. The next step is to provide access to these packages based on dependencies. Going back to msbuild's dependency on runtime, this is accomplished by modifying msbuild's nuget.config file to include feeds specific to runtime: ```xml <add key="source-built-runtime" value="/vmr/artifacts/packages/Release/Shipping/runtime/" /> <add key="source-built-transport-runtime" value="/vmr/artifacts/packages/Release/NonShipping/runtime/" /> ```
2024-02-22 10:25:55 -06:00
</ItemGroup>
<ItemGroup Condition="'$(DotNetBuildSourceOnly)' == 'true'">
<RepositoryReference Include="msbuild" />
<RepositoryReference Include="runtime" />
<RepositoryReference Include="source-build-reference-packages" />
</ItemGroup>
</Project>