<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <!-- Source of truth for dependency tooling: the commit hash of the dotnet/versions master branch as of the last auto-upgrade. -->

  <!-- For detailed explanation of the reference versions see:

        https://github.com/dotnet/buildtools/blob/master/Documentation/project-nuget-dependencies.md
        https://github.com/dotnet/buildtools/blob/master/Documentation/annotated-dependency-props.md

       These ref versions are pulled from https://github.com/dotnet/versions.
  -->
  <PropertyGroup>
    <CoreFxCurrentRef>88565452637e4312f259161d5006ef24870858c7</CoreFxCurrentRef>
    <CoreClrCurrentRef>88565452637e4312f259161d5006ef24870858c7</CoreClrCurrentRef>
    <CoreSetupCurrentRef>88565452637e4312f259161d5006ef24870858c7</CoreSetupCurrentRef>
    <ExternalCurrentRef>96dc7805f5df4a70a55783964ce69dcd91bfca80</ExternalCurrentRef>
    <ProjectNTfsCurrentRef>ccd922b62227c43ed2dac6bcb737321dd2b07be0</ProjectNTfsCurrentRef>
    <ProjectNTfsTestILCCurrentRef>ccd922b62227c43ed2dac6bcb737321dd2b07be0</ProjectNTfsTestILCCurrentRef>
    <SniCurrentRef>8bd1ec5fac9f0eec34ff6b34b1d878b4359e02dd</SniCurrentRef>
    <StandardCurrentRef>eff554f39ee29c9f2b470bf7755b83ceaaf2b1a1</StandardCurrentRef>
    <BuildToolsCurrentRef>923fc4e4aade5e96f0ebdbd76edfa36dd0a2985c</BuildToolsCurrentRef>
  </PropertyGroup>

  <!-- Product dependency versions. -->
  <PropertyGroup>
    <NETStandardLibraryPackageVersion>2.0.3</NETStandardLibraryPackageVersion>
    <NETStandardLibraryPackageId>NETStandard.Library</NETStandardLibraryPackageId>

    <!-- SNI runtime package -->
    <RuntimeWinX64RuntimeNativeSystemDataSqlClientSniPackageVersion>4.4.0</RuntimeWinX64RuntimeNativeSystemDataSqlClientSniPackageVersion>
  </PropertyGroup>

  <!-- Tests/infrastructure dependency versions. -->
  <PropertyGroup>
    <CoreFxExpectedPrerelease>rtm-26508-03</CoreFxExpectedPrerelease>
    <MicrosoftNETCorePlatformsPackageVersion>2.1.0-rtm-26508-03</MicrosoftNETCorePlatformsPackageVersion>
    <MicrosoftNETCoreRuntimeCoreCLRPackageVersion>2.1.0-rtm-26508-04</MicrosoftNETCoreRuntimeCoreCLRPackageVersion>
    <ProjectNTfsExpectedPrerelease>beta-26413-00</ProjectNTfsExpectedPrerelease>
    <ProjectNTfsTestILCExpectedPrerelease>beta-26413-00</ProjectNTfsTestILCExpectedPrerelease>
    <ProjectNTfsTestILCPackageVersion>1.0.0-beta-26413-00</ProjectNTfsTestILCPackageVersion>
    <MicrosoftNETCoreDotNetHostPackageVersion>2.1.0-rtm-26508-02</MicrosoftNETCoreDotNetHostPackageVersion>
    <MicrosoftNETCoreDotNetHostPolicyPackageVersion>2.1.0-rtm-26508-02</MicrosoftNETCoreDotNetHostPolicyPackageVersion>
    <MicrosoftNETCoreAppPackageVersion>2.1.0-rtm-26508-02</MicrosoftNETCoreAppPackageVersion>

    <!-- CoreFX-built SNI identity package -->
    <RuntimeNativeSystemDataSqlClientSniPackageVersion>4.4.0</RuntimeNativeSystemDataSqlClientSniPackageVersion>

    <AppXRunnerVersion>1.0.3-prerelease-00921-01</AppXRunnerVersion>
    <XunitPerfAnalysisPackageVersion>1.0.0-beta-build0018</XunitPerfAnalysisPackageVersion>
    <TraceEventPackageVersion>2.0.5</TraceEventPackageVersion>
    <XunitNetcoreExtensionsVersion>2.1.0-rc1-02804-05</XunitNetcoreExtensionsVersion>
    
    <!-- Roslyn optimization data package version -->
    <OptimizationDataVersion>2.0.0-rc-61101-17</OptimizationDataVersion>
  </PropertyGroup>

  <!-- Package versions used as toolsets -->
  <PropertyGroup>
    <FeedTasksPackage>Microsoft.DotNet.Build.Tasks.Feed</FeedTasksPackage>
    <FeedTasksPackageVersion>2.1.0-rc1-02804-05</FeedTasksPackageVersion>
  </PropertyGroup>

  <!-- Publish symbol build task package -->
  <PropertyGroup>
    <PublishSymbolsPackage>Microsoft.SymbolUploader.Build.Task</PublishSymbolsPackage>
    <PublishSymbolsPackageVersion>1.0.0-beta-62806-01</PublishSymbolsPackageVersion>
  </PropertyGroup>

  <!-- Package dependency verification/auto-upgrade configuration. -->
  <PropertyGroup>
    <BaseDotNetBuildInfo>build-info/dotnet/</BaseDotNetBuildInfo>
    <DependencyBranch>release/2.1</DependencyBranch>
    <CurrentRefXmlPath>$(MSBuildThisFileFullPath)</CurrentRefXmlPath>
  </PropertyGroup>

  <ItemGroup>
    <RemoteDependencyBuildInfo Include="CoreFx">
      <BuildInfoPath>$(BaseDotNetBuildInfo)corefx/$(DependencyBranch)</BuildInfoPath>
      <CurrentRef>$(CoreFxCurrentRef)</CurrentRef>
    </RemoteDependencyBuildInfo>
    <RemoteDependencyBuildInfo Include="CoreClr">
      <BuildInfoPath>$(BaseDotNetBuildInfo)coreclr/$(DependencyBranch)</BuildInfoPath>
      <CurrentRef>$(CoreClrCurrentRef)</CurrentRef>
    </RemoteDependencyBuildInfo>
    <RemoteDependencyBuildInfo Include="CoreSetup">
      <BuildInfoPath>$(BaseDotNetBuildInfo)core-setup/$(DependencyBranch)</BuildInfoPath>
      <CurrentRef>$(CoreSetupCurrentRef)</CurrentRef>
    </RemoteDependencyBuildInfo>
    <!--
    <RemoteDependencyBuildInfo Include="External">
      <BuildInfoPath>$(BaseDotNetBuildInfo)projectk-tfs/$(DependencyBranch)</BuildInfoPath>
      <CurrentRef>$(ExternalCurrentRef)</CurrentRef>
    </RemoteDependencyBuildInfo>
    <RemoteDependencyBuildInfo Include="Sni">
      <BuildInfoPath>$(BaseDotNetBuildInfo)sni/$(DependencyBranch)</BuildInfoPath>
      <CurrentRef>$(SniCurrentRef)</CurrentRef>
    </RemoteDependencyBuildInfo>
    -->
    <RemoteDependencyBuildInfo Include="Standard">
      <BuildInfoPath>$(BaseDotNetBuildInfo)standard/release/2.0.0</BuildInfoPath>
      <CurrentRef>$(StandardCurrentRef)</CurrentRef>
    </RemoteDependencyBuildInfo>
    <!--
    <RemoteDependencyBuildInfo Include="ProjectNTfs">
      <BuildInfoPath>$(BaseDotNetBuildInfo)projectn-tfs/$(DependencyBranch)</BuildInfoPath>
      <CurrentRef>$(ProjectNTfsCurrentRef)</CurrentRef>
    </RemoteDependencyBuildInfo>
    <RemoteDependencyBuildInfo Include="ProjectNTfsTestILC">
      <BuildInfoPath>$(BaseDotNetBuildInfo)projectn-tfs-testilc/$(DependencyBranch)</BuildInfoPath>
      <CurrentRef>$(ProjectNTfsTestILCCurrentRef)</CurrentRef>
    </RemoteDependencyBuildInfo>
    -->
    <RemoteDependencyBuildInfo Include="BuildTools">
      <BuildInfoPath>$(BaseDotNetBuildInfo)buildtools/$(DependencyBranch)</BuildInfoPath>
      <CurrentRef>$(BuildToolsCurrentRef)</CurrentRef>
    </RemoteDependencyBuildInfo>

    <DependencyBuildInfo Include="@(RemoteDependencyBuildInfo)">
      <RawVersionsBaseUrl>https://raw.githubusercontent.com/dotnet/versions</RawVersionsBaseUrl>
    </DependencyBuildInfo>

    <XmlUpdateStep Include="CoreFx">
      <Path>$(MSBuildThisFileFullPath)</Path>
      <ElementName>CoreFxExpectedPrerelease</ElementName>
      <BuildInfoName>CoreFx</BuildInfoName>
    </XmlUpdateStep>
    <XmlUpdateStep Include="CoreFx">
      <Path>$(MSBuildThisFileFullPath)</Path>
      <ElementName>MicrosoftNETCorePlatformsPackageVersion</ElementName>
      <PackageId>Microsoft.NETCore.Platforms</PackageId>
    </XmlUpdateStep>
    <XmlUpdateStep Include="CoreClr">
      <Path>$(MSBuildThisFileFullPath)</Path>
      <ElementName>MicrosoftNETCoreRuntimeCoreCLRPackageVersion</ElementName>
      <PackageId>Microsoft.NETCore.Runtime.CoreCLR</PackageId>
    </XmlUpdateStep>
    <XmlUpdateStep Include="Standard">
      <Path>$(MSBuildThisFileFullPath)</Path>
      <ElementName>NETStandardLibraryPackageVersion</ElementName>
      <PackageId>$(NETStandardLibraryPackageId)</PackageId>
    </XmlUpdateStep>
    <!--
    <XmlUpdateStep Include="ProjectNTfs">
      <Path>$(MSBuildThisFileFullPath)</Path>
      <ElementName>ProjectNTfsExpectedPrerelease</ElementName>
      <BuildInfoName>ProjectNTfs</BuildInfoName>
    </XmlUpdateStep>
    <XmlUpdateStep Include="ProjectNTfsTestILC">
      <Path>$(MSBuildThisFileFullPath)</Path>
      <ElementName>ProjectNTfsTestILCExpectedPrerelease</ElementName>
      <BuildInfoName>ProjectNTfsTestILC</BuildInfoName>
    </XmlUpdateStep>
    <XmlUpdateStep Include="ProjectNTfsTestILC">
      <Path>$(MSBuildThisFileFullPath)</Path>
      <ElementName>ProjectNTfsTestILCPackageVersion</ElementName>
      <PackageId>TestILC.amd64ret</PackageId>
    </XmlUpdateStep>
    <XmlUpdateStep Include="Sni">
      <Path>$(MSBuildThisFileFullPath)</Path>
      <ElementName>RuntimeWinX64RuntimeNativeSystemDataSqlClientSniPackageVersion</ElementName>
      <PackageId>runtime.win-x64.runtime.native.System.Data.SqlClient.sni</PackageId>
    </XmlUpdateStep>
    -->
    <XmlUpdateStep Include="CoreSetup">
      <Path>$(MSBuildThisFileFullPath)</Path>
      <ElementName>MicrosoftNETCoreDotNetHostPackageVersion</ElementName>
      <PackageId>Microsoft.NETCore.DotNetHost</PackageId>
    </XmlUpdateStep>
    <XmlUpdateStep Include="CoreSetup">
      <Path>$(MSBuildThisFileFullPath)</Path>
      <ElementName>MicrosoftNETCoreDotNetHostPolicyPackageVersion</ElementName>
      <PackageId>Microsoft.NETCore.DotNetHostPolicy</PackageId>
    </XmlUpdateStep>
    <XmlUpdateStep Include="CoreSetup">
      <Path>$(MSBuildThisFileFullPath)</Path>
      <ElementName>MicrosoftNETCoreAppPackageVersion</ElementName>
      <PackageId>Microsoft.NETCore.App</PackageId>
    </XmlUpdateStep>
    <UpdateStep Include="BuildTools">
      <UpdaterType>File</UpdaterType>
      <Path>$(MSBuildThisFileDirectory)BuildToolsVersion.txt</Path>
      <PackageId>Microsoft.DotNet.BuildTools</PackageId>
    </UpdateStep>
    <UpdateStep Include="BuildTools">
      <UpdaterType>File</UpdaterType>
      <Path>$(MSBuildThisFileDirectory)tools-local/ILAsmVersion.txt</Path>
      <PackageId>Microsoft.NETCore.ILAsm</PackageId>
    </UpdateStep>
    <XmlUpdateStep Include="BuildTools">
       <Path>$(MSBuildThisFileFullPath)</Path>
       <ElementName>XunitNetcoreExtensionsVersion</ElementName>
       <PackageId>Microsoft.xunit.netcore.extensions</PackageId>
     </XmlUpdateStep>
     <XmlUpdateStep Include="BuildTools">
       <Path>$(MSBuildThisFileFullPath)</Path>
       <ElementName>FeedTasksPackageVersion</ElementName>
       <PackageId>$(FeedTasksPackage)</PackageId>
     </XmlUpdateStep>
  </ItemGroup>

  <PropertyGroup>
    <XUnitPackageVersion>2.3.0-beta1-build3642</XUnitPackageVersion>
    <CompatibilityShimsPackageVersion>2.0.0</CompatibilityShimsPackageVersion>
  </PropertyGroup>

  <!-- Set up dependencies on packages that aren't found in a BuildInfo. -->
  <ItemGroup>
    <TargetingPackDependency Include="Microsoft.TargetingPack.NETFramework.v4.5" />
    <TargetingPackDependency Include="Microsoft.TargetingPack.NETFramework.v4.5.1" />
    <TargetingPackDependency Include="Microsoft.TargetingPack.NETFramework.v4.5.2" />
    <TargetingPackDependency Include="Microsoft.TargetingPack.NETFramework.v4.6" />
    <TargetingPackDependency Include="Microsoft.TargetingPack.NETFramework.v4.6.1" />
    <TargetingPackDependency Include="Microsoft.TargetingPack.NETFramework.v4.6.2" />
    <StaticDependency Include="@(TargetingPackDependency)">
      <Version>1.0.1</Version>
    </StaticDependency>

    <StaticDependency Include="Microsoft.TargetingPack.Private.WinRT">
      <Version>1.0.5</Version>
    </StaticDependency>

    <XUnitDependency Include="xunit"/>
    <XUnitDependency Include="xunit.runner.utility"/>
    <XUnitDependency Include="xunit.runner.console"/>
    <StaticDependency Include="@(XUnitDependency)">
      <Version>$(XUnitPackageVersion)</Version>
    </StaticDependency>

    <StaticDependency Include="Microsoft.xunit.netcore.extensions;Microsoft.DotNet.BuildTools.TestSuite">
      <Version>$(XunitNetcoreExtensionsVersion)</Version>
    </StaticDependency>

    <PerformancePackDependency Include="xunit.performance.core" />
    <PerformancePackDependency Include="xunit.performance.api" />
    <PerformancePackDependency Include="xunit.performance.execution" />
    <PerformancePackDependency Include="xunit.performance.metrics" />
    <StaticDependency Include="@(PerformancePackDependency)">
      <Version>$(XunitPerfAnalysisPackageVersion)</Version>
    </StaticDependency>

    <DependencyBuildInfo Include="@(StaticDependency)">
      <PackageId>%(Identity)</PackageId>
      <UpdateStableVersions>true</UpdateStableVersions>
    </DependencyBuildInfo>

    <DependencyBuildInfo Include="uwpRunnerVersion">
      <PackageId>microsoft.xunit.runner.uwp</PackageId>
      <Version>$(AppXRunnerVersion)</Version>
    </DependencyBuildInfo>

    <!-- project.json files to update -->
    <ProjectJsonFiles Include="$(MSBuildThisFileDirectory)external\**\optional.json" />
  </ItemGroup>

  <!-- Override isolated build dependency versions with versions from Repo API. -->
  <Import Project="$(DotNetPackageVersionPropsPath)"
          Condition="'$(DotNetPackageVersionPropsPath)' != ''" />

  <!--
    Map PackageVersion properties that don't match the Repo API naming conventions. This must be
    defined after the DotNetPackageVersionPropsPath Import so overrides apply correctly.
  -->
  <PropertyGroup>
    <!-- Backward compatibility for BuildTools usage. -->
    <PlatformPackageVersion>$(MicrosoftNETCorePlatformsPackageVersion)</PlatformPackageVersion>
  </PropertyGroup>
</Project>
