mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-06-05 08:46:02 +02:00
LLDB: Add support for local debugging of new processes
This commit adds support for debugging new processes launched locally using the LLDB debugger (lldb-mi). The minimum version supported is LLDB 3.8. Preliminary documentation on how to set it up is available here: https://github.com/MarkZ3/Eclipse-CDT-WIP/issues/9#issuecomment-236483223 Bug: 405670 Change-Id: If46543e974e2f19c45ab3bba088eab35fe737077 Signed-off-by: Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
This commit is contained in:
parent
461639d4ee
commit
5e32334aa0
41 changed files with 1683 additions and 1 deletions
7
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/.classpath
Normal file
7
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/.classpath
Normal file
|
@ -0,0 +1,7 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="src" path="src"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
1
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/.gitignore
vendored
Normal file
1
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/.gitignore
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
/bin/
|
34
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/.project
Normal file
34
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/.project
Normal file
|
@ -0,0 +1,34 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>org.eclipse.cdt.llvm.dsf.lldb.core</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.jdt.core.javabuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.pde.ManifestBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.pde.SchemaBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.pde.PluginNature</nature>
|
||||
<nature>org.eclipse.jdt.core.javanature</nature>
|
||||
<nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
|
||||
</natures>
|
||||
</projectDescription>
|
|
@ -0,0 +1,125 @@
|
|||
eclipse.preferences.version=1
|
||||
org.eclipse.jdt.core.codeComplete.argumentPrefixes=
|
||||
org.eclipse.jdt.core.codeComplete.argumentSuffixes=
|
||||
org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
|
||||
org.eclipse.jdt.core.codeComplete.fieldSuffixes=
|
||||
org.eclipse.jdt.core.codeComplete.localPrefixes=
|
||||
org.eclipse.jdt.core.codeComplete.localSuffixes=
|
||||
org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=s
|
||||
org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
|
||||
org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
|
||||
org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
|
||||
org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=disabled
|
||||
org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
|
||||
org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
|
||||
org.eclipse.jdt.core.compiler.annotation.nonnull.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
|
||||
org.eclipse.jdt.core.compiler.annotation.nonnullbydefault.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
|
||||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.doc.comment.support=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
|
||||
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
|
||||
org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning
|
||||
org.eclipse.jdt.core.compiler.problem.deadCode=warning
|
||||
org.eclipse.jdt.core.compiler.problem.deprecation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
|
||||
org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
|
||||
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning
|
||||
org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning
|
||||
org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
|
||||
org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning
|
||||
org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning
|
||||
org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=warning
|
||||
org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingDefaultCase=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=return_tag
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning
|
||||
org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nonnullTypeVariableFromLegacyInvocation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error
|
||||
org.eclipse.jdt.core.compiler.problem.nullReference=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
|
||||
org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
|
||||
org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
|
||||
org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning
|
||||
org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=warning
|
||||
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
|
||||
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unclosedCloseable=warning
|
||||
org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedImport=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedLocal=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
|
@ -0,0 +1,64 @@
|
|||
cleanup_settings_version=2
|
||||
eclipse.preferences.version=1
|
||||
editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
|
||||
org.eclipse.jdt.ui.exception.name=e
|
||||
org.eclipse.jdt.ui.gettersetter.use.is=true
|
||||
org.eclipse.jdt.ui.keywordthis=false
|
||||
org.eclipse.jdt.ui.overrideannotation=true
|
||||
sp_cleanup.add_default_serial_version_id=true
|
||||
sp_cleanup.add_generated_serial_version_id=false
|
||||
sp_cleanup.add_missing_annotations=false
|
||||
sp_cleanup.add_missing_deprecated_annotations=true
|
||||
sp_cleanup.add_missing_methods=false
|
||||
sp_cleanup.add_missing_nls_tags=false
|
||||
sp_cleanup.add_missing_override_annotations=true
|
||||
sp_cleanup.add_missing_override_annotations_interface_methods=true
|
||||
sp_cleanup.add_serial_version_id=false
|
||||
sp_cleanup.always_use_blocks=true
|
||||
sp_cleanup.always_use_parentheses_in_expressions=false
|
||||
sp_cleanup.always_use_this_for_non_static_field_access=false
|
||||
sp_cleanup.always_use_this_for_non_static_method_access=false
|
||||
sp_cleanup.convert_functional_interfaces=false
|
||||
sp_cleanup.convert_to_enhanced_for_loop=false
|
||||
sp_cleanup.correct_indentation=false
|
||||
sp_cleanup.format_source_code=false
|
||||
sp_cleanup.format_source_code_changes_only=false
|
||||
sp_cleanup.insert_inferred_type_arguments=false
|
||||
sp_cleanup.make_local_variable_final=true
|
||||
sp_cleanup.make_parameters_final=false
|
||||
sp_cleanup.make_private_fields_final=true
|
||||
sp_cleanup.make_type_abstract_if_missing_method=false
|
||||
sp_cleanup.make_variable_declarations_final=false
|
||||
sp_cleanup.never_use_blocks=false
|
||||
sp_cleanup.never_use_parentheses_in_expressions=true
|
||||
sp_cleanup.on_save_use_additional_actions=true
|
||||
sp_cleanup.organize_imports=false
|
||||
sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
|
||||
sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
|
||||
sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
|
||||
sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
|
||||
sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
|
||||
sp_cleanup.remove_private_constructors=true
|
||||
sp_cleanup.remove_redundant_type_arguments=false
|
||||
sp_cleanup.remove_trailing_whitespaces=true
|
||||
sp_cleanup.remove_trailing_whitespaces_all=true
|
||||
sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
|
||||
sp_cleanup.remove_unnecessary_casts=false
|
||||
sp_cleanup.remove_unnecessary_nls_tags=false
|
||||
sp_cleanup.remove_unused_imports=false
|
||||
sp_cleanup.remove_unused_local_variables=false
|
||||
sp_cleanup.remove_unused_private_fields=true
|
||||
sp_cleanup.remove_unused_private_members=false
|
||||
sp_cleanup.remove_unused_private_methods=true
|
||||
sp_cleanup.remove_unused_private_types=true
|
||||
sp_cleanup.sort_members=false
|
||||
sp_cleanup.sort_members_all=false
|
||||
sp_cleanup.use_anonymous_class_creation=false
|
||||
sp_cleanup.use_blocks=true
|
||||
sp_cleanup.use_blocks_only_for_return_and_throw=false
|
||||
sp_cleanup.use_lambda=true
|
||||
sp_cleanup.use_parentheses_in_expressions=false
|
||||
sp_cleanup.use_this_for_non_static_field_access=false
|
||||
sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
|
||||
sp_cleanup.use_this_for_non_static_method_access=false
|
||||
sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
|
22
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/META-INF/MANIFEST.MF
Normal file
22
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/META-INF/MANIFEST.MF
Normal file
|
@ -0,0 +1,22 @@
|
|||
Manifest-Version: 1.0
|
||||
Bundle-ManifestVersion: 2
|
||||
Bundle-Name: %pluginName
|
||||
Bundle-Vendor: %providerName
|
||||
Bundle-SymbolicName: org.eclipse.cdt.llvm.dsf.lldb.core;singleton:=true
|
||||
Bundle-Version: 1.0.0.qualifier
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
Bundle-Localization: plugin
|
||||
Require-Bundle: org.eclipse.debug.core,
|
||||
org.eclipse.cdt.dsf.gdb,
|
||||
org.eclipse.cdt.launch,
|
||||
org.eclipse.core.runtime,
|
||||
org.eclipse.cdt.dsf,
|
||||
org.eclipse.cdt.debug.core,
|
||||
org.eclipse.core.variables,
|
||||
org.eclipse.cdt.core
|
||||
Export-Package: org.eclipse.cdt.llvm.dsf.lldb.core,
|
||||
org.eclipse.cdt.llvm.dsf.lldb.core.internal;x-friends:="org.eclipse.cdt.llvm.dsf.lldb.ui",
|
||||
org.eclipse.cdt.llvm.dsf.lldb.core.internal.launching;x-internal:=true,
|
||||
org.eclipse.cdt.llvm.dsf.lldb.core.internal.service;x-internal:=true
|
||||
Bundle-Activator: org.eclipse.cdt.llvm.dsf.lldb.core.internal.LLDBCorePlugin
|
||||
Bundle-ActivationPolicy: lazy
|
24
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/about.html
Normal file
24
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/about.html
Normal file
|
@ -0,0 +1,24 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"><head>
|
||||
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>About</title></head><body lang="EN-US">
|
||||
<h2>About This Content</h2>
|
||||
|
||||
<p>June 5, 2007</p>
|
||||
<h3>License</h3>
|
||||
|
||||
<p>The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise
|
||||
indicated below, the Content is provided to you under the terms and conditions of the
|
||||
Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available
|
||||
at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
|
||||
For purposes of the EPL, "Program" will mean the Content.</p>
|
||||
|
||||
<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is
|
||||
being redistributed by another party ("Redistributor") and different terms and conditions may
|
||||
apply to your use of any object code in the Content. Check the Redistributor's license that was
|
||||
provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
|
||||
indicated below, the terms and conditions of the EPL still apply to any source code in the Content
|
||||
and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
|
||||
|
||||
</body></html>
|
8
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/build.properties
Normal file
8
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/build.properties
Normal file
|
@ -0,0 +1,8 @@
|
|||
source.. = src/
|
||||
output.. = bin/
|
||||
bin.includes = META-INF/,\
|
||||
.,\
|
||||
plugin.xml,\
|
||||
about.html,\
|
||||
plugin.properties
|
||||
src.includes = about.html
|
12
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/plugin.properties
Normal file
12
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/plugin.properties
Normal file
|
@ -0,0 +1,12 @@
|
|||
###############################################################################
|
||||
# Copyright (c) 2016 Ericsson
|
||||
# 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
|
||||
###############################################################################
|
||||
pluginName=LLDB Debugger Integration Core
|
||||
providerName=Eclipse CDT
|
||||
|
||||
launchDelegate.localApplication.name=LLDB-MI Debug Process
|
||||
launchDelegate.localApplication.description=Start new application under control of LLBM-MI debugger
|
23
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/plugin.xml
Normal file
23
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/plugin.xml
Normal file
|
@ -0,0 +1,23 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?eclipse version="3.4"?>
|
||||
<plugin>
|
||||
<extension
|
||||
point="org.eclipse.debug.core.launchDelegates">
|
||||
<launchDelegate
|
||||
delegate="org.eclipse.cdt.llvm.dsf.lldb.core.internal.launching.LLDBLaunchDelegate"
|
||||
delegateDescription="%launchDelegate.localApplication.description"
|
||||
id="org.eclipse.cdt.llvm.dsf.lldb.launch.localCLaunch"
|
||||
modes="debug"
|
||||
name="%launchDelegate.localApplication.name"
|
||||
sourceLocatorId="org.eclipse.cdt.debug.core.sourceLocator"
|
||||
sourcePathComputerId="org.eclipse.cdt.debug.core.sourcePathComputer"
|
||||
type="org.eclipse.cdt.launch.applicationLaunchType">
|
||||
</launchDelegate>
|
||||
</extension>
|
||||
<extension
|
||||
point="org.eclipse.core.runtime.preferences">
|
||||
<initializer
|
||||
class="org.eclipse.cdt.llvm.dsf.lldb.core.internal.LLDBPreferenceInitializer">
|
||||
</initializer>
|
||||
</extension>
|
||||
</plugin>
|
17
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/pom.xml
Normal file
17
llvm/org.eclipse.cdt.llvm.dsf.lldb.core/pom.xml
Normal file
|
@ -0,0 +1,17 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
|
||||
xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<parent>
|
||||
<groupId>org.eclipse.cdt</groupId>
|
||||
<artifactId>cdt-parent</artifactId>
|
||||
<version>9.0.0-SNAPSHOT</version>
|
||||
<relativePath>../../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
<version>1.0.0-SNAPSHOT</version>
|
||||
<artifactId>org.eclipse.cdt.llvm.dsf.lldb.core</artifactId>
|
||||
<packaging>eclipse-plugin</packaging>
|
||||
</project>
|
|
@ -0,0 +1,32 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.core;
|
||||
|
||||
/**
|
||||
* Preference constants that affect behavior in the core LLDB plugin.
|
||||
*
|
||||
* @noimplement This interface is not intended to be implemented by clients.
|
||||
*/
|
||||
public interface ILLDBDebugPreferenceConstants {
|
||||
|
||||
/**
|
||||
* The default command for lldb-mi
|
||||
*/
|
||||
public static final String PREF_DEFAULT_LLDB_COMMAND = "defaultLLDBCommand"; //$NON-NLS-1$
|
||||
|
||||
/**
|
||||
* The value is a boolean specifying the default for whether to stop at main().
|
||||
*/
|
||||
public static final String PREF_DEFAULT_STOP_AT_MAIN = "defaultStopAtMain"; //$NON-NLS-1$
|
||||
|
||||
/**
|
||||
* The value is a string specifying the default symbol to use for the main breakpoint.
|
||||
*/
|
||||
public static final String PREF_DEFAULT_STOP_AT_MAIN_SYMBOL = "defaultStopAtMainSymbol"; //$NON-NLS-1$
|
||||
}
|
||||
|
|
@ -0,0 +1,31 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.core;
|
||||
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.internal.LLDBCorePlugin;
|
||||
|
||||
/**
|
||||
* Preference constants that are used in some ways by the LLDB launch
|
||||
* configuration.
|
||||
*
|
||||
* @noimplement This interface is not intended to be implemented by clients.
|
||||
*/
|
||||
public class ILLDBLaunchConfigurationConstants {
|
||||
|
||||
/**
|
||||
* Launch configuration attribute key. The value is the name of
|
||||
* the Debuger associated with a C/C++ launch configuration.
|
||||
*/
|
||||
public static final String ATTR_DEBUG_NAME = LLDBCorePlugin.PLUGIN_ID + ".DEBUG_NAME"; //$NON-NLS-1$
|
||||
|
||||
/**
|
||||
* Launch configuration attribute value. The key is ATTR_DEBUG_NAME.
|
||||
*/
|
||||
public static final String DEBUGGER_DEBUG_NAME_DEFAULT = "lldb-mi"; //$NON-NLS-1$
|
||||
}
|
|
@ -0,0 +1,50 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2006, 2014 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
|
||||
* Abeer Bagul (Tensilica) - Updated error message (Bug 339048)
|
||||
* Jason Litton (Sage Electronic Engineering, LLC) - Added support for dynamic tracing option (Bug 379169)
|
||||
* Alvaro Sanchez-Leon (Ericsson AB) - Each memory context needs a different MemoryRetrieval (Bug 250323)
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.core.internal;
|
||||
|
||||
import org.eclipse.core.runtime.Plugin;
|
||||
import org.osgi.framework.BundleContext;
|
||||
|
||||
/**
|
||||
* The activator class controls the plug-in life cycle
|
||||
*/
|
||||
public class LLDBCorePlugin extends Plugin {
|
||||
|
||||
/**
|
||||
* LLDB Core Plug-in ID
|
||||
*/
|
||||
public static final String PLUGIN_ID = "org.eclipse.cdt.llvm.dsf.lldb.core"; //$NON-NLS-1$
|
||||
private static LLDBCorePlugin plugin;
|
||||
|
||||
@Override
|
||||
public void start(BundleContext context) throws Exception {
|
||||
super.start(context);
|
||||
plugin = this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void stop(BundleContext context) throws Exception {
|
||||
plugin = null;
|
||||
super.stop(context);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the shared instance
|
||||
*
|
||||
* @return the shared instance
|
||||
*/
|
||||
public static LLDBCorePlugin getDefault() {
|
||||
return plugin;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,43 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.core.internal;
|
||||
|
||||
import java.io.File;
|
||||
|
||||
import org.eclipse.cdt.debug.core.ICDTLaunchConfigurationConstants;
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.ILLDBDebugPreferenceConstants;
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.ILLDBLaunchConfigurationConstants;
|
||||
import org.eclipse.core.runtime.Platform;
|
||||
import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;
|
||||
import org.eclipse.core.runtime.preferences.DefaultScope;
|
||||
import org.eclipse.core.runtime.preferences.IEclipsePreferences;
|
||||
|
||||
/**
|
||||
* Initializes default values for LLDB preferences.
|
||||
*/
|
||||
public class LLDBPreferenceInitializer extends AbstractPreferenceInitializer {
|
||||
|
||||
private static final String XCODE_BUNDLED_LLDB_PATH = "/Applications/Xcode.app/Contents/Developer/usr/bin/lldb-mi"; //$NON-NLS-1$
|
||||
|
||||
private static String getDefaultCommand() {
|
||||
if (Platform.getOS().equals(Platform.OS_MACOSX) && new File(XCODE_BUNDLED_LLDB_PATH).exists()) {
|
||||
return XCODE_BUNDLED_LLDB_PATH;
|
||||
}
|
||||
return ILLDBLaunchConfigurationConstants.DEBUGGER_DEBUG_NAME_DEFAULT;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void initializeDefaultPreferences() {
|
||||
IEclipsePreferences node = DefaultScope.INSTANCE.getNode(LLDBCorePlugin.PLUGIN_ID);
|
||||
node.put(ILLDBDebugPreferenceConstants.PREF_DEFAULT_LLDB_COMMAND, getDefaultCommand());
|
||||
node.putBoolean(ILLDBDebugPreferenceConstants.PREF_DEFAULT_STOP_AT_MAIN, ICDTLaunchConfigurationConstants.DEBUGGER_STOP_AT_MAIN_DEFAULT);
|
||||
node.put(ILLDBDebugPreferenceConstants.PREF_DEFAULT_STOP_AT_MAIN_SYMBOL, ICDTLaunchConfigurationConstants.DEBUGGER_STOP_AT_MAIN_SYMBOL_DEFAULT);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,47 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.core.internal.launching;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import org.eclipse.cdt.dsf.concurrent.RequestMonitor;
|
||||
import org.eclipse.cdt.dsf.concurrent.RequestMonitorWithProgress;
|
||||
import org.eclipse.cdt.dsf.gdb.launching.FinalLaunchSequence_7_2;
|
||||
import org.eclipse.cdt.dsf.service.DsfSession;
|
||||
|
||||
/**
|
||||
* A LLDB-specific launch sequence that was initially created to work around the
|
||||
* fact that LLDB always has to run in async mode, even in all-stop.
|
||||
*/
|
||||
public class LLDBFinalLaunchSequence extends FinalLaunchSequence_7_2 {
|
||||
|
||||
/**
|
||||
* Constructs the {@link LLDBFinalLaunchSequence}.
|
||||
*
|
||||
* @param session
|
||||
* The debugging session
|
||||
* @param attributes
|
||||
* the launch configuration attributes
|
||||
* @param rm
|
||||
* a request monitor that will indicate when the sequence is
|
||||
* completed
|
||||
*/
|
||||
public LLDBFinalLaunchSequence(DsfSession session, Map<String, Object> attributes, RequestMonitorWithProgress rm) {
|
||||
super(session, attributes, rm);
|
||||
}
|
||||
|
||||
@Execute
|
||||
@Override
|
||||
public void stepSetNonStop(RequestMonitor requestMonitor) {
|
||||
// LLDB doesn't support non-stop and target-async cannot be disabled so
|
||||
// do not do anything in this step
|
||||
requestMonitor.done();
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,109 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.core.internal.launching;
|
||||
|
||||
import org.eclipse.cdt.dsf.gdb.launching.GdbLaunch;
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.ILLDBDebugPreferenceConstants;
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.ILLDBLaunchConfigurationConstants;
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.internal.LLDBCorePlugin;
|
||||
import org.eclipse.core.runtime.CoreException;
|
||||
import org.eclipse.core.runtime.IPath;
|
||||
import org.eclipse.core.runtime.Path;
|
||||
import org.eclipse.core.runtime.Platform;
|
||||
import org.eclipse.core.variables.VariablesPlugin;
|
||||
import org.eclipse.debug.core.ILaunchConfiguration;
|
||||
import org.eclipse.debug.core.model.ISourceLocator;
|
||||
|
||||
/**
|
||||
* LLDB specific launch. It mostly deals with setting up the paths correctly.
|
||||
*/
|
||||
public class LLDBLaunch extends GdbLaunch {
|
||||
|
||||
/**
|
||||
* Constructs a launch.
|
||||
*
|
||||
* @param launchConfiguration
|
||||
* the launch configuration
|
||||
* @param mode
|
||||
* the launch mode, i.e., debug, profile, etc.
|
||||
* @param locator
|
||||
*/
|
||||
public LLDBLaunch(ILaunchConfiguration launchConfiguration, String mode, ISourceLocator locator) {
|
||||
super(launchConfiguration, mode, locator);
|
||||
}
|
||||
|
||||
/*
|
||||
* TODO: GdbLaunch.getGDBPath() and setGDBPath() should reference each other
|
||||
* in the javadoc to make sure extenders override both.
|
||||
*/
|
||||
public IPath getGDBPath() {
|
||||
String lldbPath = getAttribute(ILLDBLaunchConfigurationConstants.ATTR_DEBUG_NAME);
|
||||
if (lldbPath != null) {
|
||||
return new Path(lldbPath);
|
||||
}
|
||||
|
||||
return getLLDBPath(getLaunchConfiguration());
|
||||
}
|
||||
|
||||
public void setGDBPath(String path) {
|
||||
setAttribute(ILLDBLaunchConfigurationConstants.ATTR_DEBUG_NAME, path);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the LLDB path based on a launch configuration.
|
||||
*
|
||||
* @param configuration
|
||||
* the launch configuration.
|
||||
* @return the LLDB path
|
||||
*/
|
||||
public static IPath getLLDBPath(ILaunchConfiguration configuration) {
|
||||
String defaultLLdbCommand = getDefaultLLDBPath();
|
||||
|
||||
IPath retVal = new Path(defaultLLdbCommand);
|
||||
try {
|
||||
String lldbPath = configuration.getAttribute(ILLDBLaunchConfigurationConstants.ATTR_DEBUG_NAME, defaultLLdbCommand);
|
||||
lldbPath = VariablesPlugin.getDefault().getStringVariableManager().performStringSubstitution(lldbPath, false);
|
||||
retVal = new Path(lldbPath);
|
||||
} catch (CoreException e) {
|
||||
LLDBCorePlugin.getDefault().getLog().log(e.getStatus());
|
||||
}
|
||||
return retVal;
|
||||
}
|
||||
|
||||
protected String getDefaultGDBPath() {
|
||||
return getDefaultLLDBPath();
|
||||
}
|
||||
|
||||
private static String getDefaultLLDBPath() {
|
||||
return Platform.getPreferencesService().getString(LLDBCorePlugin.PLUGIN_ID,
|
||||
ILLDBDebugPreferenceConstants.PREF_DEFAULT_LLDB_COMMAND,
|
||||
ILLDBLaunchConfigurationConstants.DEBUGGER_DEBUG_NAME_DEFAULT, null);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getGDBInitFile() throws CoreException {
|
||||
// Not supported by LLDB-MI right now. There is also no MI command in
|
||||
// GDB to source a file. We should look into adding this in GDB first.
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getProgramPath() throws CoreException {
|
||||
IPath path = new Path(super.getProgramPath());
|
||||
|
||||
// FIXME: LLDB-MI only accepts absolute paths for the program. But this
|
||||
// seems to work with the latest version in SVN trunk (Mac) so we will
|
||||
// need to find out in which version this was or will be fixed and stop
|
||||
// doing this work-around if possible.
|
||||
if (!path.isAbsolute()) {
|
||||
path = getGDBWorkingDirectory().append(path);
|
||||
}
|
||||
return path.toOSString();
|
||||
}
|
||||
}
|
|
@ -0,0 +1,63 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.core.internal.launching;
|
||||
|
||||
import org.eclipse.cdt.dsf.debug.service.IDsfDebugServicesFactory;
|
||||
import org.eclipse.cdt.dsf.gdb.launching.GdbLaunch;
|
||||
import org.eclipse.cdt.dsf.gdb.launching.GdbLaunchDelegate;
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.internal.service.LLDBServiceFactory;
|
||||
import org.eclipse.core.runtime.CoreException;
|
||||
import org.eclipse.debug.core.ILaunchConfiguration;
|
||||
import org.eclipse.debug.core.model.ISourceLocator;
|
||||
|
||||
/**
|
||||
* A specific LLDB launch delegate that allows customization such as setting the
|
||||
* LLDB path, using LLDB-specific preferences and creating a service factory
|
||||
* (mostly used to work around the current LLDB-MI limitations)
|
||||
*/
|
||||
public class LLDBLaunchDelegate extends GdbLaunchDelegate {
|
||||
|
||||
/**
|
||||
* Constructs the {@link LLDBLaunchDelegate}.
|
||||
*
|
||||
* This is meant to be called by the plug-in registry (plugin.xml)
|
||||
*/
|
||||
public LLDBLaunchDelegate() {
|
||||
super();
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs the {@link LLDBLaunchDelegate}.
|
||||
*
|
||||
* @param requireCProject whether or not debugging requires a C/C++ project. For example, in attach mode is is not required.
|
||||
*/
|
||||
public LLDBLaunchDelegate(boolean requireCProject) {
|
||||
super(requireCProject);
|
||||
}
|
||||
|
||||
/*
|
||||
* TODO: The fact that both getCLILabel and GdbLaunch.getGDBPath have to be
|
||||
* overridden and made consistent seems error prone. getCLILabel should call
|
||||
* GdbLaunch.getGDBPath somehow by default. This is something that should be
|
||||
* looked into in dsf-gdb.
|
||||
*/
|
||||
@Override
|
||||
protected String getCLILabel(ILaunchConfiguration config, String gdbVersion) throws CoreException {
|
||||
return LLDBLaunch.getLLDBPath(config).toString().trim() + " (" + Messages.LLDBLaunchDelegate_mimicking_gdb + " gdb " + gdbVersion + ")"; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
|
||||
}
|
||||
|
||||
@Override
|
||||
protected IDsfDebugServicesFactory newServiceFactory(ILaunchConfiguration config, String version) {
|
||||
return new LLDBServiceFactory(version, config);
|
||||
}
|
||||
|
||||
protected GdbLaunch createGdbLaunch(ILaunchConfiguration configuration, String mode, ISourceLocator locator) throws CoreException {
|
||||
return new LLDBLaunch(configuration, mode, locator);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,27 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.core.internal.launching;
|
||||
|
||||
import org.eclipse.osgi.util.NLS;
|
||||
|
||||
/**
|
||||
* Messages related to launching LLDB.
|
||||
*/
|
||||
@SuppressWarnings("javadoc")
|
||||
public class Messages extends NLS {
|
||||
private static final String BUNDLE_NAME = "org.eclipse.cdt.llvm.dsf.lldb.core.internal.launching.messages"; //$NON-NLS-1$
|
||||
public static String LLDBLaunchDelegate_mimicking_gdb;
|
||||
static {
|
||||
// initialize resource bundle
|
||||
NLS.initializeMessages(BUNDLE_NAME, Messages.class);
|
||||
}
|
||||
|
||||
private Messages() {
|
||||
}
|
||||
}
|
|
@ -0,0 +1,9 @@
|
|||
###############################################################################
|
||||
# Copyright (c) 2016 Ericsson.
|
||||
# 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
|
||||
###############################################################################
|
||||
|
||||
LLDBLaunchDelegate_mimicking_gdb=mimicking
|
|
@ -0,0 +1,59 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.core.internal.service;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import org.eclipse.cdt.dsf.debug.service.IBreakpoints;
|
||||
import org.eclipse.cdt.dsf.gdb.service.GDBBreakpoints_7_4;
|
||||
import org.eclipse.cdt.dsf.service.DsfSession;
|
||||
import org.eclipse.core.runtime.Path;
|
||||
|
||||
/**
|
||||
* Provides service for breakpoint operations. See {@link IBreakpoints}
|
||||
*
|
||||
* This LLDB specific implementation was initially created in order to work
|
||||
* around a bug with absolute paths when specifying the breakpoint location.
|
||||
*/
|
||||
public class LLDBBreakpoints extends GDBBreakpoints_7_4 {
|
||||
|
||||
/**
|
||||
* Constructs the {@link LLDBBreakpoints} service.
|
||||
*
|
||||
* @param session
|
||||
* The debugging session
|
||||
*/
|
||||
public LLDBBreakpoints(DsfSession session) {
|
||||
super(session);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String formatLocation(Map<String, Object> attributes) {
|
||||
// FIXME: ***Big hack*** lldb-mi's -breakpoint-insert doesn't handle
|
||||
// locations that look like absolute paths (leading /). This will have
|
||||
// to be fixed upstream because the work-around is not ideal: we only
|
||||
// use the last segment to insert the breakpoint. This is not good if
|
||||
// there are two files of the same name in the inferior.
|
||||
// See https://llvm.org/bugs/show_bug.cgi?id=28709
|
||||
String location = super.formatLocation(attributes);
|
||||
return adjustDebuggerPath(location);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String adjustDebuggerPath(String originalPath) {
|
||||
// FIXME: See also #formatLocation for hack explanation. This one needs
|
||||
// to be overridden for moveToLine, runToLine and stepIntoSelection
|
||||
// (Once this hack is removed, they should be tested).
|
||||
Path path = new Path(originalPath);
|
||||
if (path.isAbsolute()) {
|
||||
return path.lastSegment();
|
||||
}
|
||||
return super.adjustDebuggerPath(originalPath);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,48 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.core.internal.service;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
import org.eclipse.cdt.dsf.concurrent.RequestMonitorWithProgress;
|
||||
import org.eclipse.cdt.dsf.concurrent.Sequence;
|
||||
import org.eclipse.cdt.dsf.debug.service.command.ICommandControl;
|
||||
import org.eclipse.cdt.dsf.gdb.service.command.GDBControl_7_4;
|
||||
import org.eclipse.cdt.dsf.mi.service.command.CommandFactory;
|
||||
import org.eclipse.cdt.dsf.service.DsfSession;
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.internal.launching.LLDBFinalLaunchSequence;
|
||||
import org.eclipse.debug.core.ILaunchConfiguration;
|
||||
|
||||
/**
|
||||
* Provides service for controlling sending and receiving commands. See
|
||||
* {@link ICommandControl}
|
||||
*
|
||||
* This LLDB specific implementation was initially created in order to be able
|
||||
* to control the launch sequence of LLDB.
|
||||
*/
|
||||
public class LLDBControl extends GDBControl_7_4 {
|
||||
|
||||
/**
|
||||
* Constructs the {@link LLDBControl} service.
|
||||
*
|
||||
* @param session
|
||||
* The debugging session
|
||||
* @param config
|
||||
* the launch configuration
|
||||
* @param factory
|
||||
* the command factory used to send commands
|
||||
*/
|
||||
public LLDBControl(DsfSession session, ILaunchConfiguration config, CommandFactory factory) {
|
||||
super(session, config, factory);
|
||||
}
|
||||
|
||||
protected Sequence getCompleteInitializationSequence(Map<String,Object> attributes, RequestMonitorWithProgress rm) {
|
||||
return new LLDBFinalLaunchSequence(getSession(), attributes, rm);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,51 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.core.internal.service;
|
||||
|
||||
import org.eclipse.cdt.core.IAddress;
|
||||
import org.eclipse.cdt.dsf.concurrent.DataRequestMonitor;
|
||||
import org.eclipse.cdt.dsf.debug.service.IRunControl;
|
||||
import org.eclipse.cdt.dsf.gdb.service.GDBRunControl_7_0;
|
||||
import org.eclipse.cdt.dsf.service.DsfSession;
|
||||
|
||||
/**
|
||||
* Provides service for controlling the process. See {@link IRunControl}
|
||||
*
|
||||
* This LLDB specific implementation was initially created in order to disable
|
||||
* "move to line" and "resume at line" because the -exec-jump MI command was not
|
||||
* implemented.
|
||||
*/
|
||||
public class LLDBRunControl extends GDBRunControl_7_0 {
|
||||
|
||||
/**
|
||||
* Constructs the {@link LLDBRunControl} service.
|
||||
*
|
||||
* @param session
|
||||
* The debugging session
|
||||
*/
|
||||
public LLDBRunControl(DsfSession session) {
|
||||
super(session);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void canMoveToAddress(IExecutionDMContext context, IAddress address, boolean resume,
|
||||
DataRequestMonitor<Boolean> rm) {
|
||||
// FIXME: LLDB-MI doesn't implement -exec-jump so it will fail. So
|
||||
// disable "move to address" (disassembly) for now.
|
||||
rm.setData(false);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void canMoveToLine(IExecutionDMContext context, String sourceFile, int lineNumber, boolean resume,
|
||||
DataRequestMonitor<Boolean> rm) {
|
||||
// FIXME: LLDB-MI doesn't implement -exec-jump so it will fail. So
|
||||
// disable "move to line" for now.
|
||||
rm.setData(false);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,50 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.core.internal.service;
|
||||
|
||||
import org.eclipse.cdt.dsf.debug.service.IBreakpoints;
|
||||
import org.eclipse.cdt.dsf.debug.service.IRunControl;
|
||||
import org.eclipse.cdt.dsf.debug.service.command.ICommandControl;
|
||||
import org.eclipse.cdt.dsf.gdb.service.GdbDebugServicesFactory;
|
||||
import org.eclipse.cdt.dsf.mi.service.command.CommandFactory;
|
||||
import org.eclipse.cdt.dsf.service.DsfSession;
|
||||
import org.eclipse.debug.core.ILaunchConfiguration;
|
||||
|
||||
/**
|
||||
* A service factor specific to LLDB that replaces some services in order to
|
||||
* offer a more tailored experience and mostly work around some issues with
|
||||
* LLDB-MI.
|
||||
*/
|
||||
public class LLDBServiceFactory extends GdbDebugServicesFactory {
|
||||
|
||||
/**
|
||||
* Constructs the {@link LLDBServiceFactory}.
|
||||
*
|
||||
* @param version the GDB-equivalent version of LLDB
|
||||
* @param config the launch configuration
|
||||
*/
|
||||
public LLDBServiceFactory(String version, ILaunchConfiguration config) {
|
||||
super(version, config);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected ICommandControl createCommandControl(DsfSession session, ILaunchConfiguration config) {
|
||||
return new LLDBControl(session, config, new CommandFactory());
|
||||
}
|
||||
|
||||
@Override
|
||||
protected IBreakpoints createBreakpointService(DsfSession session) {
|
||||
return new LLDBBreakpoints(session);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected IRunControl createRunControlService(DsfSession session) {
|
||||
return new LLDBRunControl(session);
|
||||
}
|
||||
}
|
7
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/.classpath
Normal file
7
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/.classpath
Normal file
|
@ -0,0 +1,7 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="src" path="src"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
1
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/.gitignore
vendored
Normal file
1
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/.gitignore
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
/bin/
|
34
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/.project
Normal file
34
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/.project
Normal file
|
@ -0,0 +1,34 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>org.eclipse.cdt.llvm.dsf.lldb.ui</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.jdt.core.javabuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.pde.ManifestBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.pde.SchemaBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.pde.PluginNature</nature>
|
||||
<nature>org.eclipse.jdt.core.javanature</nature>
|
||||
<nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
|
||||
</natures>
|
||||
</projectDescription>
|
|
@ -0,0 +1,125 @@
|
|||
eclipse.preferences.version=1
|
||||
org.eclipse.jdt.core.codeComplete.argumentPrefixes=
|
||||
org.eclipse.jdt.core.codeComplete.argumentSuffixes=
|
||||
org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
|
||||
org.eclipse.jdt.core.codeComplete.fieldSuffixes=
|
||||
org.eclipse.jdt.core.codeComplete.localPrefixes=
|
||||
org.eclipse.jdt.core.codeComplete.localSuffixes=
|
||||
org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=s
|
||||
org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
|
||||
org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
|
||||
org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
|
||||
org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=disabled
|
||||
org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
|
||||
org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
|
||||
org.eclipse.jdt.core.compiler.annotation.nonnull.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
|
||||
org.eclipse.jdt.core.compiler.annotation.nonnullbydefault.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
|
||||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.doc.comment.support=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
|
||||
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
|
||||
org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning
|
||||
org.eclipse.jdt.core.compiler.problem.deadCode=warning
|
||||
org.eclipse.jdt.core.compiler.problem.deprecation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
|
||||
org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
|
||||
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning
|
||||
org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning
|
||||
org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
|
||||
org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning
|
||||
org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning
|
||||
org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=warning
|
||||
org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingDefaultCase=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=return_tag
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning
|
||||
org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nonnullTypeVariableFromLegacyInvocation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error
|
||||
org.eclipse.jdt.core.compiler.problem.nullReference=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
|
||||
org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
|
||||
org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
|
||||
org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning
|
||||
org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=warning
|
||||
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
|
||||
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unclosedCloseable=warning
|
||||
org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedImport=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedLocal=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
|
@ -0,0 +1,64 @@
|
|||
cleanup_settings_version=2
|
||||
eclipse.preferences.version=1
|
||||
editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
|
||||
org.eclipse.jdt.ui.exception.name=e
|
||||
org.eclipse.jdt.ui.gettersetter.use.is=true
|
||||
org.eclipse.jdt.ui.keywordthis=false
|
||||
org.eclipse.jdt.ui.overrideannotation=true
|
||||
sp_cleanup.add_default_serial_version_id=true
|
||||
sp_cleanup.add_generated_serial_version_id=false
|
||||
sp_cleanup.add_missing_annotations=false
|
||||
sp_cleanup.add_missing_deprecated_annotations=true
|
||||
sp_cleanup.add_missing_methods=false
|
||||
sp_cleanup.add_missing_nls_tags=false
|
||||
sp_cleanup.add_missing_override_annotations=true
|
||||
sp_cleanup.add_missing_override_annotations_interface_methods=true
|
||||
sp_cleanup.add_serial_version_id=false
|
||||
sp_cleanup.always_use_blocks=true
|
||||
sp_cleanup.always_use_parentheses_in_expressions=false
|
||||
sp_cleanup.always_use_this_for_non_static_field_access=false
|
||||
sp_cleanup.always_use_this_for_non_static_method_access=false
|
||||
sp_cleanup.convert_functional_interfaces=false
|
||||
sp_cleanup.convert_to_enhanced_for_loop=false
|
||||
sp_cleanup.correct_indentation=false
|
||||
sp_cleanup.format_source_code=false
|
||||
sp_cleanup.format_source_code_changes_only=false
|
||||
sp_cleanup.insert_inferred_type_arguments=false
|
||||
sp_cleanup.make_local_variable_final=true
|
||||
sp_cleanup.make_parameters_final=false
|
||||
sp_cleanup.make_private_fields_final=true
|
||||
sp_cleanup.make_type_abstract_if_missing_method=false
|
||||
sp_cleanup.make_variable_declarations_final=false
|
||||
sp_cleanup.never_use_blocks=false
|
||||
sp_cleanup.never_use_parentheses_in_expressions=true
|
||||
sp_cleanup.on_save_use_additional_actions=true
|
||||
sp_cleanup.organize_imports=false
|
||||
sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
|
||||
sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
|
||||
sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
|
||||
sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
|
||||
sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
|
||||
sp_cleanup.remove_private_constructors=true
|
||||
sp_cleanup.remove_redundant_type_arguments=false
|
||||
sp_cleanup.remove_trailing_whitespaces=true
|
||||
sp_cleanup.remove_trailing_whitespaces_all=true
|
||||
sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
|
||||
sp_cleanup.remove_unnecessary_casts=false
|
||||
sp_cleanup.remove_unnecessary_nls_tags=false
|
||||
sp_cleanup.remove_unused_imports=false
|
||||
sp_cleanup.remove_unused_local_variables=false
|
||||
sp_cleanup.remove_unused_private_fields=true
|
||||
sp_cleanup.remove_unused_private_members=false
|
||||
sp_cleanup.remove_unused_private_methods=true
|
||||
sp_cleanup.remove_unused_private_types=true
|
||||
sp_cleanup.sort_members=false
|
||||
sp_cleanup.sort_members_all=false
|
||||
sp_cleanup.use_anonymous_class_creation=false
|
||||
sp_cleanup.use_blocks=true
|
||||
sp_cleanup.use_blocks_only_for_return_and_throw=false
|
||||
sp_cleanup.use_lambda=true
|
||||
sp_cleanup.use_parentheses_in_expressions=false
|
||||
sp_cleanup.use_this_for_non_static_field_access=false
|
||||
sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
|
||||
sp_cleanup.use_this_for_non_static_method_access=false
|
||||
sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
|
22
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/META-INF/MANIFEST.MF
Normal file
22
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/META-INF/MANIFEST.MF
Normal file
|
@ -0,0 +1,22 @@
|
|||
Manifest-Version: 1.0
|
||||
Bundle-ManifestVersion: 2
|
||||
Bundle-Name: %pluginName
|
||||
Bundle-Vendor: %providerName
|
||||
Bundle-SymbolicName: org.eclipse.cdt.llvm.dsf.lldb.ui;singleton:=true
|
||||
Bundle-Version: 1.0.0.qualifier
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
Bundle-Localization: plugin
|
||||
Require-Bundle: org.eclipse.cdt.debug.ui,
|
||||
org.eclipse.cdt.dsf.gdb.ui,
|
||||
org.eclipse.debug.ui,
|
||||
org.eclipse.swt,
|
||||
org.eclipse.cdt.dsf.gdb,
|
||||
org.eclipse.ui.workbench,
|
||||
org.eclipse.core.runtime,
|
||||
org.eclipse.jface,
|
||||
org.eclipse.cdt.llvm.dsf.lldb.core,
|
||||
org.eclipse.cdt.dsf.ui,
|
||||
org.eclipse.cdt.debug.core
|
||||
Bundle-Activator: org.eclipse.cdt.llvm.dsf.lldb.ui.internal.LLDBUIPlugin
|
||||
Bundle-ActivationPolicy: lazy
|
||||
Export-Package: org.eclipse.cdt.llvm.dsf.lldb.ui.internal;x-internal:=true
|
24
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/about.html
Normal file
24
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/about.html
Normal file
|
@ -0,0 +1,24 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"><head>
|
||||
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>About</title></head><body lang="EN-US">
|
||||
<h2>About This Content</h2>
|
||||
|
||||
<p>June 5, 2007</p>
|
||||
<h3>License</h3>
|
||||
|
||||
<p>The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise
|
||||
indicated below, the Content is provided to you under the terms and conditions of the
|
||||
Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available
|
||||
at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
|
||||
For purposes of the EPL, "Program" will mean the Content.</p>
|
||||
|
||||
<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is
|
||||
being redistributed by another party ("Redistributor") and different terms and conditions may
|
||||
apply to your use of any object code in the Content. Check the Redistributor's license that was
|
||||
provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
|
||||
indicated below, the terms and conditions of the EPL still apply to any source code in the Content
|
||||
and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
|
||||
|
||||
</body></html>
|
8
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/build.properties
Normal file
8
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/build.properties
Normal file
|
@ -0,0 +1,8 @@
|
|||
source.. = src/
|
||||
output.. = bin/
|
||||
bin.includes = META-INF/,\
|
||||
.,\
|
||||
plugin.xml,\
|
||||
about.html,\
|
||||
plugin.properties
|
||||
src.includes = about.html
|
19
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/plugin.properties
Normal file
19
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/plugin.properties
Normal file
|
@ -0,0 +1,19 @@
|
|||
###############################################################################
|
||||
# Copyright (c) 2016 Ericsson
|
||||
# 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
|
||||
###############################################################################
|
||||
pluginName=LLDB Debugger Integration UI
|
||||
providerName=Eclipse CDT
|
||||
|
||||
lldbPreferencePage.name = LLDB
|
||||
|
||||
launchTab.main.name=Main
|
||||
launchTab.arguments.name=Arguments
|
||||
launchTab.debugger.name=Debugger
|
||||
launchTab.sourceLookup.name=Source
|
||||
launchTab.common.name=Common
|
||||
launchTab.environment.name=Environment
|
||||
lldbPreferencePage.name = LLDB
|
55
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/plugin.xml
Normal file
55
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/plugin.xml
Normal file
|
@ -0,0 +1,55 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?eclipse version="3.4"?>
|
||||
<plugin>
|
||||
<extension
|
||||
point="org.eclipse.debug.ui.launchConfigurationTabs">
|
||||
<!-- Local application launch tabs-->
|
||||
<tab
|
||||
id="org.eclipse.cdt.llvm.dsf.lldb.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.llvm.dsf.lldb.launch.localCLaunch"/>
|
||||
</tab>
|
||||
<tab id="org.eclipse.cdt.llvm.dsf.lldb.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.llvm.dsf.lldb.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.llvm.dsf.lldb.launch.mainTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.llvm.dsf.lldb.launch.localApplicationLaunch.environmentTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%launchTab.environment.name"
|
||||
class="org.eclipse.debug.ui.EnvironmentTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.llvm.dsf.lldb.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.llvm.dsf.lldb.launch.argumentsTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.llvm.dsf.lldb.launch.localApplicationLaunch.debuggerTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%launchTab.debugger.name"
|
||||
class="org.eclipse.cdt.llvm.dsf.lldb.ui.internal.LLDBLocalApplicationCDebuggerTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.llvm.dsf.lldb.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.debug.ui.environmentTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.llvm.dsf.lldb.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.llvm.dsf.lldb.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.cdt.llvm.dsf.lldb.launch.debuggerTab"/>
|
||||
</tab>
|
||||
<tab
|
||||
id="org.eclipse.cdt.llvm.dsf.lldb.launch.localApplicationLaunch.commonTab"
|
||||
group="org.eclipse.cdt.launch.applicationLaunchTabGroup"
|
||||
name="%launchTab.common.name"
|
||||
class="org.eclipse.debug.ui.CommonTab">
|
||||
<associatedDelegate delegate="org.eclipse.cdt.llvm.dsf.lldb.launch.localCLaunch"/>
|
||||
<placement after="org.eclipse.debug.ui.sourceLookupTab"/>
|
||||
</tab>
|
||||
</extension>
|
||||
|
||||
</plugin>
|
17
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/pom.xml
Normal file
17
llvm/org.eclipse.cdt.llvm.dsf.lldb.ui/pom.xml
Normal file
|
@ -0,0 +1,17 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
|
||||
xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<parent>
|
||||
<groupId>org.eclipse.cdt</groupId>
|
||||
<artifactId>cdt-parent</artifactId>
|
||||
<version>9.0.0-SNAPSHOT</version>
|
||||
<relativePath>../../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
<version>1.0.0-SNAPSHOT</version>
|
||||
<artifactId>org.eclipse.cdt.llvm.dsf.lldb.ui</artifactId>
|
||||
<packaging>eclipse-plugin</packaging>
|
||||
</project>
|
|
@ -0,0 +1,128 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.ui.internal;
|
||||
|
||||
import java.io.File;
|
||||
|
||||
import org.eclipse.cdt.debug.core.ICDTLaunchConfigurationConstants;
|
||||
import org.eclipse.cdt.debug.ui.AbstractCDebuggerPage;
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.ILLDBDebugPreferenceConstants;
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.ILLDBLaunchConfigurationConstants;
|
||||
import org.eclipse.core.runtime.CoreException;
|
||||
import org.eclipse.debug.core.ILaunchConfiguration;
|
||||
import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
|
||||
import org.eclipse.jface.preference.IPreferenceStore;
|
||||
import org.eclipse.swt.SWT;
|
||||
import org.eclipse.swt.events.ModifyEvent;
|
||||
import org.eclipse.swt.events.ModifyListener;
|
||||
import org.eclipse.swt.events.SelectionAdapter;
|
||||
import org.eclipse.swt.events.SelectionEvent;
|
||||
import org.eclipse.swt.layout.GridData;
|
||||
import org.eclipse.swt.layout.GridLayout;
|
||||
import org.eclipse.swt.widgets.Button;
|
||||
import org.eclipse.swt.widgets.Composite;
|
||||
import org.eclipse.swt.widgets.FileDialog;
|
||||
import org.eclipse.swt.widgets.Label;
|
||||
import org.eclipse.swt.widgets.Text;
|
||||
|
||||
/**
|
||||
* A LLDB-specific debugger page that only shows the options currently supported
|
||||
* by LLDB and its integration with CDT.
|
||||
*/
|
||||
public class LLDBCDebuggerPage extends AbstractCDebuggerPage {
|
||||
|
||||
protected Text fLLDBCommandText;
|
||||
|
||||
@Override
|
||||
public void createControl(Composite parent) {
|
||||
Composite composite = new Composite(parent, SWT.NULL);
|
||||
composite.setFont(parent.getFont());
|
||||
|
||||
composite.setLayout(new GridLayout(3, false));
|
||||
composite.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, false));
|
||||
Label lbl = new Label(composite, SWT.LEFT);
|
||||
lbl.setFont(parent.getFont());
|
||||
lbl.setText(Messages.LLDBCDebuggerPage_debugger_command);
|
||||
fLLDBCommandText = new Text(composite, SWT.SINGLE | SWT.BORDER);
|
||||
fLLDBCommandText.setLayoutData(new GridData(SWT.FILL, SWT.TOP, true, false));
|
||||
fLLDBCommandText.addModifyListener(new ModifyListener() {
|
||||
@Override
|
||||
public void modifyText(ModifyEvent evt) {
|
||||
updateLaunchConfigurationDialog();
|
||||
}
|
||||
});
|
||||
|
||||
Button button = createPushButton(composite, Messages.LLDBCDebuggerPage_browse, null);
|
||||
button.addSelectionListener(new SelectionAdapter() {
|
||||
@Override
|
||||
public void widgetSelected(SelectionEvent evt) {
|
||||
handleButtonSelected();
|
||||
updateLaunchConfigurationDialog();
|
||||
}
|
||||
|
||||
private void handleButtonSelected() {
|
||||
FileDialog dialog = new FileDialog(getShell(), SWT.NONE);
|
||||
dialog.setText(Messages.LLDBCDebuggerPage_browse_dialog_title);
|
||||
String lldbCommand = fLLDBCommandText.getText().trim();
|
||||
int lastSeparatorIndex = lldbCommand.lastIndexOf(File.separator);
|
||||
if (lastSeparatorIndex != -1) {
|
||||
dialog.setFilterPath(lldbCommand.substring(0, lastSeparatorIndex));
|
||||
}
|
||||
String res = dialog.open();
|
||||
if (res == null) {
|
||||
return;
|
||||
}
|
||||
fLLDBCommandText.setText(res);
|
||||
}
|
||||
});
|
||||
setControl(parent);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setDefaults(ILaunchConfigurationWorkingCopy configuration) {
|
||||
// I'm actually not sure this is needed but it seems this will be called
|
||||
// if this delegate is used when first initializing defaults (i.e. GDB
|
||||
// is not the delegate for this configuration first)
|
||||
IPreferenceStore corePreferenceStore = LLDBUIPlugin.getDefault().getCorePreferenceStore();
|
||||
configuration.setAttribute(ILLDBLaunchConfigurationConstants.ATTR_DEBUG_NAME,
|
||||
corePreferenceStore.getString(ILLDBDebugPreferenceConstants.PREF_DEFAULT_LLDB_COMMAND));
|
||||
configuration.setAttribute(ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_STOP_AT_MAIN,
|
||||
corePreferenceStore.getBoolean(ILLDBDebugPreferenceConstants.PREF_DEFAULT_STOP_AT_MAIN));
|
||||
configuration.setAttribute(ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_STOP_AT_MAIN_SYMBOL,
|
||||
corePreferenceStore.getBoolean(ILLDBDebugPreferenceConstants.PREF_DEFAULT_STOP_AT_MAIN_SYMBOL));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void initializeFrom(ILaunchConfiguration configuration) {
|
||||
IPreferenceStore preferenceStore = LLDBUIPlugin.getDefault().getCorePreferenceStore();
|
||||
String lldbCommand = getStringAttr(configuration, ILLDBLaunchConfigurationConstants.ATTR_DEBUG_NAME,
|
||||
preferenceStore.getString(ILLDBDebugPreferenceConstants.PREF_DEFAULT_LLDB_COMMAND));
|
||||
fLLDBCommandText.setText(lldbCommand);
|
||||
}
|
||||
|
||||
private static String getStringAttr(ILaunchConfiguration config, String attributeName, String defaultValue) {
|
||||
try {
|
||||
return config.getAttribute(attributeName, defaultValue);
|
||||
} catch (CoreException e) {
|
||||
return defaultValue;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void performApply(ILaunchConfigurationWorkingCopy configuration) {
|
||||
configuration.setAttribute(ILLDBLaunchConfigurationConstants.ATTR_DEBUG_NAME,
|
||||
fLLDBCommandText.getText().trim());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getName() {
|
||||
return Messages.LLDBCDebuggerPage_tab_name;
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,102 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.ui.internal;
|
||||
|
||||
import org.eclipse.cdt.debug.core.ICDTLaunchConfigurationConstants;
|
||||
import org.eclipse.cdt.debug.ui.ICDebuggerPage;
|
||||
import org.eclipse.cdt.dsf.gdb.internal.ui.launching.LocalApplicationCDebuggerTab;
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.ILLDBDebugPreferenceConstants;
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.ILLDBLaunchConfigurationConstants;
|
||||
import org.eclipse.core.runtime.CoreException;
|
||||
import org.eclipse.debug.core.ILaunchConfiguration;
|
||||
import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
|
||||
import org.eclipse.jface.preference.IPreferenceStore;
|
||||
import org.eclipse.swt.widgets.Composite;
|
||||
import org.eclipse.swt.widgets.Control;
|
||||
|
||||
/**
|
||||
* A LLDB-specific debugger tab that allows us to present a different debugger
|
||||
* page.
|
||||
*/
|
||||
@SuppressWarnings("restriction")
|
||||
public class LLDBLocalApplicationCDebuggerTab extends LocalApplicationCDebuggerTab {
|
||||
|
||||
private final static String LOCAL_DEBUGGER_ID = "lldb-mi";//$NON-NLS-1$
|
||||
|
||||
protected void initDebuggerTypes(String selection) {
|
||||
setDebuggerId(LOCAL_DEBUGGER_ID);
|
||||
updateComboFromSelection();
|
||||
}
|
||||
|
||||
/*
|
||||
* This flag it to make sure that setDefaults gets called, even if the configuration is initially created for another delegate (GDB) then switched to LLDB.
|
||||
*/
|
||||
private final static String DEFAULTS_SET = "org.eclipse.cdt.llvm.dsf.lldb.ui.internal.LLDBLocalApplicationCDebuggerTab.DEFAULTS_SET"; //$NON-NLS-1$
|
||||
|
||||
@Override
|
||||
public void initializeFrom(ILaunchConfiguration config) {
|
||||
try {
|
||||
if (config.hasAttribute(DEFAULTS_SET) == false) {
|
||||
ILaunchConfigurationWorkingCopy wc;
|
||||
wc = config.getWorkingCopy();
|
||||
setDefaults(wc);
|
||||
wc.doSave();
|
||||
}
|
||||
} catch (CoreException e) {
|
||||
}
|
||||
|
||||
super.initializeFrom(config);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setDefaults(ILaunchConfigurationWorkingCopy config) {
|
||||
super.setDefaults(config);
|
||||
IPreferenceStore corePreferenceStore = LLDBUIPlugin.getDefault().getCorePreferenceStore();
|
||||
config.setAttribute(ILLDBLaunchConfigurationConstants.ATTR_DEBUG_NAME,
|
||||
corePreferenceStore.getString(ILLDBDebugPreferenceConstants.PREF_DEFAULT_LLDB_COMMAND));
|
||||
config.setAttribute(ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_STOP_AT_MAIN,
|
||||
corePreferenceStore.getBoolean(ILLDBDebugPreferenceConstants.PREF_DEFAULT_STOP_AT_MAIN));
|
||||
config.setAttribute(ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_STOP_AT_MAIN_SYMBOL,
|
||||
corePreferenceStore.getString(ILLDBDebugPreferenceConstants.PREF_DEFAULT_STOP_AT_MAIN_SYMBOL));
|
||||
|
||||
config.setAttribute(DEFAULTS_SET, true);
|
||||
}
|
||||
|
||||
protected void loadDynamicDebugArea() {
|
||||
Composite dynamicTabHolder = getDynamicTabHolder();
|
||||
// Dispose of any current child widgets in the tab holder area
|
||||
Control[] children = dynamicTabHolder.getChildren();
|
||||
for (int i = 0; i < children.length; i++) {
|
||||
children[i].dispose();
|
||||
}
|
||||
|
||||
String debuggerId = getIdForCurrentDebugger();
|
||||
if (debuggerId == null) {
|
||||
setDynamicTab(null);
|
||||
} else {
|
||||
if (debuggerId.equals(LOCAL_DEBUGGER_ID)) {
|
||||
setDynamicTab(new LLDBCDebuggerPage());
|
||||
} else {
|
||||
assert false : "Unknown debugger id"; //$NON-NLS-1$
|
||||
}
|
||||
}
|
||||
setDebuggerId(debuggerId);
|
||||
|
||||
ICDebuggerPage debuggerPage = getDynamicTab();
|
||||
if (debuggerPage == null) {
|
||||
return;
|
||||
}
|
||||
// Ask the dynamic UI to create its Control
|
||||
debuggerPage.setLaunchConfigurationDialog(getLaunchConfigurationDialog());
|
||||
debuggerPage.createControl(dynamicTabHolder);
|
||||
debuggerPage.getControl().setVisible(true);
|
||||
dynamicTabHolder.layout(true);
|
||||
contentsChanged();
|
||||
}
|
||||
}
|
|
@ -0,0 +1,75 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.ui.internal;
|
||||
|
||||
import org.eclipse.cdt.llvm.dsf.lldb.core.internal.LLDBCorePlugin;
|
||||
import org.eclipse.core.runtime.preferences.InstanceScope;
|
||||
import org.eclipse.jface.preference.IPreferenceStore;
|
||||
import org.eclipse.ui.plugin.AbstractUIPlugin;
|
||||
import org.eclipse.ui.preferences.ScopedPreferenceStore;
|
||||
import org.osgi.framework.BundleContext;
|
||||
|
||||
/**
|
||||
* The activator class controls the plug-in life cycle
|
||||
*/
|
||||
public class LLDBUIPlugin extends AbstractUIPlugin {
|
||||
|
||||
/**
|
||||
* LLDB UI Plug-in ID
|
||||
*/
|
||||
public static final String PLUGIN_ID = "org.eclipse.cdt.llvm.dsf.lldb.ui"; //$NON-NLS-1$
|
||||
private static LLDBUIPlugin plugin;
|
||||
private static IPreferenceStore fCorePreferenceStore;
|
||||
private static IPreferenceStore fPreferenceStore;
|
||||
|
||||
@Override
|
||||
public void start(BundleContext context) throws Exception {
|
||||
super.start(context);
|
||||
plugin = this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void stop(BundleContext context) throws Exception {
|
||||
plugin = null;
|
||||
super.stop(context);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the shared instance
|
||||
*
|
||||
* @return the shared instance
|
||||
*/
|
||||
public static LLDBUIPlugin getDefault() {
|
||||
return plugin;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the preference store for this plug-in.
|
||||
*/
|
||||
@Override
|
||||
public IPreferenceStore getPreferenceStore() {
|
||||
if (fPreferenceStore == null) {
|
||||
fPreferenceStore = new ScopedPreferenceStore(InstanceScope.INSTANCE, PLUGIN_ID);
|
||||
}
|
||||
return fPreferenceStore;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the preference store for the Core plug-in.
|
||||
*
|
||||
* @return the Core plug-in preference store
|
||||
*/
|
||||
public IPreferenceStore getCorePreferenceStore() {
|
||||
if (fCorePreferenceStore == null) {
|
||||
fCorePreferenceStore = new ScopedPreferenceStore(InstanceScope.INSTANCE, LLDBCorePlugin.PLUGIN_ID);
|
||||
}
|
||||
return fCorePreferenceStore;
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,31 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2016 Ericsson.
|
||||
* 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
|
||||
*******************************************************************************/
|
||||
|
||||
package org.eclipse.cdt.llvm.dsf.lldb.ui.internal;
|
||||
|
||||
import org.eclipse.osgi.util.NLS;
|
||||
|
||||
/**
|
||||
* Messages related to preferences and launch configuration.
|
||||
*/
|
||||
@SuppressWarnings("javadoc")
|
||||
public class Messages extends NLS {
|
||||
private static final String BUNDLE_NAME = "org.eclipse.cdt.llvm.dsf.lldb.ui.internal.messages"; //$NON-NLS-1$
|
||||
public static String LLDBCDebuggerPage_browse;
|
||||
public static String LLDBCDebuggerPage_browse_dialog_title;
|
||||
public static String LLDBCDebuggerPage_tab_name;
|
||||
public static String LLDBCDebuggerPage_debugger_command;
|
||||
|
||||
static {
|
||||
// initialize resource bundle
|
||||
NLS.initializeMessages(BUNDLE_NAME, Messages.class);
|
||||
}
|
||||
|
||||
private Messages() {
|
||||
}
|
||||
}
|
|
@ -0,0 +1,12 @@
|
|||
###############################################################################
|
||||
# Copyright (c) 2016 Ericsson.
|
||||
# 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
|
||||
###############################################################################
|
||||
|
||||
LLDBCDebuggerPage_browse=&Browse...
|
||||
LLDBCDebuggerPage_browse_dialog_title=LLDB-MI Debugger
|
||||
LLDBCDebuggerPage_tab_name=LLDB Debugger Options
|
||||
LLDBCDebuggerPage_debugger_command=LLDB command:
|
4
pom.xml
4
pom.xml
|
@ -205,7 +205,9 @@
|
|||
|
||||
<module>llvm/org.eclipse.cdt.managedbuilder.llvm.ui</module>
|
||||
<module>llvm/org.eclipse.cdt.managedbuilder.llvm-feature</module>
|
||||
|
||||
<module>llvm/org.eclipse.cdt.llvm.dsf.lldb.core</module>
|
||||
<module>llvm/org.eclipse.cdt.llvm.dsf.lldb.ui</module>
|
||||
|
||||
<module>qt/org.eclipse.cdt.qt.core</module>
|
||||
<module>qt/org.eclipse.cdt.qt.ui</module>
|
||||
<!--module>qt/org.eclipse.cdt.qt.core.tests</module-->
|
||||
|
|
Loading…
Add table
Reference in a new issue