1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00

Merge remote-tracking branch 'cdt/master' into sd90

This commit is contained in:
Andrew Gvozdev 2012-02-06 12:21:57 -05:00
commit b568998d02
39 changed files with 177 additions and 42 deletions

View file

@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %Bundle-Name
Bundle-SymbolicName: org.eclipse.cdt.codan.ui; singleton:=true
Bundle-Version: 2.0.0.qualifier
Bundle-Version: 2.0.1.qualifier
Bundle-Activator: org.eclipse.cdt.codan.internal.ui.CodanUIActivator
Bundle-Vendor: %Bundle-Vendor
Require-Bundle: org.eclipse.ui,

View file

@ -11,7 +11,7 @@
<relativePath>../../pom.xml</relativePath>
</parent>
<version>2.0.0-SNAPSHOT</version>
<version>2.0.1-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.codan.ui</artifactId>
<packaging>eclipse-plugin</packaging>
</project>

View file

@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %fragmentName.aix
Bundle-SymbolicName: org.eclipse.cdt.core.aix; singleton:=true
Bundle-Version: 5.1.0.qualifier
Bundle-Version: 5.1.1.qualifier
Bundle-ClassPath: cdtaix.jar
Bundle-Vendor: %providerName
Fragment-Host: org.eclipse.cdt.core;bundle-version="[5.0.0,6.0.0)"

View file

@ -11,7 +11,7 @@
<relativePath>../../pom.xml</relativePath>
</parent>
<version>5.1.0-SNAPSHOT</version>
<version>5.1.1-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.core.aix</artifactId>
<packaging>eclipse-plugin</packaging>

View file

@ -2,7 +2,7 @@
<feature
id="org.eclipse.cdt.build.crossgcc"
label="%featureName"
version="1.0.0.qualifier"
version="1.1.0.qualifier"
provider-name="%providerName"
plugin="org.eclipse.cdt.build.crossgcc"
license-feature="org.eclipse.cdt.license"

View file

@ -12,7 +12,7 @@
</parent>
<groupId>org.eclipse.cdt.features</groupId>
<version>1.0.0-SNAPSHOT</version>
<version>1.1.0-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.build.crossgcc</artifactId>
<packaging>eclipse-feature</packaging>
</project>

View file

@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.cdt.debug.mi.ui; singleton:=true
Bundle-Version: 6.1.0.qualifier
Bundle-Version: 6.1.1.qualifier
Bundle-Activator: org.eclipse.cdt.debug.mi.internal.ui.MIUIPlugin
Bundle-Vendor: %providerName
Bundle-Localization: plugin

View file

@ -11,7 +11,7 @@
<relativePath>../../pom.xml</relativePath>
</parent>
<version>6.1.0-SNAPSHOT</version>
<version>6.1.1-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.debug.mi.ui</artifactId>
<packaging>eclipse-plugin</packaging>
</project>

View file

@ -2,7 +2,7 @@
<feature
id="org.eclipse.cdt.gnu.debug"
label="%featureName"
version="7.1.0.qualifier"
version="7.1.1.qualifier"
provider-name="%providerName">
<description>

View file

@ -14,5 +14,5 @@
<groupId>org.eclipse.cdt.feature</groupId>
<artifactId>org.eclipse.cdt.gnu.debug</artifactId>
<packaging>eclipse-feature</packaging>
<version>7.1.0-SNAPSHOT</version>
<version>7.1.1-SNAPSHOT</version>
</project>

View file

@ -2,7 +2,7 @@
<feature
id="org.eclipse.cdt.gnu.debug.source"
label="%featureName"
version="7.1.0.qualifier"
version="7.1.1.qualifier"
provider-name="%providerName">
<description>

View file

@ -14,5 +14,5 @@
<groupId>org.eclipse.cdt.features</groupId>
<artifactId>org.eclipse.cdt.gnu.debug.source</artifactId>
<packaging>eclipse-feature</packaging>
<version>7.1.0-SNAPSHOT</version>
<version>7.1.1-SNAPSHOT</version>
</project>

View file

@ -67,4 +67,11 @@
class="org.eclipse.cdt.dsf.gdb.internal.GdbPreferenceInitializer">
</initializer>
</extension>
<extension
point="org.eclipse.debug.core.processFactories">
<processFactory
class="org.eclipse.cdt.dsf.gdb.launching.GdbProcessFactory"
id="org.eclipse.cdt.dsf.gdb.GdbProcessFactory">
</processFactory>
</extension>
</plugin>

View file

@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2008, 2010 Ericsson and others.
* Copyright (c) 2008, 2012 Ericsson 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
@ -8,6 +8,7 @@
* Contributors:
* Ericsson - initial API and implementation
* Marc Khouzam (Ericsson) - Support for fast tracepoints (Bug 346320)
* Anton Gorenkov - Need to use a process factory (Bug 210366)
*******************************************************************************/
package org.eclipse.cdt.dsf.gdb;
@ -210,4 +211,11 @@ public class IGDBLaunchConfigurationConstants {
*/
public static final String DEBUGGER_TRACEPOINT_MODE_DEFAULT = DEBUGGER_TRACEPOINT_SLOW_ONLY;
/**
* The default value of DebugPlugin.ATTR_PROCESS_FACTORY_ID.
* @since 4.1
*/
// Bug 210366
public static final String DEBUGGER_ATTR_PROCESS_FACTORY_ID_DEFAULT = "org.eclipse.cdt.dsf.gdb.GdbProcessFactory"; //$NON-NLS-1$
}

View file

@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2011 Ericsson and others.
* Copyright (c) 2011, 2012 Ericsson 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
@ -7,6 +7,8 @@
*
* Contributors:
* Ericsson - initial implementation
* Anton Gorenkov - Need to use a process factory (Bug 210366)
* Marc Khouzam (Ericsson) - Support for factory to create the gdb process (Bug 210366)
*******************************************************************************/
package org.eclipse.cdt.dsf.gdb;
@ -29,6 +31,29 @@ public interface IGdbDebugConstants {
*/
public static final String INFERIOR_GROUPID_ATTR = PREFIX + "inferiorGroupId"; //$NON-NLS-1$
/**
* Attribute key to be passed to DebugPlugin.newProcess to specify the type of process
* that should be created by our IProcessFactory.
* @since 4.1
*/
public static final String PROCESS_TYPE_CREATION_ATTR = PREFIX + "createProcessType"; //$NON-NLS-1$
/**
* Attribute value of PROCESS_TYPE_CREATION_ATTR to be passed to DebugPlugin.newProcess to
* require the creation of an InferiorRuntimeProcess instead of a RuntimeProcess
* (which is used by default).
* @since 4.1
*/
public static final String INFERIOR_PROCESS_CREATION_VALUE = PREFIX + "inferiorProcess"; //$NON-NLS-1$
/**
* Attribute value of PROCESS_TYPE_CREATION_ATTR to be passed to DebugPlugin.newProcess to
* require the creation of an GdbProcess instead of a RuntimeProcess
* (which is used by default).
* @since 4.1
*/
public static final String GDB_PROCESS_CREATION_VALUE = PREFIX + "gdbProcess"; //$NON-NLS-1$
}

View file

@ -8,9 +8,12 @@
* Contributors:
* Wind River Systems - initial API and implementation
* Marc Khouzam (Ericsson) - Fix NPE for partial launches (Bug 368597)
* Marc Khouzam (Ericsson) - Create the gdb process through the process factory (Bug 210366)
*******************************************************************************/
package org.eclipse.cdt.dsf.gdb.launching;
import java.util.HashMap;
import java.util.Map;
import java.util.concurrent.Callable;
import java.util.concurrent.ExecutionException;
import java.util.concurrent.RejectedExecutionException;
@ -33,6 +36,7 @@ import org.eclipse.cdt.dsf.debug.service.IMemory.IMemoryDMContext;
import org.eclipse.cdt.dsf.debug.service.IProcesses.IProcessDMContext;
import org.eclipse.cdt.dsf.debug.service.command.ICommandControlService;
import org.eclipse.cdt.dsf.debug.service.command.ICommandControlService.ICommandControlShutdownDMEvent;
import org.eclipse.cdt.dsf.gdb.IGdbDebugConstants;
import org.eclipse.cdt.dsf.gdb.internal.GdbPlugin;
import org.eclipse.cdt.dsf.gdb.internal.memory.GdbMemoryBlockRetrieval;
import org.eclipse.cdt.dsf.gdb.service.command.IGDBControl;
@ -173,8 +177,14 @@ public class GdbLaunch extends DsfLaunch
}
}).get();
GDBProcess gdbProcess = new GDBProcess(this, cliProc, label, null);
addProcess(gdbProcess);
// Need to go through DebugPlugin.newProcess so that we can use
// the overrideable process factory to allow others to override.
// First set attribute to specify we want to create the gdb process.
// Bug 210366
Map<String, String> attributes = new HashMap<String, String>();
attributes.put(IGdbDebugConstants.PROCESS_TYPE_CREATION_ATTR,
IGdbDebugConstants.GDB_PROCESS_CREATION_VALUE);
DebugPlugin.newProcess(this, cliProc, label, attributes);
} catch (InterruptedException e) {
throw new CoreException(new Status(IStatus.ERROR, GdbPlugin.PLUGIN_ID, 0, "Interrupted while waiting for get process callable.", e)); //$NON-NLS-1$
} catch (ExecutionException e) {

View file

@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2008, 2011 QNX Software Systems and others.
* Copyright (c) 2008, 2012 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
@ -12,6 +12,7 @@
* Ericsson - Added support for Mac OS
* Ericsson - Added support for post-mortem trace files
* Abeer Bagul (Tensilica) - Allow to better override GdbLaunch (bug 339550)
* Anton Gorenkov - Need to use a process factory (Bug 210366)
*******************************************************************************/
package org.eclipse.cdt.dsf.gdb.launching;
@ -44,6 +45,7 @@ import org.eclipse.core.runtime.NullProgressMonitor;
import org.eclipse.core.runtime.Status;
import org.eclipse.core.runtime.SubProgressMonitor;
import org.eclipse.debug.core.DebugException;
import org.eclipse.debug.core.DebugPlugin;
import org.eclipse.debug.core.ILaunch;
import org.eclipse.debug.core.ILaunchConfiguration;
import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
@ -274,6 +276,10 @@ public class GdbLaunchDelegate extends AbstractCLaunchDelegate2
@Override
public boolean preLaunchCheck(ILaunchConfiguration config, String mode, IProgressMonitor monitor) throws CoreException {
// Setup default GDB Process Factory
// Bug 210366
setDefaultProcessFactory(config);
// Forcibly turn off non-stop for post-mortem sessions.
// Non-stop does not apply to post-mortem sessions.
// Now that we can have non-stop defaulting to enabled, it will prevent
@ -293,6 +299,25 @@ public class GdbLaunchDelegate extends AbstractCLaunchDelegate2
return super.preLaunchCheck(config, mode, monitor);
}
/**
* Modify the ILaunchConfiguration to set the DebugPlugin.ATTR_PROCESS_FACTORY_ID attribute,
* so as to specify the process factory to use.
*
* This attribute should only be set if it is not part of the configuration already, to allow
* other code to set it to something else.
* @since 4.1
*/
protected void setDefaultProcessFactory(ILaunchConfiguration config) throws CoreException {
// Bug 210366
if (!config.hasAttribute(DebugPlugin.ATTR_PROCESS_FACTORY_ID)) {
ILaunchConfigurationWorkingCopy wc = config.getWorkingCopy();
wc.setAttribute(DebugPlugin.ATTR_PROCESS_FACTORY_ID,
IGDBLaunchConfigurationConstants.DEBUGGER_ATTR_PROCESS_FACTORY_ID_DEFAULT);
wc.doSave();
}
}
@Override
public ILaunch getLaunch(ILaunchConfiguration configuration, String mode) throws CoreException {
// Need to configure the source locator before creating the launch

View file

@ -0,0 +1,44 @@
/*******************************************************************************
* Copyright (c) 2011 Anton Gorenkov
* 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:
* Anton Gorenkov - initial API and implementation (Bug 210366)
* Marc Khouzam (Ericsson) - Add support to create the gdb process as well (Bug 210366)
*******************************************************************************/
package org.eclipse.cdt.dsf.gdb.launching;
import java.util.Map;
import org.eclipse.cdt.dsf.gdb.IGdbDebugConstants;
import org.eclipse.debug.core.ILaunch;
import org.eclipse.debug.core.IProcessFactory;
import org.eclipse.debug.core.model.IProcess;
import org.eclipse.debug.core.model.RuntimeProcess;
/**
* Default GDB Process Factory creation of launch processes
* using DebugPlugin.newProcess()
* @since 4.1
*/
public class GdbProcessFactory implements IProcessFactory {
@SuppressWarnings({ "rawtypes", "unchecked" })
@Override
public IProcess newProcess(ILaunch launch, Process process, String label, Map attributes) {
if (attributes != null) {
if (IGdbDebugConstants.GDB_PROCESS_CREATION_VALUE.equals(attributes.get(IGdbDebugConstants.PROCESS_TYPE_CREATION_ATTR))) {
return new GDBProcess(launch, process, label, attributes);
}
if (IGdbDebugConstants.INFERIOR_PROCESS_CREATION_VALUE.equals(attributes.get(IGdbDebugConstants.PROCESS_TYPE_CREATION_ATTR))) {
return new InferiorRuntimeProcess(launch, process, label, attributes);
}
}
return new RuntimeProcess(launch, process, label, attributes);
}
}

View file

@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2008, 2011 Ericsson and others.
* Copyright (c) 2008, 2012 Ericsson 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
@ -7,6 +7,7 @@
*
* Contributors:
* Ericsson - initial API and implementation
* Anton Gorenkov - Need to use a process factory (Bug 210366)
*******************************************************************************/
package org.eclipse.cdt.dsf.gdb.service;
@ -545,9 +546,16 @@ public class GDBProcesses extends MIProcesses implements IGDBProcesses {
}
// Add the inferior
InferiorRuntimeProcess runtimeInferior = new InferiorRuntimeProcess(launch, inferior, label, null);
// Need to go through DebugPlugin.newProcess so that we can use
// the overrideable process factory to allow others to override.
// First set attribute to specify we want to create an inferior process.
// Bug 210366
Map<String, String> attributes = new HashMap<String, String>();
attributes.put(IGdbDebugConstants.PROCESS_TYPE_CREATION_ATTR,
IGdbDebugConstants.INFERIOR_PROCESS_CREATION_VALUE);
IProcess runtimeInferior = DebugPlugin.newProcess(launch, inferior, label, attributes);
// Now set the inferior groupId
runtimeInferior.setAttribute(IGdbDebugConstants.INFERIOR_GROUPID_ATTR, MIProcesses.UNIQUE_GROUP_ID);
launch.addProcess(runtimeInferior);
rm.done();
}

View file

@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2011 Ericsson and others.
* Copyright (c) 2011, 2012 Ericsson 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
@ -8,6 +8,7 @@
* Contributors:
* Ericsson - initial API and implementation
* Sergey Prigogin (Google)
* Anton Gorenkov - Need to use a process factory (Bug 210366)
*******************************************************************************/
package org.eclipse.cdt.dsf.gdb.service;
@ -363,9 +364,16 @@ public class StartOrRestartProcessSequence_7_0 extends ReflectionSequence {
}
// Add the inferior
InferiorRuntimeProcess runtimeInferior = new InferiorRuntimeProcess(launch, inferior, label, null);
// Need to go through DebugPlugin.newProcess so that we can use
// the overrideable process factory to allow others to override.
// First set attribute to specify we want to create an inferior process.
// Bug 210366
Map<String, String> attributes = new HashMap<String, String>();
attributes.put(IGdbDebugConstants.PROCESS_TYPE_CREATION_ATTR,
IGdbDebugConstants.INFERIOR_PROCESS_CREATION_VALUE);
IProcess runtimeInferior = DebugPlugin.newProcess(launch, inferior, label, attributes);
// Now set the inferior groupId
runtimeInferior.setAttribute(IGdbDebugConstants.INFERIOR_GROUPID_ATTR, groupId);
launch.addProcess(runtimeInferior);
rm.done();
}

View file

@ -2,7 +2,7 @@
<feature
id="org.eclipse.cdt.gnu.dsf"
label="%featureName"
version="4.0.0.qualifier"
version="4.0.1.qualifier"
provider-name="%providerName">
<description>

View file

@ -12,7 +12,7 @@
</parent>
<groupId>org.eclipse.cdt.feature</groupId>
<version>4.0.0-SNAPSHOT</version>
<version>4.0.1-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.gnu.dsf</artifactId>
<packaging>eclipse-feature</packaging>
</project>

View file

@ -2,7 +2,7 @@
<feature
id="org.eclipse.cdt.gnu.dsf.source"
label="%featureName"
version="4.0.0.qualifier"
version="4.0.1.qualifier"
provider-name="%providerName">
<description>

View file

@ -12,7 +12,7 @@
</parent>
<groupId>org.eclipse.cdt.features</groupId>
<version>4.0.0-SNAPSHOT</version>
<version>4.0.1-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.gnu.dsf.source</artifactId>
<packaging>eclipse-feature</packaging>
</project>

View file

@ -2,7 +2,7 @@
<feature
id="org.eclipse.cdt.debug.ui.memory"
label="%featureName"
version="2.1.100.qualifier"
version="2.2.0.qualifier"
provider-name="%providerName">
<description>

View file

@ -12,7 +12,7 @@
</parent>
<groupId>org.eclipse.cdt.features</groupId>
<version>2.1.100-SNAPSHOT</version>
<version>2.2.0-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.debug.ui.memory</artifactId>
<packaging>eclipse-feature</packaging>
</project>

View file

@ -2,7 +2,7 @@
<feature
id="org.eclipse.cdt.debug.ui.memory.source"
label="%featureName"
version="2.1.100.qualifier"
version="2.2.0.qualifier"
provider-name="%providerName">
<description>

View file

@ -11,7 +11,7 @@
<relativePath>../../pom.xml</relativePath>
</parent>
<version>2.1.100-SNAPSHOT</version>
<version>2.2.0-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.debug.ui.memory.source</artifactId>
<packaging>eclipse-feature</packaging>
</project>

View file

@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.cdt.debug.ui.memory.traditional;singleton:=true
Bundle-Version: 1.2.0.qualifier
Bundle-Version: 1.2.1.qualifier
Bundle-Localization: plugin
Require-Bundle: org.eclipse.debug.core,
org.eclipse.debug.ui,

View file

@ -11,7 +11,7 @@
<relativePath>../../pom.xml</relativePath>
</parent>
<version>1.2.0-SNAPSHOT</version>
<version>1.2.1-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.debug.ui.memory.traditional</artifactId>
<packaging>eclipse-plugin</packaging>
</project>

View file

@ -16,7 +16,7 @@
<properties>
<tycho-version>0.13.0</tycho-version>
<platform-version>4.2milestones</platform-version>
<platform-version>3.8milestones</platform-version>
<platform-site>http://download.eclipse.org/eclipse/updates/${platform-version}</platform-site>
<orbit-version>R20110523182458</orbit-version>
<orbit-site>http://download.eclipse.org/tools/orbit/downloads/drops/${orbit-version}/repository</orbit-site>

View file

@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.cdt.managedbuilder.xlc.core;singleton:=true
Bundle-Version: 5.0.0.qualifier
Bundle-Version: 5.0.1.qualifier
Bundle-Vendor: %providerName
Bundle-Localization: plugin
Require-Bundle: org.eclipse.cdt.managedbuilder.core,

View file

@ -11,7 +11,7 @@
<relativePath>../../pom.xml</relativePath>
</parent>
<version>5.0.0-SNAPSHOT</version>
<version>5.0.1-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.managedbuilder.xlc.core</artifactId>
<packaging>eclipse-plugin</packaging>
</project>

View file

@ -2,7 +2,7 @@
<feature
id="org.eclipse.cdt.xlc.feature"
label="%featureName"
version="6.3.0.qualifier"
version="6.3.1.qualifier"
provider-name="%providerName"
plugin="org.eclipse.cdt.managedbuilder.xlc.core"
image="eclipse_update_120.jpg">

View file

@ -11,7 +11,7 @@
<relativePath>../../pom.xml</relativePath>
</parent>
<version>6.3.0-SNAPSHOT</version>
<version>6.3.1-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.xlc.feature</artifactId>
<packaging>eclipse-feature</packaging>
</project>

View file

@ -2,7 +2,7 @@
<feature
id="org.eclipse.cdt.xlc.sdk"
label="%featureName"
version="6.1.0.qualifier"
version="6.1.1.qualifier"
provider-name="%providerName"
image="eclipse_update_120.jpg">

View file

@ -12,7 +12,7 @@
</parent>
<groupId>org.eclipse.cdt.features</groupId>
<version>6.1.0-SNAPSHOT</version>
<version>6.1.1-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.xlc.sdk</artifactId>
<packaging>eclipse-feature</packaging>
</project>

View file

@ -2,7 +2,7 @@
<feature
id="org.eclipse.cdt.xlc.source"
label="%featureName"
version="6.1.0.qualifier"
version="6.1.1.qualifier"
provider-name="%providerName">
<description>

View file

@ -12,7 +12,7 @@
</parent>
<groupId>org.eclipse.cdt.features</groupId>
<version>6.1.0-SNAPSHOT</version>
<version>6.1.1-SNAPSHOT</version>
<artifactId>org.eclipse.cdt.xlc.source</artifactId>
<packaging>eclipse-feature</packaging>
</project>