A lightweight logging utility for C++ applications.
- Four log levels: Info, Debug, Warning, Error
- Automatic stream routing (stdout for info/debug, stderror for warnings/errors)
- Caller, function, and msg context in every log message
- Debug logs compiled out in release builds (NDEBUG)
- Custom warning return value for permissible warnings
- C++17 or later
- CMake 3.20+
include(FetchContent)
FetchContent_Declare(starlet_logger
GIT_REPOSITORY https://github.com/masonlet/starlet-logger.git
GIT_TAG main
)
FetchContent_MakeAvailable(starlet_logger)
target_link_libraries(app_name PRIVATE starlet_logger)# 1. Clone starlet-logger
git clone https://github.com/masonlet/starlet-logger.git
cd starlet-logger
# 2. Create a build directory and generate build files
mkdir build
cd build
cmake -DBUILD_TESTS=ON ..
# 3. Build and run tests
cmake --build .
ctestMIT License - see LICENSE for details.