diff options
author | Eric Mellino <erme@microsoft.com> | 2017-03-21 22:41:05 +0300 |
---|---|---|
committer | Eric Mellino <erme@microsoft.com> | 2017-03-24 21:52:40 +0300 |
commit | 33c665c2ccbd87bdad7ead85fd4e70561502214a (patch) | |
tree | 139aecf9099acc2e6f6aff48e4eaa896323b53e4 /dir.targets | |
parent | 1dd2219b1ba4705ee8291bc0c48cc7222285e7fb (diff) |
Move contents of binplace.targets
* The targets themselves are now located in FrameworkTargeting.targets.
This will let us easily merge them back into buildtools, where the
common logic should live
* The specific properties used in corefx are now in dir.targets.
Diffstat (limited to 'dir.targets')
-rw-r--r-- | dir.targets | 74 |
1 files changed, 73 insertions, 1 deletions
diff --git a/dir.targets b/dir.targets index 154babe658..8b13157945 100644 --- a/dir.targets +++ b/dir.targets @@ -34,9 +34,81 @@ <!-- permit a wrapping build system to contribute targets to this build --> <Import Condition="Exists('$(MSBuildThisFileDirectory)..\open.targets')" Project="$(MSBuildThisFileDirectory)..\open.targets" /> - <Import Project="$(MSBuildThisFileDirectory)binplace.targets" /> <Import Project="$(MSBuildThisFileDirectory)referenceFromRuntime.targets" /> + <!-- Corefx-specific binplacing properties --> + <PropertyGroup> + <IsRuntimeAssembly Condition="'$(IsRuntimeAssembly)'=='' AND '$(IsReferenceAssembly)' != 'true' AND '$(BinPlaceRef)' != 'true' AND '$(IsTestProject)' != 'true'">true</IsRuntimeAssembly> + <!-- Try to determine if this is a simple library without a ref project. + https://github.com/dotnet/corefx/issues/14291 is tracking cleaning this up --> + <IsRuntimeAndReferenceAssembly Condition="'$(IsRuntimeAndReferenceAssembly)' == '' and '$(IsRuntimeAssembly)' == 'true' and Exists('$(SourceDir)/$(AssemblyName)') and !Exists('$(SourceDir)/$(AssemblyName)/ref') and !$(AssemblyName.StartsWith('System.Private'))">true</IsRuntimeAndReferenceAssembly> + <IsNETCoreAppRef Condition="'$(IsNETCoreAppRef)' == ''">$(IsNETCoreApp)</IsNETCoreAppRef> + <IsUAPRef Condition="'$(IsUAPRef)' == ''">$(IsUAP)</IsUAPRef> + + <BuildingDesktopFacade Condition="'$(IsDesktopFacade)' == 'true' And ('$(TargetGroup)' == 'netfx' Or $(TargetGroup.StartsWith('net4')))" >true</BuildingDesktopFacade> + + <!-- if building desktop facade, we don't bin place the refs --> + <BinPlaceRef Condition="'$(BinPlaceRef)' == '' And '$(BuildingDesktopFacade)' != 'true' And ('$(IsReferenceAssembly)' == 'true' OR '$(IsRuntimeAndReferenceAssembly)' == 'true')">true</BinPlaceRef> + <BinPlaceRuntime Condition="'$(BinPlaceRuntime)' == '' And ('$(IsRuntimeAssembly)' == 'true' OR '$(IsRuntimeAndReferenceAssembly)' == 'true')">true</BinPlaceRuntime> + + <!-- if building desktop facade and bin placing the runtime, then we need to bin place the refs too --> + <BinPlaceRef Condition="'$(BuildingDesktopFacade)' == 'true' And '$(BinPlaceRuntime)' == 'true'">true</BinPlaceRef> + + <BinPlaceUseHardlinksIfPossible Condition="'$(BinPlaceUseHardlinksIfPossible)' == ''">true</BinPlaceUseHardlinksIfPossible> + </PropertyGroup> + + <ItemGroup Condition="'@(BinPlaceConfiguration)' == ''"> + <!-- binplace to directories for the target vertical --> + <BinPlaceConfiguration Include="$(BuildConfiguration)"> + <RefPath>$(BuildConfigurationRefPath)</RefPath> + <RuntimePath>$(RuntimePath)</RuntimePath> + </BinPlaceConfiguration> + + <!-- binplace to directories for packages --> + <BinPlaceConfiguration Condition="'$(IsNETCoreApp)' == 'true' AND '$(BuildingNETCoreAppVertical)' == 'true'" Include="netcoreapp-$(_bc_OSGroup)"> + <PackageFileRefPath Condition="'$(IsNETCoreAppRef)' == 'true'">$(NETCoreAppPackageRefPath)</PackageFileRefPath> + <PackageFileRuntimePath>$(NETCoreAppPackageRuntimePath)</PackageFileRuntimePath> + </BinPlaceConfiguration> + <BinPlaceConfiguration Condition="'$(IsUAP)' == 'true' AND '$(BuildingUAPVertical)' == 'true'" Include="uap-$(_bc_OSGroup)"> + <PackageFileRefPath Condition="'$(IsUAPRef)'=='true'">$(UAPPackageRefPath)</PackageFileRefPath> + <PackageFileRuntimePath>$(UAPPackageRuntimePath)</PackageFileRuntimePath> + </BinPlaceConfiguration> + <BinPlaceConfiguration Condition="'$(IsUAP)' == 'true' AND '$(BuildingUAPAOTVertical)' == 'true'" Include="uapaot-$(_bc_OSGroup)"> + <PackageFileRefPath Condition="'$(IsUAPRef)'=='true'">$(UAPPackageRefPath)</PackageFileRefPath> + <PackageFileRuntimePath>$(UAPAOTPackageRuntimePath)</PackageFileRuntimePath> + </BinPlaceConfiguration> + + <!-- Setup the shared framework directory for testing --> + <BinPlaceConfiguration Condition="'$(BinPlaceTestSharedFramework)' == 'true'" Include="netcoreapp-$(_bc_OSGroup)"> + <RuntimePath>$(NETCoreAppTestSharedFrameworkPath)</RuntimePath> + </BinPlaceConfiguration> + <!-- Setup the ILCInputFolder directory for testing uapaot --> + <BinPlaceConfiguration Condition="'$(BinPlaceILCInputFolder)' == 'true'" Include="uapaot-$(_bc_OSGroup)"> + <RuntimePath>$(ILCFXInputFolder)</RuntimePath> + </BinPlaceConfiguration> + <!-- And the UAP folder for the F5 (CoreCLR UAP-debugging) scenario --> + <BinPlaceConfiguration Condition="'$(BinPlaceUAPFramework)' == 'true'" Include="uap-$(_bc_OSGroup)"> + <RuntimePath>$(UAPTestSharedFrameworkPath)</RuntimePath> + </BinPlaceConfiguration> + + <!-- binplace targeting packs which may be different from BuildConfiguration --> + <BinPlaceConfiguration Include="netstandard"> + <RefPath>$(RefRootPath)netstandard/</RefPath> + </BinPlaceConfiguration> + <BinPlaceConfiguration Condition="'$(BuildAllConfigurations)' == 'true'" + Include="netcoreapp"> + <RefPath>$(RefRootPath)netcoreapp/</RefPath> + </BinPlaceConfiguration> + <BinPlaceConfiguration Condition="'$(BuildAllConfigurations)' == 'true'" + Include="uap"> + <RefPath>$(RefRootPath)uap/</RefPath> + </BinPlaceConfiguration> + <BinPlaceConfiguration Condition="'$(BuildAllConfigurations)' == 'true'" + Include="netfx"> + <RefPath>$(RefRootPath)netfx/</RefPath> + </BinPlaceConfiguration> + </ItemGroup> + <PropertyGroup> <!-- We don't use any of MSBuild's resolution logic for resolving the framework, so just set these two properties to any folder that exists to skip the GenerateReferenceAssemblyPaths task (not target) and to prevent it from outputting a warning (MSB3644). --> |