From 0b1ff4cbb7b79ea5e6b8c60570aace17d9daceaf Mon Sep 17 00:00:00 2001 From: Mikhail Sennikovsky Date: Thu, 29 Mar 2007 13:45:22 +0000 Subject: [PATCH] fix for the Makfile Project creation with the non-empty tool-chain --- .../internal/core/Configuration.java | 40 ++++++++++++++++++- 1 file changed, 39 insertions(+), 1 deletion(-) diff --git a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Configuration.java b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Configuration.java index f9c836102ab..2fcb78dae53 100644 --- a/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Configuration.java +++ b/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/internal/core/Configuration.java @@ -54,6 +54,7 @@ import org.eclipse.cdt.managedbuilder.core.IOptionApplicability; import org.eclipse.cdt.managedbuilder.core.IProjectType; import org.eclipse.cdt.managedbuilder.core.IResourceConfiguration; import org.eclipse.cdt.managedbuilder.core.IResourceInfo; +import org.eclipse.cdt.managedbuilder.core.ITargetPlatform; import org.eclipse.cdt.managedbuilder.core.ITool; import org.eclipse.cdt.managedbuilder.core.IToolChain; import org.eclipse.cdt.managedbuilder.core.ManagedBuildManager; @@ -464,7 +465,44 @@ public class Configuration extends BuildObject implements IConfiguration, IBuild String tcId = ManagedBuildManager.calculateChildId(tCh.getId(), null); - createToolChain(tCh, tcId, tCh.getId(), false); + IToolChain newChain = createToolChain(tCh, tcId, tCh.getId(), false); + + // For each option/option category child of the tool-chain that is + // the child of the selected configuration element, create an option/ + // option category child of the cloned configuration's tool-chain element + // that specifies the original tool element as its superClass. + newChain.createOptions(tCh); + + // For each tool element child of the tool-chain that is the child of + // the selected configuration element, create a tool element child of + // the cloned configuration's tool-chain element that specifies the + // original tool element as its superClass. + String subId; + ITool[] tools = tCh.getTools(); + for (int i=0; i