summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2020-05-26 09:27:47 +0200
committerMichał Górny <mgorny@gentoo.org>2020-05-28 13:41:21 +0200
commit2f90db9a989471a41a152b7ccf59bb1c590d14e0 (patch)
tree64a761089bdaaad0625f5dde7854a15559aa0155 /eclass/llvm.eclass
parentllvm.eclass: Add initial tests (diff)
downloadgentoo-2f90db9a989471a41a152b7ccf59bb1c590d14e0.tar.gz
gentoo-2f90db9a989471a41a152b7ccf59bb1c590d14e0.tar.bz2
gentoo-2f90db9a989471a41a152b7ccf59bb1c590d14e0.zip
llvm.eclass: Remove remnants of slot :0 support
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'eclass/llvm.eclass')
-rw-r--r--eclass/llvm.eclass18
1 files changed, 5 insertions, 13 deletions
diff --git a/eclass/llvm.eclass b/eclass/llvm.eclass
index a2da231b035a..4f968dc39f87 100644
--- a/eclass/llvm.eclass
+++ b/eclass/llvm.eclass
@@ -71,6 +71,10 @@ EXPORT_FUNCTIONS pkg_setup
if [[ ! ${_LLVM_ECLASS} ]]; then
+# make sure that the versions installing straight into /usr/bin
+# are uninstalled
+DEPEND="!!sys-devel/llvm:0"
+
# @ECLASS-VARIABLE: LLVM_MAX_SLOT
# @DEFAULT_UNSET
# @DESCRIPTION:
@@ -173,13 +177,6 @@ get_llvm_prefix() {
die "${FUNCNAME}: invalid max_slot=${max_slot}"
fi
- # fallback to :0
- # assume it's always <= 4 (the lower max_slot allowed)
- if has_version ${hv_switch} "sys-devel/llvm:0"; then
- echo "${prefix}/usr"
- return
- fi
-
die "No LLVM slot${1:+ <= ${1}} found installed!"
}
@@ -202,12 +199,7 @@ llvm_pkg_setup() {
if [[ ${MERGE_TYPE} != binary ]]; then
local llvm_prefix=$(get_llvm_prefix "${LLVM_MAX_SLOT}")
-
- # do not prepend /usr/bin, it's not necessary and breaks other
- # prepends, https://bugs.gentoo.org/622866
- if [[ ${llvm_prefix} != ${EPREFIX}/usr ]]; then
- export PATH=${llvm_prefix}/bin:${PATH}
- fi
+ export PATH=${llvm_prefix}/bin:${PATH}
fi
}