Blob Blame History Raw
diff --git a/autotools/org.eclipse.linuxtools.cdt.autotools.core/src/org/eclipse/linuxtools/internal/cdt/autotools/core/AutotoolsNewMakeGenerator.java b/autotools/org.eclipse.linuxtools.cdt.autotools.core/src/org/eclipse/linuxtools/internal/cdt/autotools/core/AutotoolsNewMakeGenerator.java
index 2676526..261fef6 100644
--- a/autotools/org.eclipse.linuxtools.cdt.autotools.core/src/org/eclipse/linuxtools/internal/cdt/autotools/core/AutotoolsNewMakeGenerator.java
+++ b/autotools/org.eclipse.linuxtools.cdt.autotools.core/src/org/eclipse/linuxtools/internal/cdt/autotools/core/AutotoolsNewMakeGenerator.java
@@ -1251,10 +1251,12 @@ public class AutotoolsNewMakeGenerator extends MarkerGenerator {
 			if (!isValidTarget(targetName, makeTargetManager))
 				continue;
 			try {
-				IMakeTarget makeTarget = makeTargetManager.findTarget(project, targetName);
-				if (makeTarget == null)
-					makeTarget = makeTargetManager.createTarget(
-						project, targetName, targetBuildID);
+				// Bug #351660 - always create a new MakeTarget because an
+				// existing MakeTarget will cause events to occur on every
+				// modification whereas a new MakeTarget not yet added will
+				// not cause this delay.
+				IMakeTarget makeTarget = makeTargetManager.createTarget(
+								project, targetName, targetBuildID);
 				makeTarget.setContainer(project);
 				makeTarget.setStopOnError(isStopOnError);
 				makeTarget.setRunAllBuilders(false);