Skip to content

[Docs]: C/C++ debug not working #5764

Closed

Description

@sakthivel-axim

Is there an existing issue for this?

  • I have searched the existing issues

OS/Web Information

  • Web Browser: Chrome
  • Local OS: Ubuntu 18.04
  • Remote OS: Debian
  • Remote Architecture: BeagleBone (armhf)
  • code-server --version: 4.8.1

Steps to Reproduce

  1. Download and install using dpkg -i <package.deb>
  2. Add launch.json with type cppdbg
  3. Able to compile and execute. But debug not working.

Expected

Able to debug

Actual

Throws error Configured debug type 'cppdbg' is not supported.

Logs

No response

Screenshot/Video

image

Does this issue happen in VS Code or GitHub Codespaces?

  • I cannot reproduce this in VS Code.
  • I cannot reproduce this in GitHub Codespaces.

Are you accessing code-server over HTTPS?

  • I am using HTTPS.

Notes

Installed the .deb package in BeagleBone board. Running over HTTP.

Activity

  1. added
    bugSomething isn't working
    triageThis issue needs to be triaged by a maintainer
    on Nov 8, 2022
  2. changed the title [-][Bug]: C/C++ debug not working[/-] [+][Docs]: C/C++ debug not working[/+] on Nov 8, 2022
  3. jsjoeio commented on Nov 8, 2022

    @jsjoeio
    Contributor

    I think the CPP debugger is in the MSFT extension which we can't use in code-server (based off this) so I don't think there's anything we can do here sadly.

    cc @code-asher are there any workarounds that you know of?

  4. sakthivel-axim commented on Nov 10, 2022

    @sakthivel-axim
    Author

    Thanks, @jsjoeio. Understand that cannot use cppdbg. Please let me know the possibilities to use gdb for debugging in Debian environment.

  5. jsjoeio commented on Nov 10, 2022

    @jsjoeio
    Contributor

    Understand that cannot use cppdbg. Please let me know the possibilities to use gdb for debugging in Debian environment

    None that I know of but maybe @code-asher knows

  6. code-asher commented on Nov 10, 2022

    @code-asher
    Member

    The only open-source version of the Microsoft C++ extension I know of is https://open-vsx.org/extension/llvm-vs-code-extensions/vscode-clangd but I have never used it so I am not sure how/if debugging works.

  7. a279437145 commented on Nov 18, 2022

    @a279437145

    I can have cpp debugging working on code-server running on my Raspberry pi (Ubuntu 22.04 , arm64) , I installed https://github.com/Microsoft/vscode-cpptools (there are armhf builds), you may try it . (It can work even without https)

  8. sakthivel-axim commented on Nov 23, 2022

    @sakthivel-axim
    Author

    Thanks you @a279437145 .

    I have tried to install but it doesn't show in extension. Could you please share config/steps to bring up? It will be helpful.

  9. a279437145 commented on Nov 23, 2022

    @a279437145

    yep , it's not in the openVSX extension gallery , so you cant install it directly.
    I downloaded the vsix from https://marketplace.visualstudio.com/items?itemName=ms-vscode.cpptools
    and chose the Download extensionoption in the right , then choose the right one for you
    you are on armhf ubuntu , so you should choose Linux arm32 , like this:
    IMG_20221123_171335

    then put it on your code-server and install, the way to install exis extensions are described in the code-server docs

    Also if you want i can provide my tasks.jsonandlaunch.json

  10. sakthivel-axim commented on Nov 23, 2022

    @sakthivel-axim
    Author

    Thanks @a279437145 . I will try to setup. Please share your tasks.json and launch.json, it helps a lot. Thanks once again.

  11. a279437145 commented on Nov 23, 2022

    @a279437145

    the files are here
    launch.txt
    tasks.txt
    change the attribute to .json(I can't upload json files to github directly),and please ignore the python configuration in launch.json
    it should work like this
    Screenshot_2022-11-23-19-58-51-30_3aea4af51f236e4932235fdada7d1643
    I cant use computer now so I did that on phone , the screenshot may somehow look a bit strange,regret~

  12. sakthivel-axim commented on Nov 23, 2022

    @sakthivel-axim
    Author

    It's working. Thank you @a279437145.

  13. a279437145 commented on Nov 23, 2022

    @a279437145
  14. sakthivel-axim commented on Nov 24, 2022

    @sakthivel-axim
    Author

    yep , it's not in the openVSX extension gallery , so you cant install it directly. I downloaded the vsix from https://marketplace.visualstudio.com/items?itemName=ms-vscode.cpptools and chose the Download extensionoption in the right , then choose the right one for you you are on armhf ubuntu , so you should choose Linux arm32 , like this: IMG_20221123_171335

    then put it on your code-server and install, the way to install exis extensions are described in the code-server docs

    Also if you want i can provide my tasks.jsonandlaunch.json

    Debugging is working with help of this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingtriageThis issue needs to be triaged by a maintainer

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions