diff options
author | Georgy Yakovlev <gyakovlev@gentoo.org> | 2019-03-21 15:49:31 -0700 |
---|---|---|
committer | Georgy Yakovlev <gyakovlev@gentoo.org> | 2019-03-21 21:27:48 -0700 |
commit | 8d3572f4171ba4ad6b0ecd03711b0b52d975bd6c (patch) | |
tree | 427e06d202a688938e0e4846b9f89d7663ba8532 /dev-lang | |
parent | www-client/chromium: bump to 73.0.3683.86 (diff) | |
download | gentoo-8d3572f4171ba4ad6b0ecd03711b0b52d975bd6c.tar.gz gentoo-8d3572f4171ba4ad6b0ecd03711b0b52d975bd6c.tar.bz2 gentoo-8d3572f4171ba4ad6b0ecd03711b0b52d975bd6c.zip |
dev-lang/rust: 1.33.0 requires llvm:7 to build
improve llvm handling for future use, taken from mesa ebuild
make sure 1.33 pulls only llvm:7
Bug: https://bugs.gentoo.org/681108
Package-Manager: Portage-2.3.62, Repoman-2.3.12
Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org>
Diffstat (limited to 'dev-lang')
-rw-r--r-- | dev-lang/rust/rust-1.33.0.ebuild | 41 |
1 files changed, 29 insertions, 12 deletions
diff --git a/dev-lang/rust/rust-1.33.0.ebuild b/dev-lang/rust/rust-1.33.0.ebuild index aff9229221d0..0cc4462509e3 100644 --- a/dev-lang/rust/rust-1.33.0.ebuild +++ b/dev-lang/rust/rust-1.33.0.ebuild @@ -5,8 +5,6 @@ EAPI=6 PYTHON_COMPAT=( python2_7 python3_{5,6,7} pypy ) -LLVM_MAX_SLOT=8 - inherit check-reqs eapi7-ver estack flag-o-matic llvm multiprocessing multilib-build python-any-r1 rust-toolchain toolchain-funcs if [[ ${PV} = *beta* ]]; then @@ -40,13 +38,34 @@ LICENSE="|| ( MIT Apache-2.0 ) BSD-1 BSD-2 BSD-4 UoI-NCSA" IUSE="clippy cpu_flags_x86_sse2 debug doc libressl rls rustfmt system-llvm wasm ${ALL_LLVM_TARGETS[*]}" -COMMON_DEPEND="sys-libs/zlib - !libressl? ( dev-libs/openssl:0= ) - libressl? ( dev-libs/libressl:0= ) - net-libs/libssh2 - net-libs/http-parser:= - net-misc/curl[ssl] - system-llvm? ( >=sys-devel/llvm-7:= )" +# Please keep the LLVM dependency block separate. Since LLVM is slotted, +# we need to *really* make sure we're not pulling one than more slot +# simultaneously. + +# How to use it: +# 1. List all the working slots (with min versions) in ||, newest first. +# 2. Update the := to specify *max* version, e.g. < 8. +# 3. Specify LLVM_MAX_SLOT, e.g. 7. +LLVM_DEPEND=" + || ( + sys-devel/llvm:7 + ) + <sys-devel/llvm-8:= +" +LLVM_MAX_SLOT=7 + +COMMON_DEPEND=" + sys-libs/zlib + !libressl? ( dev-libs/openssl:0= ) + libressl? ( dev-libs/libressl:0= ) + net-libs/libssh2 + net-libs/http-parser:= + net-misc/curl[ssl] + system-llvm? ( + ${LLVM_DEPEND} + ) +" + DEPEND="${COMMON_DEPEND} ${PYTHON_DEPS} || ( @@ -91,9 +110,7 @@ pkg_pretend() { pkg_setup() { pre_build_checks python-any-r1_pkg_setup - if use system-llvm; then - llvm_pkg_setup - fi + use system-llvm && llvm_pkg_setup } src_prepare() { |