From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1181093-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 6CE551382C5
	for <garchives@archives.gentoo.org>; Sat, 20 Jun 2020 16:34:21 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 59443E0936;
	Sat, 20 Jun 2020 16:34:17 +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 B4B6FE0928
	for <gentoo-commits@lists.gentoo.org>; Sat, 20 Jun 2020 16:34:16 +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 457FF34F3C6
	for <gentoo-commits@lists.gentoo.org>; Sat, 20 Jun 2020 16:34:15 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id E70312C3
	for <gentoo-commits@lists.gentoo.org>; Sat, 20 Jun 2020 16:34:10 +0000 (UTC)
From: "Michał Górny" <mgorny@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, "Michał Górny" <mgorny@gentoo.org>
Message-ID: <1592670775.b18dd9cc1373f55bfcfcb0d323c4ca56a02b1db9.mgorny@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-libs/libcxx/
X-VCS-Repository: repo/gentoo
X-VCS-Files: sys-libs/libcxx/libcxx-10.0.1.9999.ebuild sys-libs/libcxx/libcxx-10.0.1_rc1.ebuild sys-libs/libcxx/libcxx-11.0.0.9999.ebuild
X-VCS-Directories: sys-libs/libcxx/
X-VCS-Committer: mgorny
X-VCS-Committer-Name: Michał Górny
X-VCS-Revision: b18dd9cc1373f55bfcfcb0d323c4ca56a02b1db9
X-VCS-Branch: master
Date: Sat, 20 Jun 2020 16:34:10 +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: dad3d629-f64d-4b31-b422-10796b0eaee9
X-Archives-Hash: ccb58eeb544f6d340c8880255e313e6b

commit:     b18dd9cc1373f55bfcfcb0d323c4ca56a02b1db9
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Sat Jun 20 16:24:09 2020 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Sat Jun 20 16:32:55 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b18dd9cc

sys-libs/libcxx: Apply patches in WORKDIR in 10.0.1+

Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 sys-libs/libcxx/libcxx-10.0.1.9999.ebuild | 17 +++++++++++------
 sys-libs/libcxx/libcxx-10.0.1_rc1.ebuild  | 17 +++++++++++------
 sys-libs/libcxx/libcxx-11.0.0.9999.ebuild | 17 +++++++++++------
 3 files changed, 33 insertions(+), 18 deletions(-)

diff --git a/sys-libs/libcxx/libcxx-10.0.1.9999.ebuild b/sys-libs/libcxx/libcxx-10.0.1.9999.ebuild
index 6e1bba971a9..8e1fa4f0419 100644
--- a/sys-libs/libcxx/libcxx-10.0.1.9999.ebuild
+++ b/sys-libs/libcxx/libcxx-10.0.1.9999.ebuild
@@ -33,12 +33,6 @@ BDEPEND="
 
 DOCS=( CREDITS.TXT )
 
-PATCHES=(
-	# Add link flag "-Wl,-z,defs" to avoid underlinking; this is needed in a
-	# out-of-tree build.
-	"${FILESDIR}/${PN}-3.9-cmake-link-flags.patch"
-)
-
 # least intrusive of all
 CMAKE_BUILD_TYPE=RelWithDebInfo
 
@@ -58,6 +52,17 @@ pkg_setup() {
 	fi
 }
 
+src_prepare() {
+	# Add link flag "-Wl,-z,defs" to avoid underlinking; this is needed in a
+	# out-of-tree build.
+	eapply "${FILESDIR}/${PN}-3.9-cmake-link-flags.patch"
+
+	# cmake eclasses suck by forcing ${S} here
+	CMAKE_USE_DIR=${S} \
+	S=${WORKDIR} \
+	cmake-utils_src_prepare
+}
+
 test_compiler() {
 	$(tc-getCXX) ${CXXFLAGS} ${LDFLAGS} "${@}" -o /dev/null -x c++ - \
 		<<<'int main() { return 0; }' &>/dev/null

diff --git a/sys-libs/libcxx/libcxx-10.0.1_rc1.ebuild b/sys-libs/libcxx/libcxx-10.0.1_rc1.ebuild
index 6e1bba971a9..8e1fa4f0419 100644
--- a/sys-libs/libcxx/libcxx-10.0.1_rc1.ebuild
+++ b/sys-libs/libcxx/libcxx-10.0.1_rc1.ebuild
@@ -33,12 +33,6 @@ BDEPEND="
 
 DOCS=( CREDITS.TXT )
 
-PATCHES=(
-	# Add link flag "-Wl,-z,defs" to avoid underlinking; this is needed in a
-	# out-of-tree build.
-	"${FILESDIR}/${PN}-3.9-cmake-link-flags.patch"
-)
-
 # least intrusive of all
 CMAKE_BUILD_TYPE=RelWithDebInfo
 
@@ -58,6 +52,17 @@ pkg_setup() {
 	fi
 }
 
+src_prepare() {
+	# Add link flag "-Wl,-z,defs" to avoid underlinking; this is needed in a
+	# out-of-tree build.
+	eapply "${FILESDIR}/${PN}-3.9-cmake-link-flags.patch"
+
+	# cmake eclasses suck by forcing ${S} here
+	CMAKE_USE_DIR=${S} \
+	S=${WORKDIR} \
+	cmake-utils_src_prepare
+}
+
 test_compiler() {
 	$(tc-getCXX) ${CXXFLAGS} ${LDFLAGS} "${@}" -o /dev/null -x c++ - \
 		<<<'int main() { return 0; }' &>/dev/null

diff --git a/sys-libs/libcxx/libcxx-11.0.0.9999.ebuild b/sys-libs/libcxx/libcxx-11.0.0.9999.ebuild
index c8f3b48d30c..a06bb57dd7b 100644
--- a/sys-libs/libcxx/libcxx-11.0.0.9999.ebuild
+++ b/sys-libs/libcxx/libcxx-11.0.0.9999.ebuild
@@ -34,12 +34,6 @@ BDEPEND="
 
 DOCS=( CREDITS.TXT )
 
-PATCHES=(
-	# Add link flag "-Wl,-z,defs" to avoid underlinking; this is needed in a
-	# out-of-tree build.
-	"${FILESDIR}/${PN}-3.9-cmake-link-flags.patch"
-)
-
 # least intrusive of all
 CMAKE_BUILD_TYPE=RelWithDebInfo
 
@@ -59,6 +53,17 @@ pkg_setup() {
 	fi
 }
 
+src_prepare() {
+	# Add link flag "-Wl,-z,defs" to avoid underlinking; this is needed in a
+	# out-of-tree build.
+	eapply "${FILESDIR}/${PN}-3.9-cmake-link-flags.patch"
+
+	# cmake eclasses suck by forcing ${S} here
+	CMAKE_USE_DIR=${S} \
+	S=${WORKDIR} \
+	cmake-utils_src_prepare
+}
+
 test_compiler() {
 	$(tc-getCXX) ${CXXFLAGS} ${LDFLAGS} "${@}" -o /dev/null -x c++ - \
 		<<<'int main() { return 0; }' &>/dev/null