[xbuild] Add workaround for pre-2.0 csc and convert full to portable debug mode
authorMarek Safar <marek.safar@gmail.com>
Wed, 30 Nov 2016 13:35:54 +0000 (14:35 +0100)
committerMarek Safar <marek.safar@gmail.com>
Wed, 30 Nov 2016 13:35:54 +0000 (14:35 +0100)
mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks/ManagedCompiler.cs

index 75eb5fa4b28fbed98e68f515c3229b729313f1a3..8d7a501d4cf1160ad96d85c4ea6c849418bbf759 100644 (file)
@@ -58,7 +58,11 @@ namespace Microsoft.Build.Tasks {
                        if (Bag ["CodePage"] != null)
                                commandLine.AppendSwitchIfNotNull ("/codepage:", CodePage.ToString ());
 
-                       commandLine.AppendSwitchIfNotNull ("/debug:", DebugType);
+                       var dtype = DebugType;
+                       if (string.Equals (dtype, "full", StringComparison.OrdinalIgnoreCase))
+                               dtype = "portable";
+
+                       commandLine.AppendSwitchIfNotNull ("/debug:", dtype);
 
                        if (Bag ["DelaySign"] != null)
                                if (DelaySign)