virtual/opencl: add dev-libs/opencl-icd-loader as alternative provider
authorMarek Szuba <marecki@gentoo.org>
Fri, 10 Apr 2020 13:15:21 +0000 (14:15 +0100)
committerMarek Szuba <marecki@gentoo.org>
Fri, 10 Apr 2020 13:15:21 +0000 (14:15 +0100)
Works perfectly well, with one caveat - /usr/lib*/libOpenCL.so* symlinks
created by eselect-opencl are not actually owned by that package so
switching from ocl-icd to opencl-icd-loader will result in file
collisions unless said symlinks are manually removed in advance.

Signed-off-by: Marek Szuba <marecki@gentoo.org>
virtual/opencl/opencl-3.ebuild

index 6268723a166f9af25e9c632f031c0d3283974a53..baa33caadb732f89137e281a0ce4e4442e4a92f5 100644 (file)
@@ -9,9 +9,8 @@ DESCRIPTION="Virtual for OpenCL API"
 SLOT="0"
 KEYWORDS="~amd64 ~x86"
 
-# Will add dev-libs/opencl-icd-loader here as an alternative once all potential
-# file collisions with eselect-opencl have been resolved
-RDEPEND="dev-libs/ocl-icd[khronos-headers,${MULTILIB_USEDEP}]"
+RDEPEND="|| ( dev-libs/ocl-icd[khronos-headers,${MULTILIB_USEDEP}]
+       dev-libs/opencl-icd-loader[${MULTILIB_USEDEP}] )"
 
 # so that src_install() doesn't fail on missing directory
 S="${WORKDIR}"