CLion
 
Get CLion
Join the CLion 2025.1 Early Access Program and try out new features before they are released! Find out more

Complicated remote scenarios

Last modified: 26 May 2024

This article gives general recommendations for the case when you need to build a CMake or Makefile application on a remote system and then debug it on another remote system:

  • CLion is running locally (is referred below as local machine)

  • build is performed remotely inside a Docker container or another system (build machine)

  • the application is launched on an embedded device or yet another system (target machine)

Now when you launch that Remote GDB Server configuration, the following sequence of steps will be performed:

  1. Your project will be built on the build machine using the Remote/Docker toolchain.

  2. In the case of Docker, the binary will be copied locally. Otherwise, it will be downloaded to the local system by the external tool.

  3. The binary will be then uploaded to the target machine and launched under gdbserver.

  4. CLion debugger (which you configured to be the GDB from your build machine) will connect to the gdbserver on the target machine.