Skip to main content



      Home
Home » Language IDEs » C / C++ IDE (CDT) » Application opens with external console output when extending GDBCDIDebugger2 on Windows(Application opens with external console output when extending GDBCDIDebugger2 on Windows)
Application opens with external console output when extending GDBCDIDebugger2 on Windows [message #1095118] Mon, 26 August 2013 12:49 Go to next message
Eclipse UserFriend
Hello,

We have an extension point for org.eclipse.cdt.debug.core.CDebugger.

When the Debugger class extends GDBCDIDebugger2, only on Windows, the application opens up in a Windows console instead of a new built-in Eclipse console output.

If we choose to extend the AbstractGDBCDIDebugger instead, the application opens as expectedly in a new build-in Eclipse console.


I would like to ask if anyone has seen this behavior previously and has some pointers to what is causing it.

What are the benefits of extending GDBCDIDebugger2?


Thank you,
Catalin
Re: Application opens with external console output when extending GDBCDIDebugger2 on Windows [message #1095826 is a reply to message #1095118] Tue, 27 August 2013 11:31 Go to previous message
Eclipse UserFriend
Hello,

I found out that this is implemented to be the desired behavior in the GDBCDIDebugger2 class, with the mentioning that it doesn't work on Linux.

protected void startLocalGDBSession( ILaunchConfiguration config, Session session, IProgressMonitor monitor ) throws CoreException {
// TODO: need a better solution for new-console
MISession miSession = getMISession( session );
try {
CommandFactory factory = miSession.getCommandFactory();
MIGDBSetNewConsole newConsole = factory.createMIGDBSetNewConsole();
miSession.postCommand( newConsole );
MIInfo info = newConsole.getMIInfo();
if ( info == null ) {
throw new MIException( MIPlugin.getResourceString( "src.common.No_answer" ) ); //$NON-NLS-1$
}
}
catch( MIException e ) {
// We ignore this exception, for example
// on GNU/Linux the new-console is an error.
}
}

To disable this, override with an empty method and the application console will show within Eclipse.

Catalin
Previous Topic:Help with Window Management
Next Topic:Eclipse on ubuntu 12.04
Goto Forum:
  


Current Time: Tue May 13 16:49:04 EDT 2025

Powered by FUDForum. Page generated in 0.04107 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top