[xbuild] Update another default tools setting
authorMarek Safar <marek.safar@gmail.com>
Tue, 2 Dec 2014 22:29:15 +0000 (23:29 +0100)
committerMarek Safar <marek.safar@gmail.com>
Tue, 2 Dec 2014 22:29:15 +0000 (23:29 +0100)
mcs/class/Microsoft.Build/Microsoft.Build.Evaluation/ProjectCollection.cs
mcs/class/Microsoft.Build/Test/Microsoft.Build.Execution/ProjectInstanceTest.cs

index 11343933971adf05106698d5efd0ed573954fb52..60ccbe37bde67cffc80d065984522b6351688169 100644 (file)
@@ -251,12 +251,6 @@ namespace Microsoft.Build.Evaluation
                //FIXME: should also support config file, depending on ToolsetLocations
                void LoadDefaultToolsets ()
                {
-                       AddToolset (new Toolset ("2.0",
-                               ToolLocationHelper.GetPathToDotNetFramework (TargetDotNetFrameworkVersion.Version20), this, null));
-                       AddToolset (new Toolset ("3.0",
-                               ToolLocationHelper.GetPathToDotNetFramework (TargetDotNetFrameworkVersion.Version30), this, null));
-                       AddToolset (new Toolset ("3.5",
-                               ToolLocationHelper.GetPathToDotNetFramework (TargetDotNetFrameworkVersion.Version35), this, null));
 #if NET_4_0
                        AddToolset (new Toolset ("4.0",
                                ToolLocationHelper.GetPathToDotNetFramework (TargetDotNetFrameworkVersion.Version40), this, null));
@@ -267,7 +261,16 @@ namespace Microsoft.Build.Evaluation
 #if XBUILD_14
                        AddToolset (new Toolset ("14.0", ToolLocationHelper.GetPathToBuildTools ("14.0"), this, null));
 #endif
-                       default_tools_version = toolsets.First ().ToolsVersion;
+
+                       // We don't support these anymore
+                       AddToolset (new Toolset ("2.0",
+                               ToolLocationHelper.GetPathToDotNetFramework (TargetDotNetFrameworkVersion.Version20), this, null));
+                       AddToolset (new Toolset ("3.0",
+                               ToolLocationHelper.GetPathToDotNetFramework (TargetDotNetFrameworkVersion.Version30), this, null));
+                       AddToolset (new Toolset ("3.5",
+                               ToolLocationHelper.GetPathToDotNetFramework (TargetDotNetFrameworkVersion.Version35), this, null));
+
+                       default_tools_version = toolsets [0].ToolsVersion;
                }
                
                [MonoTODO ("not verified at all")]
index 4e23c2a7a5ac8d0c72e58af4fda1c7d53312bb9b..c4fe2401bd518d2415c83ba4f94848dea8d15a86 100644 (file)
@@ -66,7 +66,7 @@ namespace MonoTests.Microsoft.Build.Execution
                        var prop = proj.Properties.First (p => p.Name=="P");
                        Assert.AreEqual ("valid", prop.EvaluatedValue, "#2");
                        Assert.IsNotNull (proj.GetProperty ("MSBuildProjectDirectory"), "#3");
-                       Assert.AreEqual ("2.0", proj.ToolsVersion, "#4");
+                       Assert.AreEqual ("4.0", proj.ToolsVersion, "#4");
                }
                
                [Test]