thetek 2d4a7ec4ec | ||
---|---|---|
build | ||
inc | ||
src | ||
test | ||
.ccls | ||
.clang-format | ||
.gitignore | ||
LICENSE | ||
README.md |
README.md
C Template
A template for C programs. Its features include:
- Sane defaults (especially compiler flags)
- A custom build system written in Python
- Simple custom testing framework
- Formatting using
clang-format
- Common functions and typedefs included
- Simple logging library
Usage
# debug build
build/build.py
build/build.py debug
# release build
build/build.py release
# run tests
build/build.py test
# format source files
build/build.py fmt
# clean build files
build/build.py clean
By default, source files are located in src/
, header files are located in
inc/
and anything used for testing goes in test/
.
Compiler options, source folders and the target binary name can be changed in
build/config.py
.