Skip to content

Commit

Permalink
Addressing Minor Cleanup (dotnet#31845)
Browse files Browse the repository at this point in the history
* addressing viktor feedback

* Update System.Reflection.Emit.ILGeneration.csproj

* Update tests.proj

* Update System.Reflection.Emit.Lightweight.csproj

* Update System.Xml.XPath.XDocument.Tests.csproj

* fixing emit projects, making them similar before config change

Co-authored-by: Viktor Hofer <[email protected]>
  • Loading branch information
Anipik and ViktorHofer authored Feb 7, 2020
1 parent 796d36a commit c0e876f
Show file tree
Hide file tree
Showing 22 changed files with 19 additions and 54 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFrameworks>netcoreapp3.0</TargetFrameworks>
<TargetFramework>netcoreapp3.0</TargetFramework>
<EnableDefaultItems>false</EnableDefaultItems>
<LangVersion>preview</LangVersion>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
<NoWarn>$(NoWarn);CS1573</NoWarn>
<DefineConstants>$(DefineConstants);REGISTRY_ASSEMBLY</DefineConstants>
<IsPartialFacadeAssembly Condition="'$(TargetsNetFx)' == 'true'">true</IsPartialFacadeAssembly>
<GeneratePlatformNotSupportedAssemblyMessage Condition="'$(TargetFrameworkSuffix)' == '' and '$(TargetsNetStandard)' == 'true'">SR.PlatformNotSupported_Registry</GeneratePlatformNotSupportedAssemblyMessage>
<GeneratePlatformNotSupportedAssemblyMessage Condition="'$(TargetsAnyOS)' == 'true' and '$(TargetsNetStandard)' == 'true'">SR.PlatformNotSupported_Registry</GeneratePlatformNotSupportedAssemblyMessage>
<NoWarn Condition="'$(TargetsUnix)' == 'true'">$(NoWarn);CA1823</NoWarn> <!-- Avoid unused fields warnings in Unix build -->
<TargetFrameworks>netstandard2.0-Windows_NT;netstandard2.0-Unix;netstandard2.0;net461-Windows_NT;$(NetCoreAppCurrent)-Windows_NT;$(NetCoreAppCurrent)-Unix;$(NetFrameworkCurrent)-Windows_NT</TargetFrameworks>
<ExcludeCurrentNetCoreApp>true</ExcludeCurrentNetCoreApp>
<ExcludeCurrentFullFramework>true</ExcludeCurrentFullFramework>
</PropertyGroup>
<ItemGroup Condition="'$(TargetsNetFx)' != 'true' and '$(TargetFrameworkSuffix)' != ''">
<ItemGroup Condition="'$(TargetsNetFx)' != 'true' and '$(TargetsAnyOS)' != 'true'">
<Compile Include="$(CommonPath)Interop\Windows\Advapi32\Interop.RegistryConstants.cs">
<Link>Common\Interop\Windows\Advapi32\Interop.RegistryConstants.cs</Link>
</Compile>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<IsPartialFacadeAssembly Condition="'$(TargetsNetFx)' == 'true'">true</IsPartialFacadeAssembly>
<Nullable>enable</Nullable>
<GeneratePlatformNotSupportedAssemblyMessage Condition="'$(TargetsNetStandard)' == 'true' and '$(TargetFrameworkSuffix)' == ''">SR.PlatformNotSupported_SystemEvents</GeneratePlatformNotSupportedAssemblyMessage>
<GeneratePlatformNotSupportedAssemblyMessage Condition="'$(TargetsNetStandard)' == 'true' and '$(TargetsAnyOS)' == 'true'">SR.PlatformNotSupported_SystemEvents</GeneratePlatformNotSupportedAssemblyMessage>
<TargetFrameworks>netstandard2.0;netcoreapp2.0-Windows_NT;netcoreapp3.0-Windows_NT;net461;$(NetCoreAppCurrent)-Windows_NT;$(NetFrameworkCurrent)</TargetFrameworks>
<ExcludeCurrentNetCoreApp>true</ExcludeCurrentNetCoreApp>
<ExcludeCurrentFullFramework>true</ExcludeCurrentFullFramework>
Expand Down
4 changes: 2 additions & 2 deletions src/libraries/System.Data.OleDb/src/System.Data.OleDb.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<NoWarn>$(NoWarn);CS1573</NoWarn>
<IsPartialFacadeAssembly Condition="'$(TargetsNetFx)' == 'true'">true</IsPartialFacadeAssembly>
<GeneratePlatformNotSupportedAssemblyMessage Condition="'$(TargetFrameworkSuffix)' == '' and '$(TargetsNetStandard)' == 'true'">SR.PlatformNotSupported_OleDb</GeneratePlatformNotSupportedAssemblyMessage>
<NoWarn Condition="'$(TargetFrameworkSuffix)' == '' and '$(TargetsNetStandard)' == 'true'">$(NoWarn);CS0618</NoWarn>
<GeneratePlatformNotSupportedAssemblyMessage Condition="'$(TargetsAnyOS)' == 'true' and '$(TargetsNetStandard)' == 'true'">SR.PlatformNotSupported_OleDb</GeneratePlatformNotSupportedAssemblyMessage>
<NoWarn Condition="'$(TargetsAnyOS)' == 'true' and '$(TargetsNetStandard)' == 'true'">$(NoWarn);CS0618</NoWarn>
<TargetFrameworks>netstandard2.0-Windows_NT;netstandard2.0;net461-Windows_NT;$(NetFrameworkCurrent)-Windows_NT</TargetFrameworks>
<ExcludeCurrentFullFramework>true</ExcludeCurrentFullFramework>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,4 +63,4 @@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -65,4 +65,4 @@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -65,4 +65,4 @@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
</Project>
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<DefineConstants Condition="'$(TargetsNetCoreApp)' == 'true'">$(DefineConstants);STREAM_MEMORY_OVERLOADS_AVAILABLE</DefineConstants>
<TargetFrameworks>$(NetCoreAppCurrent)-Unix;$(NetCoreAppCurrent)-Windows_NT</TargetFrameworks>
</PropertyGroup>
<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<!-- This constant is only here for usage in $(CommonTestPath), since not all projects using these tests have been updated yet-->
<DefineConstants>$(DefineConstants);STREAM_MEMORY_OVERLOADS_AVAILABLE</DefineConstants>
<TargetFrameworks>$(NetCoreAppCurrent)-Unix;$(NetCoreAppCurrent)-Windows_NT</TargetFrameworks>
</PropertyGroup>
<ItemGroup>
Expand Down
6 changes: 3 additions & 3 deletions src/libraries/System.IO.Ports/src/System.IO.Ports.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
<PropertyGroup>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<IsPartialFacadeAssembly Condition="'$(TargetsNetFx)' == 'true'">true</IsPartialFacadeAssembly>
<GeneratePlatformNotSupportedAssemblyMessage Condition="'$(TargetsNetStandard)' == 'true' and '$(TargetFrameworkSuffix)' == ''">SR.PlatformNotSupported_IOPorts</GeneratePlatformNotSupportedAssemblyMessage>
<GeneratePlatformNotSupportedAssemblyMessage Condition="'$(TargetsNetStandard)' == 'true' and '$(TargetsAnyOS)' == 'true'">SR.PlatformNotSupported_IOPorts</GeneratePlatformNotSupportedAssemblyMessage>
<DefineConstants>$(DefineConstants);NOSPAN</DefineConstants>
<IncludeDllSafeSearchPathAttribute>true</IncludeDllSafeSearchPathAttribute>
<Nullable>annotations</Nullable>
<TargetFrameworks>netstandard2.0-Windows_NT;netstandard2.0-Linux;netstandard2.0-OSX;netstandard2.0;net461-Windows_NT;netstandard2.0-FreeBSD;$(NetFrameworkCurrent)-Windows_NT</TargetFrameworks>
<ExcludeCurrentFullFramework>true</ExcludeCurrentFullFramework>
<ExcludeFromPackage Condition="'$(TargetFramework)' == 'netstandard2.0' AND '$(TargetFrameworkSuffix)' == 'FreeBSD'">true</ExcludeFromPackage>
<ExcludeFromPackage Condition="'$(TargetFramework)' == 'netstandard2.0' AND '$(TargetsFreeBSD)' == 'true'">true</ExcludeFromPackage>
</PropertyGroup>
<ItemGroup Condition="'$(TargetsNetStandard)' == 'true' and '$(TargetFrameworkSuffix)' != ''">
<ItemGroup Condition="'$(TargetsNetStandard)' == 'true' and '$(TargetsAnyOS)' != 'true'">
<Compile Include="System\IO\Ports\Handshake.cs" />
<Compile Include="System\IO\Ports\InternalResources.cs" />
<Compile Include="System\IO\Ports\Parity.cs" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@
<Compile Include="$(CommonPath)System\Net\Logging\NetEventSource.Common.cs">
<Link>Common\System\Net\Logging\NetEventSource.cs</Link>
</Compile>
<Compile Include="$(CommonPath)System\Net\Sockets\ProtocolType.cs" Condition="'$(TargetFrameworkSuffix)' == 'Windows_NT'">
<Compile Include="$(CommonPath)System\Net\Sockets\ProtocolType.cs" Condition="'$(TargetsWindows)' == 'true'">
<Link>Common\System\Net\Sockets\ProtocolType.cs</Link>
</Compile>
<Compile Include="$(CommonPath)System\Net\Sockets\SocketType.cs" Condition="'$(TargetFrameworkSuffix)' == 'Windows_NT'">
<Compile Include="$(CommonPath)System\Net\Sockets\SocketType.cs" Condition="'$(TargetsWindows)' == 'true'">
<Link>Common\System\Net\Sockets\SocketType.cs</Link>
</Compile>
<Compile Include="$(CommonPath)System\Net\IPEndPointStatics.cs">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,4 @@
<LastGenOutput>GenericVectorTests.cs</LastGenOutput>
</None>
</ItemGroup>
<ItemGroup>
<Content Include="GenericVectorTests.netcoreapp.tt">
<Generator>TextTemplatingFileGenerator</Generator>
<LastGenOutput>GenericVectorTests.netcoreapp.cs</LastGenOutput>
</Content>
</ItemGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<RootNamespace>System.Xml.XPath.XDocument.Tests</RootNamespace>
<CommonPathXPath>$(CommonPath)System\Xml\XPath</CommonPathXPath>
<TargetFrameworks>$(NetCoreAppCurrent)</TargetFrameworks>
<CommonPathXPath>$(CommonTestPath)System\Xml\XPath</CommonPathXPath>
</PropertyGroup>
Expand Down Expand Up @@ -193,5 +191,5 @@
<EmbeddedResource Include="$(CommonPathXPath)\TestData\xpC001.xml">
<Link>TestData\xpC001.xml</Link>
</EmbeddedResource>
</ItemGroup>
</ItemGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>$(NetCoreAppCurrent)</TargetFrameworks>
<ExcludeCurrentNetCoreApp>true</ExcludeCurrentNetCoreApp>
<Nullable>enable</Nullable>
</PropertyGroup>
<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@
<PropertyGroup>
<AssemblyName>System.Reflection.Emit.ILGeneration</AssemblyName>
<IsPartialFacadeAssembly>true</IsPartialFacadeAssembly>
<OmitResources>$(IsPartialFacadeAssembly)</OmitResources>
<TargetFrameworks>$(NetCoreAppCurrent)-Windows_NT;$(NetCoreAppCurrent)-Unix</TargetFrameworks>
<ExcludeCurrentNetCoreApp>true</ExcludeCurrentNetCoreApp>
<Nullable>enable</Nullable>
</PropertyGroup>
<ItemGroup>
<ReferenceFromRuntime Include="System.Private.CoreLib" />
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>$(NetCoreAppCurrent)</TargetFrameworks>
<ExcludeCurrentNetCoreApp>true</ExcludeCurrentNetCoreApp>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<Nullable>enable</Nullable>
</PropertyGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,10 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<AssemblyName>System.Reflection.Emit.Lightweight</AssemblyName>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<IsPartialFacadeAssembly>true</IsPartialFacadeAssembly>
<OmitResources>$(IsPartialFacadeAssembly)</OmitResources>
<TargetFrameworks>$(NetCoreAppCurrent)-Windows_NT;$(NetCoreAppCurrent)-Unix</TargetFrameworks>
<ExcludeCurrentNetCoreApp>true</ExcludeCurrentNetCoreApp>
<Nullable>enable</Nullable>
<TargetFrameworks>$(NetCoreAppCurrent)-Windows_NT;$(NetCoreAppCurrent)-Unix</TargetFrameworks>
</PropertyGroup>
<ItemGroup>
<ReferenceFromRuntime Include="System.Private.CoreLib" />
</ItemGroup>
</Project>
</Project>
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>$(NetCoreAppCurrent)</TargetFrameworks>
<ExcludeCurrentNetCoreApp>true</ExcludeCurrentNetCoreApp>
<Nullable>enable</Nullable>
</PropertyGroup>
<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OmitResources>$(IsPartialFacadeAssembly)</OmitResources>
<IsPartialFacadeAssembly>true</IsPartialFacadeAssembly>
<OmitResources>$(IsPartialFacadeAssembly)</OmitResources>
<TargetFrameworks>$(NetCoreAppCurrent)-Windows_NT;$(NetCoreAppCurrent)-Unix</TargetFrameworks>
<ExcludeCurrentNetCoreApp>true</ExcludeCurrentNetCoreApp>
<Nullable>enable</Nullable>
</PropertyGroup>
<ItemGroup>
<ReferenceFromRuntime Include="System.Private.CoreLib" />
Expand Down
11 changes: 0 additions & 11 deletions src/libraries/build.proj
Original file line number Diff line number Diff line change
Expand Up @@ -76,15 +76,4 @@

<Target Name="Rebuild" DependsOnTargets="Clean;Build" />

<!-- set up inputs for UpdateVSConfigurations in a target to avoid globbing all the time -->
<Target Name="_setProjectsToUpdate" BeforeTargets="UpdateVSConfigurations">
<ItemGroup>
<ProjectsToUpdate Include="$(MSBuildThisFileDirectory)**/*.*csproj"
Exclude="$(MSBuildThisFileDirectory)shims/**/*.*csproj"/>
<ProjectsToUpdate Include="$(MSBuildThisFileDirectory)**/*.*ilproj" />
<ProjectsToUpdate Include="$(MSBuildThisFileDirectory)**/*.*vbproj" />
<_solutionsToUpdateFiles Include="$(MSBuildThisFileDirectory)*/Directory.Build.props" />
<SolutionsToUpdate Include="@(_solutionsToUpdateFiles->'%(RootDir)%(Directory)')" Exclude="@(_solutionsToExcludeFromUpdate)" />
</ItemGroup>
</Target>
</Project>
2 changes: 1 addition & 1 deletion src/libraries/shims/manual/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<RefPath>$(ArtifactsBinDir)runtime/$(BuildTargetFramework)-$(OSGroup)-$(Configuration)-$(ArchGroup)/</RefPath>
<CoreCLROSGroup>$(OSGroup)</CoreCLROSGroup>
<MonoOSGroup>$(OSGroup)</MonoOSGroup>
<TargetFrameworks>netcoreapp5.0</TargetFrameworks>
<TargetFrameworks>$(NetCoreAppCurrent)</TargetFrameworks>
</PropertyGroup>

<ItemGroup>
Expand Down
1 change: 1 addition & 0 deletions src/libraries/tests.proj
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
<Project Condition="'$(DirectoryToBuild)' != ''" Include="$(DirectoryToBuild)\**\*.Tests.csproj" />
<Project Condition="'$(SkipTestRestore)' != 'true' and '$(DirectoryToBuild)' == ''" Include="$(MSBuildThisFileDirectory)*\tests\**\*.Tests.csproj" Exclude="@(ProjectExclusions)" />
<Project Condition="'$(SkipTestRestore)' == 'true' and '$(DirectoryToBuild)' == ''" Include="$(CommonTestPath)CoreFx.Private.TestUtilities\CoreFx.Private.TestUtilities.csproj" />
<Project Remove="$(CommonTestPath)System\Net\Prerequisites\**\*.csproj" />
</ItemGroup>

<ItemGroup Condition="'$(BuildAllConfigurations)' == 'true'">
Expand Down

0 comments on commit c0e876f

Please sign in to comment.