moving more tfm dependent properties to targets file (#34532)
authorAnirudh Agnihotry <anirudhagnihotry098@gmail.com>
Tue, 7 Apr 2020 04:12:10 +0000 (21:12 -0700)
committerGitHub <noreply@github.com>
Tue, 7 Apr 2020 04:12:10 +0000 (21:12 -0700)
* moving more tfm dependent properties to targets file

* correct allconfig build

* shimrefpath -> runtime and indentation

eng/references.props [deleted file]
src/libraries/Directory.Build.props
src/libraries/Directory.Build.targets
src/libraries/Microsoft.VisualBasic.Core/src/Microsoft.VisualBasic.Core.vbproj
src/libraries/System.Numerics.Tensors/src/System.Numerics.Tensors.csproj
src/libraries/System.Text.Json/src/System.Text.Json.csproj
src/libraries/shims/manual/Directory.Build.props
src/libraries/shims/manual/System.Data.csproj
src/libraries/targetframework.props

diff --git a/eng/references.props b/eng/references.props
deleted file mode 100644 (file)
index 9c65f42..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-<Project>
-  <PropertyGroup>
-    <!--
-      The Microsoft.NET.Sdk defaults the AssemblySearchPaths earlier, so default
-      the correct search paths here. We are rather restrictive by design - only ref assemblies should
-      be resolved by default.
-    -->
-    <AssemblySearchPaths>$(AssemblySearchPaths);$(RefPath);{RawFileName}</AssemblySearchPaths>
-  </PropertyGroup>
-</Project>
\ No newline at end of file
index c190217..62f4e4a 100644 (file)
     <AdditionalBuildTargetFrameworks Condition="'$(DotNetBuildFromSource)' == 'true' and '$(BuildAllProjects)' == 'true'">$(AdditionalBuildTargetFrameworks);netstandard2.0</AdditionalBuildTargetFrameworks>
   </PropertyGroup>
 
-  <Import Project="$(RepositoryEngineeringDir)references.props" />
-
   <!-- Import it at the end of the props file to override the OutputPath for reference assemblies and use common directory props -->
   <Import Project="$(RepositoryEngineeringDir)referenceAssemblies.props" Condition="'$(IsReferenceAssembly)' == 'true'" />
 
     <!-- Workaround for https://github.com/microsoft/msbuild/issues/4474 -->
     <GenerateResourceUsePreserializedResources>false</GenerateResourceUsePreserializedResources>
 
-    <!-- Set the documentation output file globally. -->
-    <DocumentationFile Condition="'$(IsSourceProject)' == 'true' and '$(DocumentationFile)' == ''">$(OutputPath)$(MSBuildProjectName).xml</DocumentationFile>
-
     <!-- Clear the init locals flag on all src projects, except those in VB, where we can't use spans. -->
     <ILLinkClearInitLocals Condition="'$(IsSourceProject)' == 'true' and '$(Language)' != 'VB'">true</ILLinkClearInitLocals>
   </PropertyGroup>
index 896ee32..57a36f3 100644 (file)
@@ -1,5 +1,9 @@
 <Project InitialTargets="AddSkipGetTargetFrameworkToProjectReferences">
   <PropertyGroup>
+    <RefPath>$([MSBuild]::NormalizeDirectory('$(RefRootPath)', '$(TargetFramework)'))</RefPath>  
+  </PropertyGroup>
+  
+  <PropertyGroup>
     <CoreCLRTargetOS Condition="'$(CoreCLRTargetOS)' == ''">$(TargetOS)</CoreCLRTargetOS>
     <CoreCLRConfiguration Condition="'$(CoreCLRConfiguration)' == ''">$(Configuration)</CoreCLRConfiguration>
     <MonoTargetOS Condition="'$(MonoTargetOS)' == ''">$(TargetOS)</MonoTargetOS>
@@ -13,6 +17,8 @@
     <FileAlignment Condition="'$(FileAlignment)' == '512'" />
     <ErrorReport Condition="'$(ErrorReport)' == 'prompt'" />
     <WarningsAsErrors Condition="'$(WarningsAsErrors)' == 'NU1605'" />
+    <!-- Set the documentation output file globally. -->
+    <DocumentationFile Condition="'$(IsSourceProject)' == 'true' and '$(DocumentationFile)' == '' and '$(MSBuildProjectExtension)' != '.vbproj'">$(OutputPath)$(MSBuildProjectName).xml</DocumentationFile>
   </PropertyGroup>
 
   <PropertyGroup>
index e877434..3fe68cb 100644 (file)
@@ -16,8 +16,6 @@
     <NoStdLib>true</NoStdLib>
     <RemoveIntegerChecks>false</RemoveIntegerChecks>
     <RootNamespace />
-    <!-- Disable this as it seems to break windows builds for now. -->
-    <DocumentationFile />
     <!-- No plans to fix the analyzer issues. -->
     <EnableAnalyzers>false</EnableAnalyzers>
     <TargetFrameworks>$(NetCoreAppCurrent);$(NetCoreAppCurrent)-Windows_NT</TargetFrameworks>
index c4486a7..d56053c 100644 (file)
@@ -3,7 +3,6 @@
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
     <TargetFrameworks>netstandard2.0;netstandard1.1</TargetFrameworks>
     <ExcludeFromPackage Condition="'$(TargetFramework)' == 'netstandard2.0'">true</ExcludeFromPackage>
-    <DocumentationFile>$(OutputPath)$(MSBuildProjectName).xml</DocumentationFile>
     <RootNamespace>System.Numerics.Tensors</RootNamespace>
   </PropertyGroup>
   <PropertyGroup>
index 5ba0ea9..82d1d7f 100644 (file)
@@ -1,7 +1,6 @@
 <Project Sdk="Microsoft.NET.Sdk">
   <PropertyGroup>
     <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
-    <DocumentationFile>$(OutputPath)$(MSBuildProjectName).xml</DocumentationFile>
     <TargetFrameworks>$(NetCoreAppCurrent);netstandard2.0;netcoreapp3.0;net461;$(NetFrameworkCurrent)</TargetFrameworks>
     <ExcludeCurrentNetCoreAppFromPackage>true</ExcludeCurrentNetCoreAppFromPackage>
     <ExcludeCurrentFullFrameworkFromPackage>true</ExcludeCurrentFullFrameworkFromPackage>
index b29cb02..3b6d856 100644 (file)
@@ -13,8 +13,6 @@
     <IsRuntimeAssembly>true</IsRuntimeAssembly>
     <BaseIntermediateOutputPath>$([MSBuild]::NormalizeDirectory('$(ArtifactsObjDir)', '$(OutDirName)'))</BaseIntermediateOutputPath>
     <IntermediateOutputPath>$(BaseIntermediateOutputPath)$(TargetFramework)-$(Configuration)</IntermediateOutputPath>
-    <!-- Use runtime assemblies for the TargetFramework, using TargetOS -->
-    <RefPath>$(ArtifactsBinDir)runtime/$(BuildTargetFramework)-$(TargetOS)-$(Configuration)-$(TargetArchitecture)/</RefPath>
     <CoreCLRTargetOS>$(TargetOS)</CoreCLRTargetOS>
     <MonoTargetOS>$(TargetOS)</MonoTargetOS>
     <TargetFrameworks>$(NetCoreAppCurrent)</TargetFrameworks>
@@ -22,8 +20,8 @@
 
   <ItemGroup>
     <ReferencePath
-      Include="$(RefPath)System.*.dll;$(RefPath)Microsoft.Win32.*.dll;$(RefPath)netstandard.dll"
-      Exclude="$(RefPath)$(MSBuildProjectName).dll" />
+      Include="$(RuntimePath)System.*.dll;$(RuntimePath)Microsoft.Win32.*.dll;$(RuntimePath)netstandard.dll"
+      Exclude="$(RuntimePath)$(MSBuildProjectName).dll" />
   </ItemGroup>
 
   <Target Name="AddSystemPrivateCoreLibReferencePath" DependsOnTargets="GetFilesFromRuntime" BeforeTargets="ResolveReferences">
index aafe7e5..417d9bf 100644 (file)
@@ -4,7 +4,7 @@
   </ItemGroup>
   <ItemGroup>
     <!-- System.Data.SqlClient is not live built anymore, make sure to use reference assembly for it -->
-    <ReferencePath Remove="$(RefPath)\System.Data.SqlClient.dll" />
+    <ReferencePath Remove="$(RuntimePath)\System.Data.SqlClient.dll" />
     <ReferencePath Include="$(ArtifactsBinDir)ref\$(NetCoreAppCurrent)\System.Data.SqlClient.dll" />
   </ItemGroup>
 </Project>
index dc89781..8086c3e 100644 (file)
   </PropertyGroup>
   
   <PropertyGroup>
-    <!-- interop is not available on NETStandard1.0 -->
-    <IncludeDllSafeSearchPathAttribute Condition="'$(TargetFramework)' == 'netstandard1.0'">false</IncludeDllSafeSearchPathAttribute>
-  </PropertyGroup>
-
-  <PropertyGroup>
-    <RefPath>$([MSBuild]::NormalizeDirectory('$(RefRootPath)', '$(TargetFramework)'))</RefPath>
     <IntermediateOutputPath>$(BaseIntermediateOutputPath)$(TargetFramework)-$(TargetFrameworkSuffix)-$(Configuration)\</IntermediateOutputPath>
     <IntermediateOutputPath Condition="'$(TargetFrameworkSuffix)' == ''">$(BaseIntermediateOutputPath)$(TargetFramework)-$(Configuration)\</IntermediateOutputPath>
     <!-- setting the output paths -->