CLion 2016.3 Help

Creating New CMake Project

To create a new project

  1. If no project is currently opened in CLion, click New Project on the Welcome screen. Otherwise, select File | New Project on the main menu.
  2. In the New Project dialog box that opens, you can select a target type of your project (executable or library) as well as a language to be used: pure C or C++. Note, that while creating a project, CLion will generate a CMakeLists.txt file for you, that includes all the setting provided earlier in the dialog

Example

As an example, let's create a simple project. Let it be a simple shared library assuming C++ standard 14.
  1. On the left pane under C++ title, choose C++ library.
  2. On the right pane, click the Language standard control and select the desired standard from the drop down list, C++14 for our case.
  3. Go to the Library type control of the right pane and select the desired type. For us that is Shared
  4. Click Create button to create a project following the settings that you have provided and generate the respective CMakeLists.txt file.
    /help/img/idea/2016.3/cl_NewProjectDialog.png
  5. Upon the system prompt, tell CLion where to open your project: in the current or new window.
  6. And at last, let's see the CMakeLists.txt file that CLion had prepared for you:
    /help/img/idea/2016.3/cl_NewProjectCMake.png

See Also

Concepts:

External Links:

Last modified: 29 March 2017