From 0d3c717b69cc1f612070f99cfb923cc713819639 Mon Sep 17 00:00:00 2001 From: Fabian Groffen Date: Tue, 2 Jan 2018 14:24:28 +0100 Subject: [PATCH] sys-libs/compiler-rt-sanitizers: prefer compiler from prefix on Darwin Patch by Michael Weiser Bug: https://bugs.gentoo.org/642644 Package-Manager: Portage-2.3.13, Repoman-2.3.3 --- .../compiler-rt-sanitizers-5.0.1.ebuild | 9 ++++++++- .../compiler-rt-sanitizers-9999.ebuild | 9 ++++++++- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-5.0.1.ebuild b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-5.0.1.ebuild index b57277b9fbe5..439a8e639d61 100644 --- a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-5.0.1.ebuild +++ b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-5.0.1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -101,6 +101,13 @@ src_configure() { strip-unsupported-flags fi + if use prefix && [[ "${CHOST}" == *-darwin* ]] ; then + mycmakeargs+=( + # disable use of SDK for the system itself + -DDARWIN_macosx_CACHED_SYSROOT=/ + ) + fi + cmake-utils_src_configure if use test; then diff --git a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-9999.ebuild b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-9999.ebuild index d13c7b67d32f..ca1b11003293 100644 --- a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-9999.ebuild +++ b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-9999.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -110,6 +110,13 @@ src_configure() { strip-unsupported-flags fi + if use prefix && [[ "${CHOST}" == *-darwin* ]] ; then + mycmakeargs+=( + # disable use of SDK for the system itself + -DDARWIN_macosx_CACHED_SYSROOT=/ + ) + fi + cmake-utils_src_configure if use test; then -- 2.26.2