# HG changeset patch # User Ed Swartz # Date 1284589728 18000 # Node ID 264d7a9481041336239c13546470457f25e2a07f # Parent d6760e7efd55e8622cd2ce24af11a3e5515942e6 Bug 12078: revert part of change that means mmp/bld.inf changes never rebuild the indexer (duh). Just avoid rebuilding before we've even read the cache to begin with -- this was the real bug. diff -r d6760e7efd55 -r 264d7a948104 builder/com.nokia.carbide.cdt.builder/src/com/nokia/carbide/cdt/internal/builder/CarbideBuildManager.java --- a/builder/com.nokia.carbide.cdt.builder/src/com/nokia/carbide/cdt/internal/builder/CarbideBuildManager.java Wed Sep 15 16:56:50 2010 -0500 +++ b/builder/com.nokia.carbide.cdt.builder/src/com/nokia/carbide/cdt/internal/builder/CarbideBuildManager.java Wed Sep 15 17:28:48 2010 -0500 @@ -338,8 +338,6 @@ Set pathList = new HashSet(); for (ICarbideBuildConfiguration config : cpi.getBuildConfigurations()) { - // Bug 12078: I see no reason for this in C3 -- it always happens on startup and obviates the cache - /* // force a rebuild of the CarbideLanguageData cache // TODO PERFORMANCE EJS: why??? We end up forcing a cache rebuild even when you just switch configurations... CLanguageData languageData = null; @@ -362,7 +360,6 @@ } } } - */ EpocEngineHelper.addIncludedFilesFromBldInf(cpi, config, cpi.getAbsoluteBldInfPath(), pathList); diff -r d6760e7efd55 -r 264d7a948104 builder/com.nokia.carbide.cdt.builder/src/com/nokia/carbide/cdt/internal/builder/CarbideLanguageData.java --- a/builder/com.nokia.carbide.cdt.builder/src/com/nokia/carbide/cdt/internal/builder/CarbideLanguageData.java Wed Sep 15 16:56:50 2010 -0500 +++ b/builder/com.nokia.carbide.cdt.builder/src/com/nokia/carbide/cdt/internal/builder/CarbideLanguageData.java Wed Sep 15 17:28:48 2010 -0500 @@ -154,7 +154,7 @@ // But we must save the cache in a workspace job because this code // is usually called when the project description is being read for // the first time (thus saving just throws an exception). - Job job = new Job("Saving Carbide indexer cache for " + carbideBuildConfig.getDisplayString()) { + Job job = new Job("Saving Carbide indexer cache for " + carbideBuildConfig.toString()) { @Override protected IStatus run(IProgressMonitor monitor) { @@ -524,7 +524,11 @@ } public void forceRebuildCache() { - forceRebuildCache = true; + // only force rebuild if there was something loaded already -- + // we get here on startup too when first hooking up resource listeners + if (includeEntries != null && macroEntries != null && cacheFileSource != null) { + forceRebuildCache = true; + } } @Override