From: Peter Marko Date: Thu, 21 Aug 2025 12:26:55 +0000 (+0200) Subject: rust: handle softfp fpu X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=4d50135cb902037380915966ecc97399d32e9f74;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git rust: handle softfp fpu With TARGET_FPU set to "softfp" stdlib-rs fails with: error: Error loading target specification: ARM targets must specify their float ABI. Run `rustc --print target-list` for a list of built-in targets This fpu type is set for example for arm in file meta/conf/machine/include/arm/feature-arm-vfp.inc when TUNE_FEATURES do not contain "callconvention-hard", e.g. when using tune DEFAULTTUNE = "cortexa8" Signed-off-by: Peter Marko Signed-off-by: Mathieu Dubois-Briand Signed-off-by: Richard Purdie --- diff --git a/meta/classes-recipe/rust-target-config.bbclass b/meta/classes-recipe/rust-target-config.bbclass index 0df6f0904c..8ab5317c3f 100644 --- a/meta/classes-recipe/rust-target-config.bbclass +++ b/meta/classes-recipe/rust-target-config.bbclass @@ -409,7 +409,7 @@ def rust_gen_target(d, thing, wd, arch): if features != "": tspec['features'] = features fpu = d.getVar('TARGET_FPU') - if fpu == "soft": + if fpu in ["soft", "softfp"]: tspec['llvm-floatabi'] = "soft" elif fpu == "hard": tspec['llvm-floatabi'] = "hard"