diff --git a/CMakeLists.txt b/CMakeLists.txt index 3f81fa8..f3c6791 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -87,9 +87,11 @@ if (NOT MSVC) set(tiny_bvh_speedtest_cxx_flags ${common_cxx_flags}) set(tiny_bvh_speedtest_link_flags ${common_link_flags}) + # OpenCL headers + if (NOT APPLE AND NOT EMSCRIPTEN) - set(tiny_bvh_speedtest_cxx_flags ${tiny_bvh_speedtest_cxx_flags} -fopenmp) - set(tiny_bvh_speedtest_link_flags ${tiny_bvh_speedtest_link_flags} -fopenmp) + set(tiny_bvh_speedtest_cxx_flags ${tiny_bvh_speedtest_cxx_flags} -fopenmp -Iexternal/OpenCL/inc) + set(tiny_bvh_speedtest_link_flags ${tiny_bvh_speedtest_link_flags} -fopenmp -Lexternal/OpenCL/lib) elseif (EMSCRIPTEN) # Embed Sponza into the wasm to load it (in theory there are other methods, but this is the simplest) # See https://emscripten.org/docs/porting/files/packaging_files.html#modifying-file-locations-in-the-virtual-file-system