From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1160458-garchives=archives.gentoo.org@lists.gentoo.org>
Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	by finch.gentoo.org (Postfix) with ESMTPS id EA104138351
	for <garchives@archives.gentoo.org>; Fri, 10 Apr 2020 23:27:54 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id EA86DE0B1A;
	Fri, 10 Apr 2020 23:27:53 +0000 (UTC)
Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id BA8EAE0B1A
	for <gentoo-commits@lists.gentoo.org>; Fri, 10 Apr 2020 23:27:53 +0000 (UTC)
Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by smtp.gentoo.org (Postfix) with ESMTPS id 5E27D34EF26
	for <gentoo-commits@lists.gentoo.org>; Fri, 10 Apr 2020 23:27:52 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id F3D801CF
	for <gentoo-commits@lists.gentoo.org>; Fri, 10 Apr 2020 23:27:49 +0000 (UTC)
From: "Marek Szuba" <marecki@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Marek Szuba" <marecki@gentoo.org>
Message-ID: <1586561113.780818b4b055f8c41d253e71cd9641322776e7a4.marecki@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/ocl-icd/
X-VCS-Repository: repo/gentoo
X-VCS-Files: dev-libs/ocl-icd/ocl-icd-2.2.12-r3.ebuild
X-VCS-Directories: dev-libs/ocl-icd/
X-VCS-Committer: marecki
X-VCS-Committer-Name: Marek Szuba
X-VCS-Revision: 780818b4b055f8c41d253e71cd9641322776e7a4
X-VCS-Branch: master
Date: Fri, 10 Apr 2020 23:27:49 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
X-Archives-Salt: 3449af24-bb92-4e98-823a-260705ea1d20
X-Archives-Hash: 6a70536d73e919a328157e9283a305f3

commit:     780818b4b055f8c41d253e71cd9641322776e7a4
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Fri Apr 10 23:13:10 2020 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Fri Apr 10 23:25:13 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=780818b4

dev-libs/ocl-icd: use dev-util/opencl-headers instead of bundled ones

Builds just fine against these, which is not surprising given both sets
are official Khronos Group OpenCL 2.2 headers - the only difference
being the bundled ones are legacy and the separately packaged ones are
unified. Furthermore, without having to worry about file collisions in
/usr/include/CL, it will become possible for packages depending on
unified headers (e.g. dev-libs/intel-neo, which too uses a bundled copy
for now) to use dev-util/opencl-headers regardless of which ICD loader
provides the library. Last but not least, one bundling less to worry
about!

Note that this change makes USE=khronos-headers redundant, that said we
keep it in IUSE - at least for now anyway - so that ebuilds explicitly
requesting this USE flag needn't be modified.

No revbump because the first commit introducing -r3 has at the time of
me writing this not had been pushed to Gentoo servers yet.

Committed directly due to prolonged absence of the maintainer.

Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 dev-libs/ocl-icd/ocl-icd-2.2.12-r3.ebuild | 18 ++++++++++--------
 1 file changed, 10 insertions(+), 8 deletions(-)

diff --git a/dev-libs/ocl-icd/ocl-icd-2.2.12-r3.ebuild b/dev-libs/ocl-icd/ocl-icd-2.2.12-r3.ebuild
index 783021a439e..980cac2e750 100644
--- a/dev-libs/ocl-icd/ocl-icd-2.2.12-r3.ebuild
+++ b/dev-libs/ocl-icd/ocl-icd-2.2.12-r3.ebuild
@@ -13,10 +13,16 @@ LICENSE="BSD-2"
 SLOT="0"
 KEYWORDS="~amd64 ~x86"
 
+# Does nothing now but by keeping it here we avoid having to have virtual/opencl
+# handle ebuilds both with and without this flag.
 IUSE="+khronos-headers"
 
 BDEPEND="${RUBY_DEPS}"
-RDEPEND="!app-eselect/eselect-opencl
+DEPEND="dev-util/opencl-headers"
+# nvidia-drivers block is hopefully temporary, until it has ceased
+# to depend on eselect-opencl
+RDEPEND="${DEPEND}
+	!app-eselect/eselect-opencl
 	!dev-libs/opencl-icd-loader
 	!x11-drivers/nvidia-drivers"
 
@@ -30,7 +36,9 @@ src_prepare() {
 }
 
 multilib_src_configure() {
-	ECONF_SOURCE="${S}" econf --enable-pthread-once
+	# dev-util/opencl-headers ARE official Khronos Group headers, what this option
+	# does is disable the use of the bundled ones
+	ECONF_SOURCE="${S}" econf --enable-pthread-once --disable-official-khronos-headers
 }
 
 multilib_src_install() {
@@ -38,10 +46,4 @@ multilib_src_install() {
 
 	# Drop .la files
 	find "${ED}" -name '*.la' -delete || die
-
-	# Install vendor headers
-	if use khronos-headers; then
-		insinto /usr/include
-		doins -r "${S}/khronos-headers/CL"
-	fi
 }