Building in Docker with CLion

Personal Notes

Patricia Aas, 22 August 2019

This workflow was inspired by the Windows Subsystem for Linux (WSL) workflow described by Jetbrains here.

The idea is to be able to develop for Linux in CLion on Windows and Mac aswell. For Windows the WSL is preferable because it’s faster and has a lot of support. On Mac there isn’t a similar native Linux solution. The idea was to use a Docker container as a Remote Host following this Jetbrans article.

To do this we need a suitable Docker image, this one has currently only been tested on Linux, but seems to work: Dockerfile.

Do use it you have to run the container - there are some comments in the Dockerfile on how. Then set up CLion using the Remote Host tutorial.