1- diff --git a/meta/classes-recipe/rust-target-config.bbclass b/meta/classes-recipe/rust-target-config.bbclass
2- index 31b4bd9afd..0c304f62e1 100644
3- --- a/meta/classes-recipe/rust-target-config.bbclass
4- +++ b/meta/classes-recipe/rust-target-config.bbclass
5- @@ -127,7 +127,7 @@ def llvm_features(d):
6- llvm_features[vardepvalue] = "${@llvm_features(d)}"
7-
8- ## arm-unknown-linux-gnueabihf
9- - DATA_LAYOUT[arm-eabi] = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64"
10- + DATA_LAYOUT[arm-eabi] = "e-m:e-p:32:32-Fi8-i64:64-v128:64:128-a:0:32-n32-S64"
11- TARGET_ENDIAN[arm-eabi] = "little"
12- TARGET_POINTER_WIDTH[arm-eabi] = "32"
13- TARGET_C_INT_WIDTH[arm-eabi] = "32"
14- @@ -135,7 +135,7 @@ MAX_ATOMIC_WIDTH[arm-eabi] = "64"
15- FEATURES[arm-eabi] = "+v6,+vfp2"
16-
17- ## armv7-unknown-linux-gnueabihf
18- - DATA_LAYOUT[armv7-eabi] = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64"
19- + DATA_LAYOUT[armv7-eabi] = "e-m:e-p:32:32-Fi8-i64:64-v128:64:128-a:0:32-n32-S64"
20- TARGET_ENDIAN[armv7-eabi] = "little"
21- TARGET_POINTER_WIDTH[armv7-eabi] = "32"
22- TARGET_C_INT_WIDTH[armv7-eabi] = "32"
23- @@ -143,14 +143,14 @@ MAX_ATOMIC_WIDTH[armv7-eabi] = "64"
24- FEATURES[armv7-eabi] = "+v7,+vfp2,+thumb2"
25-
26- ## aarch64-unknown-linux-{gnu, musl}
27- - DATA_LAYOUT[aarch64] = "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128"
28- + DATA_LAYOUT[aarch64] = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128-Fn32"
29- TARGET_ENDIAN[aarch64] = "little"
30- TARGET_POINTER_WIDTH[aarch64] = "64"
31- TARGET_C_INT_WIDTH[aarch64] = "32"
32- MAX_ATOMIC_WIDTH[aarch64] = "128"
33-
34- ## x86_64-unknown-linux-{gnu, musl}
35- - DATA_LAYOUT[x86_64] = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
36- + DATA_LAYOUT[x86_64] = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
37- TARGET_ENDIAN[x86_64] = "little"
38- TARGET_POINTER_WIDTH[x86_64] = "64"
39- TARGET_C_INT_WIDTH[x86_64] = "32"
40- @@ -397,6 +397,15 @@ def rust_gen_target(d, thing, wd, arch):
41- tspec['position-independent-executables'] = True
42- tspec['panic-strategy'] = d.getVar("RUST_PANIC_STRATEGY")
43-
44- + # fix for: "Error loading target specification: ARM targets must set `llvm-floatabi` to `hard` or `soft`."
45- + if "arm" in tspec['arch']:
46- + tspec['llvm-floatabi'] = d.getVar('TARGET_FPU')
47- +
48- + # Convert width fields from strings to integers for Rust 1.93+
49- + for field in ['target-pointer-width', 'target-c-int-width', 'max-atomic-width']:
50- + if field in tspec and isinstance(tspec[field], str):
51- + tspec[field] = int(tspec[field])
52- +
53- # write out the target spec json file
54- with open(wd + rustsys + '.json', 'w') as f:
55- json.dump(tspec, f, indent=4)
56- @@ -404,7 +413,7 @@ def rust_gen_target(d, thing, wd, arch):
57- # These are accounted for in tmpdir path names so don't need to be in the task sig
58- rust_gen_target[vardepsexclude] += "ABIEXTENSION llvm_cpu"
59-
60- - do_rust_gen_targets[vardeps] += "DATA_LAYOUT TARGET_ENDIAN TARGET_POINTER_WIDTH TARGET_C_INT_WIDTH MAX_ATOMIC_WIDTH FEATURES"
61- + do_rust_gen_targets[vardeps] += "DATA_LAYOUT TARGET_ENDIAN TARGET_POINTER_WIDTH TARGET_C_INT_WIDTH MAX_ATOMIC_WIDTH FEATURES LLVM_TARGET"
62-
63- RUST_TARGETS_DIR = "${WORKDIR}/rust-targets/"
64- export RUST_TARGET_PATH = "${RUST_TARGETS_DIR}"
65- diff --git a/meta/conf/layer.conf b/meta/conf/layer.conf
66- index 4d09619a28..495f51b602 100644
67- --- a/meta/conf/layer.conf
68- +++ b/meta/conf/layer.conf
69- @@ -133,3 +133,5 @@ PATH := "${@'${BITBAKEPATH}:' if '${BITBAKEPATH}' != '' else ''}${HOSTTOOLS_DIR}
70- BB_GLOBAL_PYMODULES = "os sys time"
71-
72- addpylib ${LAYERDIR}/lib oe
73- +
74- + LAYERDIR_core = "${LAYERDIR}"
751diff --git a/scripts/lib/wic/plugins/source/bootimg-efi.py b/scripts/lib/wic/plugins/source/bootimg-efi.py
76- index 37d07093f5..7a63453f2e 100644
2+ index 7cc5131541..4e899200f1 100644
773--- a/scripts/lib/wic/plugins/source/bootimg-efi.py
784+++ b/scripts/lib/wic/plugins/source/bootimg-efi.py
795@@ -297,113 +297,17 @@ class BootimgEFIPlugin(SourcePlugin):
80-
6+
817 hdddir = "%s/hdd/boot" % cr_workdir
82-
8+
839- kernel = get_bitbake_var("KERNEL_IMAGETYPE")
8410- if get_bitbake_var("INITRAMFS_IMAGE_BUNDLE") == "1":
8511- if get_bitbake_var("INITRAMFS_IMAGE"):
@@ -198,7 +124,7 @@ index 37d07093f5..7a63453f2e 100644
198124+ for grub_efi_sb_file in grub_efi_sb_files:
199125+ efi_install_cmd = "install -m 0644 -D %s/%s %s/EFI/BOOT/%s" % (deploy_dir_img, grub_efi_sb_file, hdddir, grub_efi_sb_file)
200126+ exec_cmd(efi_install_cmd)
201-
127+
202128 if get_bitbake_var("IMAGE_EFI_BOOT_FILES"):
203129 for src_path, dst_path in cls.install_task:
204130diff --git a/meta/conf/layer.conf b/meta/conf/layer.conf
@@ -207,7 +133,7 @@ index efbf2610f9..330c964f87 100644
207133+++ b/meta/conf/layer.conf
208134@@ -132,3 +132,5 @@ PATH := "${@'${BITBAKEPATH}:' if '${BITBAKEPATH}' != '' else ''}${HOSTTOOLS_DIR}
209135 BB_GLOBAL_PYMODULES = "os sys time"
210-
136+
211137 addpylib ${LAYERDIR}/lib oe
212138+
213139+ LAYERDIR_core = "${LAYERDIR}"
@@ -217,7 +143,7 @@ index 31b4bd9afd..0c304f62e1 100644
217143+++ b/meta/classes-recipe/rust-target-config.bbclass
218144@@ -127,7 +127,7 @@ def llvm_features(d):
219145 llvm_features[vardepvalue] = "${@llvm_features(d)}"
220-
146+
221147 ## arm-unknown-linux-gnueabihf
222148- DATA_LAYOUT[arm-eabi] = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64"
223149+ DATA_LAYOUT[arm-eabi] = "e-m:e-p:32:32-Fi8-i64:64-v128:64:128-a:0:32-n32-S64"
@@ -226,7 +152,7 @@ index 31b4bd9afd..0c304f62e1 100644
226152 TARGET_C_INT_WIDTH[arm-eabi] = "32"
227153@@ -135,7 +135,7 @@ MAX_ATOMIC_WIDTH[arm-eabi] = "64"
228154 FEATURES[arm-eabi] = "+v6,+vfp2"
229-
155+
230156 ## armv7-unknown-linux-gnueabihf
231157- DATA_LAYOUT[armv7-eabi] = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64"
232158+ DATA_LAYOUT[armv7-eabi] = "e-m:e-p:32:32-Fi8-i64:64-v128:64:128-a:0:32-n32-S64"
@@ -235,15 +161,15 @@ index 31b4bd9afd..0c304f62e1 100644
235161 TARGET_C_INT_WIDTH[armv7-eabi] = "32"
236162@@ -143,14 +143,14 @@ MAX_ATOMIC_WIDTH[armv7-eabi] = "64"
237163 FEATURES[armv7-eabi] = "+v7,+vfp2,+thumb2"
238-
164+
239165 ## aarch64-unknown-linux-{gnu, musl}
240166- DATA_LAYOUT[aarch64] = "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128"
241167+ DATA_LAYOUT[aarch64] = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128-Fn32"
242168 TARGET_ENDIAN[aarch64] = "little"
243169 TARGET_POINTER_WIDTH[aarch64] = "64"
244170 TARGET_C_INT_WIDTH[aarch64] = "32"
245171 MAX_ATOMIC_WIDTH[aarch64] = "128"
246-
172+
247173 ## x86_64-unknown-linux-{gnu, musl}
248174- DATA_LAYOUT[x86_64] = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
249175+ DATA_LAYOUT[x86_64] = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
@@ -253,7 +179,7 @@ index 31b4bd9afd..0c304f62e1 100644
253179@@ -397,6 +397,15 @@ def rust_gen_target(d, thing, wd, arch):
254180 tspec['position-independent-executables'] = True
255181 tspec['panic-strategy'] = d.getVar("RUST_PANIC_STRATEGY")
256-
182+
257183+ # fix for: "Error loading target specification: ARM targets must set `llvm-floatabi` to `hard` or `soft`."
258184+ if "arm" in tspec['arch']:
259185+ tspec['llvm-floatabi'] = d.getVar('TARGET_FPU')
@@ -269,9 +195,9 @@ index 31b4bd9afd..0c304f62e1 100644
269195@@ -404,7 +413,7 @@ def rust_gen_target(d, thing, wd, arch):
270196 # These are accounted for in tmpdir path names so don't need to be in the task sig
271197 rust_gen_target[vardepsexclude] += "ABIEXTENSION llvm_cpu"
272-
198+
273199- do_rust_gen_targets[vardeps] += "DATA_LAYOUT TARGET_ENDIAN TARGET_POINTER_WIDTH TARGET_C_INT_WIDTH MAX_ATOMIC_WIDTH FEATURES"
274200+ do_rust_gen_targets[vardeps] += "DATA_LAYOUT TARGET_ENDIAN TARGET_POINTER_WIDTH TARGET_C_INT_WIDTH MAX_ATOMIC_WIDTH FEATURES LLVM_TARGET"
275-
201+
276202 RUST_TARGETS_DIR = "${WORKDIR}/rust-targets/"
277203 export RUST_TARGET_PATH = "${RUST_TARGETS_DIR}"
0 commit comments