File: C\Users\cloudtest\.nuget\packages\microsoft.dotnet.arcade.sdk\9.0.0-beta.24516.2\tools\GenerateInternalsVisibleTo.targets
Project: ..\..\..\src\Package\DevDivPackage\DevDivPackage.csproj (MSBuildFiles)
<!-- Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. -->
<Project>
 
  <PropertyGroup>
    <GeneratedInternalsVisibleToFile>$(IntermediateOutputPath)$(MSBuildProjectName).InternalsVisibleTo$(DefaultLanguageSourceExtension)</GeneratedInternalsVisibleToFile>
  </PropertyGroup>
 
  <ItemDefinitionGroup>
    <InternalsVisibleTo>
      <Visible>false</Visible>
    </InternalsVisibleTo>
  </ItemDefinitionGroup>
 
  <Target Name="PrepareGenerateInternalsVisibleToFile" Condition="'@(InternalsVisibleTo)' != ''">
    <ItemGroup>
      <_InternalsVisibleToAttribute Include="System.Runtime.CompilerServices.InternalsVisibleToAttribute">
        <_Parameter1 Condition="'%(InternalsVisibleTo.Key)' != ''">%(InternalsVisibleTo.Identity), PublicKey=%(InternalsVisibleTo.Key)</_Parameter1>
        <_Parameter1 Condition="'%(InternalsVisibleTo.Key)' == '' and '$(PublicKey)' != ''">%(InternalsVisibleTo.Identity), PublicKey=$(PublicKey)</_Parameter1>
        <_Parameter1 Condition="'%(InternalsVisibleTo.Key)' == '' and '$(PublicKey)' == ''">%(InternalsVisibleTo.Identity)</_Parameter1>
      </_InternalsVisibleToAttribute>
    </ItemGroup>
  </Target>
 
  <!--
    Dependency on PrepareForBuild is necessary so that we don't accidentally get ordered before it.
    We rely on PrepareForBuild to create the IntermediateOutputDirectory if it doesn't exist.
 
    Must run before BeforeCompile, as it's the MSBuild's convention for code generators.
  -->
  <Target Name="GenerateInternalsVisibleToFile"
          Inputs="$(MSBuildThisFileFullPath);$(MSBuildProjectFile)"
          Outputs="$(GeneratedInternalsVisibleToFile)"
          DependsOnTargets="PrepareGenerateInternalsVisibleToFile;PrepareForBuild"
          Condition="'@(InternalsVisibleTo)' != ''"
          BeforeTargets="BeforeCompile;CoreCompile">
 
    <WriteCodeFragment AssemblyAttributes="@(_InternalsVisibleToAttribute)"
                       Language="$(Language)"
                       OutputFile="$(GeneratedInternalsVisibleToFile)">
      <Output TaskParameter="OutputFile" ItemName="CompileBefore" Condition="'$(Language)' == 'F#'" />
      <Output TaskParameter="OutputFile" ItemName="Compile" Condition="'$(Language)' != 'F#'" />
      <Output TaskParameter="OutputFile" ItemName="FileWrites" />
    </WriteCodeFragment>
  </Target>
 
</Project>