Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/corefx.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Mellino <erme@microsoft.com>2017-01-05 01:20:01 +0300
committerEric Mellino <erme@microsoft.com>2017-01-05 03:56:57 +0300
commite51adfb7cf480ccbe29ea599b53e32285cc89827 (patch)
tree62ae493187bc6b0d8b6a564af519caf97ae85222 /dir.props
parente19ef70718a971664aa1c0d2894af1d63b8055bc (diff)
Introduce a 'RunningOnUnix' property and use it in targets.
Diffstat (limited to 'dir.props')
-rw-r--r--dir.props31
1 files changed, 11 insertions, 20 deletions
diff --git a/dir.props b/dir.props
index 8409e60c7d..86796fd07b 100644
--- a/dir.props
+++ b/dir.props
@@ -9,27 +9,13 @@
<MinorVersion>6</MinorVersion>
</PropertyGroup>
- <PropertyGroup>
- <OsEnvironment Condition="'$(OsEnvironment)'=='' AND '$(OS)'=='Unix' AND Exists('/Applications')">OSX</OsEnvironment>
- <OsEnvironment Condition="'$(OsEnvironment)'=='' AND '$(OS)'=='Unix'">Linux</OsEnvironment>
- <OsEnvironment Condition="'$(OsEnvironment)'==''">$(OS)</OsEnvironment>
- </PropertyGroup>
-
<Import Condition="Exists('$(MSBuildProjectDirectory)/Configurations.props')" Project="$(MSBuildProjectDirectory)/Configurations.props" />
- <PropertyGroup>
- <InputOSGroup Condition="'$(InputOSGroup)'==''">$(OSEnvironment)</InputOSGroup>
- </PropertyGroup>
-
<!-- Informs build tools to apply .NET Framework metadata if not a test project -->
<PropertyGroup>
<IsDotNetFrameworkProductAssembly>true</IsDotNetFrameworkProductAssembly>
</PropertyGroup>
- <PropertyGroup>
- <BuildToolsTargets45 Condition="'$(OsEnvironment)'=='Windows_NT'">true</BuildToolsTargets45>
- </PropertyGroup>
-
<!-- Common repo directories -->
<PropertyGroup>
<ProjectDir>$(MSBuildThisFileDirectory)</ProjectDir>
@@ -68,6 +54,11 @@
<!-- Import Build tools common props file where repo-independent properties are found -->
<Import Project="$(ToolsDir)Build.Common.props" Condition="Exists('$(ToolsDir)Build.Common.props')" />
+ <PropertyGroup>
+ <InputOSGroup Condition="'$(InputOSGroup)'==''">$(OSEnvironment)</InputOSGroup>
+ <BuildToolsTargets45 Condition="'$(OsEnvironment)'=='Windows_NT'">true</BuildToolsTargets45>
+ </PropertyGroup>
+
<Import Project="$(MSBuildThisFileDirectory)targetingpacks.props" />
<!-- Enable the analyzers for this repo -->
@@ -122,10 +113,10 @@
<PropertyGroup>
<DnxPackageDir Condition="'$(DnxPackageDir)'==''">$(PackagesDir)/$(DnxPackageName)/</DnxPackageDir>
- <DnuToolPath Condition="'$(DnuToolPath)'=='' and '$(OS)'!='Unix'">$(DnxPackageDir)/bin/dnu.cmd</DnuToolPath>
- <DnuToolPath Condition="'$(DnuToolPath)'=='' and '$(OS)'=='Unix'">$(DnxPackageDir)/bin/dnu</DnuToolPath>
- <DotnetToolCommand Condition="'$(DotnetToolCommand)' == '' and '$(OS)'!='Unix'">$(DotnetCliPath)dotnet.exe</DotnetToolCommand>
- <DotnetToolCommand Condition="'$(DotnetToolCommand)' == '' and '$(OS)'=='Unix'">$(DotnetCliPath)dotnet</DotnetToolCommand>
+ <DnuToolPath Condition="'$(DnuToolPath)'=='' and '$(RunningOnUnix)'!='true'">$(DnxPackageDir)/bin/dnu.cmd</DnuToolPath>
+ <DnuToolPath Condition="'$(DnuToolPath)'=='' and '$(RunningOnUnix)'=='true'">$(DnxPackageDir)/bin/dnu</DnuToolPath>
+ <DotnetToolCommand Condition="'$(DotnetToolCommand)' == '' and '$(RunningOnUnix)'!='true'">$(DotnetCliPath)dotnet.exe</DotnetToolCommand>
+ <DotnetToolCommand Condition="'$(DotnetToolCommand)' == '' and '$(RunningOnUnix)'=='true'">$(DotnetCliPath)dotnet</DotnetToolCommand>
<DnuToolPath>$(DotnetToolCommand)</DnuToolPath>
<DnuRestoreSource>@(DnuSourceList -> '--source %(Identity)', ' ')</DnuRestoreSource>
@@ -266,6 +257,6 @@
</PropertyGroup>
<!-- Use Roslyn Compilers to build -->
- <Import Project="$(RoslynPropsFile)" Condition="'$(OS)'!='Unix' and Exists('$(RoslynPropsFile)') and '$(UseRoslynCompilers)'!='false'" />
- <Import Project="$(RoslynPropsFile)" Condition="'$(OS)'=='Unix' and Exists('$(RoslynPropsFile)')" />
+ <Import Project="$(RoslynPropsFile)" Condition="'$(RunningOnUnix)'!='true' and Exists('$(RoslynPropsFile)') and '$(UseRoslynCompilers)'!='false'" />
+ <Import Project="$(RoslynPropsFile)" Condition="'$(RunningOnUnix)'=='true' and Exists('$(RoslynPropsFile)')" />
</Project>