All non-output non-user variables of the rust.eclass must be set before
inheriting the eclass. Mark those variables @PRE_INHERIT.

Signed-off-by: Florian Schmaus <[email protected]>
---
 eclass/rust.eclass | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/eclass/rust.eclass b/eclass/rust.eclass
index b5a992199dce..0365a7640594 100644
--- a/eclass/rust.eclass
+++ b/eclass/rust.eclass
@@ -143,12 +143,14 @@ declare -a -g -r _RUST_SLOTS_ORDERED=(
 # == control variables ==
 
 # @ECLASS_VARIABLE: RUST_MAX_VER
+# @PRE_INHERIT
 # @DEFAULT_UNSET
 # @DESCRIPTION:
 # Highest Rust slot supported by the package. Needs to be set before
 # rust_pkg_setup is called. If unset, no upper bound is assumed.
 
 # @ECLASS_VARIABLE: RUST_MIN_VER
+# @PRE_INHERIT
 # @DEFAULT_UNSET
 # @DESCRIPTION:
 # Lowest Rust slot supported by the package. Needs to be set before
@@ -167,6 +169,7 @@ declare -a -g -r _RUST_SLOTS_ORDERED=(
 # This is set by rust_pkg_setup.
 
 # @ECLASS_VARIABLE: RUST_NEEDS_LLVM
+# @PRE_INHERIT
 # @DEFAULT_UNSET
 # @DESCRIPTION:
 # If set to a non-empty value generate a llvm_slot_${llvm_slot}? gated
@@ -179,6 +182,7 @@ declare -a -g -r _RUST_SLOTS_ORDERED=(
 # means that a LLVM slot in LLVM_COMPAT has had all of its Rust slots filtered.
 
 # @ECLASS_VARIABLE: RUST_MULTILIB
+# @PRE_INHERIT
 # @DEFAULT_UNSET
 # @DESCRIPTION:
 # If set to a non-empty value insert MULTILIB_USEDEP into the generated
@@ -194,6 +198,7 @@ declare -a -g -r _RUST_SLOTS_ORDERED=(
 # implementations listed in LLVM_COMPAT.
 
 # @ECLASS_VARIABLE: RUST_OPTIONAL
+# @PRE_INHERIT
 # @DEFAULT_UNSET
 # @DESCRIPTION:
 # If set to a non-empty value, the Rust dependency will not be added
@@ -201,6 +206,7 @@ declare -a -g -r _RUST_SLOTS_ORDERED=(
 # certain USE themselves.
 
 # @ECLASS_VARIABLE: RUST_REQ_USE
+# @PRE_INHERIT
 # @DEFAULT_UNSET
 # @DESCRIPTION:
 # Additional USE-dependencies to be added to the Rust dependency.
-- 
2.51.0


Reply via email to