Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@
<WarningsNotAsErrors>$(WarningsNotAsErrors);CS1591</WarningsNotAsErrors>
<!-- xUnit1004 = warns about skipped tests. Make this a non-fatal build warning. -->
<WarningsNotAsErrors>$(WarningsNotAsErrors);xUnit1004</WarningsNotAsErrors>
<!-- Working around https://github.com/NuGet/Home/issues/8467 -->
<NoWarn>$(NoWarn);NU5131</NoWarn>
<!-- Needed until we resolve https://github.com/aspnet/AspNetCore-Internal/issues/3103 -->
<NoWarn>$(NoWarn);NU5048</NoWarn>
</PropertyGroup>

<!-- Source code settings -->
Expand Down
20 changes: 19 additions & 1 deletion eng/Workarounds.targets
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
<!-- Use this file to workaround issues. List the issue tracking the item to fix so we can remove the workaround when the issue is resolved. -->
<Project>

<PropertyGroup>
<NETCoreAppMaximumVersion>5.0</NETCoreAppMaximumVersion>
</PropertyGroup>
<!--
Workaround https://github.com/aspnet/AspNetCore/issues/4257.
The web sdk adds an implicit framework reference. This removes it until we can update our build to use framework references.
-->
<ItemGroup>
<FrameworkReference Remove="Microsoft.AspNetCore.App" />
<KnownFrameworkReference Remove="Microsoft.AspNetCore.App" />
<!-- Required because the Razor SDK will generate attributes -->
<Reference Include="Microsoft.AspNetCore.Mvc" Condition="'$(UsingMicrosoftNETSdkWeb)' == 'true' AND '$(TargetFrameworkIdentifier)' == '.NETCoreApp' AND '$(GenerateRazorAssemblyInfo)' == 'true'" />
</ItemGroup>
Expand All @@ -25,6 +29,20 @@
<PackageReference Include="Internal.AspNetCore.BuildTasks" PrivateAssets="All" Version="$(InternalAspNetCoreBuildTasksPackageVersion)" IsImplicitlyDefined="true" />
</ItemGroup>

<ItemGroup>
<!-- Workaround when there is no vNext SDK available, copy known apphost/framework reference info from 3.0 -->
<KnownAppHostPack
Include="@(KnownAppHostPack->WithMetadataValue('TargetFramework', 'netcoreapp3.0'))"
TargetFramework="$(DefaultNetCoreTargetFramework)"
Condition="(@(KnownAppHostPack->Count()) != '0') AND (!(@(KnownAppHostPack->AnyHaveMetadataValue('TargetFramework', '$(DefaultNetCoreTargetFramework)'))))"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why the extra layer of parentheses around both of the AND'ed clauses?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Paranoia 😆

/>
<KnownFrameworkReference
Include="@(KnownFrameworkReference->WithMetadataValue('TargetFramework', 'netcoreapp3.0'))"
TargetFramework="$(DefaultNetCoreTargetFramework)"
Condition="(@(KnownFrameworkReference->Count()) != '0') AND (!(@(KnownFrameworkReference->AnyHaveMetadataValue('TargetFramework', '$(DefaultNetCoreTargetFramework)'))))"
/>
</ItemGroup>

<!-- Workaround for netstandard2.1 projects until we can get a preview 8 SDK containing https://github.com/dotnet/sdk/pull/3463 fix. -->
<ItemGroup>
<KnownFrameworkReference Update="NETStandard.Library">
Expand Down
4 changes: 2 additions & 2 deletions global.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"sdk": {
"version": "5.0.100-alpha1-013788"
"version": "5.0.100-alpha1-014696"
},
"tools": {
"dotnet": "5.0.100-alpha1-013788",
"dotnet": "5.0.100-alpha1-014696",
"runtimes": {
"dotnet/x64": [
"$(MicrosoftNETCoreAppRuntimeVersion)"
Expand Down