From a47dff77f7397d249809bc6ba26f66e9b4df9887 Mon Sep 17 00:00:00 2001 From: Connor Date: Tue, 24 Feb 2026 20:14:54 +0900 Subject: [PATCH] opencl to cmakelist --- CMakeLists.txt | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 318616d..6a33b4a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -98,6 +98,20 @@ FetchContent_Declare( FetchContent_MakeAvailable(flecs doctest glm nlohmann_json glfw imgui imnodes FastNoiseLite) +# ---- OpenCL (GPU compute backend) ------------------------------------------- + +find_package(OpenCL REQUIRED) + +# opencl-clhpp: official Khronos C++ bindings (header-only) +FetchContent_Declare( + opencl_clhpp + GIT_REPOSITORY https://github.com/KhronosGroup/OpenCL-CLHPP.git + GIT_TAG v2024.10.24 + GIT_SHALLOW TRUE +) + +FetchContent_MakeAvailable(opencl_clhpp) + # ---- Core library ------------------------------------------------------------ set(SOURCES