Skip to content

Commit 8e90994

Browse files
Switch ia32 ABI for ShimLock to cdecl
Previously this was sysv64. As of Rust 1.83, this is rejected by the compiler as incompatible with an i386 target.
1 parent 637a2e1 commit 8e90994

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

uefi/src/proto/shim/mod.rs

+6-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,12 @@ pub struct Hashes {
4545

4646
// These macros set the correct calling convention for the Shim protocol methods.
4747

48-
#[cfg(any(target_arch = "x86", target_arch = "x86_64"))]
48+
#[cfg(target_arch = "x86")]
49+
macro_rules! shim_function {
50+
(fn $args:tt -> $return_type:ty) => (extern "cdecl" fn $args -> $return_type)
51+
}
52+
53+
#[cfg(target_arch = "x86_64")]
4954
macro_rules! shim_function {
5055
(fn $args:tt -> $return_type:ty) => (extern "sysv64" fn $args -> $return_type)
5156
}

0 commit comments

Comments
 (0)