Before you begin
Install Git, CMake 3.12 or newer, and a C++17-compatible compiler. On Windows, use a Visual Studio C++ toolchain; on macOS or Linux, install the compiler toolchain for your distribution.
Check that the tools are available:
cmake --version
git --version
1. Clone the repository
Clone CoolBox with its tracked submodules so all required source repositories are checked out:
git clone --recurse-submodules https://github.com/MeanderingAI/CoolBox.git
cd CoolBox
2. Configure the build
From the repository root, configure a build directory and enable installation of the CMake package:
cmake -S . -B build -DCOOLBOX_INSTALL_PACKAGE=ON
CMake detects the available compiler and generates the build files for your platform.
3. Build CoolBox
Build the configured project. The --config option works with multi-configuration generators such as Visual Studio and is also accepted by common CMake generators:
cmake --build build --config Debug
4. Install the libraries and package
Choose an install prefix you can write to. For PowerShell, this installs under your user profile:
cmake --install build --config Debug --prefix "$HOME\CoolBoxInstall"
On macOS or Linux, you can use a folder under your home directory instead:
cmake --install build --config Debug --prefix "$HOME/.local/coolbox"
5. Link CoolBox from another CMake project
In a consumer project, find the installed package and link the targets you use. This is the documented pattern for the deep-learning library:
find_package(CoolBox CONFIG REQUIRED)
target_link_libraries(your_app PRIVATE CoolBox::deep_learning)
If CMake cannot locate the package, set CMAKE_PREFIX_PATH to the install prefix used above. See the CoolBox build instructions for the latest options and supported targets.