diff options
author | Mike Krüger <mkrueger@xamarin.com> | 2012-03-03 11:43:22 +0400 |
---|---|---|
committer | Mike Krüger <mkrueger@xamarin.com> | 2012-03-03 11:43:22 +0400 |
commit | 79661d5405e04766cfb3ad531b7fe5af2f43e7f5 (patch) | |
tree | afa4eafd41e04d5fe7f3e36ad6c0b9b41bb481a6 | |
parent | 06062775726d85c32d4947e0d27b299f1c56c3fb (diff) | |
parent | 2b0835b6f38a0eaea16a5d1d575e89897d3b8ef6 (diff) |
Merge branch 'master' into newresolver
Conflicts:
main/src/addins/MonoDevelop.MacDev/ObjCIntegration/NSObjectInfoService.cs
main/src/addins/MonoDevelop.MacDev/ObjCIntegration/NSObjectProjectInfo.cs
main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.csproj
main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/ProjectOperations.cs
version-checks
79 files changed, 859 insertions, 299 deletions
diff --git a/main/Main.sln b/main/Main.sln index 27c5e248ac..4b61f83371 100644 --- a/main/Main.sln +++ b/main/Main.sln @@ -13,8 +13,14 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Mono.Debugging", "src\core\ EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Mono.TextEditor", "src\core\Mono.Texteditor\Mono.TextEditor.csproj", "{A2329308-3751-4DBD-9A75-5F7B8B024625}"
EndProject
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "MonoDevelop.Projects.Format.MSBuild", "MonoDevelop.Projects.Format.MSBuild", "{8F48ECA6-CFFF-4EBF-BC92-817199EDE9AF}"
+EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MonoDevelop.Projects.Formats.MSBuild", "src\core\MonoDevelop.Projects.Formats.MSBuild\MonoDevelop.Projects.Formats.MSBuild.csproj", "{A437F1A3-78DF-4F00-8053-D32A8B1EB679}"
EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MonoDevelop.Projects.Formats.MSBuild.v2.0", "src\core\MonoDevelop.Projects.Formats.MSBuild\MonoDevelop.Projects.Formats.MSBuild.v2.0.csproj", "{01206ab0-8871-42e7-9355-52e4cf1b7b9a}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MonoDevelop.Projects.Formats.MSBuild.v3.5", "src\core\MonoDevelop.Projects.Formats.MSBuild\MonoDevelop.Projects.Formats.MSBuild.v3.5.csproj", "{40a31ade-6f26-4d99-a3c7-87bb8236151d}"
+EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Addins", "Addins", "{D417E929-2B3A-46AC-BBE8-027ADB63A790}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ILAsmBinding", "src\addins\ILAsmBinding\ILAsmBinding.csproj", "{961B9266-C44A-42B6-BA3D-3FB229C9C417}"
@@ -207,6 +213,18 @@ Global Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a}.Debug|Any CPU.ActiveCfg = Debug|x86
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a}.Debug|Any CPU.Build.0 = Debug|x86
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a}.Debug|x86.ActiveCfg = Debug|x86
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a}.Debug|x86.Build.0 = Debug|x86
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a}.DebugMac|Any CPU.ActiveCfg = Debug|x86
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a}.DebugMac|Any CPU.Build.0 = Debug|x86
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a}.DebugWin32|x86.ActiveCfg = Debug|x86
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a}.DebugWin32|x86.Build.0 = Debug|x86
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a}.Release|Any CPU.ActiveCfg = Release|x86
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a}.Release|Any CPU.Build.0 = Release|x86
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a}.Release|x86.ActiveCfg = Release|x86
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a}.Release|x86.Build.0 = Release|x86
{0413DB7D-8B35-423F-9752-D75C9225E7DE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{0413DB7D-8B35-423F-9752-D75C9225E7DE}.Debug|Any CPU.Build.0 = Debug|Any CPU
{0413DB7D-8B35-423F-9752-D75C9225E7DE}.DebugMac|Any CPU.ActiveCfg = Debug|Any CPU
@@ -417,6 +435,18 @@ Global {3EC06433-F168-4C5B-A885-99CE4AB617E1}.DebugWin32|x86.Build.0 = Debug|Any CPU
{3EC06433-F168-4C5B-A885-99CE4AB617E1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{3EC06433-F168-4C5B-A885-99CE4AB617E1}.Release|Any CPU.Build.0 = Release|Any CPU
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d}.Debug|Any CPU.ActiveCfg = Debug|x86
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d}.Debug|Any CPU.Build.0 = Debug|x86
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d}.Debug|x86.ActiveCfg = Debug|x86
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d}.Debug|x86.Build.0 = Debug|x86
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d}.DebugMac|Any CPU.ActiveCfg = Debug|x86
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d}.DebugMac|Any CPU.Build.0 = Debug|x86
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d}.DebugWin32|x86.ActiveCfg = Debug|x86
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d}.DebugWin32|x86.Build.0 = Debug|x86
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d}.Release|Any CPU.ActiveCfg = Release|x86
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d}.Release|Any CPU.Build.0 = Release|x86
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d}.Release|x86.ActiveCfg = Release|x86
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d}.Release|x86.Build.0 = Release|x86
{459868D2-54DC-415B-B1AB-BE39BDBD352F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{459868D2-54DC-415B-B1AB-BE39BDBD352F}.DebugMac|Any CPU.ActiveCfg = Debug|Any CPU
{459868D2-54DC-415B-B1AB-BE39BDBD352F}.DebugWin32|x86.ActiveCfg = Debug|Any CPU
@@ -830,7 +860,10 @@ Global {DA8EDEA6-7DA8-435D-B1A0-F3A0CA07F424} = {9D360D43-0C05-49D6-84DB-4E7AB2F38F82}
{90C99ADB-7D4B-4EB4-98C2-40BD1B14C7D2} = {9D360D43-0C05-49D6-84DB-4E7AB2F38F82}
{A2329308-3751-4DBD-9A75-5F7B8B024625} = {9D360D43-0C05-49D6-84DB-4E7AB2F38F82}
- {A437F1A3-78DF-4F00-8053-D32A8B1EB679} = {9D360D43-0C05-49D6-84DB-4E7AB2F38F82}
+ {8F48ECA6-CFFF-4EBF-BC92-817199EDE9AF} = {9D360D43-0C05-49D6-84DB-4E7AB2F38F82}
+ {A437F1A3-78DF-4F00-8053-D32A8B1EB679} = {8F48ECA6-CFFF-4EBF-BC92-817199EDE9AF}
+ {01206ab0-8871-42e7-9355-52e4cf1b7b9a} = {8F48ECA6-CFFF-4EBF-BC92-817199EDE9AF}
+ {40a31ade-6f26-4d99-a3c7-87bb8236151d} = {8F48ECA6-CFFF-4EBF-BC92-817199EDE9AF}
{961B9266-C44A-42B6-BA3D-3FB229C9C417} = {D417E929-2B3A-46AC-BBE8-027ADB63A790}
{DEEB9163-3966-4E5E-9AB5-FBB3E01AC82A} = {D417E929-2B3A-46AC-BBE8-027ADB63A790}
{02280E65-C507-4931-AE68-AA2E89E15EEF} = {D417E929-2B3A-46AC-BBE8-027ADB63A790}
diff --git a/main/contrib/Mono.Cecil/Mono.CompilerServices.SymbolWriter/MonoSymbolFile.cs b/main/contrib/Mono.Cecil/Mono.CompilerServices.SymbolWriter/MonoSymbolFile.cs index ea51d82c98..834021be0d 100644 --- a/main/contrib/Mono.Cecil/Mono.CompilerServices.SymbolWriter/MonoSymbolFile.cs +++ b/main/contrib/Mono.Cecil/Mono.CompilerServices.SymbolWriter/MonoSymbolFile.cs @@ -485,7 +485,7 @@ namespace Mono.CompilerServices.SymbolWriter public static MonoSymbolFile ReadSymbolFile (string mdbFilename) { - return new MonoSymbolFile (mdbFilename, null); + return new MonoSymbolFile (mdbFilename); } public int CompileUnitCount { diff --git a/main/src/addins/AspNet/MonoDevelop.AspNet.Mvc/Makefile.am b/main/src/addins/AspNet/MonoDevelop.AspNet.Mvc/Makefile.am index 770d5c088c..c87b541d39 100644 --- a/main/src/addins/AspNet/MonoDevelop.AspNet.Mvc/Makefile.am +++ b/main/src/addins/AspNet/MonoDevelop.AspNet.Mvc/Makefile.am @@ -9,12 +9,12 @@ DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.XmlEditor/MonoDevelop.XmlEditor.dll \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Core \ diff --git a/main/src/addins/AspNet/MonoDevelop.AspNet/Makefile.am b/main/src/addins/AspNet/MonoDevelop.AspNet/Makefile.am index 83b061d0c0..95126524c1 100644 --- a/main/src/addins/AspNet/MonoDevelop.AspNet/Makefile.am +++ b/main/src/addins/AspNet/MonoDevelop.AspNet/Makefile.am @@ -11,13 +11,13 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.CSharp.dll \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Configuration \ diff --git a/main/src/addins/CBinding/Makefile.am b/main/src/addins/CBinding/Makefile.am index 5d3431f739..5eea5059c2 100644 --- a/main/src/addins/CBinding/Makefile.am +++ b/main/src/addins/CBinding/Makefile.am @@ -10,13 +10,13 @@ DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.Refactoring/MonoDevelop.Refactoring.dll \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Core \ diff --git a/main/src/addins/CSharpBinding/AspNet/Makefile.am b/main/src/addins/CSharpBinding/AspNet/Makefile.am index b75c2e5b28..3cb7b8a08e 100644 --- a/main/src/addins/CSharpBinding/AspNet/Makefile.am +++ b/main/src/addins/CSharpBinding/AspNet/Makefile.am @@ -9,12 +9,12 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll \ $(top_builddir)/build/bin/OldNRefactory.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ -r:System \ -r:System.Core diff --git a/main/src/addins/CSharpBinding/Autotools/Makefile.am b/main/src/addins/CSharpBinding/Autotools/Makefile.am index 71e5f43ada..cfe741693f 100644 --- a/main/src/addins/CSharpBinding/Autotools/Makefile.am +++ b/main/src/addins/CSharpBinding/Autotools/Makefile.am @@ -7,10 +7,11 @@ DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.DesignerSupport/MonoDevelop.DesignerSupport.dll \ $(top_builddir)/build/AddIns/MonoDevelop.Refactoring/MonoDevelop.Refactoring.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll -REFS = -r:System +REFS = \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ + -r:System FILES = CSharpAutotoolsSetup.cs diff --git a/main/src/addins/CSharpBinding/Makefile.am b/main/src/addins/CSharpBinding/Makefile.am index a27e56edf7..d6f3ff3b80 100644 --- a/main/src/addins/CSharpBinding/Makefile.am +++ b/main/src/addins/CSharpBinding/Makefile.am @@ -15,7 +15,6 @@ DEPS = \ $(top_builddir)/build/bin/Mono.Debugging.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll \ $(top_builddir)/build/bin/OldNRefactory.dll @@ -23,6 +22,7 @@ REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Cairo \ -r:Mono.Posix \ -r:System \ diff --git a/main/src/addins/ChangeLogAddIn/Makefile.am b/main/src/addins/ChangeLogAddIn/Makefile.am index a45df96055..cae06f3a0c 100644 --- a/main/src/addins/ChangeLogAddIn/Makefile.am +++ b/main/src/addins/ChangeLogAddIn/Makefile.am @@ -5,13 +5,13 @@ DEPS = \ $(top_builddir)/build/AddIns/VersionControl/MonoDevelop.VersionControl.dll \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix FILES = \ diff --git a/main/src/addins/Deployment/MonoDevelop.Deployment.Linux/Makefile.am b/main/src/addins/Deployment/MonoDevelop.Deployment.Linux/Makefile.am index 87217c65b8..ee6f2f3464 100644 --- a/main/src/addins/Deployment/MonoDevelop.Deployment.Linux/Makefile.am +++ b/main/src/addins/Deployment/MonoDevelop.Deployment.Linux/Makefile.am @@ -4,13 +4,13 @@ ASSEMBLY = $(ADDIN_BUILD)/MonoDevelop.Deployment.Linux.dll DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.Deployment/MonoDevelop.Deployment.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Xml diff --git a/main/src/addins/Deployment/MonoDevelop.Deployment/Makefile.am b/main/src/addins/Deployment/MonoDevelop.Deployment/Makefile.am index 4cc94f5b92..b0534622ae 100644 --- a/main/src/addins/Deployment/MonoDevelop.Deployment/Makefile.am +++ b/main/src/addins/Deployment/MonoDevelop.Deployment/Makefile.am @@ -4,13 +4,13 @@ ASSEMBLY = $(ADDIN_BUILD)/MonoDevelop.Deployment.dll DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.DesignerSupport/MonoDevelop.DesignerSupport.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ -r:ICSharpCode.SharpZipLib \ -r:Mono.Posix \ -r:System \ diff --git a/main/src/addins/GnomePlatform/Makefile.am b/main/src/addins/GnomePlatform/Makefile.am index 07c24c2ce0..38b4521c94 100644 --- a/main/src/addins/GnomePlatform/Makefile.am +++ b/main/src/addins/GnomePlatform/Makefile.am @@ -2,9 +2,7 @@ ADDIN_BUILD = $(top_builddir)/build/AddIns ASSEMBLY = $(ADDIN_BUILD)/GnomePlatform.dll -DEPS = \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll +DEPS = $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GCONF_SHARP_LIBS) \ @@ -12,6 +10,7 @@ REFS = \ $(GNOME_SHARP_LIBS) \ $(GNOME_VFS_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:System FILES = \ diff --git a/main/src/addins/ILAsmBinding/Makefile.am b/main/src/addins/ILAsmBinding/Makefile.am index 54c9b5aa23..f64373008e 100644 --- a/main/src/addins/ILAsmBinding/Makefile.am +++ b/main/src/addins/ILAsmBinding/Makefile.am @@ -2,14 +2,13 @@ ADDIN_BUILD = $(top_builddir)/build/AddIns/BackendBindings ASSEMBLY = $(ADDIN_BUILD)/ILAsmBinding.dll -DEPS = \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll +DEPS = $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Xml diff --git a/main/src/addins/MacPlatform/Makefile.am b/main/src/addins/MacPlatform/Makefile.am index 658671de7f..b622d59e61 100644 --- a/main/src/addins/MacPlatform/Makefile.am +++ b/main/src/addins/MacPlatform/Makefile.am @@ -5,14 +5,13 @@ ASSEMBLY = $(ADDIN_BUILD)/MacPlatform.dll MONOMAC_SRC = $(top_srcdir)/../extras/MonoDevelop.MonoMac/MonoDevelop.MonoMac/MonoMac.dll MONOMAC = $(ADDIN_BUILD)/MonoMac.dll -DEPS = \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll +DEPS = $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ -r:../../../../extras/MonoDevelop.MonoMac/MonoDevelop.MonoMac/MonoMac.dll \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Core \ diff --git a/main/src/addins/MonoDevelop.AssemblyBrowser/Makefile.am b/main/src/addins/MonoDevelop.AssemblyBrowser/Makefile.am index a1c297e76c..f2428f4051 100644 --- a/main/src/addins/MonoDevelop.AssemblyBrowser/Makefile.am +++ b/main/src/addins/MonoDevelop.AssemblyBrowser/Makefile.am @@ -47,13 +47,13 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.Cecil.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Cairo \ -r:Mono.Posix \ -r:System \ diff --git a/main/src/addins/MonoDevelop.Autotools/Makefile.am b/main/src/addins/MonoDevelop.Autotools/Makefile.am index 4be733a990..4ca04067c9 100644 --- a/main/src/addins/MonoDevelop.Autotools/Makefile.am +++ b/main/src/addins/MonoDevelop.Autotools/Makefile.am @@ -5,13 +5,13 @@ ASSEMBLY = $(ADDIN_BUILD)/MonoDevelop.Autotools.dll DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.Deployment/MonoDevelop.Deployment.dll \ $(top_builddir)/build/AddIns/MonoDevelop.DesignerSupport/MonoDevelop.DesignerSupport.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System diff --git a/main/src/addins/MonoDevelop.CodeMetrics/Makefile.am b/main/src/addins/MonoDevelop.CodeMetrics/Makefile.am index c85b70afff..9de5215e69 100644 --- a/main/src/addins/MonoDevelop.CodeMetrics/Makefile.am +++ b/main/src/addins/MonoDevelop.CodeMetrics/Makefile.am @@ -7,13 +7,13 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.CSharp.dll \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Core \ diff --git a/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/Makefile.am b/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/Makefile.am index 92e60bca8d..5fd5d3f6b5 100644 --- a/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/Makefile.am +++ b/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/Makefile.am @@ -6,6 +6,7 @@ SIGNING_KEY=$(top_srcdir)/src/core/Mono.Debugging/mono.debugging.snk DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.Debugger.Soft/Mono.Debugger.Soft.dll \ $(top_builddir)/build/bin/Mono.Cecil.dll \ + $(top_builddir)/build/bin/Mono.Cecil.Mdb.dll \ $(top_builddir)/build/bin/Mono.Debugging.dll REFS = \ diff --git a/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/Mono.Debugging.Soft.csproj b/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/Mono.Debugging.Soft.csproj index be94d1043b..5e38d5a6fd 100644 --- a/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/Mono.Debugging.Soft.csproj +++ b/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/Mono.Debugging.Soft.csproj @@ -44,6 +44,10 @@ <Name>Mono.Cecil</Name> <Private>False</Private> </ProjectReference> + <ProjectReference Include="..\..\..\..\contrib\Mono.Cecil\Mono.Cecil.Mdb.csproj"> + <Project>{201F7AC0-D2D5-4F51-85A8-17475DADBED3}</Project> + <Name>Mono.Cecil.Mdb</Name> + </ProjectReference> </ItemGroup> <ItemGroup> <Compile Include="ArrayAdaptor.cs" /> diff --git a/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/SoftDebuggerSession.cs b/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/SoftDebuggerSession.cs index 9e63636d35..239fc2e52e 100644 --- a/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/SoftDebuggerSession.cs +++ b/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/SoftDebuggerSession.cs @@ -30,6 +30,8 @@ using System; using System.Linq; using System.Threading; using System.Collections.Generic; +using Mono.Cecil.Mdb; +using Mono.CompilerServices.SymbolWriter; using Mono.Debugging.Client; using Mono.Debugger.Soft; using Mono.Debugging.Evaluation; @@ -60,6 +62,7 @@ namespace Mono.Debugging.Soft bool autoStepInto; internal int StackVersion; StepEventRequest currentStepRequest; + long currentAddress = -1; ExceptionEventRequest unhandledExceptionRequest; string remoteProcessName; Dictionary<long,long> localThreadIds = new Dictionary<long, long> (); @@ -78,6 +81,7 @@ namespace Mono.Debugging.Soft List<string> userAssemblyNames; List<AssemblyMirror> assemblyFilters; + Dictionary<string, string> assemblyPathMap; bool loggedSymlinkedRuntimesBug = false; @@ -120,7 +124,7 @@ namespace Mono.Debugging.Soft { this.startArgs = dsi.StartArgs; - RegisterUserAssemblies (dsi.UserAssemblyNames); + RegisterUserAssemblies (dsi); if (!String.IsNullOrEmpty (dsi.LogMessage)) LogWriter (false, dsi.LogMessage + "\n"); @@ -165,7 +169,7 @@ namespace Mono.Debugging.Soft { var args = (SoftDebuggerLaunchArgs) dsi.StartArgs; var runtime = Path.Combine (Path.Combine (args.MonoRuntimePrefix, "bin"), "mono"); - RegisterUserAssemblies (dsi.UserAssemblyNames); + RegisterUserAssemblies (dsi); var psi = new System.Diagnostics.ProcessStartInfo (runtime) { Arguments = string.Format ("\"{0}\" {1}", dsi.Command, dsi.Arguments), @@ -295,7 +299,7 @@ namespace Mono.Debugging.Soft remoteProcessName = args.AppName; - RegisterUserAssemblies (dsi.UserAssemblyNames); + RegisterUserAssemblies (dsi); dbgEP = new IPEndPoint (args.Address, args.DebugPort); conEP = args.RedirectOutput? new IPEndPoint (args.Address, args.OutputPort) : null; @@ -446,12 +450,16 @@ namespace Mono.Debugging.Soft eventHandler.Start (); } - protected void RegisterUserAssemblies (List<AssemblyName> userAssemblyNames) + void RegisterUserAssemblies (SoftDebuggerStartInfo dsi) { - if (Options.ProjectAssembliesOnly && userAssemblyNames != null) { + if (Options.ProjectAssembliesOnly && dsi.UserAssemblyNames != null) { assemblyFilters = new List<AssemblyMirror> (); - this.userAssemblyNames = userAssemblyNames.Select (x => x.ToString ()).ToList (); + userAssemblyNames = dsi.UserAssemblyNames.Select (x => x.ToString ()).ToList (); } + + assemblyPathMap = dsi.AssemblyPathMap; + if (assemblyPathMap == null) + assemblyPathMap = new Dictionary<string, string> (); } protected bool SetSocketTimeouts (int send_timeout, int receive_timeout, int keepalive_interval) @@ -1152,6 +1160,7 @@ namespace Mono.Debugging.Soft bool resume = true; bool steppedOut = false; bool steppedInto = false; + bool redoCurrentStep = false; ObjectMirror exception = null; TargetEventType etype = TargetEventType.TargetStopped; BreakEvent breakEvent = null; @@ -1172,16 +1181,22 @@ namespace Mono.Debugging.Soft else { //always need to evaluate all breakpoints, some might be tracepoints or conditional bps with counters foreach (Event e in es) { - var be = e as BreakpointEvent; - if (be != null) { + if (e.EventType == EventType.Breakpoint) { + var be = e as BreakpointEvent; + BreakInfo binfo; + if (!HandleBreakpoint (e.Thread, be.Request)) { etype = TargetEventType.TargetHitBreakpoint; - BreakInfo binfo; - if (breakpoints.TryGetValue (be.Request, out binfo)) - breakEvent = binfo.BreakEvent; autoStepInto = false; resume = false; } + + if (breakpoints.TryGetValue (be.Request, out binfo)) { + if (binfo.Location.ILOffset == currentAddress && e.Thread.Id == currentStepRequest.Thread.Id) + redoCurrentStep = true; + + breakEvent = binfo.BreakEvent; + } } else if (e.EventType == EventType.Step) { var stepRequest = e.Request as StepEventRequest; steppedInto = IsStepIntoRequest (stepRequest); @@ -1198,7 +1213,16 @@ namespace Mono.Debugging.Soft } } - if (resume) { + if (redoCurrentStep) { + StepDepth depth = currentStepRequest.Depth; + StepSize size = currentStepRequest.Size; + + current_thread = recent_thread = es[0].Thread; + currentStepRequest.Enabled = false; + currentStepRequest = null; + + Step (depth, size); + } else if (resume) { //all breakpoints were conditional and evaluated as false vm.Resume (); DequeueEventsForFirstThread (); @@ -1216,10 +1240,12 @@ namespace Mono.Debugging.Soft var backtrace = GetThreadBacktrace (current_thread); bool stepOut = false; - if (steppedInto && Options.StepOverPropertiesAndOperators && backtrace.FrameCount > 0) { + if (backtrace.FrameCount > 0) { var frame = backtrace.GetFrame (0) as SoftDebuggerStackFrame; + currentAddress = frame != null ? frame.Address : -1; - stepOut = frame != null && IsPropertyOrOperatorMethod (frame.StackFrame.Method); + if (steppedInto && Options.StepOverPropertiesAndOperators) + stepOut = frame != null && IsPropertyOrOperatorMethod (frame.StackFrame.Method); } if (stepOut) { @@ -1714,9 +1740,65 @@ namespace Mono.Debugging.Soft return method.Locations.Count > 0 ? method.Locations[0] : null; } + + Dictionary<string, MonoSymbolFile> symbolFiles = new Dictionary<string, MonoSymbolFile> (); + + bool CheckBetterMatch (TypeMirror type, string file, int line, Location found) + { + if (type.Assembly == null) + return false; + + string assemblyFileName; + if (!assemblyPathMap.TryGetValue (type.Assembly.GetName ().FullName, out assemblyFileName)) + assemblyFileName = type.Assembly.Location; + + if (assemblyFileName == null) + return false; + + string mdbFileName = assemblyFileName + ".mdb"; + int foundDelta = found.LineNumber - line; + MonoSymbolFile mdb; + int fileId = -1; + + try { + if (!symbolFiles.TryGetValue (mdbFileName, out mdb)) { + if (!File.Exists (mdbFileName)) + return false; + + mdb = MonoSymbolFile.ReadSymbolFile (mdbFileName); + symbolFiles.Add (mdbFileName, mdb); + } + + foreach (var src in mdb.Sources) { + if (src.FileName == file) { + fileId = src.Index; + break; + } + } + + if (fileId == -1) + return false; + + foreach (var method in mdb.Methods) { + var table = method.GetLineNumberTable (); + foreach (var entry in table.LineNumbers) { + if (entry.File != fileId) + continue; + + if (entry.Row >= line && (entry.Row - line) < foundDelta) + return true; + } + } + } catch { + } + + return false; + } + Location GetLocFromType (TypeMirror type, string file, int line, out bool genericMethod, out bool insideTypeRange) { Location target_loc = null; + bool fuzzy = true; insideTypeRange = false; genericMethod = false; @@ -1759,9 +1841,11 @@ namespace Mono.Debugging.Soft // Line number matches exactly //Console.WriteLine ("\t\tLocation matches exactly."); target_loc = location; + fuzzy = false; } } else { //Console.WriteLine ("\t\tLocation is first possible match"); + fuzzy = location.LineNumber != line; target_loc = location; } } @@ -1773,10 +1857,18 @@ namespace Mono.Debugging.Soft if (target_loc != null) { genericMethod = IsGenericMethod (method); - break; + + // If we got a fuzzy match, then we need to make sure that there isn't a better + // match in another method (e.g. code might have been extracted out into another + // method by the compiler. + if (!fuzzy) + return target_loc; } } + if (target_loc != null && fuzzy && CheckBetterMatch (type, file, line, target_loc)) + return null; + return target_loc; } diff --git a/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/SoftDebuggerStartInfo.cs b/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/SoftDebuggerStartInfo.cs index 06db05aedc..04ad7605f9 100644 --- a/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/SoftDebuggerStartInfo.cs +++ b/main/src/addins/MonoDevelop.Debugger.Soft/Mono.Debugging.Soft/SoftDebuggerStartInfo.cs @@ -53,6 +53,11 @@ namespace Mono.Debugging.Soft public List<AssemblyName> UserAssemblyNames { get; set; } /// <summary> + /// A mapping of AssemblyNames to their paths. + /// </summary> + public Dictionary<string, string> AssemblyPathMap { get; set; } + + /// <summary> /// The session will output this to the debug log as soon as it starts. It can be used to log warnings from /// creating the SoftDebuggerStartInfo /// </summary> diff --git a/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft.AspNet/Makefile.am b/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft.AspNet/Makefile.am index d61dda9a83..73b572c198 100644 --- a/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft.AspNet/Makefile.am +++ b/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft.AspNet/Makefile.am @@ -9,12 +9,12 @@ DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.Debugger/MonoDevelop.Debugger.dll \ $(top_builddir)/build/bin/Mono.Debugging.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ -r:System \ -r:System.Core diff --git a/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft.Moonlight/Makefile.am b/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft.Moonlight/Makefile.am index 5b35e95c84..0ea6b7ee64 100644 --- a/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft.Moonlight/Makefile.am +++ b/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft.Moonlight/Makefile.am @@ -9,12 +9,12 @@ DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.Moonlight/MonoDevelop.Moonlight.dll \ $(top_builddir)/build/bin/Mono.Debugging.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ -r:System \ -r:System.Core diff --git a/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft/Makefile.am b/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft/Makefile.am index a0f3082da3..ff48801a6e 100644 --- a/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft/Makefile.am +++ b/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft/Makefile.am @@ -8,12 +8,12 @@ DEPS = \ $(top_builddir)/build/bin/Mono.Cecil.dll \ $(top_builddir)/build/bin/Mono.Debugging.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ -r:System \ -r:System.Core diff --git a/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft/SoftDebuggerEngine.cs b/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft/SoftDebuggerEngine.cs index 8d063f71e3..7f1bb4068d 100644 --- a/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft/SoftDebuggerEngine.cs +++ b/main/src/addins/MonoDevelop.Debugger.Soft/MonoDevelop.Debugger.Soft/SoftDebuggerEngine.cs @@ -104,18 +104,24 @@ namespace MonoDevelop.Debugger.Soft if (files == null || files.Count == 0) return; + var pathMap = new Dictionary<string, string> (); var names = new List<AssemblyName> (); + foreach (var file in files) { if (!File.Exists (file)) { dsi.LogMessage = GettextCatalog.GetString ("User assembly '{0}' is missing. " + "Debugger will now debug all code, not just user code.", file); return; } + try { var asm = Mono.Cecil.AssemblyDefinition.ReadAssembly (file); if (string.IsNullOrEmpty (asm.Name.Name)) throw new InvalidOperationException ("Assembly has no assembly name"); - names.Add (new AssemblyName (asm.Name.FullName)); + + AssemblyName name = new AssemblyName (asm.Name.FullName); + pathMap.Add (asm.Name.FullName, file); + names.Add (name); } catch (Exception ex) { dsi.LogMessage = GettextCatalog.GetString ("Could not get assembly name for user assembly '{0}'. " + "Debugger will now debug all code, not just user code.", file); @@ -123,7 +129,9 @@ namespace MonoDevelop.Debugger.Soft return; } } + dsi.UserAssemblyNames = names; + dsi.AssemblyPathMap = pathMap; } class MDLogger : ICustomLogger diff --git a/main/src/addins/MonoDevelop.Debugger/Makefile.am b/main/src/addins/MonoDevelop.Debugger/Makefile.am index 780110cc89..59a06909df 100644 --- a/main/src/addins/MonoDevelop.Debugger/Makefile.am +++ b/main/src/addins/MonoDevelop.Debugger/Makefile.am @@ -8,13 +8,13 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.Debugging.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Cairo \ -r:Mono.Posix \ -r:System \ diff --git a/main/src/addins/MonoDevelop.DesignerSupport/Makefile.am b/main/src/addins/MonoDevelop.DesignerSupport/Makefile.am index c13de6c5d8..920673fc9e 100644 --- a/main/src/addins/MonoDevelop.DesignerSupport/Makefile.am +++ b/main/src/addins/MonoDevelop.DesignerSupport/Makefile.am @@ -5,13 +5,13 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.Cecil.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Cairo \ -r:Mono.Posix \ -r:System \ diff --git a/main/src/addins/MonoDevelop.Gettext/Makefile.am b/main/src/addins/MonoDevelop.Gettext/Makefile.am index 8771f086cb..d262506a46 100644 --- a/main/src/addins/MonoDevelop.Gettext/Makefile.am +++ b/main/src/addins/MonoDevelop.Gettext/Makefile.am @@ -8,13 +8,13 @@ DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.DesignerSupport/MonoDevelop.DesignerSupport.dll \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Core \ diff --git a/main/src/addins/MonoDevelop.GtkCore/Makefile.am b/main/src/addins/MonoDevelop.GtkCore/Makefile.am index ea49ad60bf..9dcd90e743 100644 --- a/main/src/addins/MonoDevelop.GtkCore/Makefile.am +++ b/main/src/addins/MonoDevelop.GtkCore/Makefile.am @@ -12,14 +12,14 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.Cecil.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLADE_SHARP_LIBS) \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Core \ diff --git a/main/src/addins/MonoDevelop.HexEditor/Makefile.am b/main/src/addins/MonoDevelop.HexEditor/Makefile.am index 5b42ee17c5..f191c4315b 100644 --- a/main/src/addins/MonoDevelop.HexEditor/Makefile.am +++ b/main/src/addins/MonoDevelop.HexEditor/Makefile.am @@ -50,14 +50,14 @@ DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.Refactoring/MonoDevelop.Refactoring.dll \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLADE_SHARP_LIBS) \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Cairo \ -r:Mono.Posix \ -r:System \ diff --git a/main/src/addins/MonoDevelop.MacDev/Makefile.am b/main/src/addins/MonoDevelop.MacDev/Makefile.am index ccd87fff7c..454438bf32 100644 --- a/main/src/addins/MonoDevelop.MacDev/Makefile.am +++ b/main/src/addins/MonoDevelop.MacDev/Makefile.am @@ -8,14 +8,14 @@ DEPS = \ ../../../build/AddIns/VersionControl/MonoDevelop.VersionControl.dll \ ../../../build/bin/ICSharpCode.NRefactory.dll \ ../../../build/bin/Mono.TextEditor.dll \ - ../../../build/bin/MonoDevelop.Core.dll \ - ../../../build/bin/MonoDevelop.Ide.dll + ../../../build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ -r:../../../../extras/MonoDevelop.MonoMac/MonoDevelop.MonoMac/MonoMac.dll \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Cairo \ -r:Mono.Posix \ -r:System \ diff --git a/main/src/addins/MonoDevelop.MacDev/ObjCIntegration/NSObjectInfoService.cs b/main/src/addins/MonoDevelop.MacDev/ObjCIntegration/NSObjectInfoService.cs index 4447acab86..831d85603f 100755 --- a/main/src/addins/MonoDevelop.MacDev/ObjCIntegration/NSObjectInfoService.cs +++ b/main/src/addins/MonoDevelop.MacDev/ObjCIntegration/NSObjectInfoService.cs @@ -81,7 +81,6 @@ namespace MonoDevelop.MacDev.ObjCIntegration var dom = TypeSystemService.GetProjectContentWrapper (project); if (dom == null) return null; - TypeSystemService.ForceUpdate (dom); project.ReferenceAddedToProject += HandleDomReferencesUpdated; project.ReferenceRemovedFromProject += HandleDomReferencesUpdated; return GetProjectInfo (dom, lookinAssembly); diff --git a/main/src/addins/MonoDevelop.MacDev/ObjCIntegration/NSObjectProjectInfo.cs b/main/src/addins/MonoDevelop.MacDev/ObjCIntegration/NSObjectProjectInfo.cs index 6e6c3983cd..25a60d3daf 100755 --- a/main/src/addins/MonoDevelop.MacDev/ObjCIntegration/NSObjectProjectInfo.cs +++ b/main/src/addins/MonoDevelop.MacDev/ObjCIntegration/NSObjectProjectInfo.cs @@ -77,7 +77,12 @@ namespace MonoDevelop.MacDev.ObjCIntegration { if (!needsUpdating) return; - + foreach (var r in dom.GetReferencedProjects ()) { + var info = infoService.GetProjectInfo (r); + if (info != null) + info.Update (); + } + TypeSystemService.ForceUpdate (dom); objcTypes.Clear (); cliTypes.Clear (); refObjcTypes.Clear (); diff --git a/main/src/addins/MonoDevelop.MacDev/XcodeSyncing/XcodeProjectTracker.cs b/main/src/addins/MonoDevelop.MacDev/XcodeSyncing/XcodeProjectTracker.cs index aa99545cc8..9e425e2101 100644 --- a/main/src/addins/MonoDevelop.MacDev/XcodeSyncing/XcodeProjectTracker.cs +++ b/main/src/addins/MonoDevelop.MacDev/XcodeSyncing/XcodeProjectTracker.cs @@ -174,7 +174,7 @@ namespace MonoDevelop.MacDev.XcodeSyncing try { EnableSyncing (monitor); - if (!UpdateTypes (monitor, true) || monitor.IsCancelRequested) + if (!UpdateTypes (monitor) || monitor.IsCancelRequested) return false; if (!UpdateXcodeProject (monitor) || monitor.IsCancelRequested) @@ -323,7 +323,7 @@ namespace MonoDevelop.MacDev.XcodeSyncing using (var monitor = GetStatusMonitor (GettextCatalog.GetString ("Syncing types to Xcode..."))) { //FIXME: make this async (and safely async) //FIXME: only update the project if obj-c types change - updateProject |= UpdateTypes (monitor, true); + updateProject |= UpdateTypes (monitor); } } @@ -365,7 +365,7 @@ namespace MonoDevelop.MacDev.XcodeSyncing #region Outbound syncing - bool UpdateTypes (IProgressMonitor monitor, bool force) + bool UpdateTypes (IProgressMonitor monitor) { monitor.BeginTask (GettextCatalog.GetString ("Updating Objective-C type information"), 0); try { @@ -373,7 +373,7 @@ namespace MonoDevelop.MacDev.XcodeSyncing if (pinfo == null) throw new Exception ("Did not get project info"); // FIXME: report progress - pinfo.Update (force); + pinfo.Update (true); userTypes = pinfo.GetTypes ().Where (t => t.IsUserType).ToList (); return true; } catch (Exception ex) { diff --git a/main/src/addins/MonoDevelop.MacDev/XcodeSyncing/XcodeSyncBackContext.cs b/main/src/addins/MonoDevelop.MacDev/XcodeSyncing/XcodeSyncBackContext.cs index 5a18d2d67c..e786e90948 100644 --- a/main/src/addins/MonoDevelop.MacDev/XcodeSyncing/XcodeSyncBackContext.cs +++ b/main/src/addins/MonoDevelop.MacDev/XcodeSyncing/XcodeSyncBackContext.cs @@ -70,7 +70,13 @@ namespace MonoDevelop.MacDev.XcodeSyncing public NSObjectProjectInfo ProjectInfo { get { - return pinfo ?? (pinfo = InfoService.GetProjectInfo (Project)); + if (pinfo == null) + pinfo = InfoService.GetProjectInfo (Project); + + if (pinfo != null) + pinfo.Update (true); + + return pinfo; } } diff --git a/main/src/addins/MonoDevelop.Moonlight/Makefile.am b/main/src/addins/MonoDevelop.Moonlight/Makefile.am index 081c83253a..07e1dfcca3 100644 --- a/main/src/addins/MonoDevelop.Moonlight/Makefile.am +++ b/main/src/addins/MonoDevelop.Moonlight/Makefile.am @@ -7,12 +7,12 @@ DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.DesignerSupport/MonoDevelop.DesignerSupport.dll \ $(top_builddir)/build/AddIns/MonoDevelop.XmlEditor/MonoDevelop.XmlEditor.dll \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:ICSharpCode.SharpZipLib \ -r:Mono.Posix \ -r:System \ diff --git a/main/src/addins/MonoDevelop.Refactoring/Makefile.am b/main/src/addins/MonoDevelop.Refactoring/Makefile.am index c637b8fc9f..78d328630b 100644 --- a/main/src/addins/MonoDevelop.Refactoring/Makefile.am +++ b/main/src/addins/MonoDevelop.Refactoring/Makefile.am @@ -8,13 +8,13 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.CSharp.dll \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Cairo \ -r:Mono.Posix \ -r:System \ diff --git a/main/src/addins/MonoDevelop.RegexToolkit/Makefile.am b/main/src/addins/MonoDevelop.RegexToolkit/Makefile.am index 0c2507bf35..081b99cc30 100644 --- a/main/src/addins/MonoDevelop.RegexToolkit/Makefile.am +++ b/main/src/addins/MonoDevelop.RegexToolkit/Makefile.am @@ -4,13 +4,13 @@ ASSEMBLY = $(ADDIN_BUILD)/MonoDevelop.RegexToolkit.dll DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.DesignerSupport/MonoDevelop.DesignerSupport.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Data \ diff --git a/main/src/addins/MonoDevelop.SourceEditor2/Makefile.am b/main/src/addins/MonoDevelop.SourceEditor2/Makefile.am index c06f3b2e65..5b1db0d8df 100644 --- a/main/src/addins/MonoDevelop.SourceEditor2/Makefile.am +++ b/main/src/addins/MonoDevelop.SourceEditor2/Makefile.am @@ -66,13 +66,13 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.Debugging.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Cairo \ -r:Mono.Posix \ -r:System \ diff --git a/main/src/addins/MonoDevelop.WebReferences/Makefile.am b/main/src/addins/MonoDevelop.WebReferences/Makefile.am index 54749f7638..5e417d4632 100644 --- a/main/src/addins/MonoDevelop.WebReferences/Makefile.am +++ b/main/src/addins/MonoDevelop.WebReferences/Makefile.am @@ -2,14 +2,13 @@ ADDIN_BUILD = $(top_builddir)/build/AddIns/MonoDevelop.WebReferences ASSEMBLY = $(ADDIN_BUILD)/MonoDevelop.WebReferences.dll -DEPS = \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll +DEPS = $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Configuration \ diff --git a/main/src/addins/MonoDevelop.XmlEditor/Makefile.am b/main/src/addins/MonoDevelop.XmlEditor/Makefile.am index cb47c85432..efbd831f62 100644 --- a/main/src/addins/MonoDevelop.XmlEditor/Makefile.am +++ b/main/src/addins/MonoDevelop.XmlEditor/Makefile.am @@ -9,14 +9,14 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.Debugging.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLADE_SHARP_LIBS) \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Core \ diff --git a/main/src/addins/MonoDeveloperExtensions/Makefile.am b/main/src/addins/MonoDeveloperExtensions/Makefile.am index 31477fdbd2..1567703870 100644 --- a/main/src/addins/MonoDeveloperExtensions/Makefile.am +++ b/main/src/addins/MonoDeveloperExtensions/Makefile.am @@ -7,13 +7,12 @@ FILES = \ MonoMakefileFormat.cs \ MonoSolutionItemHandler.cs -DEPS = \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll +DEPS = $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:System \ -r:System.Data \ -r:System.Xml diff --git a/main/src/addins/NUnit/Makefile.am b/main/src/addins/NUnit/Makefile.am index 4dcf8974ad..f8704e0c5c 100644 --- a/main/src/addins/NUnit/Makefile.am +++ b/main/src/addins/NUnit/Makefile.am @@ -7,14 +7,14 @@ DEPS = \ $(top_builddir)/build/AddIns/NUnit/NUnitRunner.dll \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLADE_SHARP_LIBS) \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:$(top_srcdir)/build/bin/MonoDevelop.Ide.dll \ -r:$(top_srcdir)/src/addins/NUnit/lib/nunit.core.dll \ -r:$(top_srcdir)/src/addins/NUnit/lib/nunit.core.interfaces.dll \ -r:$(top_srcdir)/src/addins/NUnit/lib/nunit.framework.dll \ diff --git a/main/src/addins/TextTemplating/MonoDevelop.TextTemplating/Makefile.am b/main/src/addins/TextTemplating/MonoDevelop.TextTemplating/Makefile.am index 670a6eabe3..cb6cc46f9a 100644 --- a/main/src/addins/TextTemplating/MonoDevelop.TextTemplating/Makefile.am +++ b/main/src/addins/TextTemplating/MonoDevelop.TextTemplating/Makefile.am @@ -7,12 +7,12 @@ DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.TextTemplating/Mono.TextTemplating.dll \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ -r:System \ -r:System.Core diff --git a/main/src/addins/VBNetBinding/Makefile.am b/main/src/addins/VBNetBinding/Makefile.am index 354e928849..4ea960bcb3 100644 --- a/main/src/addins/VBNetBinding/Makefile.am +++ b/main/src/addins/VBNetBinding/Makefile.am @@ -4,13 +4,13 @@ ASSEMBLY = $(ADDIN_BUILD)/MonoDevelop.VBNetBinding.dll DEPS = \ $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll \ $(top_builddir)/build/bin/OldNRefactory.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Core \ diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Git/Makefile.am b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Git/Makefile.am index 1759861107..b0e99af144 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Git/Makefile.am +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Git/Makefile.am @@ -8,7 +8,6 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll \ $(top_builddir)/contrib/bin/NGit.dll \ $(top_builddir)/contrib/bin/NSch.dll \ $(top_builddir)/contrib/bin/Sharpen.dll @@ -16,6 +15,7 @@ DEPS = \ REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Core diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion/Makefile.am b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion/Makefile.am index 0bb8b9735e..20cade8045 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion/Makefile.am +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion/Makefile.am @@ -7,12 +7,12 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.CSharp.dll \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Core diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl/Makefile.am b/main/src/addins/VersionControl/MonoDevelop.VersionControl/Makefile.am index 6ae08a3ac1..755297b2fe 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl/Makefile.am +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl/Makefile.am @@ -88,13 +88,13 @@ DEPS = \ $(top_builddir)/build/bin/ICSharpCode.NRefactory.dll \ $(top_builddir)/build/bin/Mono.Debugging.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll + $(top_builddir)/build/bin/MonoDevelop.Core.dll REFS = \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Cairo \ -r:Mono.Posix \ -r:System \ diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl/VersionControlNodeExtension.cs b/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl/VersionControlNodeExtension.cs index 1250bad1b6..17505e2a04 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl/VersionControlNodeExtension.cs +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl/VersionControlNodeExtension.cs @@ -51,7 +51,7 @@ namespace MonoDevelop.VersionControl ClearDirCache (ce.BaseDirectory);
Repository rep = VersionControlService.GetRepository (ce); if (rep != null) - AddFolderOverlay (rep, ce.BaseDirectory, ref icon, ref closedIcon);
+ AddFolderOverlay (rep, ce.BaseDirectory, ref icon, ref closedIcon, false);
return; } else if (dataObject is ProjectFolder) { ProjectFolder ce = (ProjectFolder) dataObject;
@@ -59,7 +59,7 @@ namespace MonoDevelop.VersionControl ClearDirCache (ce.Path);
Repository rep = VersionControlService.GetRepository (ce.ParentWorkspaceObject); if (rep != null) - AddFolderOverlay (rep, ce.Path, ref icon, ref closedIcon);
+ AddFolderOverlay (rep, ce.Path, ref icon, ref closedIcon, true);
} return; } @@ -93,14 +93,15 @@ namespace MonoDevelop.VersionControl AddOverlay (ref icon, overlay);
}
- void AddFolderOverlay (Repository rep, string folder, ref Gdk.Pixbuf icon, ref Gdk.Pixbuf closedIcon) + void AddFolderOverlay (Repository rep, string folder, ref Gdk.Pixbuf icon, ref Gdk.Pixbuf closedIcon, bool skipVersionedOverlay) { Gdk.Pixbuf overlay = null; VersionInfo vinfo = rep.GetVersionInfo (folder, false); if (vinfo == null || !vinfo.IsVersioned) { overlay = VersionControlService.LoadOverlayIconForStatus (VersionStatus.Unversioned); - } else if (vinfo.IsVersioned && !vinfo.HasLocalChanges) { - overlay = VersionControlService.overlay_controled; + } else if (vinfo.IsVersioned && !vinfo.HasLocalChanges) {
+ if (!skipVersionedOverlay) + overlay = VersionControlService.overlay_controled; } else { overlay = VersionControlService.LoadOverlayIconForStatus (vinfo.Status); } diff --git a/main/src/addins/prj2make-sharp-lib/Makefile.am b/main/src/addins/prj2make-sharp-lib/Makefile.am index ba37cfcbf0..64a94a9a7a 100644 --- a/main/src/addins/prj2make-sharp-lib/Makefile.am +++ b/main/src/addins/prj2make-sharp-lib/Makefile.am @@ -9,12 +9,12 @@ DEPS = \ $(top_builddir)/build/AddIns/MonoDevelop.Refactoring/MonoDevelop.Refactoring.dll \ $(top_builddir)/build/bin/Mono.TextEditor.dll \ $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll \ $(top_builddir)/build/bin/OldNRefactory.dll REFS = \ $(GTK_SHARP_LIBS) \ $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Posix \ -r:System \ -r:System.Xml diff --git a/main/src/core/MonoDevelop.Core/Makefile.am b/main/src/core/MonoDevelop.Core/Makefile.am index f274796f82..8b2b240fab 100644 --- a/main/src/core/MonoDevelop.Core/Makefile.am +++ b/main/src/core/MonoDevelop.Core/Makefile.am @@ -79,6 +79,7 @@ FILES = \ MonoDevelop.Core.FileSystem/UnixFileSystemExtension.cs \ MonoDevelop.Core.Instrumentation/Counter.cs \ MonoDevelop.Core.Instrumentation/CounterCategory.cs \ + MonoDevelop.Core.Instrumentation/IInstrumentationConsumer.cs \ MonoDevelop.Core.Instrumentation/InstrumentationService.cs \ MonoDevelop.Core.Instrumentation/MemoryProbe.cs \ MonoDevelop.Core.Instrumentation/TimeCounter.cs \ diff --git a/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Instrumentation/Counter.cs b/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Instrumentation/Counter.cs index c3c2202308..11ce9e69ad 100644 --- a/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Instrumentation/Counter.cs +++ b/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Instrumentation/Counter.cs @@ -43,7 +43,30 @@ namespace MonoDevelop.Core.Instrumentation DateTime lastValueTime = DateTime.MinValue; CounterDisplayMode displayMode = CounterDisplayMode.Block; bool disposed; + bool storeValues; + bool enabled; + List<IInstrumentationConsumer> handlers = new List<IInstrumentationConsumer> (); + + public bool StoreValues { + get { + return storeValues; + } + set { + storeValues = value; + } + } + + internal List<IInstrumentationConsumer> Handlers { + get { return handlers; } + } + + internal void UpdateStatus () + { + enabled = InstrumentationService.Enabled || handlers.Count > 0; + storeValues = InstrumentationService.Enabled; + } + internal Counter (string name, CounterCategory category) { this.name = name; @@ -166,7 +189,13 @@ namespace MonoDevelop.Core.Instrumentation if (now - lastValueTime < resolution) return -1; } - values.Add (new CounterValue (count, totalCount, now, message, traces)); + var val = new CounterValue (count, totalCount, now, message, traces); + if (storeValues) + values.Add (val); + if (handlers.Count > 0) { + foreach (var h in handlers) + h.ConsumeValue (this, val); + } return values.Count - 1; } @@ -198,7 +227,7 @@ namespace MonoDevelop.Core.Instrumentation public void Inc (int n, string message) { - if (InstrumentationService.Enabled) { + if (enabled) { lock (values) { count += n; totalCount += n; @@ -226,7 +255,7 @@ namespace MonoDevelop.Core.Instrumentation public void Dec (int n, string message) { - if (InstrumentationService.Enabled) { + if (enabled) { lock (values) { count -= n; StoreValue (message, null); @@ -243,7 +272,7 @@ namespace MonoDevelop.Core.Instrumentation public void SetValue (int value, string message) { - if (InstrumentationService.Enabled) { + if (enabled) { lock (values) { count = value; StoreValue (message, null); @@ -272,7 +301,7 @@ namespace MonoDevelop.Core.Instrumentation public virtual void Trace (string message) { - if (InstrumentationService.Enabled) { + if (enabled) { lock (values) { StoreValue (message, null); } diff --git a/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Instrumentation/IInstrumentationConsumer.cs b/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Instrumentation/IInstrumentationConsumer.cs new file mode 100644 index 0000000000..9f6af53387 --- /dev/null +++ b/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Instrumentation/IInstrumentationConsumer.cs @@ -0,0 +1,37 @@ +// +// IInstrumentationConsumer.cs +// +// Author: +// Lluis Sanchez <lluis@xamarin.com> +// +// Copyright (c) 2012 Xamarin Inc +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. +using System; + +namespace MonoDevelop.Core.Instrumentation +{ + [Mono.Addins.TypeExtensionPoint] + public interface IInstrumentationConsumer + { + bool SupportsCounter (Counter counter); + void ConsumeValue (Counter counter, CounterValue value); + } +} + diff --git a/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Instrumentation/InstrumentationService.cs b/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Instrumentation/InstrumentationService.cs index fa77cc8255..ce2f1ce370 100644 --- a/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Instrumentation/InstrumentationService.cs +++ b/main/src/core/MonoDevelop.Core/MonoDevelop.Core.Instrumentation/InstrumentationService.cs @@ -40,6 +40,7 @@ using System.Threading; using System.Linq; using System.Runtime.Serialization.Formatters.Binary; using MonoDevelop.Core.Execution; +using Mono.Addins; namespace MonoDevelop.Core.Instrumentation { @@ -53,6 +54,8 @@ namespace MonoDevelop.Core.Instrumentation static Thread autoSaveThread; static bool stopping; static int autoSaveInterval; + static List<IInstrumentationConsumer> handlers = new List<IInstrumentationConsumer> (); + static bool handlersLoaded; static InstrumentationService () { @@ -61,6 +64,46 @@ namespace MonoDevelop.Core.Instrumentation startTime = DateTime.Now; } + static void InitializeHandlers () + { + if (!handlersLoaded && AddinManager.IsInitialized) { + lock (counters) { + handlersLoaded = true; + AddinManager.AddExtensionNodeHandler (typeof(IInstrumentationConsumer), HandleInstrumentationHandlerExtension); + } + } + } + + static void UpdateCounterStatus () + { + lock (counters) { + foreach (var c in counters.Values) + c.UpdateStatus (); + } + } + + static void HandleInstrumentationHandlerExtension (object sender, ExtensionNodeEventArgs args) + { + var handler = (IInstrumentationConsumer)args.ExtensionObject; + if (args.Change == ExtensionChange.Add) { + handlers.Add (handler); + lock (counters) { + foreach (var c in counters.Values) { + if (handler.SupportsCounter (c)) + c.Handlers.Add (handler); + } + } + } + else { + handlers.Remove (handler); + lock (counters) { + foreach (var c in counters.Values) + c.Handlers.Remove (handler); + } + } + UpdateCounterStatus (); + } + public static int PublishService () { RemotingService.RegisterRemotingChannel (); @@ -156,7 +199,10 @@ namespace MonoDevelop.Core.Instrumentation public static bool Enabled { get { return enabled; } - set { enabled = value; } + set { + enabled = value; + UpdateCounterStatus (); + } } public static DateTime StartTime { @@ -180,6 +226,8 @@ namespace MonoDevelop.Core.Instrumentation static Counter CreateCounter (string name, string category, bool logMessages, bool isTimer) { + InitializeHandlers (); + if (category == null) category = "Global"; @@ -198,6 +246,13 @@ namespace MonoDevelop.Core.Instrumentation if (counters.TryGetValue (name, out old)) old.Disposed = true; counters [name] = c; + + foreach (var h in handlers) { + if (h.SupportsCounter (c)) + c.Handlers.Add (h); + } + c.UpdateStatus (); + return c; } } diff --git a/main/src/core/MonoDevelop.Core/MonoDevelop.Core.csproj b/main/src/core/MonoDevelop.Core/MonoDevelop.Core.csproj index b53d35bc97..ae85339bc7 100644 --- a/main/src/core/MonoDevelop.Core/MonoDevelop.Core.csproj +++ b/main/src/core/MonoDevelop.Core/MonoDevelop.Core.csproj @@ -407,6 +407,7 @@ <Compile Include="MonoDevelop.Core\PasswordService.cs" /> <Compile Include="MonoDevelop.Core\IPasswordProvider.cs" /> <Compile Include="MonoDevelop.Projects.Utility\ByteOrderMark.cs" /> + <Compile Include="MonoDevelop.Core.Instrumentation\IInstrumentationConsumer.cs" /> </ItemGroup> <ItemGroup> <None Include="Makefile.am" /> diff --git a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Dom.Serialization/CodeCompletionDatabase.cs b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Dom.Serialization/CodeCompletionDatabase.cs index ac31152193..48a0b988f4 100644 --- a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Dom.Serialization/CodeCompletionDatabase.cs +++ b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Dom.Serialization/CodeCompletionDatabase.cs @@ -44,6 +44,7 @@ using Mono.Addins; using System.Reflection; using MonoDevelop.Projects.Dom.Parser; using MonoDevelop.Core.Instrumentation; +using System.Collections.Concurrent; namespace MonoDevelop.Projects.Dom.Serialization { @@ -51,7 +52,7 @@ namespace MonoDevelop.Projects.Dom.Serialization { static protected readonly int MAX_ACTIVE_COUNT = 100; static protected readonly int MIN_ACTIVE_COUNT = 10; - static protected readonly int FORMAT_VERSION = 85; + static protected readonly int FORMAT_VERSION = 86; Dictionary<string, ClassEntry> typeEntries = new Dictionary<string, ClassEntry> (); Dictionary<string, ClassEntry> typeEntriesIgnoreCase = new Dictionary<string, ClassEntry> (StringComparer.InvariantCultureIgnoreCase); @@ -105,11 +106,11 @@ namespace MonoDevelop.Projects.Dom.Serialization classEntriesIgnoreCase.Clear (); namespaceEntries.Clear (); namespaceEntriesIgnoreCase.Clear (); - namespaceEntriesIgnoreCase[""] = namespaceEntries[""] = new List<Namespace> (); + namespaceEntriesIgnoreCase [""] = namespaceEntries [""] = new List<Namespace> (); foreach (ClassEntry ce in typeEntries.Values) { if (!classEntries.ContainsKey (ce.Namespace)) - classEntriesIgnoreCase[ce.Namespace] = classEntries[ce.Namespace] = new List<ClassEntry> (); - classEntries[ce.Namespace].Add (ce); + classEntriesIgnoreCase [ce.Namespace] = classEntries [ce.Namespace] = new List<ClassEntry> (); + classEntries [ce.Namespace].Add (ce); AddNamespace (ce.Namespace); } } @@ -262,11 +263,11 @@ namespace MonoDevelop.Projects.Dom.Serialization void Read (bool verify) { - if (!File.Exists (dataFile)) return; + if (!File.Exists (dataFile)) + return; ITimeTracker timer = Counters.DatabasesRead.BeginTiming ("Reading Parser Database " + dataFile); - lock (rwlock) - { + lock (rwlock) { timer.Trace ("Clearing"); Clear (); @@ -282,8 +283,7 @@ namespace MonoDevelop.Projects.Dom.Serialization return; } - try - { + try { Modified = false; currentGetTime = 0; @@ -292,8 +292,8 @@ namespace MonoDevelop.Projects.Dom.Serialization timer.Trace ("Read headers"); // Read the headers - headers = (Hashtable) bf.Deserialize (dataFileStream); - int ver = (int) headers["Version"]; + headers = (Hashtable)bf.Deserialize (dataFileStream); + int ver = (int)headers ["Version"]; if (ver != FORMAT_VERSION) throw new OldPidbVersionException (ver, FORMAT_VERSION); @@ -303,23 +303,24 @@ namespace MonoDevelop.Projects.Dom.Serialization BinaryReader br = new BinaryReader (dataFileStream); long indexOffset = br.ReadInt64 (); dataFileStream.Position = indexOffset; - + object oo = bf.Deserialize (dataFileStream); - object[] data = (object[]) oo; + object[] data = (object[])oo; Queue dataQueue = new Queue (data); - references = (List<ReferenceEntry>) dataQueue.Dequeue () ?? new List<ReferenceEntry> (); - typeEntries = (Dictionary<string, ClassEntry>) dataQueue.Dequeue () ?? new Dictionary<string, ClassEntry> (); - files = (Dictionary<string, FileEntry>) dataQueue.Dequeue () ?? new Dictionary<string, FileEntry> (); - unresolvedSubclassTable = (Hashtable) dataQueue.Dequeue () ?? new Hashtable (); + references = (List<ReferenceEntry>)dataQueue.Dequeue () ?? new List<ReferenceEntry> (); + KeyValuePair<string, ClassEntry>[] entries = (KeyValuePair<string, ClassEntry>[])dataQueue.Dequeue () ?? new KeyValuePair<string, ClassEntry>[0]; + typeEntries = new Dictionary<string, ClassEntry> (); + foreach (var entry in entries) + typeEntries [entry.Key] = entry.Value; + files = (Dictionary<string, FileEntry>)dataQueue.Dequeue () ?? new Dictionary<string, FileEntry> (); + unresolvedSubclassTable = (Hashtable)dataQueue.Dequeue () ?? new Hashtable (); // Read the global attributes position globalAttributesPosition = br.ReadInt64 (); DeserializeData (dataQueue); UpdateClassEntries (); - } - catch (Exception ex) - { + } catch (Exception ex) { OldPidbVersionException opvEx = ex as OldPidbVersionException; if (opvEx != null) LoggingService.LogWarning ("PIDB file '{0}' could not be loaded. Expected version {1}, found version {2}'. The file will be recreated.", dataFile, opvEx.ExpectedVersion, opvEx.FoundVersion); @@ -333,7 +334,7 @@ namespace MonoDevelop.Projects.Dom.Serialization // Notify read comments foreach (FileEntry fe in files.Values) { - if (!fe.IsAssembly && fe.CommentTasks != null) {
+ if (!fe.IsAssembly && fe.CommentTasks != null) { ProjectDomService.UpdatedCommentTasks (fe.FileName, fe.CommentTasks, Project); } } @@ -352,7 +353,7 @@ namespace MonoDevelop.Projects.Dom.Serialization LoggingService.LogWarning ("PIDB file verification failed. Class '" + ce.Name + "' could not be deserialized: " + ex.Message); } } - /* foreach (FileEntry fe in files.Values) { + /* foreach (FileEntry fe in files.Values) { foreach (ClassEntry ce in fe.ClassEntries) { if (!classes.Contains (ce)) LoggingService.LogWarning ("PIDB file verification failed. Class '" + ce.Name + "' from file '" + fe.FileName + "' not found in main index."); @@ -362,15 +363,15 @@ namespace MonoDevelop.Projects.Dom.Serialization } foreach (ClassEntry ce in classes) LoggingService.LogWarning ("PIDB file verification failed. Class '" + ce.Name + "' not found in file index."); - */ } + */ + } timer.Trace ("Notify tag changes"); // Update comments if needed... CommentTagSet lastTags = new CommentTagSet (LastValidTaskListTokens); if (!lastTags.Equals (ProjectDomService.SpecialCommentTags)) OnSpecialTagsChanged (null, null); - } - finally { + } finally { timer.End (); } } @@ -532,7 +533,7 @@ namespace MonoDevelop.Projects.Dom.Serialization Queue dataQueue = new Queue (); dataQueue.Enqueue (references); - dataQueue.Enqueue (typeEntries); + dataQueue.Enqueue (typeEntries.ToArray ()); dataQueue.Enqueue (files); dataQueue.Enqueue (unresolvedSubclassTable); SerializeData (dataQueue); @@ -610,8 +611,12 @@ namespace MonoDevelop.Projects.Dom.Serialization internal IEnumerable<ClassEntry> GetAllClasses () { - // ensure that the GetAllClasses methods is save of type entry changes - return this.typeEntries.Values.Where (ce => ce != null).ToArray (); + var entries = this.typeEntries.ToArray (); + foreach (var entry in entries) { + if (entry.Value == null) + continue; + yield return entry.Value; + } } public void Flush () @@ -1024,14 +1029,14 @@ namespace MonoDevelop.Projects.Dom.Serialization public void RemoveFile (string fileName) { - lock (rwlock) - { + lock (rwlock) { TypeUpdateInformation classInfo = new TypeUpdateInformation (); FileEntry fe; - if (!files.TryGetValue (fileName, out fe)) return; + if (!files.TryGetValue (fileName, out fe)) + return; - int te=0, tc=0; + int te = 0, tc = 0; foreach (ClassEntry ce in fe.ClassEntries) { LoadClass (ce); @@ -1064,8 +1069,7 @@ namespace MonoDevelop.Projects.Dom.Serialization public TypeUpdateInformation UpdateTypeInformation (IList<IType> newClasses, IEnumerable<IAttribute> fileAttributes, string fileName) { - lock (rwlock) - { + lock (rwlock) { TypeUpdateInformation res = new TypeUpdateInformation (); FileEntry fe; if (!files.TryGetValue (fileName, out fe)) @@ -1085,20 +1089,18 @@ namespace MonoDevelop.Projects.Dom.Serialization // Update types bool[] added = new bool [newClasses.Count]; - for (int n = 0; n < newClasses.Count; n++) { - ((DomType)newClasses[n]).SourceProjectDom = sourceProjectDom; + for( int n = 0; n < newClasses.Count; n++) { + ((DomType)newClasses [n]).SourceProjectDom = sourceProjectDom; } List<ClassEntry> newFileClasses = new List<ClassEntry> (); - if (fe != null) - { - foreach (ClassEntry ce in fe.ClassEntries) - { + if (fe != null) { + foreach (ClassEntry ce in fe.ClassEntries) { IType newClass = null; - for (int n=0; n<newClasses.Count && newClass == null; n++) { + for( int n=0; n<newClasses.Count && newClass == null; n++) { IType uc = newClasses [n]; - if (uc.Name == ce.Name && uc.TypeParameters.Count == ce.TypeParameterCount && uc.Namespace == ce.Namespace) { + if (uc.Name == ce.Name && uc.TypeParameters.Count == ce.TypeParameterCount && uc.Namespace == ce.Namespace) { newClass = newClass == null ? uc : CompoundType.Merge (newClass, uc); - added[n] = true; + added [n] = true; } } @@ -1111,7 +1113,7 @@ namespace MonoDevelop.Projects.Dom.Serialization ce.Class = tp != null ? CompoundType.Merge (tp, newClass) : newClass; AddSubclassReferences (ce); string name = ce.Class.DecoratedFullName; - typeEntriesIgnoreCase[name] = typeEntries[name] = ce; + typeEntriesIgnoreCase [name] = typeEntries [name] = ce; ce.LastGetTime = currentGetTime++; newFileClasses.Add (ce); res.Modified.Add (ce.Class); diff --git a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Formats.MSBuild/MSBuildProjectService.cs b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Formats.MSBuild/MSBuildProjectService.cs index e3fff3dafc..7c2461a99b 100644 --- a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Formats.MSBuild/MSBuildProjectService.cs +++ b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Formats.MSBuild/MSBuildProjectService.cs @@ -50,9 +50,8 @@ namespace MonoDevelop.Projects.Formats.MSBuild //NOTE: default toolsversion should match the default format. // remember to update the builder process' app.config too - public const string DefaultFormat = "MSBuild08"; - const string REFERENCED_MSBUILD_TOOLS = "3.5"; - const string REFERENCED_MSBUILD_UTILS = "Microsoft.Build.Utilities.v3.5"; + public const string DefaultFormat = "MSBuild10"; + const string REFERENCED_MSBUILD_TOOLS = "4.0"; internal const string DefaultToolsVersion = REFERENCED_MSBUILD_TOOLS; static DataContext dataContext; @@ -490,69 +489,11 @@ namespace MonoDevelop.Projects.Formats.MSBuild if (toolsVersion == REFERENCED_MSBUILD_TOOLS) return sourceExe; - var newVersions = new Dictionary<string, string[]> (); - string version; - Mono.Cecil.TargetRuntime runtime; + var exe = sourceExe.ParentDirectory.Combine ("MSBuild", toolsVersion, sourceExe.FileName); + if (File.Exists (exe)) + return exe; - switch (toolsVersion) { - case "2.0": - version = "2.0.0.0"; - newVersions.Add ("Microsoft.Build.Engine", new string[] {"Microsoft.Build.Engine", version}); - newVersions.Add ("Microsoft.Build.Framework", new string[] {"Microsoft.Build.Framework", version}); - newVersions.Add (REFERENCED_MSBUILD_UTILS, new string[] {"Microsoft.Build.Utilities", version}); - runtime = Mono.Cecil.TargetRuntime.Net_2_0; - break; - case "3.5": - version = "3.5.0.0"; - newVersions.Add ("Microsoft.Build.Engine", new string[] {"Microsoft.Build.Engine", version}); - newVersions.Add ("Microsoft.Build.Framework", new string[] {"Microsoft.Build.Framework", version}); - newVersions.Add (REFERENCED_MSBUILD_UTILS, new string[] {"Microsoft.Build.Utilities.v3.5", version}); - runtime = Mono.Cecil.TargetRuntime.Net_2_0; - break; - case "4.0": - version = "4.0.0.0"; - newVersions.Add ("Microsoft.Build.Engine", new string[] {"Microsoft.Build.Engine", version}); - newVersions.Add ("Microsoft.Build.Framework", new string[] {"Microsoft.Build.Framework", version}); - newVersions.Add (REFERENCED_MSBUILD_UTILS, new string[] {"Microsoft.Build.Utilities.v4.0", version}); - runtime = Mono.Cecil.TargetRuntime.Net_4_0; - break; - default: - throw new InvalidOperationException ("Unknown MSBuild ToolsVersion '" + toolsVersion + "'"); - } - - FilePath p = UserProfile.Current.CacheDir.Combine ("xbuild", toolsVersion, "MonoDevelop.Projects.Formats.MSBuild.exe"); - if (!File.Exists (p) || File.GetLastWriteTime (p) < File.GetLastWriteTime (sourceExe)) { - if (!Directory.Exists (p.ParentDirectory)) - Directory.CreateDirectory (p.ParentDirectory); - - // Update the references to msbuild - Cecil.AssemblyDefinition asm = Cecil.AssemblyDefinition.ReadAssembly (sourceExe); - foreach (Cecil.AssemblyNameReference ar in asm.MainModule.AssemblyReferences) { - string[] replacement; - if (newVersions.TryGetValue (ar.Name, out replacement)) { - ar.Name = replacement[0]; - ar.Version = new Version (replacement[1]); - } - } - asm.MainModule.Runtime = runtime; - - //run in 32-bit mode because usually msbuild targets are installed for 32-bit only - asm.MainModule.Attributes |= Mono.Cecil.ModuleAttributes.Required32Bit; - - // Workaround to a bug in mcs. The ILOnly flag is not emitted when using /platform:x86 - asm.MainModule.Attributes |= Mono.Cecil.ModuleAttributes.ILOnly; - - asm.Write (p); - } - - FilePath configFile = p + ".config"; - FilePath configSrc = typeof(ProjectBuilder).Assembly.Location + ".config"; - if (!File.Exists (configFile) || File.GetLastWriteTime (configFile) < File.GetLastWriteTime (configSrc)) { - var config = File.ReadAllText (configSrc); - config = config.Replace (REFERENCED_MSBUILD_TOOLS + ".0.0", version); - File.WriteAllText (p + ".config", config); - } - return p; + throw new InvalidOperationException ("Unsupported MSBuild ToolsVersion '" + toolsVersion + "'"); } internal static void ReleaseProjectBuilder (RemoteBuildEngine engine) diff --git a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/BuildEventHandler.cs b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/BuildEventHandler.cs index 290a02b7d8..ef76135af7 100644 --- a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/BuildEventHandler.cs +++ b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/BuildEventHandler.cs @@ -42,6 +42,10 @@ namespace MonoDevelop.Projects { this.monitor = monitor; this.success = success; + this.WarningCount = -1; + this.ErrorCount = -1; + this.BuildCount = -1; + this.FailedBuildCount = -1; } public IProgressMonitor ProgressMonitor { @@ -51,5 +55,25 @@ namespace MonoDevelop.Projects public bool Success { get { return success; } } + + public int WarningCount { + get; set; + } + + public int ErrorCount { + get; set; + } + + public int BuildCount { + get; set; + } + + public int FailedBuildCount { + get; set; + } + + public SolutionItem SolutionItem { + get; set; + } } } diff --git a/main/src/core/MonoDevelop.Ide/ExtensionModel/MonoDevelop.Ide.addin.xml b/main/src/core/MonoDevelop.Ide/ExtensionModel/MonoDevelop.Ide.addin.xml index 1ac875edcc..0eb36166b9 100644 --- a/main/src/core/MonoDevelop.Ide/ExtensionModel/MonoDevelop.Ide.addin.xml +++ b/main/src/core/MonoDevelop.Ide/ExtensionModel/MonoDevelop.Ide.addin.xml @@ -136,6 +136,11 @@ <Description>Addins can register own fonts to be configured.</Description> <ExtensionNode name="Font" type="MonoDevelop.Ide.Fonts.FontDescriptionCodon"/> </ExtensionPoint> + + <ExtensionPoint path = "/MonoDevelop/Ide/FeedbackService" name = "Feedback reporting service"> + <Description>Provides the webservice url to which MonoDevelop will send user feedback.</Description> + <ExtensionNode name="Service" type="MonoDevelop.Ide.Extensions.ServiceUrlExtensionNode" /> + </ExtensionPoint> <ExtensionPoint path = "/MonoDevelop/Ide/CodeFormatters" name = "Code formatters"> <ExtensionNode name="Formatter" type="MonoDevelop.Ide.CodeFormatting.CodeFormatterExtensionNode" /> diff --git a/main/src/core/MonoDevelop.Ide/Makefile.am b/main/src/core/MonoDevelop.Ide/Makefile.am index a33f0becb1..39666368f9 100644 --- a/main/src/core/MonoDevelop.Ide/Makefile.am +++ b/main/src/core/MonoDevelop.Ide/Makefile.am @@ -373,6 +373,7 @@ FILES = \ MonoDevelop.Ide.Extensions/MimeTypeOptionsPanelNode.cs \ MonoDevelop.Ide.Extensions/OptionsDialogSection.cs \ MonoDevelop.Ide.Extensions/OptionsPanelNode.cs \ + MonoDevelop.Ide.Extensions/ServiceUrlExtensionNode.cs \ MonoDevelop.Ide.Extensions/StartupHandlerExtensionAttribute.cs \ MonoDevelop.Ide.Extensions/StockIconCodon.cs \ MonoDevelop.Ide.Extensions/TextEditorExtensionNode.cs \ @@ -708,6 +709,7 @@ FILES = \ MonoDevelop.Ide/ImageService.cs \ MonoDevelop.Ide/LogReportingStartup.cs \ MonoDevelop.Ide/MessageService.cs \ + MonoDevelop.Ide/ProjectCreatedEventArgs.cs \ MonoDevelop.Ide/ProjectOperations.cs \ MonoDevelop.Ide/RootWorkspace.cs \ MonoDevelop.Ide/Services.cs \ diff --git a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Extensions/ServiceUrlExtensionNode.cs b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Extensions/ServiceUrlExtensionNode.cs new file mode 100644 index 0000000000..9044bce150 --- /dev/null +++ b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Extensions/ServiceUrlExtensionNode.cs @@ -0,0 +1,40 @@ +//
+// ServiceUrlExtensionNode.cs
+//
+// Author:
+// Michael Hutchinson <mhutch@xamarin.com>
+//
+// Copyright (c) 2012 Xamarin Inc.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a copy
+// of this software and associated documentation files (the "Software"), to deal
+// in the Software without restriction, including without limitation the rights
+// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+// copies of the Software, and to permit persons to whom the Software is
+// furnished to do so, subject to the following conditions:
+//
+// The above copyright notice and this permission notice shall be included in
+// all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+// THE SOFTWARE.
+
+using System;
+using Mono.Addins;
+
+namespace MonoDevelop.Ide.Extensions
+{
+ public class ServiceUrlExtensionNode : ExtensionNode
+ {
+ [NodeAttribute (Required=true)]
+ string url;
+
+ public string Url { get { return url; } }
+ }
+}
+
diff --git a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/MonoDevelopStatusBar.cs b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/MonoDevelopStatusBar.cs index ff85cc83c3..c46d209e52 100644 --- a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/MonoDevelopStatusBar.cs +++ b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui/MonoDevelopStatusBar.cs @@ -80,29 +80,31 @@ namespace MonoDevelop.Ide // Feedback button - CustomFrame fr = new CustomFrame (0, 0, 1, 1); - Gdk.Pixbuf px = Gdk.Pixbuf.LoadFromResource ("balloon.png"); - HBox b = new HBox (false, 3); - b.PackStart (new Gtk.Image (px)); - b.PackStart (new Gtk.Label ("Feedback")); - Gtk.Alignment al = new Gtk.Alignment (0f, 0f, 1f, 1f); - al.RightPadding = 5; - al.LeftPadding = 3; - al.Add (b); - feedbackButton = new MiniButton (al); - //feedbackButton.BackroundColor = new Gdk.Color (200, 200, 255); - fr.Add (feedbackButton); - PackStart (fr, false, false, 0); - feedbackButton.Clicked += HandleFeedbackButtonClicked; - feedbackButton.ButtonPressEvent += HandleFeedbackButtonButtonPressEvent;; - feedbackButton.ClickOnRelease = true; - FeedbackService.FeedbackPositionGetter = delegate { - int x, y; - feedbackButton.GdkWindow.GetOrigin (out x, out y); - x += feedbackButton.Allocation.Width; - y -= 6; - return new Gdk.Point (x, y); - }; + if (FeedbackService.Enabled) { + CustomFrame fr = new CustomFrame (0, 0, 1, 1); + Gdk.Pixbuf px = Gdk.Pixbuf.LoadFromResource ("balloon.png"); + HBox b = new HBox (false, 3); + b.PackStart (new Gtk.Image (px)); + b.PackStart (new Gtk.Label ("Feedback")); + Gtk.Alignment al = new Gtk.Alignment (0f, 0f, 1f, 1f); + al.RightPadding = 5; + al.LeftPadding = 3; + al.Add (b); + feedbackButton = new MiniButton (al); + //feedbackButton.BackroundColor = new Gdk.Color (200, 200, 255); + fr.Add (feedbackButton); + PackStart (fr, false, false, 0); + feedbackButton.Clicked += HandleFeedbackButtonClicked; + feedbackButton.ButtonPressEvent += HandleFeedbackButtonButtonPressEvent;; + feedbackButton.ClickOnRelease = true; + FeedbackService.FeedbackPositionGetter = delegate { + int x, y; + feedbackButton.GdkWindow.GetOrigin (out x, out y); + x += feedbackButton.Allocation.Width; + y -= 6; + return new Gdk.Point (x, y); + }; + } // Dock area diff --git a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.csproj b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.csproj index 8c2148cb60..df6ff41682 100644 --- a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.csproj +++ b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide.csproj @@ -1508,6 +1508,8 @@ <Compile Include="gtk-gui\MonoDevelop.Ide.Projects.ExportSolutionDialog.cs" /> <Compile Include="MonoDevelop.Components.Commands\CustomCommandTargetAttribute.cs" /> <Compile Include="MonoDevelop.TypeSystem\MonoDocDocumentationProvider.cs" /> + <Compile Include="MonoDevelop.Ide.Extensions\ServiceUrlExtensionNode.cs" /> + <Compile Include="MonoDevelop.Ide\ProjectCreatedEventArgs.cs" /> </ItemGroup> <ItemGroup> <None Include="Makefile.am" /> diff --git a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/FeedbackService.cs b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/FeedbackService.cs index 2ff56dfc65..2e1413c5d2 100644 --- a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/FeedbackService.cs +++ b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/FeedbackService.cs @@ -32,6 +32,8 @@ using System.Xml; using MonoDevelop.Components.Commands; using MonoDevelop.Ide.Extensions; using System.Reflection; +using System.Linq; +using Mono.Addins; namespace MonoDevelop.Ide { @@ -40,6 +42,20 @@ namespace MonoDevelop.Ide static bool sending; static object sendingLock = new object (); static FeedbackDialog currentFeedbackDialog; + static Lazy<string> feedbackUrl; + + internal static bool Enabled { + get { return !string.IsNullOrEmpty (feedbackUrl.Value); } + } + + static FeedbackService () + { + feedbackUrl = new Lazy<string> (() => { + var node = AddinManager.GetExtensionNodes<ServiceUrlExtensionNode> ("/MonoDevelop/Ide/FeedbackService") + .FirstOrDefault (); + return node != null? node.Url : null; + }); + } public static bool IsFeedbackWindowVisible { get { return currentFeedbackDialog != null && currentFeedbackDialog.Visible; } @@ -47,6 +63,9 @@ namespace MonoDevelop.Ide public static void ShowFeedbackWindow () { + if (string.IsNullOrEmpty (feedbackUrl.Value)) + return; + if (currentFeedbackDialog == null) { var p = FeedbackPositionGetter (); currentFeedbackDialog = new FeedbackDialog (p.X, p.Y); @@ -121,6 +140,9 @@ namespace MonoDevelop.Ide public static void SendPendingFeedback () { + if (string.IsNullOrEmpty (feedbackUrl.Value)) + return; + lock (sendingLock) { if (sending) return; @@ -152,7 +174,7 @@ namespace MonoDevelop.Ide { string email = feedbackElem.GetAttribute ("email"); string body = feedbackElem.InnerText; - var request = (HttpWebRequest) HttpWebRequest.Create ("http://software.xamarin.com/Service/Feedback?m=" + email); + var request = (HttpWebRequest) HttpWebRequest.Create (feedbackUrl.Value + "?m=" + email); request.Method = "POST"; request.BeginGetRequestStream (delegate (IAsyncResult res) { HandleGetRequestStream (res, request, body); diff --git a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/ProjectCreatedEventArgs.cs b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/ProjectCreatedEventArgs.cs new file mode 100644 index 0000000000..b2fc40de8e --- /dev/null +++ b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/ProjectCreatedEventArgs.cs @@ -0,0 +1,44 @@ +// +// ProjectCreatedEventArgs.cs +// +// Author: +// Marek Habersack <grendel@twistedcode.net> +// +// Copyright (c) 2012 Xamarin, Inc (http://xamarin.com) +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. +using System; + +using MonoDevelop.Projects; + +namespace MonoDevelop.Ide +{ + public class ProjectCreatedEventArgs : EventArgs + { + public Project Project { + get; private set; + } + + public ProjectCreatedEventArgs (Project project) + { + this.Project = project; + } + } +} + diff --git a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/ProjectOperations.cs b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/ProjectOperations.cs index 92ca1ea682..13c4c1cf0b 100644 --- a/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/ProjectOperations.cs +++ b/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/ProjectOperations.cs @@ -655,8 +655,12 @@ namespace MonoDevelop.Ide { string basePath = parentFolder != null ? parentFolder.BaseDirectory : null; NewProjectDialog npdlg = new NewProjectDialog (parentFolder, false, basePath); - if (MessageService.ShowCustomDialog (npdlg) == (int)Gtk.ResponseType.Ok) - return npdlg.NewItem as SolutionItem; + if (MessageService.ShowCustomDialog (npdlg) == (int)Gtk.ResponseType.Ok) { + var item = npdlg.NewItem as SolutionItem; + if ((item is Project) && ProjectCreated != null) + ProjectCreated (this, new ProjectCreatedEventArgs (item as Project)); + return item; + } return null; } @@ -1210,7 +1214,7 @@ namespace MonoDevelop.Ide monitor.ReportError(GettextCatalog.GetString("Build failed."), null); } tt.Trace ("End build event"); - OnEndBuild (monitor, lastResult.FailedBuildCount == 0); + OnEndBuild (monitor, lastResult.FailedBuildCount == 0, lastResult, entry as SolutionItem); } else { tt.Trace ("End build event"); OnEndBuild (monitor, false); @@ -1571,7 +1575,7 @@ namespace MonoDevelop.Ide filesToRemove.Add (folder); } else { filesToRemove = new List<ProjectFile> (); - var pf = sourceProject.GetProjectFile (sourcePath); + var pf = sourceProject.Files.GetFileWithVirtualPath (sourceProject.GetRelativeChildPath (sourcePath)); if (pf != null) filesToRemove.Add (pf); } @@ -1668,7 +1672,7 @@ namespace MonoDevelop.Ide if (sourceProject != null) { if (fileIsLink) { - var linkFile = (sourceProject == targetProject)? file : (ProjectFile) file.Clone (); + var linkFile = (ProjectFile) file.Clone (); if (movingFolder) { var abs = linkFile.Link.ToAbsolute (sourceProject.BaseDirectory); var relSrc = abs.ToRelative (sourcePath); @@ -1791,11 +1795,21 @@ namespace MonoDevelop.Ide } } - void OnEndBuild (IProgressMonitor monitor, bool success) + void OnEndBuild (IProgressMonitor monitor, bool success, BuildResult result = null, SolutionItem item = null) { - if (EndBuild != null) { - EndBuild (this, new BuildEventArgs (monitor, success)); + if (EndBuild == null) + return; + + var args = new BuildEventArgs (monitor, success) { + SolutionItem = item + }; + if (result != null) { + args.WarningCount = result.WarningCount; + args.ErrorCount = result.ErrorCount; + args.BuildCount = result.BuildCount; + args.FailedBuildCount = result.FailedBuildCount; } + EndBuild (this, args); } void OnStartClean (IProgressMonitor monitor, ITimeTracker tt) @@ -1865,6 +1879,7 @@ namespace MonoDevelop.Ide public event EventHandler<SolutionEventArgs> CurrentSelectedSolutionChanged; public event ProjectEventHandler CurrentProjectChanged; + public event EventHandler<ProjectCreatedEventArgs> ProjectCreated; // Fired just before an entry is added to a combine public event AddEntryEventHandler AddingEntryToCombine; @@ -1967,7 +1982,6 @@ namespace MonoDevelop.Ide #endregion } - public IEditableTextFile GetEditableTextFile (FilePath filePath) { diff --git a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.cs b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.cs index 8f73347f86..534c0a749c 100644 --- a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.cs +++ b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.cs @@ -29,7 +29,6 @@ using System.Runtime.CompilerServices; // Information about this assembly is defined by the following attributes. // Change them to the values specific to your project. -[assembly: AssemblyTitle("MonoDevelop.Projects.Formats")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] diff --git a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.v2.0.cs b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.v2.0.cs new file mode 100644 index 0000000000..ce86fd384f --- /dev/null +++ b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.v2.0.cs @@ -0,0 +1 @@ +[assembly: System.Reflection.AssemblyTitle ("MonoDevelop MSBuild 2.0 Builder")]
\ No newline at end of file diff --git a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.v3.5.cs b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.v3.5.cs new file mode 100644 index 0000000000..a38dfbe97e --- /dev/null +++ b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.v3.5.cs @@ -0,0 +1 @@ +[assembly: System.Reflection.AssemblyTitle ("MonoDevelop MSBuild 3.5 Builder")]
\ No newline at end of file diff --git a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.v4.0.cs b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.v4.0.cs new file mode 100644 index 0000000000..a6ee70814b --- /dev/null +++ b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/AssemblyInfo.v4.0.cs @@ -0,0 +1 @@ +[assembly: System.Reflection.AssemblyTitle ("MonoDevelop MSBuild 4.0 Builder")]
\ No newline at end of file diff --git a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/Makefile.am b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/Makefile.am index ef996b9e0e..4c700117a4 100644 --- a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/Makefile.am +++ b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/Makefile.am @@ -1,15 +1,8 @@ - -ASSEMBLY = $(top_builddir)/build/bin/MonoDevelop.Projects.Formats.MSBuild.exe - -REFS = \ - -r:Microsoft.Build.Engine \ - -r:Microsoft.Build.Framework \ - -r:Microsoft.Build.Utilities.v3.5 \ - -r:System \ - -r:System.Runtime.Remoting - FILES = \ AssemblyInfo.cs \ + AssemblyInfo.v2.0.cs \ + AssemblyInfo.v3.5.cs \ + AssemblyInfo.v4.0.cs \ Main.cs \ MonoDevelop.Projects.Formats.MSBuild/BuildEngine.cs \ MonoDevelop.Projects.Formats.MSBuild/ConsoleLogger.cs \ @@ -20,28 +13,36 @@ FILES = \ MonoDevelop.Projects.Formats.MSBuild/MSBuildResult.cs \ MonoDevelop.Projects.Formats.MSBuild/ProjectBuilder.cs -RES = - -# Mono's 2.0/3.5 compiler doesn't recognize 3.5 variants of the MSBuild assemblies -# so patch up the references -MSB_REF_PREFIX:=$(shell pkg-config --variable prefix mono)/lib/mono/3.5/ -FIXED_REFS:=$(shell echo '$(REFS)' | sed -e 's@Microsoft.Build[^ ]*@$(MSB_REF_PREFIX)&.dll@g') +PROJECTS = \ + MonoDevelop.Projects.Formats.MSBuild.csproj \ + MonoDevelop.Projects.Formats.MSBuild.v2.0.csproj \ + MonoDevelop.Projects.Formats.MSBuild.v3.5.csproj -all: $(ASSEMBLY) $(ASSEMBLY).mdb +all: + for p in $(PROJECTS); do xbuild $$p; done -$(ASSEMBLY): $(build_sources) $(build_resources) $(DEPS) - $(CSC) $(CSC_FLAGS) -warnaserror -debug -out:$@ -target:winexe $(FIXED_REFS) $(build_deps) $(build_resources:%=/resource:%) $(build_sources) - -$(ASSEMBLY).mdb: $(ASSEMBLY) - -$(ASSEMBLY).config: $(srcdir)/app.config - cp $< $@ +clean-local: + for p in $(PROJECTS); do xbuild -t:Clean $$p; done +ASSEMBLY = $(top_builddir)/build/bin/MonoDevelop.Projects.Formats.MSBuild.exe assemblydir = $(MD_ASSEMBLY_DIR) assembly_DATA = $(ASSEMBLY) $(ASSEMBLY).mdb $(ASSEMBLY).config -CLEANFILES = $(ASSEMBLY) $(ASSEMBLY).mdb $(ASSEMBLY).config +ASSEMBLY20 = $(top_builddir)/build/bin/MSBuild/2.0/MonoDevelop.Projects.Formats.MSBuild.exe +assembly20dir = $(MD_ASSEMBLY_DIR)\MSBuild\2.0 +assembly20_DATA = $(ASSEMBLY20) $(ASSEMBLY20).mdb $(ASSEMBLY20).config + +ASSEMBLY35 = $(top_builddir)/build/bin/MSBuild/3.5/MonoDevelop.Projects.Formats.MSBuild.exe +assembly35dir = $(MD_ASSEMBLY_DIR)\MSBuild\3.5 +assembly35_DATA = $(ASSEMBLY35) $(ASSEMBLY35).mdb $(ASSEMBLY35).config -EXTRA_DIST = $(FILES) $(RES) app.config +.PHONY: $(ASSEMBLY) $(ASSEMBLY).mdb $(ASSEMBLY).config $(ASSEMBLY20) $(ASSEMBLY20).mdb $(ASSEMBLY20).config $(ASSEMBLY35) $(ASSEMBLY35).mdb $(ASSEMBLY35).config + +EXTRA_DIST = $(FILES) \ + $(PROJECTS) \ + app.config \ + MonoDevelop.Projects.Formats.MSBuild.v2.0.exe.config \ + MonoDevelop.Projects.Formats.MSBuild.v3.5.exe.config include $(top_srcdir)/Makefile.include + diff --git a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.csproj b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.csproj index 3bc5cd8c97..68ac5d9db5 100644 --- a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.csproj +++ b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.csproj @@ -9,7 +9,6 @@ <OutputType>WinExe</OutputType> <AssemblyName>MonoDevelop.Projects.Formats.MSBuild</AssemblyName> <RootNamespace>MonoDevelop.Projects.Formats.MSBuild</RootNamespace> - <TargetFrameworkVersion>v3.5</TargetFrameworkVersion> </PropertyGroup> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' "> <DebugSymbols>true</DebugSymbols> @@ -24,18 +23,17 @@ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' "> <DebugType>none</DebugType> <Optimize>false</Optimize> - <OutputPath>bin\Release</OutputPath> + <OutputPath>..\..\..\build\bin</OutputPath> <ErrorReport>prompt</ErrorReport> <WarningLevel>4</WarningLevel> <PlatformTarget>x86</PlatformTarget> </PropertyGroup> <ItemGroup> - <Reference Include="System"> - </Reference> + <Reference Include="System" /> <Reference Include="System.Runtime.Remoting" /> <Reference Include="Microsoft.Build.Engine" /> <Reference Include="Microsoft.Build.Framework" /> - <Reference Include="Microsoft.Build.Utilities.v3.5" /> + <Reference Include="Microsoft.Build.Utilities.v4.0" /> </ItemGroup> <ItemGroup> <Compile Include="Main.cs" /> @@ -48,6 +46,7 @@ <Compile Include="MonoDevelop.Projects.Formats.MSBuild\BuildEngine.cs" /> <Compile Include="MonoDevelop.Projects.Formats.MSBuild\IBuildEngine.cs" /> <Compile Include="MonoDevelop.Projects.Formats.MSBuild\ConsoleLogger.cs" /> + <Compile Include="AssemblyInfo.v4.0.cs" /> </ItemGroup> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" /> <ItemGroup> @@ -69,8 +68,6 @@ </MonoDevelop> </ProjectExtensions> <ItemGroup> - <None Include="app.config"> - <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> - </None> + <None Include="app.config" /> </ItemGroup> </Project> diff --git a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.v2.0.csproj b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.v2.0.csproj new file mode 100644 index 0000000000..6ee0bf8ed1 --- /dev/null +++ b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.v2.0.csproj @@ -0,0 +1,79 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> + <PropertyGroup> + <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> + <Platform Condition=" '$(Platform)' == '' ">x86</Platform> + <ProductVersion>9.0.21022</ProductVersion> + <SchemaVersion>2.0</SchemaVersion> + <ProjectGuid>{01206ab0-8871-42e7-9355-52e4cf1b7b9a}</ProjectGuid> + <OutputType>WinExe</OutputType> + <AssemblyName>MonoDevelop.Projects.Formats.MSBuild</AssemblyName> + <RootNamespace>MonoDevelop.Projects.Formats.MSBuild</RootNamespace> + <TargetFrameworkVersion>v2.0</TargetFrameworkVersion> + <BaseIntermediateOutputPath>obj\2.0</BaseIntermediateOutputPath> + </PropertyGroup> + <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' "> + <DebugSymbols>true</DebugSymbols> + <DebugType>full</DebugType> + <Optimize>false</Optimize> + <OutputPath>..\..\..\build\bin\MSBuild\2.0</OutputPath> + <DefineConstants>DEBUG</DefineConstants> + <ErrorReport>prompt</ErrorReport> + <WarningLevel>4</WarningLevel> + <PlatformTarget>x86</PlatformTarget> + </PropertyGroup> + <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' "> + <DebugType>none</DebugType> + <Optimize>false</Optimize> + <OutputPath>..\..\..\build\bin\MSBuild\2.0</OutputPath> + <ErrorReport>prompt</ErrorReport> + <WarningLevel>4</WarningLevel> + <PlatformTarget>x86</PlatformTarget> + </PropertyGroup> + <ItemGroup> + <Reference Include="System"> + </Reference> + <Reference Include="System.Runtime.Remoting" /> + <Reference Include="Microsoft.Build.Engine" /> + <Reference Include="Microsoft.Build.Framework" /> + <Reference Include="Microsoft.Build.Utilities" /> + </ItemGroup> + <ItemGroup> + <Compile Include="Main.cs" /> + <Compile Include="AssemblyInfo.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\ProjectBuilder.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\MSBuildResult.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\LocalLogger.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\ILogWriter.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\IProjectBuilder.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\BuildEngine.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\IBuildEngine.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\ConsoleLogger.cs" /> + <Compile Include="AssemblyInfo.v2.0.cs" /> + </ItemGroup> + <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" /> + <ItemGroup> + <Folder Include="MonoDevelop.Projects.Formats.MSBuild\" /> + </ItemGroup> + <ProjectExtensions> + <MonoDevelop> + <Properties> + <MonoDevelop.Autotools.MakefileInfo IntegrationEnabled="true" RelativeMakefileName="Makefile.am" BuildTargetName="" CleanTargetName="" SyncReferences="true" IsAutotoolsProject="true" RelativeConfigureInPath="../../.."> + <BuildFilesVar Sync="true" Name="FILES" /> + <DeployFilesVar /> + <ResourcesVar Sync="true" Name="RES" /> + <OthersVar /> + <GacRefVar Sync="true" Name="REFS" Prefix="-r:" /> + <AsmRefVar Sync="true" Name="REFS" Prefix="-r:" /> + <ProjectRefVar Sync="true" Name="REFS" Prefix="-r:" /> + </MonoDevelop.Autotools.MakefileInfo> + </Properties> + </MonoDevelop> + </ProjectExtensions> + <ItemGroup> + <None Include="MonoDevelop.Projects.Formats.MSBuild.v2.0.exe.config"> + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> + <Link>MonoDevelop.Projects.Formats.MSBuild.exe.config</Link> + </None> + </ItemGroup> +</Project> diff --git a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.v2.0.exe.config b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.v2.0.exe.config new file mode 100644 index 0000000000..4e4303ebdf --- /dev/null +++ b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.v2.0.exe.config @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8"?> +<configuration> + <runtime> + <generatePublisherEvidence enabled="false" /> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly> + <assemblyIdentity name="Microsoft.Build.Framework" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" /> + <bindingRedirect oldVersion="0.0.0.0-100.0.0.0" newVersion="2.0.0.0" /> + </dependentAssembly> + <dependentAssembly> + <assemblyIdentity name="Microsoft.Build.Engine" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" /> + <bindingRedirect oldVersion="0.0.0.0-100.0.0.0" newVersion="2.0.0.0" /> + </dependentAssembly> + </assemblyBinding> + </runtime> +</configuration> diff --git a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.v3.5.csproj b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.v3.5.csproj new file mode 100644 index 0000000000..3882e489a3 --- /dev/null +++ b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.v3.5.csproj @@ -0,0 +1,79 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> + <PropertyGroup> + <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> + <Platform Condition=" '$(Platform)' == '' ">x86</Platform> + <ProductVersion>9.0.21022</ProductVersion> + <SchemaVersion>2.0</SchemaVersion> + <ProjectGuid>{40a31ade-6f26-4d99-a3c7-87bb8236151d}</ProjectGuid> + <OutputType>WinExe</OutputType> + <AssemblyName>MonoDevelop.Projects.Formats.MSBuild</AssemblyName> + <RootNamespace>MonoDevelop.Projects.Formats.MSBuild</RootNamespace> + <TargetFrameworkVersion>v3.5</TargetFrameworkVersion> + <BaseIntermediateOutputPath>obj\3.5</BaseIntermediateOutputPath> + </PropertyGroup> + <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' "> + <DebugSymbols>true</DebugSymbols> + <DebugType>full</DebugType> + <Optimize>false</Optimize> + <OutputPath>..\..\..\build\bin\MSBuild\3.5</OutputPath> + <DefineConstants>DEBUG</DefineConstants> + <ErrorReport>prompt</ErrorReport> + <WarningLevel>4</WarningLevel> + <PlatformTarget>x86</PlatformTarget> + </PropertyGroup> + <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' "> + <DebugType>none</DebugType> + <Optimize>false</Optimize> + <OutputPath>..\..\..\build\bin\MSBuild\3.5</OutputPath> + <ErrorReport>prompt</ErrorReport> + <WarningLevel>4</WarningLevel> + <PlatformTarget>x86</PlatformTarget> + </PropertyGroup> + <ItemGroup> + <Reference Include="System"> + </Reference> + <Reference Include="System.Runtime.Remoting" /> + <Reference Include="Microsoft.Build.Engine" /> + <Reference Include="Microsoft.Build.Framework" /> + <Reference Include="Microsoft.Build.Utilities.v3.5" /> + </ItemGroup> + <ItemGroup> + <Compile Include="Main.cs" /> + <Compile Include="AssemblyInfo.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\ProjectBuilder.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\MSBuildResult.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\LocalLogger.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\ILogWriter.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\IProjectBuilder.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\BuildEngine.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\IBuildEngine.cs" /> + <Compile Include="MonoDevelop.Projects.Formats.MSBuild\ConsoleLogger.cs" /> + <Compile Include="AssemblyInfo.v3.5.cs" /> + </ItemGroup> + <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" /> + <ItemGroup> + <Folder Include="MonoDevelop.Projects.Formats.MSBuild\" /> + </ItemGroup> + <ProjectExtensions> + <MonoDevelop> + <Properties> + <MonoDevelop.Autotools.MakefileInfo IntegrationEnabled="true" RelativeMakefileName="Makefile.am" BuildTargetName="" CleanTargetName="" SyncReferences="true" IsAutotoolsProject="true" RelativeConfigureInPath="../../.."> + <BuildFilesVar Sync="true" Name="FILES" /> + <DeployFilesVar /> + <ResourcesVar Sync="true" Name="RES" /> + <OthersVar /> + <GacRefVar Sync="true" Name="REFS" Prefix="-r:" /> + <AsmRefVar Sync="true" Name="REFS" Prefix="-r:" /> + <ProjectRefVar Sync="true" Name="REFS" Prefix="-r:" /> + </MonoDevelop.Autotools.MakefileInfo> + </Properties> + </MonoDevelop> + </ProjectExtensions> + <ItemGroup> + <None Include="MonoDevelop.Projects.Formats.MSBuild.v3.5.exe.config"> + <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> + <Link>MonoDevelop.Projects.Formats.MSBuild.exe.config</Link> + </None> + </ItemGroup> +</Project> diff --git a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.v3.5.exe.config b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.v3.5.exe.config new file mode 100644 index 0000000000..8309829ba3 --- /dev/null +++ b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/MonoDevelop.Projects.Formats.MSBuild.v3.5.exe.config @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8"?> +<configuration> + <runtime> + <generatePublisherEvidence enabled="false" /> + <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> + <dependentAssembly> + <assemblyIdentity name="Microsoft.Build.Framework" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" /> + <bindingRedirect oldVersion="0.0.0.0-100.0.0.0" newVersion="3.5.0.0" /> + </dependentAssembly> + <dependentAssembly> + <assemblyIdentity name="Microsoft.Build.Engine" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" /> + <bindingRedirect oldVersion="0.0.0.0-100.0.0.0" newVersion="3.5.0.0" /> + </dependentAssembly> + </assemblyBinding> + </runtime> +</configuration> diff --git a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/app.config b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/app.config index 8309829ba3..30df74844c 100644 --- a/main/src/core/MonoDevelop.Projects.Formats.MSBuild/app.config +++ b/main/src/core/MonoDevelop.Projects.Formats.MSBuild/app.config @@ -5,11 +5,11 @@ <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <dependentAssembly> <assemblyIdentity name="Microsoft.Build.Framework" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" /> - <bindingRedirect oldVersion="0.0.0.0-100.0.0.0" newVersion="3.5.0.0" /> + <bindingRedirect oldVersion="0.0.0.0-100.0.0.0" newVersion="4.0.0.0" /> </dependentAssembly> <dependentAssembly> <assemblyIdentity name="Microsoft.Build.Engine" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" /> - <bindingRedirect oldVersion="0.0.0.0-100.0.0.0" newVersion="3.5.0.0" /> + <bindingRedirect oldVersion="0.0.0.0-100.0.0.0" newVersion="4.0.0.0" /> </dependentAssembly> </assemblyBinding> </runtime> diff --git a/main/src/core/MonoDevelop.Startup/Makefile.am b/main/src/core/MonoDevelop.Startup/Makefile.am index b52b1719fd..aaabb7dd6b 100644 --- a/main/src/core/MonoDevelop.Startup/Makefile.am +++ b/main/src/core/MonoDevelop.Startup/Makefile.am @@ -9,11 +9,11 @@ RES = all: $(ASSEMBLY) $(ASSEMBLY).mdb $(ASSEMBLY).config -DEPS = \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll +DEPS = $(top_builddir)/build/bin/MonoDevelop.Core.dll -REFS = $(MONO_ADDINS_LIBS) +REFS = \ + $(MONO_ADDINS_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll ICON = $(top_builddir)/theme-icons/Windows/monodevelop.ico diff --git a/main/src/tools/mdmonitor/Makefile.am b/main/src/tools/mdmonitor/Makefile.am index 1708e59e38..b639c15193 100644 --- a/main/src/tools/mdmonitor/Makefile.am +++ b/main/src/tools/mdmonitor/Makefile.am @@ -34,15 +34,14 @@ REFS = \ $(GLADE_SHARP_LIBS) \ $(GLIB_SHARP_LIBS) \ $(GTK_SHARP_LIBS) \ + -r:../../../build/bin/MonoDevelop.Ide.dll \ -r:Mono.Cairo \ -r:Mono.Posix \ -r:System \ -r:System.Core \ -r:System.Xml -DEPS = \ - $(top_builddir)/build/bin/MonoDevelop.Core.dll \ - $(top_builddir)/build/bin/MonoDevelop.Ide.dll +DEPS = $(top_builddir)/build/bin/MonoDevelop.Core.dll $(ASSEMBLY): $(build_sources) $(build_resources) $(DEPS) |