summaryrefslogtreecommitdiffstats
path: root/docs/getting-started/app-workflow-debug-app.md
blob: 9273bee0697219f11680518a254e2e86fa9f2f0f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19

@media only all and (prefers-color-scheme: dark) {
.highlight .hll { background-color: #49483e }
.highlight .c { color: #75715e } /* Comment */
.highlight .err { color: #960050; background-color: #1e0010 } /* Error */
.highlight .k { color: #66d9ef } /* Keyword */
.highlight .l { color: #ae81ff } /* Literal */
.highlight .n { color: #f8f8f2 } /* Name */
.highlight .o { color: #f92672 } /* Operator */
.highlight .p { color: #f8f8f2 } /* Punctuation */
.highlight .ch { color: #75715e } /* Comment.Hashbang */
.highlight .cm { color: #75715e } /* Comment.Multiline */
.highlight .cp { color: #75715e } /* Comment.Preproc */
.highlight .cpf { color: #75715e } /* Comment.PreprocFile */
.highlight .c1 { color: #75715e } /* Comment.Single */
.highlight .cs { color: #75715e } /* Comment.Special */
.highlight .gd { color: #f92672 } /* Generic.Deleted */
.highlight .ge { font-style: italic } /* Ge
# Debug the Application #

You can debug your application many ways.
The method depends on factors such as the component you are debugging,
whether or not you are doing a post-mortem analysis, and your debugging
skills and productivity.
For example, do you know how to use the
[GNU Project Debugger](https://www.gnu.org/software/gdb/) (`gdb`) from a
console?
Or, is it better for you to use a remote user interface that is part of
an Integrated Development Environment (IDE) such as Eclipse?

For general information on debugging an application, see the
"[Debug Your First AGL Application](../../../devguides/reference/xds/part-1/debug-overview.html)"
section.

Here are three methods:

   * Use `gdb` on the target.

     **NOTE:** How to use `gdb` and other debugging tools such as `valgrind`, `strace`,
     and so forth is beyond the scope of the AGL Documentation.
     See the appropriate documentation for third-party debugging tools.

   * Use Core Dumps if you have set the `agl-devel` feature.
     Core Dumps are obviously more suited for post-mortem analysis.
     For features, see the
     "[Initializing Your Build Environment](./image-workflow-initialize-build-environment.html#initializing-your-build-environment)"
     section.

     **NOTE:** Core Dumps are available only with the "Flunky Flounder" release (i.e. 6.x).

   * Use XDS remotely, which is based on `gdb` and
     [`gdbserver`](https://en.wikipedia.org/wiki/Gdbserver).
     See the
     "[XDS remote debugging mode](../../../devguides/reference/xds/part-1/debug-cmd-line.html#xds-remote-debugging-mode)"
     section for more information.

     For information on how to remotely debug the application using XDS from within an IDE, see the
     "[Debug using `xds-gdb` within an IDE](../../../devguides/reference/xds/part-1/debug-ide.html)"
     section.

   In order to use third-party debugging tools, you need to include the tools in the target image.
   You gain access to the tools by enabling the `agl-devel` feature when you run the
   `aglsetup.sh` script as described in the
   "[Initializing Your Build Environment](./image-workflow-initialize-build-environment.html#initializing-your-build-environment)"
   section.