diff options
author | Jacob Floyd <cognifloyd@gmail.com> | 2020-12-18 18:53:24 -0600 |
---|---|---|
committer | Fabian Groffen <grobian@gentoo.org> | 2020-12-27 10:49:32 +0100 |
commit | 1b2b62e093d789f6b1a4609c866581991e287b88 (patch) | |
tree | d003ed70504bf2dc50ab5c5d36bc64622329f443 /sys-devel/clang/clang-11.0.0.ebuild | |
parent | sys-libs/libcxx: fix prefix bootstrap (diff) | |
download | gentoo-1b2b62e093d789f6b1a4609c866581991e287b88.tar.gz gentoo-1b2b62e093d789f6b1a4609c866581991e287b88.tar.bz2 gentoo-1b2b62e093d789f6b1a4609c866581991e287b88.zip |
sys-devel/clang: fix bootstrap on darwin prefix
Adjust the clang internal header/framework search paths when building on
darwin prefix. We symlink the selected MacOSX.sdk to EPREFIX/MacOSX.sdk
during bootstrap, so that is the correct place to get system headers,
such as those for libc, or for system framework headers, that we do not
replace in prefix.
Bug: https://bugs.gentoo.org/758167
Signed-off-by: Jacob Floyd <cognifloyd@gmail.com>
Signed-off-by: Fabian Groffen <grobian@gentoo.org>
Diffstat (limited to 'sys-devel/clang/clang-11.0.0.ebuild')
-rw-r--r-- | sys-devel/clang/clang-11.0.0.ebuild | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/sys-devel/clang/clang-11.0.0.ebuild b/sys-devel/clang/clang-11.0.0.ebuild index cf0dde1f1604..1d4f4bad16c9 100644 --- a/sys-devel/clang/clang-11.0.0.ebuild +++ b/sys-devel/clang/clang-11.0.0.ebuild @@ -5,7 +5,7 @@ EAPI=7 PYTHON_COMPAT=( python3_{6..9} ) inherit cmake llvm llvm.org multilib-minimal pax-utils \ - python-single-r1 toolchain-funcs + prefix python-single-r1 toolchain-funcs DESCRIPTION="C language family frontend for LLVM" HOMEPAGE="https://llvm.org/" @@ -30,7 +30,7 @@ ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" ) LICENSE="Apache-2.0-with-LLVM-exceptions UoI-NCSA MIT" SLOT="$(ver_cut 1)" -KEYWORDS="amd64 arm arm64 ppc64 ~riscv x86 ~amd64-linux" +KEYWORDS="amd64 arm arm64 ppc64 ~riscv x86 ~amd64-linux ~x64-macos" IUSE="debug default-compiler-rt default-libcxx default-lld doc +static-analyzer test xml kernel_FreeBSD ${ALL_LLVM_TARGETS[*]}" REQUIRED_USE="${PYTHON_REQUIRED_USE} @@ -75,6 +75,10 @@ PDEPEND=" # Therefore: use sys-devel/clang[${MULTILIB_USEDEP}] only if you need # multilib clang* libraries (not runtime, not wrappers). +PATCHES=( + "${FILESDIR}"/9999/prefix-dirs.patch +) + pkg_setup() { LLVM_MAX_SLOT=${SLOT} llvm_pkg_setup python-single-r1_pkg_setup @@ -88,6 +92,11 @@ src_prepare() { llvm.org_src_prepare mv ../clang-tools-extra tools/extra || die + + # add Gentoo Portage Prefix for Darwin (see prefix-dirs.patch) + eprefixify \ + lib/Frontend/InitHeaderSearch.cpp \ + lib/Driver/ToolChains/Darwin.cpp || die } check_distribution_components() { |