diff options
Diffstat (limited to 'eng/BeforeTargetFrameworkInference.targets')
-rw-r--r-- | eng/BeforeTargetFrameworkInference.targets | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/eng/BeforeTargetFrameworkInference.targets b/eng/BeforeTargetFrameworkInference.targets new file mode 100644 index 00000000000..92adb5df635 --- /dev/null +++ b/eng/BeforeTargetFrameworkInference.targets @@ -0,0 +1,23 @@ +<Project> + + <PropertyGroup Condition="$(TargetFramework.Contains('-'))"> + <_OriginalTargetFramework>$(TargetFramework)</_OriginalTargetFramework> + <TargetFrameworkSuffix>$(TargetFramework.SubString($([MSBuild]::Add($(TargetFramework.IndexOf('-')), 1))))</TargetFrameworkSuffix> + <TargetFramework>$(TargetFramework.SubString(0, $(TargetFramework.IndexOf('-'))))</TargetFramework> + </PropertyGroup> + + <PropertyGroup> + <RefPath>$([MSBuild]::NormalizeDirectory('$(RefRootPath)', '$(TargetFramework)'))</RefPath> + </PropertyGroup> + + <Import Project="$(MSBuildThisDirectory)targetframeworksuffix.props" Condition="'$(DesignTimeBuild)' == 'true'" /> + + <PropertyGroup> + <IntermediateOutputPath>$([MSBuild]::NormalizeDirectory('$(BaseIntermediateOutputPath)', '$(TargetFramework)-$(TargetFrameworkSuffix)-$(Configuration)'))</IntermediateOutputPath> + <IntermediateOutputPath Condition="'$(TargetFrameworkSuffix)' == ''">$([MSBuild]::NormalizeDirectory('$(BaseIntermediateOutputPath)', '$(TargetFramework)-$(Configuration)'))</IntermediateOutputPath> + <!-- setting the output paths --> + <OutputPath>$([MSBuild]::NormalizeDirectory('$(BaseOutputPath)', '$(TargetFramework)-$(TargetFrameworkSuffix)-$(Configuration)'))</OutputPath> + <OutputPath Condition="'$(TargetFrameworkSuffix)' == ''">$([MSBuild]::NormalizeDirectory('$(BaseOutputPath)', '$(TargetFramework)-$(Configuration)'))</OutputPath> + </PropertyGroup> + +</Project> |