mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 17:09:10 -07:00
dev-libs/beignet: run "eselect opencl" in pkg_postinst()
Select ocl-icd if the relevant USE flag was set, self otherwise. In both cases use --use-old to honour possible earlier user-made choice. Package-Manager: Portage-2.3.49, Repoman-2.3.10
This commit is contained in:
@@ -25,16 +25,16 @@ else
|
||||
S=${WORKDIR}/Beignet-${PV}-Source
|
||||
fi
|
||||
|
||||
COMMON="media-libs/mesa[${MULTILIB_USEDEP}]
|
||||
COMMON="app-eselect/eselect-opencl
|
||||
media-libs/mesa[${MULTILIB_USEDEP}]
|
||||
<sys-devel/clang-6.0.9999:=[${MULTILIB_USEDEP}]
|
||||
>=x11-libs/libdrm-2.4.70[video_cards_intel,${MULTILIB_USEDEP}]
|
||||
x11-libs/libXext[${MULTILIB_USEDEP}]
|
||||
x11-libs/libXfixes[${MULTILIB_USEDEP}]"
|
||||
RDEPEND="${COMMON}
|
||||
app-eselect/eselect-opencl"
|
||||
x11-libs/libXfixes[${MULTILIB_USEDEP}]
|
||||
ocl-icd? ( dev-libs/ocl-icd )"
|
||||
RDEPEND="${COMMON}"
|
||||
DEPEND="${COMMON}
|
||||
${PYTHON_DEPS}
|
||||
ocl-icd? ( dev-libs/ocl-icd )
|
||||
virtual/pkgconfig"
|
||||
|
||||
LLVM_MAX_SLOT=6
|
||||
@@ -105,3 +105,11 @@ multilib_src_install() {
|
||||
dosym "lib/${PN}/libcl.so" "${VENDOR_DIR}"/libcl.so.1
|
||||
dosym "lib/${PN}/libcl.so" "${VENDOR_DIR}"/libcl.so
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
if use ocl-icd; then
|
||||
"${ROOT}"/usr/bin/eselect opencl set --use-old ocl-icd
|
||||
else
|
||||
"${ROOT}"/usr/bin/eselect opencl set --use-old beignet
|
||||
fi
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user