Creates a CMake project structure for a C project. A script i've been using for some projects of mine.
Argument | Short | Explanation |
---|---|---|
--name | -n | The name of the project. (e.g.: "my_project") |
--cmake | -c | The CMake version to use. (e.g.: "2.8") |
--lib | Optional argument for building a library project instead of an exectuable. | |
--help | -h | Prints help text. |
>py create_c_project.py --name"name" --cmake"3.2" --lib
This creates a the following structure where name
is the project name:
name
+--name
| +--include
| | +--name
| | +--name.h
| |
| +--src
| | +--name.c
| |
| +--CMakeLists.txt
|
+--test
| +--include
| +--src
| | +--main.c
| |
| +--CMakeLists.txt
|
+--CMakeLists.txt
>py create_c_project.py --name"name" --cmake"3.2"
This creates a the following structure where name
is the project name:
name
+--include
+--src
| +--main.c
|
+--CMakeLists.txt
MIT License: see License for more information.