summaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorItamar <itamar8910@gmail.com>2021-02-26 15:37:48 +0200
committerAndreas Kling <kling@serenityos.org>2021-02-26 14:43:26 +0100
commit780e84f2e10fac4c7aefa43232068165c9bc967f (patch)
tree61c62ac70616d34c67ca04d8ae06a3ee04d3694e /Documentation
parent1e737a5c50837a9746bcbf8762f9f45caa332787 (diff)
downloadserenity-780e84f2e10fac4c7aefa43232068165c9bc967f.zip
Documentation: Update CLion configuration documentation
Closes #5512
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/CLionConfiguration.md33
1 files changed, 5 insertions, 28 deletions
diff --git a/Documentation/CLionConfiguration.md b/Documentation/CLionConfiguration.md
index 6210db31d7..667c1cd0e2 100644
--- a/Documentation/CLionConfiguration.md
+++ b/Documentation/CLionConfiguration.md
@@ -1,36 +1,13 @@
## CLion Project Configuration
-Configuring CLion for development requires a CMakeLists.txt file.
-The one provided in Meta/CLion packs the bare minimum configuration required for code completion and basic error checking.
-This is not necessarily the best setup, there could be better ways to configure the IDE.
-Below instructions are intended for people not familiar with CMake, or who don't want to get bothered setting up the IDE first.
+CLion can integrate with CMake to provide code comprehension features.
-It's assumed that a directory named `serenity` contains all your source files.
-If you cloned the repository directly from GitHub, this is the directory that git creates to copy sources.
+After opening the `serenity` repository in CLion as a new project, go to "`File->Settings->Build, Execution, Deployment->Cmake`",
+and set the following fields: (Assuming you use `Ninja` as the build system and configured the CMake build directory to `Build`)
-- Create the project directory and cd to it: `mkdir serenity-project && cd serenity-project`
-- Move `serenity` to the project directory: `mv <path/to/serenity> .`
-- Copy CMake file to project directory: `cp serenity/Meta/CLion/CMakeLists.txt .`
-- Create new CMake project in IDE: `File->New CMake Project from Sources`
-- In the file selection dialog, find and select `serenity-project`, then click OK.
+`CMake Options`: `-G Ninja -DBUILD_LAGOM=ON -DCMAKE_C_COMPILER=gcc-10 -DCMAKE_CXX_COMPILER=g++-10`
-The project will start loading.
-Building the index for the first time takes a while. Let it finish the first scan.
-
-## Notes
-
-**Note:** If you have created the project after building the toolchain, you may get errors on `make install` after moving `serenity` to the project directory.
-If you move `serenity` out to its original location, the build will succeed again.
-It is recommended that you create a script that merely moves `serenity` before attempting to rebuild and once the build finishes, moves `serenity` back to the project directory.
-Also during the build, be careful not to switch to the IDE window.
-Doing so will cause CLion to panic because the `serenity` directory has suddenly disappeared.
-CLion will try to delete indexes and when the build finishes and `serenity` is moved back to the project directory, indexes will be built again. This is a waste of time.
-In order to completely eliminate the rebuilding of indexes, you have to rebuild everything (toolchain included) from scratch while `serenity` resides in the project directory.
-
-**Note:** Don't create a new git repo in `serenity-project`.
-The whole point of wrapping the sources to a new directory is to keep the project files away from the main git repository.
-
-**Note:** If you don't want the workspace to list files ending with certain extensions, go to `File->Settings->Editor->File Types` and add entries to the `Ignore files and folders` field.
+`Build Directory`: `Build`
## Notes for WSL Users