docs: Add docs/ folder with in depth topics as well as DoxygenLayout.xml file
[contrib/mraa.git] / docs / building.md
1 Building libmaa                         {#building}
2 ===============
3
4 libmaa uses cmake in order to make compilation relatively painless. Cmake runs
5 build out of tree so the recommended way is to clone from git and make a build/ directory.
6
7 ~~~~~~~~~~~~~{.sh}
8 mkdir build
9 cd build
10 cmake ..
11 make
12 ~~~~~~~~~~~~~
13
14 Our cmake configure has a number of options, `cmake -i` will ask you all sorts
15 of interesting questions, you can disable swig modules, build documentation
16 etc...
17
18 Few recommended options:
19 Changing install path from /usr/local to /usr
20 -DCMAKE_INSTALL_PREFIX:PATH=/usr
21
22 Building debug build:
23 -DCMAKE_BUILD_TYPE=DEBUG
24
25 Using clang instead of gcc:
26  -DCMAKE_C_COMPILER=/usr/bin/clang -DCMAKE_CXX_COMPILER=/usr/bin/clang
27