\page installation Installation guide
LogIt++ requires CMake 3.18 or newer and TimeShield 1.0.6 or newer. The core library and most built-in backends use C++11. OTLP, the Prometheus HTTP server, and MDBX integrations require C++17.
Use add_subdirectory() when LogIt++ is part of the source tree:
add_subdirectory(external/log-it-cpp)
target_link_libraries(my_app PRIVATE log-it-cpp::log-it-cpp)The directory name is arbitrary. If dependencies are supplied as sibling targets, define them before adding LogIt++.
git submodule add https://github.com/LimiNode/log-it-cpp.git external/log-it-cpp
git submodule update --init --recursiveThen use the vendored CMake flow above. The bundled TimeShield submodule is a
development fallback; package-manager builds may provide an installed
time_shield::time_shield target instead.
Build and install the package from a clean checkout:
cmake -S . -B build -DLOGIT_CPP_BUILD_TESTS=OFF
cmake --build build
cmake --install build --prefix ./installConsume it from another CMake project:
find_package(log-it-cpp CONFIG REQUIRED)
target_link_libraries(my_app PRIVATE log-it-cpp::log-it-cpp)Pass -DCMAKE_PREFIX_PATH=/path/to/install when configuring the consumer.
Enable only the features needed by the application. fmt, zlib, and zstd can
be provided as installed CMake packages or by bundled submodules with
LOGIT_USE_SUBMODULES=ON. LOGIT_WITH_OTLP=ON currently requires kurlyk for
both OTLP logger variants because the option controls the shared OTLP build.
MDBX requires mdbx-containers. Prometheus payload support has no extra
dependency; the Prometheus HTTP server uses Simple-Web-Server and Asio.
See the Backend matrix for standards, dependencies, and
platform restrictions. All CMake options are listed in the API reference.
Installed exports require optional dependencies to be available as installed
or imported targets. Bundled optional dependencies are intended for source and
build-tree development. LOGIT_WITH_PROMETHEUS_SERVER=ON is currently
rejected by cmake --install because its HTTP dependency tree is not exported
as part of the package.
The exported target is suitable for package-manager recipes that provide the required dependency targets before configuring LogIt++. For the repository's current vcpkg integration, follow the port and consumer checks in the CI workflow. Treat package-manager manifests as versioned integration metadata and verify them against the exact release tag being packaged.