virtual/opencl: Only pull in media-libs/mesa on supported GPUs
virtual/opencl uses media-libs/mesa[opencl] as driver-independent
fallback OpenCL provider. However, media-libs/mesa[opencl] depends
on dev-libs/libclc - which at the time of me writing this only
supports nvidia, r600 and radeonsi, and whose REQUIRED_USE clause
requires at least one of the corresponding VIDEO_CARDS flags to be
set. This effectively breaks the OpenCL dependency cycle for a lot of
configurations, e.g. for VIDEO_CARDS="nouveau" systems.
Only try to use Mesa as an OpenCL provider when VIDEO_CARDS includes a
GPU supported by dev-libs/libclc.
Note that this means there is now no fallback OpenCL provider for
ABI_X86_32. Moreover, for ABI_X86_64 the fallback provider is now
dev-util/intel-ocl-sdk, which almost certainly doesn't work on AMD CPUs
- which however should be mostly harmless (the package should simply do
nothing beyond satisfying virtual/opencl dependencies), especially given
many OpenCL-aware applications ignore CPU-type devices anyway.
Closes: https://bugs.gentoo.org/710724
Signed-off-by: Marek Szuba <marecki@gentoo.org>