boostorg / boost

Super-project for modularized Boost
https://github.com/boostorg/wiki/wiki/Getting-Started%3A-Overview
Boost Software License 1.0
7.03k stars 1.73k forks source link

[question] I cannot use boost from Conan on WSL #940

Open markspacehub opened 1 month ago

markspacehub commented 1 month ago

I am trying to use Boost's dynamic_bitset class, my project currently uses Conan to get its dependencies and CMake to build. I added Boost to Conan's requires and then I used CMake to find_package(Boost REQUIRED) and target_link_libraries(MyProject PRIVATE boost::boost). When I call conan install . it installs boost and then when I configure with CMake, it finds boost with all the header files etc.

When I build the project however, there is a chain of linked header files that ends with #include <boost/compute/cl/hpp>. This in turn tries to #include <CL/cl.h> which does not exist on my system, I can try and force define APPLE to try and #include <OpenCL/cl.h> instead, but again it doesnt appear to exist for me.

I am using WSL (v2.2.4) Ubuntu (v 24.04) to both build and run the application.

Why can I not find cl.h, why do I need it and what can I do to fix this?

Thanks :)

mclow commented 1 month ago

You will probably get more responses if you post this to the boost-users mailing list. You can subscribe here: https://lists.boost.org/mailman/listinfo.cgi/boost-users