Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/corefx.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Perovich <alperovi@microsoft.com>2016-11-22 02:39:22 +0300
committerGitHub <noreply@github.com>2016-11-22 02:39:22 +0300
commit4bf98d1729b503430e7cb8ac87c68872a970efb5 (patch)
tree7e1bb4fef4fcc9fdaaca2365f548e48cc95a4b1b /Documentation/debugging
parente5b2fba8f386849f57d94afe018a96fefc650967 (diff)
Add linux debugging instructions (#13867)
* Add linux debugging instructions * s/linux/unix
Diffstat (limited to 'Documentation/debugging')
-rw-r--r--Documentation/debugging/unix-instructions.md26
1 files changed, 26 insertions, 0 deletions
diff --git a/Documentation/debugging/unix-instructions.md b/Documentation/debugging/unix-instructions.md
new file mode 100644
index 0000000000..20f60b8a18
--- /dev/null
+++ b/Documentation/debugging/unix-instructions.md
@@ -0,0 +1,26 @@
+Debugging CoreFX on Unix
+==========================
+
+CoreFX can be debugged on unix using both lldb and visual studio code
+
+## Using lldb and SOS
+
+- Run the test using msbuild at least once with `/t:BuildAndTest`.
+- Install version 3.6 of lldb and launch lldb with corerun as the process and arguments matching the arguments used when running the test through msbuild.
+- Load the sos plugin using `plugin load libsosplugin.so`.
+- Type `soshelp` to get help. You can now use all sos commands like `bpmd`.
+
+## Using Visual Studio Code
+
+- Install [Visual Studio Code](https://code.visualstudio.com/)
+- Install the [C# Extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode.csharp)
+- Open the folder containing the source you want to debug in VS Code
+- Open the debug window: `ctrl-shift-D` or click on the button on the left
+- Click the gear button at the top to create a launch configuration, select `.NET Core` from the selection dropdown
+- In the `.NET Core Launch (console)` configuration do the following
+ - delete the `preLaunchTask` property
+ - set `program` to the full path to corerun in the test directory
+ - set `cwd` to the test directory
+ - set `args` to the command line arguments to pass to the test
+ - something like: `[ "xunit.console.netcore.exe", "<test>.dll", "-notrait", .... ]`
+- Set a breakpoint and launch the debugger, inspecting variables and call stacks will now work