|
|
|
@ -214,6 +214,7 @@ namespace ICSharpCode.SharpDevelop.Project
@@ -214,6 +214,7 @@ namespace ICSharpCode.SharpDevelop.Project
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
Dictionary<ProjectBuildOptions, ICollection<IBuildable>> cachedBuildDependencies = new Dictionary<ProjectBuildOptions, ICollection<IBuildable>>(); |
|
|
|
|
ICollection<IBuildable> cachedBuildDependenciesForNullOptions; |
|
|
|
|
|
|
|
|
|
public ICollection<IBuildable> GetBuildDependencies(ProjectBuildOptions buildOptions) |
|
|
|
|
{ |
|
|
|
@ -222,7 +223,10 @@ namespace ICSharpCode.SharpDevelop.Project
@@ -222,7 +223,10 @@ namespace ICSharpCode.SharpDevelop.Project
|
|
|
|
|
result.Add(factory.GetWrapper(b)); |
|
|
|
|
} |
|
|
|
|
lock (cachedBuildDependencies) { |
|
|
|
|
cachedBuildDependencies[buildOptions] = result; |
|
|
|
|
if (buildOptions != null) |
|
|
|
|
cachedBuildDependencies[buildOptions] = result; |
|
|
|
|
else |
|
|
|
|
cachedBuildDependenciesForNullOptions = result; |
|
|
|
|
} |
|
|
|
|
return result; |
|
|
|
|
} |
|
|
|
@ -254,7 +258,8 @@ namespace ICSharpCode.SharpDevelop.Project
@@ -254,7 +258,8 @@ namespace ICSharpCode.SharpDevelop.Project
|
|
|
|
|
} |
|
|
|
|
if (lastCompilationPass != null && Setting == BuildOnExecuteSetting.BuildModifiedAndDependent) { |
|
|
|
|
lock (cachedBuildDependencies) { |
|
|
|
|
if (cachedBuildDependencies[buildOptions].OfType<Wrapper>().Any(w=>w.WasRecompiledAfter(lastCompilationPass))) { |
|
|
|
|
var dependencies = buildOptions != null ? cachedBuildDependencies[buildOptions] : cachedBuildDependenciesForNullOptions; |
|
|
|
|
if (dependencies.OfType<Wrapper>().Any(w=>w.WasRecompiledAfter(lastCompilationPass))) { |
|
|
|
|
lastCompilationPass = null; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|