cbase

https://alfred-jijo.github.io/docs/cbase/index.html

A high-performance, modern C project template designed to provide a clean, zero-dependency starting point for professional C development.

This template drags C into the modern era by providing “Quality of Life” features commonly found in languages like Odin, Zig, and Rust, such as string slices, exact-width types, and virtual memory arenas without sacrificing the raw speed and simplicity of standard C.

Features


Directory Structure

.
├── include/            # Public APIs and headers
│   ├── base/           # Core primitives (types, strings, macros, logging)
│   └── memory/         # Allocators (Arena and OS memory wrappers)
├── src/                # Implementation files and Application code
│   ├── base/           # Internal base implementations
│   ├── memory/         # OS-level memory implementations
│   └── main.c          # Application entry point
├── lib/                # (Optional) Drop external libraries here
├── test/               # Custom test harness and unit tests
├── docs/               # Doxygen generated documentation output
├── build/              # All build artifacts and binaries end up here
└── CMakeLists.txt      # Root build configuration

Getting Started

Clone the Template

Get this template to your local machine:

git clone https://gitlab.com/Alfred-Jijo/cbase.git my_project
cd my_project

Build the Project

This project uses CMake (Minimum v3.13) wrapped in convenient build scripts. You don’t need to manually invoke CMake.

(Note: The build scripts automatically handle creating the build/ directory, generating the CMake cache, and compiling the executable.)

Run the Application

The build scripts output the compiled binaries into the build/bin/ directory.

Run the Tests

To ensure the core systems are working correctly on your specific OS/Architecture, run the included test suite:


Roadmap

License

See the LICENSE file for details.