<Project Sdk="Microsoft.NET.Sdk">

  <PropertyGroup>
      <OutputType>Exe</OutputType>
      <AssemblyName>DafnyDriver</AssemblyName>
      <GenerateAssemblyInfo>false</GenerateAssemblyInfo>
      <DefineConstants>TRACE</DefineConstants>
      <TargetFramework>net6.0</TargetFramework>
<RollForward>Major</RollForward>
      <OutputPath>..\..\Binaries\</OutputPath>
      <ValidateExecutableReferencesMatchSelfContained>false</ValidateExecutableReferencesMatchSelfContained>

      <PackageLicenseExpression>MIT</PackageLicenseExpression>

      <IsPackable>true</IsPackable>
  </PropertyGroup>

  <PropertyGroup Condition="'$(Configuration)|$(TargetFramework)|$(Platform)'=='Debug|net6.0|AnyCPU'">
    <AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
    <AppendRuntimeIdentifierToOutputPath>false</AppendRuntimeIdentifierToOutputPath>
  </PropertyGroup>

  <!-- Working around some stange behavior in dotnet publish: https://github.com/dotnet/sdk/issues/10566 -->
  <PropertyGroup Condition="$(RUNTIME_IDENTIFIER) != ''">
    <RuntimeIdentifier>$(RUNTIME_IDENTIFIER)</RuntimeIdentifier>
  </PropertyGroup>
    
  <ItemGroup>
    <PackageReference Include="Microsoft.TestPlatform.Extensions.TrxLogger" Version="17.9.0" />
    <PackageReference Include="Microsoft.TestPlatform.TestHost" Version="17.9.0" />
    <PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
      
    <!-- Locking down versions that would otherwise be downgraded -->
    <PackageReference Include="System.Security.Principal.Windows" Version="4.6.0" />
    <PackageReference Include="System.Collections" Version="4.3.0" />
    <PackageReference Include="System.Diagnostics.Debug" Version="4.3.0" />
    <PackageReference Include="System.IO.FileSystem.Primitives" Version="4.3.0" />
    <PackageReference Include="System.Runtime.Handles" Version="4.3.0" />
    <PackageReference Include="System.Runtime.InteropServices" Version="4.3.0" />
    <PackageReference Include="System.Text.Encoding.Extensions" Version="4.3.0" />
    <PackageReference Include="System.Threading" Version="4.3.0" />
  </ItemGroup>
    
  <ItemGroup>
    <ProjectReference Include="..\DafnyCore\DafnyCore.csproj" />
    <ProjectReference Include="..\DafnyTestGeneration\DafnyTestGeneration.csproj" />
    <ProjectReference Include="..\DafnyServer\DafnyServer.csproj" />
  </ItemGroup>
  
  <ItemGroup>
    <EmbeddedResource Include="assets\coverage_report_template.html">
      <LogicalName>coverage_report_template.html</LogicalName>
    </EmbeddedResource>
    <EmbeddedResource Include="assets\coverage_report_index_template.html">
      <LogicalName>coverage_report_index_template.html</LogicalName>
    </EmbeddedResource>
    <EmbeddedResource Include="assets\.resources\*">
    </EmbeddedResource>
  </ItemGroup>  
  
</Project>
