mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-05 07:15:39 +02:00
Bug 262826 - Create common C/C++ launch configurations
This commit is contained in:
parent
22b507266d
commit
b006bc98c3
37 changed files with 881 additions and 245 deletions
|
@ -14,6 +14,10 @@
|
|||
pluginName=C/C++ Development Tools Debug Model
|
||||
providerName=Eclipse.org
|
||||
|
||||
ApplicationLaunch.name=C/C++ Application
|
||||
AttachLaunch.name=C/C++ Attach to Application
|
||||
PostMortemLaunch.name=C/C++ Postmortem Debugger
|
||||
|
||||
CDebugger.name=C/C++ Development Tools Core Debugger Extension
|
||||
BreakpointAction.name=Breakpoint Action Extension
|
||||
|
||||
|
|
|
@ -6,6 +6,25 @@
|
|||
<extension-point id="BreakpointActionType" name="%BreakpointAction" schema="schema/BreakpointAction.exsd"/>
|
||||
<extension-point id="BreakpointExtension" name="%BreakpointAction" schema="schema/BreakpointExtension.exsd"/>
|
||||
|
||||
<extension
|
||||
point="org.eclipse.debug.core.launchConfigurationTypes">
|
||||
<launchConfigurationType
|
||||
id="org.eclipse.cdt.launch.applicationLaunchType"
|
||||
name="%ApplicationLaunch.name"
|
||||
public="true">
|
||||
</launchConfigurationType>
|
||||
<launchConfigurationType
|
||||
id="org.eclipse.cdt.launch.attachLaunchType"
|
||||
name="%AttachLaunch.name"
|
||||
public="true">
|
||||
</launchConfigurationType>
|
||||
<launchConfigurationType
|
||||
id="org.eclipse.cdt.launch.postmortemLaunchType"
|
||||
name="%PostMortemLaunch.name"
|
||||
public="true">
|
||||
</launchConfigurationType>
|
||||
</extension>
|
||||
|
||||
<extension
|
||||
id="cBreakpointMarker"
|
||||
point="org.eclipse.core.resources.markers">
|
||||
|
|
|
@ -28,6 +28,8 @@ import javax.xml.transform.TransformerFactory;
|
|||
import javax.xml.transform.dom.DOMSource;
|
||||
import javax.xml.transform.stream.StreamResult;
|
||||
|
||||
import org.eclipse.cdt.core.CCorePlugin;
|
||||
import org.eclipse.cdt.core.model.ICProject;
|
||||
import org.eclipse.cdt.debug.core.cdi.CDIException;
|
||||
import org.eclipse.cdt.debug.core.model.ICAddressBreakpoint;
|
||||
import org.eclipse.cdt.debug.core.model.ICBreakpoint;
|
||||
|
@ -40,11 +42,13 @@ import org.eclipse.cdt.debug.core.model.ICWatchpoint2;
|
|||
import org.eclipse.cdt.debug.internal.core.model.CFloatingPointValue;
|
||||
import org.eclipse.core.resources.IMarker;
|
||||
import org.eclipse.core.resources.IProject;
|
||||
import org.eclipse.core.resources.ResourcesPlugin;
|
||||
import org.eclipse.core.runtime.CoreException;
|
||||
import org.eclipse.core.runtime.IPath;
|
||||
import org.eclipse.core.runtime.IStatus;
|
||||
import org.eclipse.core.runtime.Path;
|
||||
import org.eclipse.debug.core.DebugPlugin;
|
||||
import org.eclipse.debug.core.ILaunchConfiguration;
|
||||
import org.eclipse.debug.core.IStatusHandler;
|
||||
import org.eclipse.debug.core.model.IBreakpoint;
|
||||
import org.w3c.dom.Document;
|
||||
|
@ -511,4 +515,50 @@ public class CDebugUtils {
|
|||
return fDecoder;
|
||||
}
|
||||
|
||||
/**
|
||||
* Note: Moved from AbstractCLaunchDelegate
|
||||
* @since 6.0
|
||||
*/
|
||||
public static ICProject getCProject(ILaunchConfiguration configuration) throws CoreException {
|
||||
String projectName = getProjectName(configuration);
|
||||
if (projectName != null) {
|
||||
projectName = projectName.trim();
|
||||
if (projectName.length() > 0) {
|
||||
IProject project = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
|
||||
ICProject cProject = CCorePlugin.getDefault().getCoreModel().create(project);
|
||||
if (cProject != null && cProject.exists()) {
|
||||
return cProject;
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Note: Moved from AbstractCLaunchDelegate
|
||||
* @since 6.0
|
||||
*/
|
||||
public static String getProjectName(ILaunchConfiguration configuration) throws CoreException {
|
||||
return configuration.getAttribute(ICDTLaunchConfigurationConstants.ATTR_PROJECT_NAME, (String)null);
|
||||
}
|
||||
|
||||
/**
|
||||
* Note: Moved from AbstractCLaunchDelegate
|
||||
* @since 6.0
|
||||
*/
|
||||
public static String getProgramName(ILaunchConfiguration configuration) throws CoreException {
|
||||
return configuration.getAttribute(ICDTLaunchConfigurationConstants.ATTR_PROGRAM_NAME, (String)null);
|
||||
}
|
||||
|
||||
/**
|
||||
* Note: Moved from AbstractCLaunchDelegate
|
||||
* @since 6.0
|
||||
*/
|
||||
public static IPath getProgramPath(ILaunchConfiguration configuration) throws CoreException {
|
||||
String path = getProgramName(configuration);
|
||||
if (path == null || path.trim().length() == 0) {
|
||||
return null;
|
||||
}
|
||||
return new Path(path);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -17,9 +17,23 @@ public interface ICDTLaunchConfigurationConstants {
|
|||
public static final String CDT_LAUNCH_ID = "org.eclipse.cdt.launch"; //$NON-NLS-1$
|
||||
|
||||
/**
|
||||
* This is the launch type id.
|
||||
* This is the application launch type id.
|
||||
*/
|
||||
public static final String ID_LAUNCH_C_APP = "org.eclipse.cdt.launch.localCLaunch"; //$NON-NLS-1$
|
||||
public static final String ID_LAUNCH_C_APP = "org.eclipse.cdt.launch.applicationLaunchType"; //$NON-NLS-1$
|
||||
|
||||
/**
|
||||
* This is the attach launch type id.
|
||||
*
|
||||
* @since 6.0
|
||||
*/
|
||||
public static final String ID_LAUNCH_C_ATTACH = "org.eclipse.cdt.launch.attachLaunchType"; //$NON-NLS-1$
|
||||
|
||||
/**
|
||||
* This is the post-mortem launch type id.
|
||||
*
|
||||
* @since 6.0
|
||||
*/
|
||||
public static final String ID_LAUNCH_C_POST_MORTEM = "org.eclipse.cdt.launch.postmortemLaunchType"; //$NON-NLS-1$
|
||||
|
||||
/**
|
||||
* Identifier for the C/C++ program process type, which is annotated on processes created
|
||||
|
|
|
@ -189,3 +189,9 @@ breapointType.regular.label=Regular
|
|||
breapointType.hardware.label=Hardware
|
||||
breapointType.temporay.label=Temporary
|
||||
breapointType.hardwaretemporaty.label=Hardware Temporary
|
||||
|
||||
CApplicationShortcut.label=Local C/C++ Application
|
||||
ContextualRunCApplication.description=Runs a local C/C++ application
|
||||
ContextualDebugCApplication.description=Debugs a local C/C++ application
|
||||
|
||||
|
||||
|
|
|
@ -7,6 +7,119 @@
|
|||
<extension-point id="breakpointContribution" name="%breakpointContribution" schema="schema/BreakpointUIContribution.exsd"/>
|
||||
|
||||
<!-- Extensions -->
|
||||
<extension
|
||||
point="org.eclipse.debug.ui.launchConfigurationTypeImages">
|
||||
<launchConfigurationTypeImage
|
||||
icon="icons/obj16/c_app.gif"
|
||||
configTypeID="org.eclipse.cdt.launch.applicationLaunchType"
|
||||
id="org.eclipse.cdt.launch.localRunLaunchImage">
|
||||
</launchConfigurationTypeImage>
|
||||
<launchConfigurationTypeImage
|
||||
icon="icons/obj16/c_app.gif"
|
||||
configTypeID="org.eclipse.cdt.launch.attachLaunchType"
|
||||
id="org.eclipse.cdt.launch.localAttachLaunchImage">
|
||||
</launchConfigurationTypeImage>
|
||||
<launchConfigurationTypeImage
|
||||
icon="icons/obj16/c_app.gif"
|
||||
configTypeID="org.eclipse.cdt.launch.postmortemLaunchType"
|
||||
id="org.eclipse.cdt.launch.coreFileLaunchImage">
|
||||
</launchConfigurationTypeImage>
|
||||
</extension>
|
||||
|
||||
<extension
|
||||
point="org.eclipse.debug.ui.launchConfigurationTabGroups">
|
||||
<launchConfigurationTabGroup
|
||||
type="org.eclipse.cdt.launch.applicationLaunchType"
|
||||
class="org.eclipse.cdt.debug.internal.ui.launch.PlaceHolderLaunchConfigurationTabGroup"
|
||||
id="org.eclipse.cdt.launch.applicationLaunchTabGroup">
|
||||
</launchConfigurationTabGroup>
|
||||
<launchConfigurationTabGroup
|
||||
type="org.eclipse.cdt.launch.attachLaunchType"
|
||||
class="org.eclipse.cdt.debug.internal.ui.launch.PlaceHolderLaunchConfigurationTabGroup"
|
||||
id="org.eclipse.cdt.launch.attachLaunchTabGroup">
|
||||
</launchConfigurationTabGroup>
|
||||
<launchConfigurationTabGroup
|
||||
type="org.eclipse.cdt.launch.postmortemLaunchType"
|
||||
class="org.eclipse.cdt.debug.internal.ui.launch.PlaceHolderLaunchConfigurationTabGroup"
|
||||
id="org.eclipse.cdt.launch.postmortemLaunchTabGroup">
|
||||
</launchConfigurationTabGroup>
|
||||
</extension>
|
||||
|
||||
<extension
|
||||
point="org.eclipse.debug.ui.launchShortcuts">
|
||||
<shortcut
|
||||
label="%CApplicationShortcut.label"
|
||||
icon="icons/obj16/c_app.gif"
|
||||
modes="run, debug"
|
||||
class="org.eclipse.cdt.debug.internal.ui.launch.CApplicationLaunchShortcut"
|
||||
id="org.eclipse.cdt.debug.ui.localCShortcut">
|
||||
<contextualLaunch>
|
||||
<enablement>
|
||||
<with variable="selection">
|
||||
<count value="1"/>
|
||||
<iterate>
|
||||
<or>
|
||||
<instanceof value="org.eclipse.cdt.core.model.IBinary"/>
|
||||
<instanceof value="org.eclipse.cdt.core.model.ICProject"/>
|
||||
<test
|
||||
forcePluginActivation="true"
|
||||
property="org.eclipse.cdt.launch.isExecutable"/>
|
||||
<test
|
||||
forcePluginActivation="true"
|
||||
property="org.eclipse.cdt.launch.isCProject"/>
|
||||
<and>
|
||||
<instanceof value="org.eclipse.ui.IFileEditorInput"/>
|
||||
<adapt type="org.eclipse.core.resources.IResource">
|
||||
<adapt type="org.eclipse.cdt.core.model.ICElement"/>
|
||||
</adapt>
|
||||
</and>
|
||||
</or>
|
||||
</iterate>
|
||||
</with>
|
||||
</enablement>
|
||||
</contextualLaunch>
|
||||
<description
|
||||
mode="run"
|
||||
description="%ContextualRunCApplication.description"/>
|
||||
<description
|
||||
mode="debug"
|
||||
description="%ContextualDebugCApplication.description"/>
|
||||
<configurationType
|
||||
id="org.eclipse.cdt.launch.applicationLaunchType">
|
||||
</configurationType>
|
||||
</shortcut>
|
||||
</extension>
|
||||
<!-- Property testers -->
|
||||
<extension point="org.eclipse.core.expressions.propertyTesters">
|
||||
<propertyTester
|
||||
namespace="org.eclipse.cdt.launch"
|
||||
properties="isExecutable,isCProject"
|
||||
type="org.eclipse.core.runtime.IAdaptable"
|
||||
class="org.eclipse.cdt.debug.internal.ui.launch.CPropertyTester"
|
||||
id="org.eclipse.cdt.launch.CPropertyTester">
|
||||
</propertyTester>
|
||||
</extension>
|
||||
|
||||
<!-- Adapters for contextual launch -->
|
||||
<extension point="org.eclipse.core.runtime.adapters">
|
||||
<factory
|
||||
class=""
|
||||
adaptableType="org.eclipse.cdt.core.model.IBinary">
|
||||
<adapter type="org.eclipse.debug.ui.actions.ILaunchable"/>
|
||||
</factory>
|
||||
<factory
|
||||
class=""
|
||||
adaptableType="org.eclipse.core.resources.IResource">
|
||||
<adapter type="org.eclipse.debug.ui.actions.ILaunchable"/>
|
||||
</factory>
|
||||
<factory
|
||||
class=""
|
||||
adaptableType="org.eclipse.cdt.core.model.ICProject">
|
||||
<adapter type="org.eclipse.debug.ui.actions.ILaunchable"/>
|
||||
</factory>
|
||||
</extension>
|
||||
|
||||
|
||||
<extension
|
||||
point="org.eclipse.debug.ui.debugModelPresentations">
|
||||
<debugModelPresentation
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
* QNX Software Systems - Initial API and implementation
|
||||
* Ken Ryall (Nokia) - bug 178731
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.launch.internal;
|
||||
package org.eclipse.cdt.debug.internal.ui.launch;
|
||||
|
||||
import java.lang.reflect.InvocationTargetException;
|
||||
import java.util.ArrayList;
|
||||
|
@ -24,13 +24,11 @@ import org.eclipse.cdt.core.model.ICProject;
|
|||
import org.eclipse.cdt.core.settings.model.ICConfigurationDescription;
|
||||
import org.eclipse.cdt.core.settings.model.ICProjectDescription;
|
||||
import org.eclipse.cdt.debug.core.CDebugCorePlugin;
|
||||
import org.eclipse.cdt.debug.core.CDebugUtils;
|
||||
import org.eclipse.cdt.debug.core.ICDTLaunchConfigurationConstants;
|
||||
import org.eclipse.cdt.debug.core.ICDebugConfiguration;
|
||||
import org.eclipse.cdt.debug.ui.CDebugUIPlugin;
|
||||
import org.eclipse.cdt.debug.ui.ICDebuggerPage;
|
||||
import org.eclipse.cdt.launch.AbstractCLaunchDelegate;
|
||||
import org.eclipse.cdt.launch.internal.ui.LaunchMessages;
|
||||
import org.eclipse.cdt.launch.internal.ui.LaunchUIPlugin;
|
||||
import org.eclipse.cdt.ui.CElementLabelProvider;
|
||||
import org.eclipse.core.resources.IProject;
|
||||
import org.eclipse.core.resources.IResource;
|
||||
|
@ -58,6 +56,7 @@ import org.eclipse.jface.viewers.LabelProvider;
|
|||
import org.eclipse.jface.window.Window;
|
||||
import org.eclipse.swt.widgets.Shell;
|
||||
import org.eclipse.ui.IEditorPart;
|
||||
import org.eclipse.ui.IWorkbenchWindow;
|
||||
import org.eclipse.ui.dialogs.ElementListSelectionDialog;
|
||||
import org.eclipse.ui.dialogs.TwoPaneElementSelector;
|
||||
|
||||
|
@ -94,8 +93,8 @@ public class CApplicationLaunchShortcut implements ILaunchShortcut {
|
|||
candidateConfigs = new ArrayList(configs.length);
|
||||
for (int i = 0; i < configs.length; i++) {
|
||||
ILaunchConfiguration config = configs[i];
|
||||
IPath programPath = AbstractCLaunchDelegate.getProgramPath(config);
|
||||
String projectName = AbstractCLaunchDelegate.getProjectName(config);
|
||||
IPath programPath = CDebugUtils.getProgramPath(config);
|
||||
String projectName = CDebugUtils.getProjectName(config);
|
||||
IPath name = bin.getResource().getProjectRelativePath();
|
||||
if (programPath != null && programPath.equals(name)) {
|
||||
if (projectName != null && projectName.equals(bin.getCProject().getProject().getName())) {
|
||||
|
@ -104,7 +103,7 @@ public class CApplicationLaunchShortcut implements ILaunchShortcut {
|
|||
}
|
||||
}
|
||||
} catch (CoreException e) {
|
||||
LaunchUIPlugin.log(e);
|
||||
CDebugUIPlugin.log(e);
|
||||
}
|
||||
|
||||
// If there are no existing configs associated with the IBinary, create one.
|
||||
|
@ -207,7 +206,7 @@ public class CApplicationLaunchShortcut implements ILaunchShortcut {
|
|||
|
||||
config = wc.doSave();
|
||||
} catch (CoreException ce) {
|
||||
LaunchUIPlugin.log(ce);
|
||||
CDebugUIPlugin.log(ce);
|
||||
}
|
||||
return config;
|
||||
}
|
||||
|
@ -228,7 +227,11 @@ public class CApplicationLaunchShortcut implements ILaunchShortcut {
|
|||
* Convenience method to get the window that owns this action's Shell.
|
||||
*/
|
||||
protected Shell getShell() {
|
||||
return LaunchUIPlugin.getActiveWorkbenchShell();
|
||||
IWorkbenchWindow w = CDebugUIPlugin.getDefault().getActiveWorkbenchWindow();
|
||||
if (w != null) {
|
||||
return w.getShell();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
|
@ -9,7 +9,7 @@
|
|||
* IBM Corporation - initial implementation
|
||||
* Ken Ryall (Nokia) - Modified to launch on a project context.
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.launch.internal;
|
||||
package org.eclipse.cdt.debug.internal.ui.launch;
|
||||
|
||||
import org.eclipse.cdt.core.model.CoreModel;
|
||||
import org.eclipse.cdt.core.model.IBinary;
|
|
@ -0,0 +1,41 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2004, 2006 QNX Software Systems and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* QNX Software Systems - initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.debug.internal.ui.launch;
|
||||
|
||||
import java.text.MessageFormat;
|
||||
import java.util.MissingResourceException;
|
||||
import java.util.ResourceBundle;
|
||||
|
||||
public class LaunchMessages {
|
||||
|
||||
private static final String BUNDLE_NAME = "org.eclipse.cdt.launch.internal.ui.LaunchMessages";//$NON-NLS-1$
|
||||
|
||||
private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle.getBundle(BUNDLE_NAME);
|
||||
|
||||
private LaunchMessages() {
|
||||
}
|
||||
|
||||
public static String getFormattedString(String key, String arg) {
|
||||
return MessageFormat.format(getString(key), new String[]{arg});
|
||||
}
|
||||
|
||||
public static String getFormattedString(String key, String[] args) {
|
||||
return MessageFormat.format(getString(key), args);
|
||||
}
|
||||
|
||||
public static String getString(String key) {
|
||||
try {
|
||||
return RESOURCE_BUNDLE.getString(key);
|
||||
} catch (MissingResourceException e) {
|
||||
return '!' + key + '!';
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,34 @@
|
|||
###############################################################################
|
||||
# Copyright (c) 2002, 2008 QNX Software Systems and others.
|
||||
# All rights reserved. This program and the accompanying materials
|
||||
# are made available under the terms of the Eclipse Public License v1.0
|
||||
# which accompanies this distribution, and is available at
|
||||
# http://www.eclipse.org/legal/epl-v10.html
|
||||
#
|
||||
# Contributors:
|
||||
# QNX Software Systems - Initial API and implementation
|
||||
# Monta Vista - Joanne Woo - Bug 87556
|
||||
# Nokia - Ken Ryall - Bug 118894
|
||||
# Carlos O'Donnel (CodeSourcery) - Bug 218366
|
||||
# IBM Corporation
|
||||
###############################################################################
|
||||
|
||||
CApplicationLaunchShortcut.Application_Launcher=Application Launcher
|
||||
CApplicationLaunchShortcut.ChooseConfigToDebug=Choose a debug configuration to debug
|
||||
CApplicationLaunchShortcut.ChooseConfigToRun=Choose a configuration to run
|
||||
CApplicationLaunchShortcut.CLocalApplication=C Local Application
|
||||
CApplicationLaunchShortcut.ChooseLocalAppToDebug=Choose a local application to debug
|
||||
CApplicationLaunchShortcut.ChooseLocalAppToRun=Choose a local application to run
|
||||
CApplicationLaunchShortcut.Launch_failed_no_binaries=Launch failed. Binary not found.
|
||||
CApplicationLaunchShortcut.LaunchFailed=Launch failed
|
||||
CApplicationLaunchShortcut.LaunchDebugConfigSelection=Launch Debug Configuration Selection
|
||||
CApplicationLaunchShortcut.LaunchConfigSelection=Launch Configuration Selection
|
||||
CApplicationLaunchShortcut.Invalid_launch_mode_1=Invalid launch mode
|
||||
CApplicationLaunchShortcut.Invalid_launch_mode_2=Invalid launch mode.
|
||||
CApplicationLaunchShortcut.Invalid_launch_mode_3=Invalid launch mode.
|
||||
CApplicationLaunchShortcut.ChooseLaunchConfigToDebug=Choose a launch configuration to debug
|
||||
CApplicationLaunchShortcut.ChooseLaunchConfigToRun=Choose a launch configuration to run
|
||||
CApplicationLaunchShortcut.Launch_failed_no_project_selected=Launch failed no project selected
|
||||
|
||||
Launch.common.BinariesColon=Binaries:
|
||||
Launch.common.QualifierColon=Qualifier:
|
|
@ -0,0 +1,24 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2008 Wind River Systems and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems - initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.debug.internal.ui.launch;
|
||||
|
||||
import org.eclipse.debug.ui.AbstractLaunchConfigurationTabGroup;
|
||||
import org.eclipse.debug.ui.ILaunchConfigurationDialog;
|
||||
import org.eclipse.debug.ui.ILaunchConfigurationTab;
|
||||
|
||||
/**
|
||||
* @since 6.0
|
||||
*/
|
||||
public class PlaceHolderLaunchConfigurationTabGroup extends AbstractLaunchConfigurationTabGroup {
|
||||
public void createTabs(ILaunchConfigurationDialog dialog, String mode) {
|
||||
setTabs(new ILaunchConfigurationTab[0]);
|
||||
}
|
||||
}
|
Binary file not shown.
Before Width: | Height: | Size: 1 KiB |
|
@ -35,3 +35,9 @@ command.reverseStepOver.label = Reverse StepOver
|
|||
command.uncall.name = Uncall
|
||||
command.uncall.description = Perform Uncall
|
||||
command.uncall.label = Uncall
|
||||
|
||||
launchTab.main.name=Main
|
||||
launchTab.arguments.name=Arguments
|
||||
launchTab.debugger.name=Debugger
|
||||
launchTab.sourceLookup.name=Source
|
||||
launchTab.common.name=Common
|
||||
|
|
|
@ -2,43 +2,123 @@
|
|||
<?eclipse version="3.0"?>
|
||||
<plugin>
|
||||
|
||||
<extension
|
||||
point="org.eclipse.debug.ui.launchConfigurationTabs">
|
||||
<!-- Local application launch tabs-->
|
||||
<tab
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.localApplicationLaunch.mainTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%launchTab.main.name"
|
||||
class="org.eclipse.cdt.dsf.gdb.internal.ui.launching.CMainTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.localCLaunch"/>
|
||||
</tab>
|
||||
<tab id="org.eclipse.cdt.dsf.gdb.launch.localApplicationLaunch.argumentsTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%launchTab.arguments.name"
|
||||
class="org.eclipse.cdt.dsf.gdb.internal.ui.launching.CArgumentsTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.dsf.gdb.launch.mainTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.localApplicationLaunch.debuggerTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%launchTab.debugger.name"
|
||||
class="org.eclipse.cdt.dsf.gdb.internal.ui.launching.LocalApplicationCDebuggerTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.dsf.gdb.launch.argumentsTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.localApplicationLaunch.sourceLookupTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%launchTab.sourceLookup.name"
|
||||
class="org.eclipse.debug.ui.sourcelookup.SourceLookupTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.dsf.gdb.launch.debuggerTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.localApplicationLaunch.commonTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%launchTab.common.name"
|
||||
class="org.eclipse.debug.ui.CommonTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.debug.ui.sourceLookupTab"/>
|
||||
</tab>
|
||||
|
||||
<!-- Remote application launch tabs-->
|
||||
<tab
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.remoteApplicationLaunch.mainTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%launchTab.main.name"
|
||||
class="org.eclipse.cdt.dsf.gdb.internal.ui.launching.CMainTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.remoteCLaunch"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.remoteApplicationLaunch.debuggerTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%launchTab.debugger.name"
|
||||
class="org.eclipse.cdt.dsf.gdb.internal.ui.launching.LocalApplicationCDebuggerTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.remoteCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.dsf.gdb.launch.mainTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.remoteApplicationLaunch.sourceLookupTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%launchTab.sourceLookup.name"
|
||||
class="org.eclipse.debug.ui.sourcelookup.SourceLookupTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.remoteCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.dsf.gdb.launch.debuggerTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.remoteApplicationLaunch.commonTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%launchTab.common.name"
|
||||
class="org.eclipse.debug.ui.CommonTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.remoteCLaunch"/>
|
||||
<placement after="org.eclipse.debug.ui.sourceLookupTab"/>
|
||||
</tab>
|
||||
|
||||
<!-- Attach launch tabs-->
|
||||
<tab
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.attachLaunch.mainTab"
|
||||
group="org.eclipse.cdt.launch.attachLaunchTabGroup"
|
||||
name="%launchTab.main.name"
|
||||
class="org.eclipse.cdt.dsf.gdb.internal.ui.launching.CMainAttachTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.attachCLaunch"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.attachLaunch.debuggerTab"
|
||||
group="org.eclipse.cdt.launch.attachLaunchTabGroup"
|
||||
name="%launchTab.debugger.name"
|
||||
class="org.eclipse.cdt.dsf.gdb.internal.ui.launching.AttachCDebuggerTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.attachCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.dsf.gdb.launch.mainTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.attachLaunch.sourceLookupTab"
|
||||
group="org.eclipse.cdt.launch.attachLaunchTabGroup"
|
||||
name="%launchTab.sourceLookup.name"
|
||||
class="org.eclipse.debug.ui.sourcelookup.SourceLookupTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.attachCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.dsf.gdb.launch.debuggerTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.attachLaunch.commonTab"
|
||||
group="org.eclipse.cdt.launch.attachLaunchTabGroup"
|
||||
name="%launchTab.common.name"
|
||||
class="org.eclipse.debug.ui.CommonTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.dsf.gdb.launch.attachCLaunch"/>
|
||||
<placement after="org.eclipse.debug.ui.sourceLookupTab"/>
|
||||
</tab>
|
||||
</extension>
|
||||
|
||||
<extension
|
||||
point="org.eclipse.debug.ui.launchConfigurationTabGroups">
|
||||
<launchConfigurationTabGroup
|
||||
class="org.eclipse.cdt.dsf.gdb.internal.ui.launching.GdbLocalRunLaunchConfigurationTabGroup"
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.localRunLaunchTabGroup"
|
||||
type="org.eclipse.cdt.dsf.gdb.launch.localCLaunch">
|
||||
</launchConfigurationTabGroup>
|
||||
<launchConfigurationTabGroup
|
||||
class="org.eclipse.cdt.dsf.gdb.internal.ui.launching.GdbRemoteRunLaunchConfigurationTabGroup"
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.remoteRunLaunchTabGroup"
|
||||
type="org.eclipse.cdt.dsf.gdb.launch.remoteCLaunch">
|
||||
</launchConfigurationTabGroup>
|
||||
<launchConfigurationTabGroup
|
||||
class="org.eclipse.cdt.dsf.gdb.internal.ui.launching.GdbAttachLaunchConfigurationTabGroup"
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.localAttachLaunchTabGroup"
|
||||
type="org.eclipse.cdt.dsf.gdb.launch.attachCLaunch">
|
||||
</launchConfigurationTabGroup>
|
||||
</extension>
|
||||
<extension
|
||||
point="org.eclipse.debug.ui.launchConfigurationTypeImages">
|
||||
<launchConfigurationTypeImage
|
||||
configTypeID="org.eclipse.cdt.dsf.gdb.launch.localCLaunch"
|
||||
icon="icons/full/obj16/c_app.gif"
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.localRunLaunchImage">
|
||||
</launchConfigurationTypeImage>
|
||||
<launchConfigurationTypeImage
|
||||
configTypeID="org.eclipse.cdt.dsf.gdb.launch.remoteCLaunch"
|
||||
icon="icons/full/obj16/c_app.gif"
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.remoteRunLaunchImage">
|
||||
</launchConfigurationTypeImage>
|
||||
<launchConfigurationTypeImage
|
||||
configTypeID="org.eclipse.cdt.dsf.gdb.launch.attachCLaunch"
|
||||
icon="icons/full/obj16/c_app.gif"
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.attachRunLaunchImage">
|
||||
</launchConfigurationTypeImage>
|
||||
</extension>
|
||||
|
||||
|
||||
<extension point="org.eclipse.core.runtime.adapters">
|
||||
<factory
|
||||
|
|
|
@ -0,0 +1,25 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2008 Wind River Systems and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems - initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.dsf.gdb.internal.ui.launching;
|
||||
|
||||
|
||||
/**
|
||||
* Debugger tab to use for an attach launch configuration.
|
||||
*
|
||||
* @since 2.0
|
||||
*/
|
||||
public class AttachCDebuggerTab extends CDebuggerTab {
|
||||
|
||||
public AttachCDebuggerTab() {
|
||||
// We don't know yet if we are going to do a remote or local session
|
||||
super(null, true);
|
||||
}
|
||||
}
|
|
@ -48,6 +48,15 @@ import org.eclipse.swt.widgets.Text;
|
|||
*/
|
||||
public class CArgumentsTab extends CLaunchConfigurationTab {
|
||||
|
||||
/**
|
||||
* Tab identifier used for ordering of tabs added using the
|
||||
* <code>org.eclipse.debug.ui.launchConfigurationTabs</code>
|
||||
* extension point.
|
||||
*
|
||||
* @since 2.0
|
||||
*/
|
||||
public static final String TAB_ID = "org.eclipse.cdt.dsf.gdb.launch.argumentsTab";
|
||||
|
||||
// Program arguments UI widgets
|
||||
protected Label fPrgmArgumentsLabel;
|
||||
protected Text fPrgmArgumentsText;
|
||||
|
@ -222,6 +231,11 @@ public class CArgumentsTab extends CLaunchConfigurationTab {
|
|||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getId() {
|
||||
return TAB_ID;
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.eclipse.debug.ui.ILaunchConfigurationTab#getName()
|
||||
*/
|
||||
|
|
|
@ -61,6 +61,15 @@ import org.eclipse.swt.widgets.Text;
|
|||
|
||||
public class CDebuggerTab extends AbstractCDebuggerTab {
|
||||
|
||||
/**
|
||||
* Tab identifier used for ordering of tabs added using the
|
||||
* <code>org.eclipse.debug.ui.launchConfigurationTabs</code>
|
||||
* extension point.
|
||||
*
|
||||
* @since 2.0
|
||||
*/
|
||||
public static final String TAB_ID = "org.eclipse.cdt.dsf.gdb.launch.debuggerTab";
|
||||
|
||||
private final static String LOCAL_DEBUGGER_ID = "org.eclipse.cdt.dsf.gdb.GdbDebugger";//$NON-NLS-1$
|
||||
private final static String REMOTE_DEBUGGER_ID = "org.eclipse.cdt.dsf.gdb.GdbServerDebugger";//$NON-NLS-1$
|
||||
|
||||
|
@ -85,6 +94,11 @@ public class CDebuggerTab extends AbstractCDebuggerTab {
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getId() {
|
||||
return TAB_ID;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void createControl(Composite parent) {
|
||||
fContainer = new ScrolledComposite(parent, SWT.V_SCROLL | SWT.H_SCROLL);
|
||||
|
|
|
@ -0,0 +1,23 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2008 Wind River Systems and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems - initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.dsf.gdb.internal.ui.launching;
|
||||
|
||||
|
||||
/**
|
||||
* Main tab to use for an attach launch configuration.
|
||||
*
|
||||
* @since 2.0
|
||||
*/
|
||||
public class CMainAttachTab extends CMainTab {
|
||||
public CMainAttachTab() {
|
||||
super(2);// In some case, we don't need to specify an executable
|
||||
}
|
||||
}
|
|
@ -71,6 +71,15 @@ import org.eclipse.ui.dialogs.TwoPaneElementSelector;
|
|||
|
||||
public class CMainTab extends CLaunchConfigurationTab {
|
||||
|
||||
/**
|
||||
* Tab identifier used for ordering of tabs added using the
|
||||
* <code>org.eclipse.debug.ui.launchConfigurationTabs</code>
|
||||
* extension point.
|
||||
*
|
||||
* @since 2.0
|
||||
*/
|
||||
public static final String TAB_ID = "org.eclipse.cdt.dsf.gdb.launch.mainTab";
|
||||
|
||||
// Project UI widgets
|
||||
protected Label fProjLabel;
|
||||
protected Text fProjText;
|
||||
|
@ -697,6 +706,11 @@ public class CMainTab extends CLaunchConfigurationTab {
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getId() {
|
||||
return TAB_ID;
|
||||
}
|
||||
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
*
|
||||
|
|
|
@ -0,0 +1,25 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2008 Wind River Systems and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems - initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.dsf.gdb.internal.ui.launching;
|
||||
|
||||
import org.eclipse.cdt.dsf.gdb.service.SessionType;
|
||||
|
||||
/**
|
||||
* Debugger tab to use for a local application launch configuration.
|
||||
*
|
||||
* @since 2.0
|
||||
*/
|
||||
public class LocalApplicationCDebuggerTab extends CDebuggerTab {
|
||||
|
||||
public LocalApplicationCDebuggerTab() {
|
||||
super(SessionType.LOCAL, false);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,25 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2008 Wind River Systems and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems - initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.dsf.gdb.internal.ui.launching;
|
||||
|
||||
import org.eclipse.cdt.dsf.gdb.service.SessionType;
|
||||
|
||||
/**
|
||||
* Debugger tab to use for a remote application launch configuration.
|
||||
*
|
||||
* @since 2.0
|
||||
*/
|
||||
public class RemoteApplicationCDebuggerTab extends CDebuggerTab {
|
||||
|
||||
public RemoteApplicationCDebuggerTab() {
|
||||
super(SessionType.REMOTE, false);
|
||||
}
|
||||
}
|
|
@ -11,3 +11,9 @@
|
|||
pluginName=GDB DSF Debugger Integration Core
|
||||
providerName=Eclipse.org
|
||||
|
||||
launchDelegate.localApplication.name=GDB (DSF) Create Process
|
||||
launchDelegate.localApplication.description=Start new application under control of GDB debugger integrated using the Debugger Services Framework (DSF).
|
||||
launchDelegate.remoteApplication.name=GDB (DSF) Remote System Process
|
||||
launchDelegate.remoteApplication.description=Start new application on a remote system under control of GDB debugger integrated using the Debugger Services Framework (DSF)
|
||||
launchDelegate.attach.name=GDB (DSF) Attach to Process
|
||||
launchDelegate.attach.description=Attach the GDB debugger, integrated using the Debugger Services Framework (DSF), to a running program.
|
||||
|
|
|
@ -2,34 +2,38 @@
|
|||
<?eclipse version="3.0"?>
|
||||
<plugin>
|
||||
|
||||
<extension point="org.eclipse.debug.core.launchConfigurationTypes">
|
||||
<launchConfigurationType
|
||||
sourceLocatorId="org.eclipse.cdt.debug.core.sourceLocator"
|
||||
delegate="org.eclipse.cdt.dsf.gdb.launching.GdbLaunchDelegate"
|
||||
public="true"
|
||||
sourcePathComputerId="org.eclipse.cdt.debug.core.sourcePathComputer"
|
||||
name="C/C++ Local Application (Experimental - DSF)"
|
||||
<!-- TODO: externalize the strings. For some reason strings from plugin.properties are not working -->
|
||||
<extension point="org.eclipse.debug.core.launchDelegates">
|
||||
<launchDelegate
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.localCLaunch"
|
||||
modes="debug">
|
||||
</launchConfigurationType>
|
||||
<launchConfigurationType
|
||||
type="org.eclipse.cdt.launch.applicationLaunchType"
|
||||
modes="debug"
|
||||
delegate="org.eclipse.cdt.dsf.gdb.launching.GdbLaunchDelegate"
|
||||
name="GDB (DSF) Create Process"
|
||||
delegateDescription="Start new application under control of GDB debugger integrated using the Debugger Services Framework (DSF)."
|
||||
sourceLocatorId="org.eclipse.cdt.debug.core.sourceLocator"
|
||||
sourcePathComputerId="org.eclipse.cdt.debug.core.sourcePathComputer">
|
||||
</launchDelegate>
|
||||
<launchDelegate
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.remoteCLaunch"
|
||||
type="org.eclipse.cdt.launch.applicationLaunchType"
|
||||
modes="debug"
|
||||
name="C/C++ Remote Application (Experimental - DSF)"
|
||||
public="true"
|
||||
sourceLocatorId="org.eclipse.cdt.debug.core.sourceLocator"
|
||||
sourcePathComputerId="org.eclipse.cdt.debug.core.sourcePathComputer">
|
||||
</launchConfigurationType>
|
||||
<launchConfigurationType
|
||||
delegate="org.eclipse.cdt.dsf.gdb.launching.GdbLaunchDelegate"
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.attachCLaunch"
|
||||
modes="debug"
|
||||
name="C/C++ Attach to Running Application (Experimental - DSF)"
|
||||
public="true"
|
||||
name="GDB (DSF) Remote System Process"
|
||||
delegateDescription="Start new application on a remote system under control of GDB debugger integrated using the Debugger Services Framework (DSF)"
|
||||
sourceLocatorId="org.eclipse.cdt.debug.core.sourceLocator"
|
||||
sourcePathComputerId="org.eclipse.cdt.debug.core.sourcePathComputer">
|
||||
</launchConfigurationType>
|
||||
</launchDelegate>
|
||||
<launchDelegate
|
||||
id="org.eclipse.cdt.dsf.gdb.launch.attachCLaunch"
|
||||
type="org.eclipse.cdt.launch.attachLaunchType"
|
||||
modes="debug"
|
||||
delegate="org.eclipse.cdt.dsf.gdb.launching.GdbLaunchDelegate"
|
||||
name="GDB (DSF) Attach to Process"
|
||||
delegateDescription="Attach the GDB debugger, integrated using the Debugger Services Framework (DSF), to a running program."
|
||||
sourceLocatorId="org.eclipse.cdt.debug.core.sourceLocator"
|
||||
sourcePathComputerId="org.eclipse.cdt.debug.core.sourcePathComputer">
|
||||
</launchDelegate>
|
||||
</extension>
|
||||
|
||||
<extension
|
||||
|
|
|
@ -11,11 +11,17 @@
|
|||
pluginName=C/C++ Development Tools Launching Support
|
||||
providerName=Eclipse.org
|
||||
|
||||
LocalCDTLaunch.name=C/C++ Local Application
|
||||
LocalAttachCDTLaunch.name=C/C++ Attach to Local Application
|
||||
CoreFileCDTLaunch.name=C/C++ Postmortem debugger
|
||||
|
||||
CApplicationShortcut.label=Local C/C++ Application
|
||||
ContextualRunCApplication.description=Runs a local C/C++ application
|
||||
ContextualDebugCApplication.description=Debugs a local C/C++ application
|
||||
LocalCDTLaunch.name=Standard Create Process
|
||||
LocalCDTLaunch.description=Start new application optionally under control of the standard debugger.
|
||||
LocalAttachCDTLaunch.name=Standard Attach to Process
|
||||
LocalAttachCDTLaunch.description=Attach standard debugger to a running program using.
|
||||
CoreFileCDTLaunch.name=Standard Postmortem Debugger
|
||||
CoreFileCDTLaunch.description=Load an application dump into the standard debugger.
|
||||
|
||||
MainLaunchTab.name=Main
|
||||
ArgumentsLaunchTab.name=Arguments
|
||||
EnvironmentLaunchTab.name=Environment
|
||||
DebuggerLaunchTab.name=Debugger
|
||||
SourceLookupLaunchTab.name=Source
|
||||
CommonLaunchTab.name=Common
|
||||
CoreFileLaunchTab.name=Debugger
|
|
@ -3,124 +3,155 @@
|
|||
<plugin>
|
||||
|
||||
<extension
|
||||
point="org.eclipse.debug.core.launchConfigurationTypes">
|
||||
<launchConfigurationType
|
||||
sourceLocatorId="org.eclipse.cdt.debug.core.sourceLocator"
|
||||
point="org.eclipse.debug.core.launchDelegates">
|
||||
<launchDelegate
|
||||
id="org.eclipse.cdt.cdi.launch.localCLaunch"
|
||||
type="org.eclipse.cdt.launch.applicationLaunchType"
|
||||
delegate="org.eclipse.cdt.launch.internal.LocalCDILaunchDelegate"
|
||||
public="true"
|
||||
sourcePathComputerId="org.eclipse.cdt.debug.core.sourcePathComputer"
|
||||
modes="run,debug"
|
||||
name="%LocalCDTLaunch.name"
|
||||
id="org.eclipse.cdt.launch.localCLaunch"
|
||||
modes="run,debug">
|
||||
</launchConfigurationType>
|
||||
<launchConfigurationType
|
||||
delegateDescription="%LocalCDTLaunch.description"
|
||||
sourceLocatorId="org.eclipse.cdt.debug.core.sourceLocator"
|
||||
sourcePathComputerId="org.eclipse.cdt.debug.core.sourcePathComputer">
|
||||
</launchDelegate>
|
||||
<launchDelegate
|
||||
id="org.eclipse.cdt.cdi.launch.localCAttachLaunch"
|
||||
type="org.eclipse.cdt.launch.attachLaunchType"
|
||||
delegate="org.eclipse.cdt.launch.internal.LocalCDILaunchDelegate"
|
||||
id="org.eclipse.cdt.launch.localAttachCLaunch"
|
||||
modes="debug"
|
||||
name="%LocalAttachCDTLaunch.name"
|
||||
public="true"
|
||||
delegateDescription="%LocalAttachCDTLaunch.description"
|
||||
sourceLocatorId="org.eclipse.cdt.debug.core.sourceLocator"
|
||||
sourcePathComputerId="org.eclipse.cdt.debug.core.sourcePathComputer">
|
||||
</launchConfigurationType>
|
||||
<launchConfigurationType
|
||||
</launchDelegate>
|
||||
<launchDelegate
|
||||
id="org.eclipse.cdt.cdi.launch.coreFileCLaunch"
|
||||
type="org.eclipse.cdt.launch.postmortemLaunchType"
|
||||
delegate="org.eclipse.cdt.launch.internal.LocalCDILaunchDelegate"
|
||||
id="org.eclipse.cdt.launch.coreFileCLaunch"
|
||||
modes="debug"
|
||||
name="%CoreFileCDTLaunch.name"
|
||||
public="true"
|
||||
delegateDescription="%CoreFileCDTLaunch.description"
|
||||
sourceLocatorId="org.eclipse.cdt.debug.core.sourceLocator"
|
||||
sourcePathComputerId="org.eclipse.cdt.debug.core.sourcePathComputer">
|
||||
</launchConfigurationType>
|
||||
</launchDelegate>
|
||||
</extension>
|
||||
|
||||
<extension
|
||||
point="org.eclipse.debug.ui.launchConfigurationTypeImages">
|
||||
<launchConfigurationTypeImage
|
||||
icon="icons/obj16/c_app.gif"
|
||||
configTypeID="org.eclipse.cdt.launch.localCLaunch"
|
||||
id="org.eclipse.cdt.launch.localRunLaunchImage">
|
||||
</launchConfigurationTypeImage>
|
||||
<launchConfigurationTypeImage
|
||||
icon="icons/obj16/c_app.gif"
|
||||
configTypeID="org.eclipse.cdt.launch.localAttachCLaunch"
|
||||
id="org.eclipse.cdt.launch.localAttachLaunchImage">
|
||||
</launchConfigurationTypeImage>
|
||||
<launchConfigurationTypeImage
|
||||
icon="icons/obj16/c_app.gif"
|
||||
configTypeID="org.eclipse.cdt.launch.coreFileCLaunch"
|
||||
id="org.eclipse.cdt.launch.coreFileLaunchImage">
|
||||
</launchConfigurationTypeImage>
|
||||
</extension>
|
||||
<extension
|
||||
point="org.eclipse.debug.ui.launchConfigurationTabGroups">
|
||||
<launchConfigurationTabGroup
|
||||
type="org.eclipse.cdt.launch.localCLaunch"
|
||||
class="org.eclipse.cdt.launch.internal.ui.LocalRunLaunchConfigurationTabGroup"
|
||||
id="org.eclipse.cdt.launch.localRunLaunchTabGroup">
|
||||
</launchConfigurationTabGroup>
|
||||
<launchConfigurationTabGroup
|
||||
type="org.eclipse.cdt.launch.localAttachCLaunch"
|
||||
class="org.eclipse.cdt.launch.internal.ui.LocalAttachLaunchConfigurationTabGroup"
|
||||
id="org.eclipse.cdt.launch.localAttachLaunchTabGroup">
|
||||
</launchConfigurationTabGroup>
|
||||
<launchConfigurationTabGroup
|
||||
type="org.eclipse.cdt.launch.coreFileCLaunch"
|
||||
class="org.eclipse.cdt.launch.internal.ui.CoreFileLaunchConfigurationTabGroup"
|
||||
id="org.eclipse.cdt.launch.coreFileCLaunchTabGroup">
|
||||
</launchConfigurationTabGroup>
|
||||
</extension>
|
||||
<extension
|
||||
point="org.eclipse.debug.ui.launchShortcuts">
|
||||
<shortcut
|
||||
label="%CApplicationShortcut.label"
|
||||
icon="icons/obj16/c_app.gif"
|
||||
modes="run, debug"
|
||||
class="org.eclipse.cdt.launch.internal.CApplicationLaunchShortcut"
|
||||
id="org.eclipse.cdt.debug.ui.localCShortcut">
|
||||
<contextualLaunch>
|
||||
<enablement>
|
||||
<with variable="selection">
|
||||
<count value="1"/>
|
||||
<iterate>
|
||||
<or>
|
||||
<instanceof value="org.eclipse.cdt.core.model.IBinary"/>
|
||||
<instanceof value="org.eclipse.cdt.core.model.ICProject"/>
|
||||
<test
|
||||
forcePluginActivation="true"
|
||||
property="org.eclipse.cdt.launch.isExecutable"/>
|
||||
<test
|
||||
forcePluginActivation="true"
|
||||
property="org.eclipse.cdt.launch.isCProject"/>
|
||||
<and>
|
||||
<instanceof value="org.eclipse.ui.IFileEditorInput"/>
|
||||
<adapt type="org.eclipse.core.resources.IResource">
|
||||
<adapt type="org.eclipse.cdt.core.model.ICElement"/>
|
||||
</adapt>
|
||||
</and>
|
||||
</or>
|
||||
</iterate>
|
||||
</with>
|
||||
</enablement>
|
||||
</contextualLaunch>
|
||||
<description
|
||||
mode="run"
|
||||
description="%ContextualRunCApplication.description"/>
|
||||
<description
|
||||
mode="debug"
|
||||
description="%ContextualDebugCApplication.description"/>
|
||||
<configurationType
|
||||
id="org.eclipse.cdt.launch.localCLaunch">
|
||||
</configurationType>
|
||||
</shortcut>
|
||||
</extension>
|
||||
<!-- Property testers -->
|
||||
<extension point="org.eclipse.core.expressions.propertyTesters">
|
||||
<propertyTester
|
||||
namespace="org.eclipse.cdt.launch"
|
||||
properties="isExecutable,isCProject"
|
||||
type="org.eclipse.core.runtime.IAdaptable"
|
||||
class="org.eclipse.cdt.launch.internal.CPropertyTester"
|
||||
id="org.eclipse.cdt.launch.CPropertyTester">
|
||||
</propertyTester>
|
||||
point="org.eclipse.debug.ui.launchConfigurationTabs">
|
||||
<!-- Application launch tabs-->
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.applicationLaunch.mainTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%MainLaunchTab.name"
|
||||
class="org.eclipse.cdt.launch.ui.CMainTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.localCLaunch"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.applicationLaunch.argumentsTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%ArgumentsLaunchTab.name"
|
||||
class="org.eclipse.cdt.launch.ui.CArgumentsTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.cdi.launch.mainTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.applicationLaunch.environmentTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%EnvironmentLaunchTab.name"
|
||||
class="org.eclipse.debug.ui.EnvironmentTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.cdi.launch.argumentsTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.applicationLaunch.debuggerTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%DebuggerLaunchTab.name"
|
||||
class="org.eclipse.cdt.launch.ui.ApplicationCDebuggerTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.debug.ui.environmentTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.applicationLaunch.sourceLookupTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%SourceLookupLaunchTab.name"
|
||||
class="org.eclipse.debug.ui.sourcelookup.SourceLookupTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.cdi.launch.debuggerTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.applicationLaunch.commonTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%CommonLaunchTab.name"
|
||||
class="org.eclipse.debug.ui.CommonTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.debug.ui.sourceLookupTab"/>
|
||||
</tab>
|
||||
|
||||
<!-- Attach launch tabs-->
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.attachLaunch.mainAttachTab"
|
||||
group="org.eclipse.cdt.launch.attachLaunchTabGroup"
|
||||
name="%MainLaunchTab.name"
|
||||
class="org.eclipse.cdt.launch.ui.CMainAttachTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.localCAttachLaunch"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.attachLaunch.debuggerTab"
|
||||
group="org.eclipse.cdt.launch.attachLaunchTabGroup"
|
||||
name="%DebuggerLaunchTab.name"
|
||||
class="org.eclipse.cdt.launch.ui.AttachCDebuggerTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.localCAttachLaunch"/>
|
||||
<placement after="org.eclipse.cdt.cdi.launch.mainTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.attachLaunch.sourceLookupTab"
|
||||
group="org.eclipse.cdt.launch.attachLaunchTabGroup"
|
||||
name="%SourceLookupLaunchTab.name"
|
||||
class="org.eclipse.debug.ui.sourcelookup.SourceLookupTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.localCAttachLaunch"/>
|
||||
<placement after="org.eclipse.cdt.cdi.launch.debuggerTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.attachLaunch.commonTab"
|
||||
group="org.eclipse.cdt.launch.attachLaunchTabGroup"
|
||||
name="%CommonLaunchTab.name"
|
||||
class="org.eclipse.debug.ui.CommonTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.localCAttachLaunch"/>
|
||||
<placement after="org.eclipse.debug.ui.sourceLookupTab"/>
|
||||
</tab>
|
||||
|
||||
<!-- Post mortem launch tabs-->
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.postmortemLaunch.mainTab"
|
||||
group="org.eclipse.cdt.launch.postmortemLaunchTabGroup"
|
||||
name="%MainLaunchTab.name"
|
||||
class="org.eclipse.cdt.launch.ui.CMainTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.coreFileCLaunch"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.postmortemLaunch.coreTab"
|
||||
group="org.eclipse.cdt.launch.postmortemLaunchTabGroup"
|
||||
name="%CoreFileLaunchTab.name"
|
||||
class="org.eclipse.cdt.launch.ui.CoreFileDebuggerTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.coreFileCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.cdi.launch.mainTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.postmortemLaunch.sourceLookupTab"
|
||||
group="org.eclipse.cdt.launch.postmortemLaunchTabGroup"
|
||||
name="%SourceLookupLaunchTab.name"
|
||||
class="org.eclipse.debug.ui.sourcelookup.SourceLookupTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.coreFileCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.cdi.launch.coreTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.cdi.launch.postmortemLaunch.commonTab"
|
||||
group="org.eclipse.cdt.launch.postmortemLaunchTabGroup"
|
||||
name="%CommonLaunchTab.name"
|
||||
class="org.eclipse.debug.ui.CommonTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.cdi.launch.coreFileCLaunch"/>
|
||||
<placement after="org.eclipse.debug.ui.sourceLookupTab"/>
|
||||
</tab>
|
||||
</extension>
|
||||
<extension
|
||||
point="org.eclipse.debug.core.statusHandlers">
|
||||
|
@ -138,23 +169,4 @@
|
|||
</statusHandler>
|
||||
</extension>
|
||||
|
||||
<!-- Adapters for contextual launch -->
|
||||
<extension point="org.eclipse.core.runtime.adapters">
|
||||
<factory
|
||||
class=""
|
||||
adaptableType="org.eclipse.cdt.core.model.IBinary">
|
||||
<adapter type="org.eclipse.debug.ui.actions.ILaunchable"/>
|
||||
</factory>
|
||||
<factory
|
||||
class=""
|
||||
adaptableType="org.eclipse.core.resources.IResource">
|
||||
<adapter type="org.eclipse.debug.ui.actions.ILaunchable"/>
|
||||
</factory>
|
||||
<factory
|
||||
class=""
|
||||
adaptableType="org.eclipse.cdt.core.model.ICProject">
|
||||
<adapter type="org.eclipse.debug.ui.actions.ILaunchable"/>
|
||||
</factory>
|
||||
</extension>
|
||||
|
||||
</plugin>
|
||||
|
|
|
@ -38,6 +38,7 @@ import org.eclipse.cdt.core.model.ICProject;
|
|||
import org.eclipse.cdt.core.settings.model.ICConfigurationDescription;
|
||||
import org.eclipse.cdt.core.settings.model.ICProjectDescription;
|
||||
import org.eclipse.cdt.debug.core.CDebugCorePlugin;
|
||||
import org.eclipse.cdt.debug.core.CDebugUtils;
|
||||
import org.eclipse.cdt.debug.core.ICDTLaunchConfigurationConstants;
|
||||
import org.eclipse.cdt.debug.core.ICDebugConfiguration;
|
||||
import org.eclipse.cdt.debug.ui.CDebugUIPlugin;
|
||||
|
@ -173,35 +174,32 @@ abstract public class AbstractCLaunchDelegate extends LaunchConfigurationDelegat
|
|||
|
||||
abstract protected String getPluginID();
|
||||
|
||||
/**
|
||||
* @deprecated Use {@link org.eclipse.cdt.debug.core.CDebugUtils} instead.
|
||||
*/
|
||||
public static ICProject getCProject(ILaunchConfiguration configuration) throws CoreException {
|
||||
String projectName = getProjectName(configuration);
|
||||
if (projectName != null) {
|
||||
projectName = projectName.trim();
|
||||
if (projectName.length() > 0) {
|
||||
IProject project = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
|
||||
ICProject cProject = CCorePlugin.getDefault().getCoreModel().create(project);
|
||||
if (cProject != null && cProject.exists()) {
|
||||
return cProject;
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
return CDebugUtils.getCProject(configuration);
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated Use {@link org.eclipse.cdt.debug.core.CDebugUtils} instead.
|
||||
*/
|
||||
public static String getProjectName(ILaunchConfiguration configuration) throws CoreException {
|
||||
return configuration.getAttribute(ICDTLaunchConfigurationConstants.ATTR_PROJECT_NAME, (String)null);
|
||||
return CDebugUtils.getProjectName(configuration);
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated Use {@link org.eclipse.cdt.debug.core.CDebugUtils} instead.
|
||||
*/
|
||||
public static String getProgramName(ILaunchConfiguration configuration) throws CoreException {
|
||||
return configuration.getAttribute(ICDTLaunchConfigurationConstants.ATTR_PROGRAM_NAME, (String)null);
|
||||
return CDebugUtils.getProgramName(configuration);
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated Use {@link org.eclipse.cdt.debug.core.CDebugUtils} instead.
|
||||
*/
|
||||
public static IPath getProgramPath(ILaunchConfiguration configuration) throws CoreException {
|
||||
String path = getProgramName(configuration);
|
||||
if (path == null || path.trim().length() == 0) {
|
||||
return null;
|
||||
}
|
||||
return new Path(path);
|
||||
return CDebugUtils.getProgramPath(configuration);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -233,7 +231,7 @@ abstract public class AbstractCLaunchDelegate extends LaunchConfigurationDelegat
|
|||
IPersistableSourceLocator sourceLocator;
|
||||
String id = configuration.getAttribute(ILaunchConfiguration.ATTR_SOURCE_LOCATOR_ID, (String)null);
|
||||
if (id == null) {
|
||||
ICProject cProject = getCProject(configuration);
|
||||
ICProject cProject = CDebugUtils.getCProject(configuration);
|
||||
if (cProject == null) {
|
||||
abort(LaunchMessages.getString("Launch.common.Project_does_not_exist"), null, //$NON-NLS-1$
|
||||
ICDTLaunchConfigurationConstants.ERR_NOT_A_C_PROJECT);
|
||||
|
@ -330,7 +328,7 @@ abstract public class AbstractCLaunchDelegate extends LaunchConfigurationDelegat
|
|||
@Deprecated
|
||||
protected IFile getProgramFile(ILaunchConfiguration config) throws CoreException {
|
||||
ICProject cproject = verifyCProject(config);
|
||||
String fileName = getProgramName(config);
|
||||
String fileName = CDebugUtils.getProgramName(config);
|
||||
if (fileName == null) {
|
||||
abort(LaunchMessages.getString("AbstractCLaunchDelegate.Program_file_not_specified"), null, //$NON-NLS-1$
|
||||
ICDTLaunchConfigurationConstants.ERR_UNSPECIFIED_PROGRAM);
|
||||
|
@ -349,12 +347,12 @@ abstract public class AbstractCLaunchDelegate extends LaunchConfigurationDelegat
|
|||
}
|
||||
|
||||
protected ICProject verifyCProject(ILaunchConfiguration config) throws CoreException {
|
||||
String name = getProjectName(config);
|
||||
String name = CDebugUtils.getProjectName(config);
|
||||
if (name == null) {
|
||||
abort(LaunchMessages.getString("AbstractCLaunchDelegate.C_Project_not_specified"), null, //$NON-NLS-1$
|
||||
ICDTLaunchConfigurationConstants.ERR_UNSPECIFIED_PROJECT);
|
||||
}
|
||||
ICProject cproject = getCProject(config);
|
||||
ICProject cproject = CDebugUtils.getCProject(config);
|
||||
if (cproject == null) {
|
||||
IProject proj = ResourcesPlugin.getWorkspace().getRoot().getProject(name);
|
||||
if (!proj.exists()) {
|
||||
|
@ -373,7 +371,7 @@ abstract public class AbstractCLaunchDelegate extends LaunchConfigurationDelegat
|
|||
|
||||
protected IPath verifyProgramPath(ILaunchConfiguration config) throws CoreException {
|
||||
ICProject cproject = verifyCProject(config);
|
||||
IPath programPath = getProgramPath(config);
|
||||
IPath programPath = CDebugUtils.getProgramPath(config);
|
||||
if (programPath == null || programPath.isEmpty()) {
|
||||
abort(LaunchMessages.getString("AbstractCLaunchDelegate.Program_file_not_specified"), null, //$NON-NLS-1$
|
||||
ICDTLaunchConfigurationConstants.ERR_UNSPECIFIED_PROGRAM);
|
||||
|
@ -386,7 +384,7 @@ abstract public class AbstractCLaunchDelegate extends LaunchConfigurationDelegat
|
|||
// Try the old way, which is required to support linked resources.
|
||||
IFile projFile = null;
|
||||
try {
|
||||
projFile = project.getFile(getProgramPath(config));
|
||||
projFile = project.getFile(CDebugUtils.getProgramPath(config));
|
||||
}
|
||||
catch (IllegalArgumentException exc) {} // thrown if relative path that resolves to a root file (e.g., "..\somefile")
|
||||
if (projFile != null && projFile.exists()) {
|
||||
|
@ -426,7 +424,7 @@ abstract public class AbstractCLaunchDelegate extends LaunchConfigurationDelegat
|
|||
IPath path = getWorkingDirectoryPath(configuration);
|
||||
if (path == null) {
|
||||
// default working dir is the project if this config has a project
|
||||
ICProject cp = getCProject(configuration);
|
||||
ICProject cp = CDebugUtils.getCProject(configuration);
|
||||
if (cp != null) {
|
||||
IProject p = cp.getProject();
|
||||
return p.getLocation().toFile();
|
||||
|
@ -723,7 +721,7 @@ abstract public class AbstractCLaunchDelegate extends LaunchConfigurationDelegat
|
|||
|
||||
// build project list
|
||||
orderedProjects = null;
|
||||
ICProject cProject = getCProject(configuration);
|
||||
ICProject cProject = CDebugUtils.getCProject(configuration);
|
||||
if (cProject != null) {
|
||||
project = cProject.getProject();
|
||||
HashSet projectSet = new HashSet();
|
||||
|
|
|
@ -16,6 +16,7 @@ import java.io.File;
|
|||
import org.eclipse.cdt.core.IBinaryParser.IBinaryObject;
|
||||
import org.eclipse.cdt.core.model.ICProject;
|
||||
import org.eclipse.cdt.debug.core.CDIDebugModel;
|
||||
import org.eclipse.cdt.debug.core.CDebugUtils;
|
||||
import org.eclipse.cdt.debug.core.ICDTLaunchConfigurationConstants;
|
||||
import org.eclipse.cdt.debug.core.ICDebugConfiguration;
|
||||
import org.eclipse.cdt.debug.core.cdi.CDIException;
|
||||
|
@ -58,7 +59,7 @@ public class CoreFileLaunchDelegate extends AbstractCLaunchDelegate {
|
|||
|
||||
ICDebugConfiguration debugConfig = getDebugConfig(config);
|
||||
ICDISession dsession = null;
|
||||
ICProject cproject = getCProject(config);
|
||||
ICProject cproject = CDebugUtils.getCProject(config);
|
||||
|
||||
String path = config.getAttribute(ICDTLaunchConfigurationConstants.ATTR_COREFILE_PATH, (String)null);
|
||||
if (path == null) {
|
||||
|
|
|
@ -11,9 +11,11 @@
|
|||
package org.eclipse.cdt.launch.internal;
|
||||
|
||||
import java.io.FileNotFoundException;
|
||||
|
||||
import org.eclipse.cdt.core.IBinaryParser.IBinaryObject;
|
||||
import org.eclipse.cdt.core.model.ICProject;
|
||||
import org.eclipse.cdt.debug.core.CDIDebugModel;
|
||||
import org.eclipse.cdt.debug.core.CDebugUtils;
|
||||
import org.eclipse.cdt.debug.core.ICDTLaunchConfigurationConstants;
|
||||
import org.eclipse.cdt.debug.core.ICDebugConfiguration;
|
||||
import org.eclipse.cdt.debug.core.cdi.CDIException;
|
||||
|
@ -61,7 +63,7 @@ public class LocalAttachLaunchDelegate extends AbstractCLaunchDelegate {
|
|||
try {
|
||||
monitor.worked(1);
|
||||
ICProject cproject = verifyCProject(config);
|
||||
IPath exePath = getProgramPath(config);
|
||||
IPath exePath = CDebugUtils.getProgramPath(config);
|
||||
if (exePath != null && !exePath.isEmpty()) {
|
||||
if (!exePath.isAbsolute()) {
|
||||
IFile wsProgramPath = cproject.getProject().getFile(exePath);
|
||||
|
|
|
@ -51,23 +51,6 @@ CoreFileLaunchDelegate.Corefile_not_accessible=Core file is not accessible.
|
|||
CoreFileLaunchDelegate.Corefile_not_readable=Core file does not exist or is not readable.
|
||||
CoreFileLaunchDelegate.postmortem_debugging_failed=Post-mortem debugging failed
|
||||
|
||||
CApplicationLaunchShortcut.Application_Launcher=Application Launcher
|
||||
CApplicationLaunchShortcut.ChooseConfigToDebug=Choose a debug configuration to debug
|
||||
CApplicationLaunchShortcut.ChooseConfigToRun=Choose a configuration to run
|
||||
CApplicationLaunchShortcut.CLocalApplication=C Local Application
|
||||
CApplicationLaunchShortcut.ChooseLocalAppToDebug=Choose a local application to debug
|
||||
CApplicationLaunchShortcut.ChooseLocalAppToRun=Choose a local application to run
|
||||
CApplicationLaunchShortcut.Launch_failed_no_binaries=Launch failed. Binary not found.
|
||||
CApplicationLaunchShortcut.LaunchFailed=Launch failed
|
||||
CApplicationLaunchShortcut.LaunchDebugConfigSelection=Launch Debug Configuration Selection
|
||||
CApplicationLaunchShortcut.LaunchConfigSelection=Launch Configuration Selection
|
||||
CApplicationLaunchShortcut.Invalid_launch_mode_1=Invalid launch mode
|
||||
CApplicationLaunchShortcut.Invalid_launch_mode_2=Invalid launch mode.
|
||||
CApplicationLaunchShortcut.Invalid_launch_mode_3=Invalid launch mode.
|
||||
CApplicationLaunchShortcut.ChooseLaunchConfigToDebug=Choose a launch configuration to debug
|
||||
CApplicationLaunchShortcut.ChooseLaunchConfigToRun=Choose a launch configuration to run
|
||||
CApplicationLaunchShortcut.Launch_failed_no_project_selected=Launch failed no project selected
|
||||
|
||||
AbstractCDebuggerTab.No_debugger_available=No debugger available
|
||||
AbstractCDebuggerTab.Debugger=Debugger
|
||||
AbstractCDebuggerTab.ErrorLoadingDebuggerPage=Error Loading Debugger UI Component.
|
||||
|
|
|
@ -11,7 +11,9 @@
|
|||
package org.eclipse.cdt.launch.internal.ui;
|
||||
|
||||
import org.eclipse.cdt.core.model.ICProject;
|
||||
import org.eclipse.cdt.launch.AbstractCLaunchDelegate;
|
||||
import org.eclipse.cdt.debug.core.CDebugCorePlugin;
|
||||
import org.eclipse.cdt.debug.core.CDebugUtils;
|
||||
import org.eclipse.cdt.debug.core.ICDebugConstants;
|
||||
import org.eclipse.core.resources.IProject;
|
||||
import org.eclipse.core.resources.IResource;
|
||||
import org.eclipse.core.runtime.CoreException;
|
||||
|
@ -185,6 +187,7 @@ public class LaunchUIPlugin extends AbstractUIPlugin implements IDebugEventSetLi
|
|||
*/
|
||||
public void start(BundleContext context) throws Exception {
|
||||
super.start(context);
|
||||
LaunchUIPlugin.getDefault().getPluginPreferences().getString( ICDebugConstants.PREF_FILTERED_DEBUGGERS );
|
||||
DebugPlugin.getDefault().addDebugEventListener(this);
|
||||
}
|
||||
|
||||
|
@ -216,7 +219,7 @@ public class LaunchUIPlugin extends AbstractUIPlugin implements IDebugEventSetLi
|
|||
try {
|
||||
ILaunchConfiguration launchConfig = proc.getLaunch().getLaunchConfiguration();
|
||||
if (launchConfig != null) {
|
||||
cproject = AbstractCLaunchDelegate.getCProject(launchConfig);
|
||||
cproject = CDebugUtils.getCProject(launchConfig);
|
||||
}
|
||||
} catch (CoreException e) {
|
||||
}
|
||||
|
|
|
@ -13,8 +13,8 @@ package org.eclipse.cdt.launch.internal.ui;
|
|||
import java.io.File;
|
||||
|
||||
import org.eclipse.cdt.core.model.ICProject;
|
||||
import org.eclipse.cdt.debug.core.CDebugUtils;
|
||||
import org.eclipse.cdt.debug.core.ICDTLaunchConfigurationConstants;
|
||||
import org.eclipse.cdt.launch.AbstractCLaunchDelegate;
|
||||
import org.eclipse.cdt.launch.ui.CLaunchConfigurationTab;
|
||||
import org.eclipse.core.resources.IContainer;
|
||||
import org.eclipse.core.resources.IResource;
|
||||
|
@ -249,7 +249,7 @@ public class WorkingDirectoryBlock extends CLaunchConfigurationTab {
|
|||
try {
|
||||
ILaunchConfiguration config = getLaunchConfiguration();
|
||||
if (config != null) {
|
||||
ICProject cProject = AbstractCLaunchDelegate.getCProject(config);
|
||||
ICProject cProject = CDebugUtils.getCProject(config);
|
||||
if (cProject != null) {
|
||||
fWorkingDirText.setText("${workspace_loc:" + cProject.getPath().makeRelative().toOSString() + "}"); //$NON-NLS-1$ //$NON-NLS-2$
|
||||
return;
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2008 Wind River Systems and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems - initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.launch.ui;
|
||||
|
||||
/**
|
||||
* CDebugger tab to use for an application launch configuration.
|
||||
*
|
||||
* @since 6.0
|
||||
*/
|
||||
public class ApplicationCDebuggerTab extends CDebuggerTab {
|
||||
public ApplicationCDebuggerTab() {
|
||||
super (false);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,22 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2008 Wind River Systems and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Wind River Systems - initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.launch.ui;
|
||||
|
||||
/**
|
||||
* CDebugger tab to use for an attach launch configuration.
|
||||
*
|
||||
* @since 6.0
|
||||
*/
|
||||
public class AttachCDebuggerTab extends CDebuggerTab {
|
||||
public AttachCDebuggerTab() {
|
||||
super (true);
|
||||
}
|
||||
}
|
|
@ -49,6 +49,15 @@ import org.eclipse.swt.widgets.Text;
|
|||
*/
|
||||
public class CArgumentsTab extends CLaunchConfigurationTab {
|
||||
|
||||
/**
|
||||
* Tab identifier used for ordering of tabs added using the
|
||||
* <code>org.eclipse.debug.ui.launchConfigurationTabs</code>
|
||||
* extension point.
|
||||
*
|
||||
* @since 6.0
|
||||
*/
|
||||
public static final String TAB_ID = "org.eclipse.cdt.cdi.launch.argumentsTab";
|
||||
|
||||
// Program arguments UI widgets
|
||||
protected Label fPrgmArgumentsLabel;
|
||||
protected Text fPrgmArgumentsText;
|
||||
|
@ -218,6 +227,12 @@ public class CArgumentsTab extends CLaunchConfigurationTab {
|
|||
return null;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String getId() {
|
||||
return TAB_ID;
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.eclipse.debug.ui.ILaunchConfigurationTab#getName()
|
||||
*/
|
||||
|
|
|
@ -65,6 +65,15 @@ import org.eclipse.swt.widgets.Text;
|
|||
|
||||
public class CDebuggerTab extends AbstractCDebuggerTab {
|
||||
|
||||
/**
|
||||
* Tab identifier used for ordering of tabs added using the
|
||||
* <code>org.eclipse.debug.ui.launchConfigurationTabs</code>
|
||||
* extension point.
|
||||
*
|
||||
* @since 6.0
|
||||
*/
|
||||
public static final String TAB_ID = "org.eclipse.cdt.cdi.launch.debuggerTab";
|
||||
|
||||
public class AdvancedDebuggerOptionsDialog extends Dialog {
|
||||
|
||||
private Button fVarBookKeeping;
|
||||
|
@ -154,6 +163,11 @@ public class CDebuggerTab extends AbstractCDebuggerTab {
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getId() {
|
||||
return TAB_ID;
|
||||
}
|
||||
|
||||
public void createControl(Composite parent) {
|
||||
fContainer = new ScrolledComposite( parent, SWT.V_SCROLL | SWT.H_SCROLL );
|
||||
fContainer.setLayoutData(new GridData(GridData.FILL_BOTH));
|
||||
|
|
|
@ -26,5 +26,4 @@ public class CMainAttachTab extends CMainTab {
|
|||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -81,6 +81,15 @@ import org.eclipse.ui.dialogs.TwoPaneElementSelector;
|
|||
|
||||
public class CMainTab extends CLaunchConfigurationTab {
|
||||
|
||||
/**
|
||||
* Tab identifier used for ordering of tabs added using the
|
||||
* <code>org.eclipse.debug.ui.launchConfigurationTabs</code>
|
||||
* extension point.
|
||||
*
|
||||
* @since 6.0
|
||||
*/
|
||||
public static final String TAB_ID = "org.eclipse.cdt.cdi.launch.mainTab";
|
||||
|
||||
// Project UI widgets
|
||||
protected Label fProjLabel;
|
||||
protected Text fProjText;
|
||||
|
@ -780,6 +789,12 @@ public class CMainTab extends CLaunchConfigurationTab {
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getId() {
|
||||
return TAB_ID;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
*
|
||||
|
|
Loading…
Add table
Reference in a new issue