77 * https://www.eclipse.org/legal/epl-2.0/
88 *
99 * SPDX-License-Identifier: EPL-2.0
10- *
10+ *
1111 * Contributors:
1212 * QNX - Initial API and implementation
1313 * kondal.kolipaka@espressif.com - ESP-IDF specific build configuration
@@ -140,10 +140,13 @@ public class IDFBuildConfiguration extends CBuildConfiguration
140140 public boolean isProgressSet ;
141141 private QualifiedName TIMESTAMP_COMPILE_COMMANDS_PROPERTY = new QualifiedName (null ,
142142 "timestamp:compile_commands.json" ); //$NON-NLS-1$
143+ private ILaunchConfiguration configuration ;
143144
144145 public IDFBuildConfiguration (IBuildConfiguration config , String name ) throws CoreException
145146 {
146147 super (config , name );
148+ buildConfiguration = config ;
149+ this .configuration = LAUNCH_CONFIG_PROVIDER .getActiveLaunchConfiguration ();
147150 }
148151
149152 public IDFBuildConfiguration (IBuildConfiguration config , String name , IToolChain toolChain )
@@ -156,6 +159,14 @@ public IDFBuildConfiguration(IBuildConfiguration config, String name, IToolChain
156159 {
157160 super (config , name , toolChain , launchMode );
158161 this .toolChainFile = toolChainFile ;
162+ try
163+ {
164+ this .configuration = LAUNCH_CONFIG_PROVIDER .getActiveLaunchConfiguration ();
165+ }
166+ catch (CoreException e )
167+ {
168+ Logger .log (e );
169+ }
159170 }
160171
161172 @ Override
@@ -247,7 +258,6 @@ public String getProperty(String name)
247258 {
248259 try
249260 {
250- ILaunchConfiguration configuration = LAUNCH_CONFIG_PROVIDER .getActiveLaunchConfiguration ();
251261 if (configuration != null
252262 && configuration .getType ().getIdentifier ().equals (IDFLaunchConstants .DEBUG_LAUNCH_CONFIG_TYPE ))
253263 {
@@ -639,7 +649,7 @@ private static String getIdfToolsPath()
639649
640650 /**
641651 * Link build components(build_component_paths) from project_description.json to the project.
642- *
652+ *
643653 * @param project
644654 * @throws Exception
645655 */
@@ -976,7 +986,7 @@ public void elementChanged(ElementChangedEvent event)
976986 /**
977987 * Processes the delta in order to detect whether one of the CMakeLists.txt files in the project has been modified
978988 * and saved by the user since the last build.
979- *
989+ *
980990 * @return <code>true</code> to continue with delta processing, otherwise <code>false</code>
981991 */
982992 private boolean processElementDelta (ICElementDelta delta )
0 commit comments