Move CoreCLR to the modern build tools and dnx
[platform/upstream/coreclr.git] / tests / dir.props
1 <Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
2
3   <!--
4     $(OS) is set to Unix/Windows_NT. This comes from an environment variable on Windows and MSBuild on Unix.
5   -->
6   <PropertyGroup>
7     <OsEnvironment Condition="'$(OsEnvironment)'==''">$(OS)</OsEnvironment>
8   </PropertyGroup>
9   
10   <!-- Build Tools Versions -->
11   <PropertyGroup>
12     <BuildToolsVersion>1.0.25-prerelease-00056</BuildToolsVersion>
13     <BuildToolsCoreCLRVersion>1.0.2-prerelease</BuildToolsCoreCLRVersion>
14     <DnxVersion Condition="'$(OsEnvironment)'!='Unix'">1.0.0-beta5-12101</DnxVersion>
15     <DnxVersion Condition="'$(OsEnvironment)'=='Unix'">1.0.0-beta5-12101</DnxVersion>
16     <DnxPackageName Condition="'$(DnxPackageName)' == '' and '$(OsEnvironment)'!='Unix'">dnx-coreclr-win-x86.$(DnxVersion)</DnxPackageName>
17     <DnxPackageName Condition="'$(DnxPackageName)' == '' and '$(OsEnvironment)'=='Unix'">dnx-mono.$(DnxVersion)</DnxPackageName>
18     <RoslynVersion>1.0.0-rc3-20150510-01</RoslynVersion>
19     <RoslynPackageName>Microsoft.Net.ToolsetCompilers</RoslynPackageName>
20     <BuildToolsCoreCLRPackageName>Microsoft.DotNet.BuildTools.CoreCLR</BuildToolsCoreCLRPackageName>
21     <BuildToolsCoreCLRLocation>$(ToolsDir)$(BuildToolsCoreCLRPackageName).$(BuildToolsCoreCLRVersion)</BuildToolsCoreCLRLocation>
22   </PropertyGroup>
23
24   <!-- Common repo directories -->
25   <PropertyGroup>
26     <ProjectDir>$(MSBuildThisFileDirectory)</ProjectDir>
27     <SourceDir>$(ProjectDir)src\</SourceDir>
28     <PackagesDir>$(ProjectDir)packages\</PackagesDir>
29     <ToolsDir>$(PackagesDir)Microsoft.DotNet.BuildTools.$(BuildToolsVersion)\lib\</ToolsDir>
30   </PropertyGroup>
31
32   <!-- Common nuget properties -->
33   <PropertyGroup>
34     <NuGetToolPath Condition="'$(NuGetToolPath)'==''">$(PackagesDir)NuGet.exe</NuGetToolPath>
35     <NuGetConfigFile Condition="'$(NuGetConfigFile)'==''">$(SourceDir)NuGet.Config</NuGetConfigFile>
36     <NuGetConfigCommandLine>-ConfigFile "$(NuGetConfigFile)"</NuGetConfigCommandLine>
37
38     <NugetRestoreCommand>"$(NuGetToolPath)"</NugetRestoreCommand>
39     <NugetRestoreCommand>$(NugetRestoreCommand) install</NugetRestoreCommand>
40     <!-- Trim off the last slash so that nuget doesn't get confused and say there are illegal characters on
41          the path. -->
42     <NugetRestoreCommand>$(NugetRestoreCommand) -OutputDirectory "$(PackagesDir.TrimEnd('\\'))"</NugetRestoreCommand>
43     <NugetRestoreCommand>$(NugetRestoreCommand) $(NuGetConfigCommandLine)</NugetRestoreCommand>
44     <NugetRestoreCommand>$(NugetRestoreCommand) -Verbosity detailed</NugetRestoreCommand>
45     <NugetRestoreCommand Condition="'$(OsEnvironment)'=='Unix'">mono $(NuGetRestoreCommand)</NugetRestoreCommand>
46   </PropertyGroup>
47   
48   <!-- list of directories to perform batch restore -->
49   <ItemGroup>
50     <DnuRestoreDir Include="&quot;$(MSBuildProjectDirectory)\src&quot;" />
51   </ItemGroup>
52   
53   <PropertyGroup Condition="'$(BuildAllProjects)'=='true'">
54     <!-- When we do a traversal build we get all packages up front, don't restore them again -->
55     <RestorePackages>false</RestorePackages>
56   </PropertyGroup>
57   
58   <PropertyGroup>
59     <DnxPackageDir Condition="'$(DnxPackageDir)'==''">$(PackagesDir)/$(DnxPackageName)/</DnxPackageDir>
60     <DnuToolPath Condition="'$(DnuToolPath)'=='' and '$(OsEnvironment)'!='Unix'">$(DnxPackageDir)\bin\dnu.cmd</DnuToolPath>
61     <DnuToolPath Condition="'$(DnuToolPath)'=='' and '$(OsEnvironment)'=='Unix'">$(DnxPackageDir)/bin/dnu</DnuToolPath>
62
63     <DnuRestoreSource>@(DnuSourceList -> '--source %(Identity)', ' ')</DnuRestoreSource>
64     <DnuRestoreDirs>@(DnuRestoreDir -> '%(Identity)', ' ')</DnuRestoreDirs>
65     
66     <DnuRestoreCommand>"$(DnuToolPath)"</DnuRestoreCommand>
67     <DnuRestoreCommand>$(DnuRestoreCommand) restore</DnuRestoreCommand>
68     <DnuRestoreCommand>$(DnuRestoreCommand) --packages "$(PackagesDir.TrimEnd('\\'))"</DnuRestoreCommand>
69     <DnuRestoreCommand Condition="'$(LockDependencies)' == 'true'">$(DnuRestoreCommand) --lock</DnuRestoreCommand>
70     
71   </PropertyGroup>
72   
73 </Project>