| 1 | = Tutorials = |
| 2 | |
| 3 | == Creating new component == |
| 4 | |
| 5 | Go to source directory ```src/_NewComponent```. |
| 6 | |
| 7 | {{{ |
| 8 | cd src |
| 9 | cd _NewComponent |
| 10 | }}} |
| 11 | |
| 12 | Run a script that will create a new component (batch file ```.bat``` / Unix script ```.sh```) with one argument -- component name. |
| 13 | |
| 14 | {{{ |
| 15 | NewComponent.bat MyComponentName |
| 16 | }}} |
| 17 | or |
| 18 | {{{ |
| 19 | ./NewComponent.sh MyComponentName |
| 20 | }}} |
| 21 | |
| 22 | It will use CMake to create a new component (it can take some time when used for the first time). |
| 23 | Component files will be added to ```src/MyComponentName```. |
| 24 | |
| 25 | In order to add this component to the project, just add this line to ```src/CMakeLists.txt```. |
| 26 | {{{ |
| 27 | add_directory(MyComponentName) |
| 28 | }}} |