[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
[cdt-dev] how to set PORT when launching C debug session programmatically
|
Hi,
I've extended launch configuration to make it launch 2 debug
session simultaneousness to make it suitable for multi core debugging. With
CDT's debug options I can launch 2 debug sessions varying gdb_init and port.
I could launch 2 debug session with two different gdb_init but can't vary port
number.
In the launchDelegate which extends AbstractCLaunchDelegate
- I'm launching 1st debug sessions with ILaunchConfiguration with all the debug
debug attributes set...which runs perfectly
- For the 2nd debug session,
config_2 = config.getWorkingCopy();
config_2.removeAttribute("org.eclipse.cdt.debug.mi.core.PORT");
config_2.setAttribute(IGDBServerMILaunchConfigurationConstants.ATTR_PORT,
newValueOfPort);
config_2.doSave();
((ILaunchConfiguration)config_2).launch(launch.getLaunchMode(), new
SubProgressMonitor(monitor, 50));
But still it takes old/default port number leaving 2nd debug sessions with
errors like target not responding, etc.
Please let me know if I'm missing anything here. Stuck badly. Please provide
some pointers.
Thanks a lot in advance,
Vrushali.