Giter Site home page Giter Site logo

cmakedebugplugin's Introduction

CMakeDebugPlugin

Environment Setup for source build

  1. Install jdk, add to path, set $JAVA_HOME env var
  2. Download gradle binaries, add to path
  3. Run gradle build, observe success
  4. Run gradle runIdea to launch a sand box Intellij IDE

Get pre-built binaries

They are available here

Installation from zip

Go into 'Settings' -> 'Plugins' -> 'Install plugin from disk...' and find the plugin zip file. This will require a restart of the IDE.

Get a version of CMake with the debugger feature

You can get binaries here. You can build from source from here. The plugin requires a version of CMake with the debugger integrated to work.

Usage

After installation, go into 'Edit Configurations', click the '+' button in the top left and add the 'CMake' application type (you might have to click to show more options in the dropdown).

On the configuration panel, only modify the port if you have a conflict with something else running on your system.

Modify the 'CMake Installation' option to point to a version of CMake with the integrated debugger.

You can set the build and source directory to wherever the project you want to build is. If you leave them empty, you'll get reasonable defaults -- the source directory will be the project root, and the build directory will be a build folder hanging off of that folder.

After that, select your newly configured configuration and hit the normal 'debug' button. This should start into the normal debug mode. Note that the plugin also gives you the ability to set breakpoints in CMake files.

'Add watch' can be used to display variables like in most other languages -- so CMAKE_GENERATOR would show you the current generator. You can also put a string into the watch to have it evaluate the string as CMAKE would. So if you added "${CMAKE_GENERATOR} ${CMAKE_CURRENT_SOURCE_DIR}" it would evaluate that as if you sent it to MESSAGE. This can be arbitrarily nested; basically anything you can put in MESSAGE should show up here.

cmakedebugplugin's People

Contributors

jdavidberger avatar avantgardnerio avatar

Stargazers

Aliaksandr Dubrouski avatar Dan LaManna avatar  avatar

Watchers

James Cloos avatar  avatar  avatar  avatar

cmakedebugplugin's Issues

Doesn't build for Idea/CLion 2017.3.

gradle build fails:

:compileKotline: /home/juraj/CMakeDebugPlugin/src/main/kotlin/com/radix/cmake/xdebug/CMakeDebugProcessHost.kt: (105, 1): Class 'CMakeDebugProcessHost' must be declared abstract or implement 
   abstract member public abstract fun processWillTerminate(@NotNull p0: ProcessEvent, p1: Boolean): 
   Unit defined in com.intellij.execution.process.ProcessListener
e: /home/juraj/CMakeDebugPlugin/src/main/kotlin/com/radix/cmake/xdebug/CMakeDebugProcessHost.kt: (109, 5): 
   'processWillTerminate' overrides nothing
e: /home/juraj/CMakeDebugPlugin/src/main/kotlin/com/radix/cmake/xdebug/CMakeDebugProcessHost.kt: (113, 5): 
   'startNotified' overrides nothing
e: /home/juraj/CMakeDebugPlugin/src/main/kotlin/com/radix/cmake/xdebug/CMakeDebugProcessHost.kt: (151, 5): 
   'processTerminated' overrides nothing
 FAILED

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.