From 776fdcf77a764999697c5bc838d2d82a9c00de68 Mon Sep 17 00:00:00 2001 From: Waldir Pimenta Date: Thu, 4 May 2017 00:18:57 +0100 Subject: [PATCH] cmake: fix syntax and adjust per code review --- pages/common/cmake.md | 24 +++++++----------------- 1 file changed, 7 insertions(+), 17 deletions(-) diff --git a/pages/common/cmake.md b/pages/common/cmake.md index 7aab4735a..c4e511f48 100644 --- a/pages/common/cmake.md +++ b/pages/common/cmake.md @@ -1,26 +1,16 @@ # cmake -> CMake is a cross-platform build system generator. +> Cross-platform build system generator. +> It generates Makefiles, Visual Studio projects or others, depending on the target system. -Make a project in the same directory as the source: +- Generate a Makefile and use it to compile a project in the same directory as the source: -``` -cmake -make -``` +`cmake && make` -Make a project in a subdirectory, required for some projects: +- Generate a Makefule and use it to compile a project in a separate directory (out-of-source build): -``` -mkdir build -cd build -cmake ../ -make -``` +`cd {{build_dir}} && cmake ../ && make` -To run cmake in interactive mode (It will ask you for each variable, -instead of relying on defaults): +- Run cmake in interactive mode (it will ask for each variable, instead of using defaults): `cmake -i` - -