|
3 | 3 | <PropertyGroup Condition="$(TargetFramework.Contains('-'))">
|
4 | 4 | <_OriginalTargetFramework>$(TargetFramework)</_OriginalTargetFramework>
|
5 | 5 | <TargetFrameworkSuffix>$(TargetFramework.SubString($([MSBuild]::Add($(TargetFramework.IndexOf('-')), 1))))</TargetFrameworkSuffix>
|
6 |
| - <TargetFramework>$(TargetFramework.SubString(0, $(TargetFramework.IndexOf('-'))))</TargetFramework> |
| 6 | + <!-- Strip away the TargetPlatform during the build for frameworks older than net5.0 because the assets file does not know about the TargetPlatform --> |
| 7 | + <TargetFramework>$([System.Text.RegularExpressions.Regex]::Replace('$(TargetFramework)', '$(TargetFrameworkPattern)', '${1}'))</TargetFramework> |
7 | 8 | </PropertyGroup>
|
8 | 9 |
|
9 | 10 | <Import Project="$(MSBuildThisDirectory)targetframeworksuffix.props" Condition="'$(DesignTimeBuild)' == 'true'" />
|
10 | 11 |
|
11 | 12 | <PropertyGroup>
|
12 |
| - <IntermediateOutputPath>$([MSBuild]::NormalizeDirectory('$(BaseIntermediateOutputPath)', '$(TargetFramework)-$(TargetFrameworkSuffix)-$(Configuration)'))</IntermediateOutputPath> |
13 |
| - <IntermediateOutputPath Condition="'$(TargetFrameworkSuffix)' == ''">$([MSBuild]::NormalizeDirectory('$(BaseIntermediateOutputPath)', '$(TargetFramework)-$(Configuration)'))</IntermediateOutputPath> |
| 13 | + <IntermediateOutputPath>$([MSBuild]::NormalizeDirectory('$(BaseIntermediateOutputPath)', '$(TargetFramework)-$(Configuration)'))</IntermediateOutputPath> |
| 14 | + <IntermediateOutputPath Condition="'$(TargetFrameworkSuffix)' != '' and !$(TargetFramework.Contains('-'))">$([MSBuild]::NormalizeDirectory('$(BaseIntermediateOutputPath)', '$(TargetFramework)-$(TargetFrameworkSuffix)-$(Configuration)'))</IntermediateOutputPath> |
14 | 15 | <!-- setting the output paths -->
|
15 |
| - <OutputPath>$([MSBuild]::NormalizeDirectory('$(BaseOutputPath)', '$(TargetFramework)-$(TargetFrameworkSuffix)-$(Configuration)'))</OutputPath> |
16 |
| - <OutputPath Condition="'$(TargetFrameworkSuffix)' == ''">$([MSBuild]::NormalizeDirectory('$(BaseOutputPath)', '$(TargetFramework)-$(Configuration)'))</OutputPath> |
| 16 | + <OutputPath>$([MSBuild]::NormalizeDirectory('$(BaseOutputPath)', '$(TargetFramework)-$(Configuration)'))</OutputPath> |
| 17 | + <OutputPath Condition="'$(TargetFrameworkSuffix)' != '' and !$(TargetFramework.Contains('-'))">$([MSBuild]::NormalizeDirectory('$(BaseOutputPath)', '$(TargetFramework)-$(TargetFrameworkSuffix)-$(Configuration)'))</OutputPath> |
17 | 18 | </PropertyGroup>
|
18 | 19 |
|
19 | 20 | </Project>
|
0 commit comments