1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-04-29 23:24:55 +02:00
tldr/pages/common/cmake.md
2017-05-04 08:46:54 +01:00

16 lines
499 B
Markdown

# cmake
> Cross-platform build system generator.
> It generates Makefiles, Visual Studio projects or others, depending on the target system.
- Generate a Makefile and use it to compile a project in the same directory as the source:
`cmake && make`
- Generate a Makefule and use it to compile a project in a separate directory (out-of-source build):
`cd {{build_dir}} && cmake ../ && make`
- Run cmake in interactive mode (it will ask for each variable, instead of using defaults):
`cmake -i`