Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 386592 - extend PE JAXB for additional debug implementations
Summary: extend PE JAXB for additional debug implementations
Status: RESOLVED FIXED
Alias: None
Product: PTP
Classification: Tools
Component: Debug Core (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Greg Watson CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-08-03 14:44 EDT by Jeremiah Swan CLA
Modified: 2012-08-14 15:54 EDT (History)
0 users

See Also:


Attachments
modified PE perl script (4.15 KB, application/octet-stream)
2012-08-03 14:44 EDT, Jeremiah Swan CLA
g.watson: iplog+
Details
additional debugger perl script (3.56 KB, application/octet-stream)
2012-08-03 14:44 EDT, Jeremiah Swan CLA
no flags Details
updated PE JAXB XML (149.66 KB, text/xml)
2012-08-03 14:46 EDT, Jeremiah Swan CLA
no flags Details
JAXB XML which passes a couple extra environment variables (149.70 KB, text/xml)
2012-08-08 13:54 EDT, Jeremiah Swan CLA
g.watson: iplog+
Details
updated perl script which uses environment rather than poe command (3.82 KB, application/octet-stream)
2012-08-08 13:56 EDT, Jeremiah Swan CLA
g.watson: iplog+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jeremiah Swan CLA 2012-08-03 14:44:22 EDT
Created attachment 219544 [details]
modified PE perl script

allow the PE JAXB to call additional debugger implementations
Comment 1 Jeremiah Swan CLA 2012-08-03 14:44:50 EDT
Created attachment 219545 [details]
additional debugger perl script
Comment 2 Jeremiah Swan CLA 2012-08-03 14:46:45 EDT
Created attachment 219546 [details]
updated PE JAXB XML
Comment 3 Greg Watson CLA 2012-08-06 10:35:05 EDT
What's the purpose of the updated JAXB XML? Wasn't the plan to use the existing XML? The changes will cause an extra poe command to be passed to the run_pe_app.pl script which is likely to cause problems with non-debug launches.
Comment 4 Jeremiah Swan CLA 2012-08-08 13:54:52 EDT
Created attachment 219680 [details]
JAXB XML which passes a couple extra environment variables

removed the extra 'poe' invocation
Comment 5 Jeremiah Swan CLA 2012-08-08 13:56:56 EDT
Created attachment 219681 [details]
updated perl script which uses environment rather than poe command

matching perl script which uses the environment rather than keying off the 'poe' command
Comment 6 Greg Watson CLA 2012-08-14 15:54:51 EDT
The way this now works is as follows:

1. The debugger sets the 'org.eclipse.ptp.launch.DEBUGGER_ID' attribute in the launch configuration (IPTPLaunchConfigurationConstants.DEBUGGER_ID) to something other than 'org.eclipse.ptp.debug.sdm'. This will normally be the case if you're using a different debugger extension or not using the standard debug tab at all.

2. The debugger sets the 'org.eclipse.ptp.launch.DEBUGGER_LAUNCHER' launch configuration attribute to the path of a launcher script. For the pardeb, this would be "${ptp_rm:ptpDirectory#value}/rms/PE/run_pe_app_pardeb.pl". So you would do something like:

	config.setAttribute("org.eclipse.ptp.launch.DEBUGGER_LAUNCHER", "${ptp_rm:ptpDirectory#value}/rms/PE/run_pe_app_pardeb.pl");

where config is an ILaunchConfigurationWorkingCopy. The path can be to any location, but the above path will default to the script provided with PTP.

3. PTP will translate the DEBUGGER_LAUNCH attribute to an environment variable called PTP_DEBUGGER_LAUNCHER and the run_pe_app.pl script will exec this script.

Your launch configuration delegate would just need to do step #2 somewhere, probably in the performApply method.

This has been committed to the master branch.