That's what we really need to link the CUDA plugin against,
not the CUDA runtime API in CUDA_LIBRARIES! While the latter
comes with the CUDA SDK, the Driver API is installed with
the kernel driver and there is at most one per system. As
fallback we can use the stubs library distributed with the
CUDA SDK for linking.
Details
Details
Diff Detail
Diff Detail
Event Timeline
Comment Actions
You may want to consider linking with <CUDA>/lib64/stubs/libcuda.so. This way you don't really care whether nvidia's driver is installed on the system you compile on and all you need for compilation is a CUDA installation. At runtime dynamic linker will pick the real libcuda.so from wherever it's installed.
So LIBOMPTARGET_DEP_CUDA_LIBRARIES is no longer a dependency we care about. It can be removed.