summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorMatt Jolly <kangie@gentoo.org>2024-12-04 21:34:01 +1000
committerMatt Jolly <kangie@gentoo.org>2024-12-04 21:34:01 +1000
commit7687cc69cda0158af53edae6d89944653760dea9 (patch)
treed3111247b27c7690186f14cac8b5afcdfcfe7667 /eclass
parentwww-client/opera-developer: remove old (diff)
downloadgentoo-7687cc69cda0158af53edae6d89944653760dea9.tar.gz
gentoo-7687cc69cda0158af53edae6d89944653760dea9.tar.bz2
gentoo-7687cc69cda0158af53edae6d89944653760dea9.zip
Revert "rust.eclass: add ERUST_{SLOT,TYPE} user variables"
This reverts commit 4ff6bf33c94566b2acc07b75712094d567c77fc9. My branch was dirty, this is still under review. Signed-off-by: Matt Jolly <kangie@gentoo.org>
Diffstat (limited to 'eclass')
-rw-r--r--eclass/rust.eclass49
1 files changed, 5 insertions, 44 deletions
diff --git a/eclass/rust.eclass b/eclass/rust.eclass
index 991a9cdb7f14..71cbb4b24f8c 100644
--- a/eclass/rust.eclass
+++ b/eclass/rust.eclass
@@ -98,26 +98,6 @@ declare -a -g -r _RUST_SLOTS_ORDERED=(
"1.54.0"
)
-# == user control knobs ==
-
-# @ECLASS_VARIABLE: ERUST_SLOT
-# @USER_VARIABLE
-# @DESCRIPTION:
-# Specify the version (slot) of Rust to be used by the package. This is
-# useful for troubleshooting and debugging purposes; If unset, the newest
-# acceptable Rust version will be used. May be combined with ERUST_TYPE.
-# This variable must not be set in ebuilds.
-
-# @ECLASS_VARIABLE: ERUST_TYPE
-# @USER_VARIABLE
-# @DESCRIPTION:
-# Specify the type of Rust to be used by the package from options:
-# 'source' or 'binary' (-bin). This is useful for troubleshooting and
-# debugging purposes. If unset, the standard eclass logic will be used
-# to determine the type of Rust to use (i.e. prefer source if binary
-# is also available). May be combined with ERUST_SLOT.
-# This variable must not be set in ebuilds.
-
# == control variables ==
# @ECLASS_VARIABLE: RUST_MAX_VER
@@ -352,10 +332,6 @@ _get_rust_slot() {
fi
fi
- if [[ -n "${ERUST_SLOT}" && "${slot}" != "${ERUST_SLOT}" ]]; then
- continue
- fi
-
# If we're in LLVM mode we can skip any slots that don't match the selected USE
if [[ -n "${RUST_NEEDS_LLVM}" ]]; then
if [[ "${llvm_slot}" != "${llvm_r1_slot}" ]]; then
@@ -369,27 +345,12 @@ _get_rust_slot() {
rust_check_deps && return
else
local usedep="${RUST_REQ_USE+[${RUST_REQ_USE}]}"
- # When checking for installed packages prefer the source package;
+ # When checking for installed packages prefer the non `-bin` package
# if effort was put into building it we should use it.
- local rust_pkgs
- case "${ERUST_TYPE}" in
- source)
- rust_pkgs=(
- "dev-lang/rust:${slot}${usedep}"
- )
- ;;
- binary)
- rust_pkgs=(
- "dev-lang/rust-bin:${slot}${usedep}"
- )
- ;;
- *)
- rust_pkgs=(
- "dev-lang/rust:${slot}${usedep}"
- "dev-lang/rust-bin:${slot}${usedep}"
- )
- ;;
- esac
+ local rust_pkgs=(
+ "dev-lang/rust:${slot}${usedep}"
+ "dev-lang/rust-bin:${slot}${usedep}"
+ )
local _pkg
for _pkg in "${rust_pkgs[@]}"; do
if has_version "${hv_switch}" "${_pkg}"; then