Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build errors on a Windows ARM32 target since c1464fa #572

Closed
kleisauke opened this issue Nov 3, 2023 · 2 comments · Fixed by #573
Closed

Build errors on a Windows ARM32 target since c1464fa #572

kleisauke opened this issue Nov 3, 2023 · 2 comments · Fixed by #573

Comments

@kleisauke
Copy link
Contributor

Since commit c1464fa, I'm getting the following build errors on a custom armv7-pc-windows-gnullvm target:

Details
error[E0609]: no field `Eip` on type `backtrace_rs::windows::CONTEXT`
   --> /data/mxe/usr/x86_64-pc-linux-gnu/lib/rustlib/src/rust/library/std/src/../../backtrace/src/backtrace/dbghelp.rs:170:54
    |
170 |             stack_frame_ex.AddrPC.Offset = context.0.Eip as u64;
    |                                                      ^^^ unknown field
    |
    = note: available fields are: `ContextFlags`, `R0`, `R1`, `R2`, `R3` ... and 21 others

error[E0609]: no field `Esp` on type `backtrace_rs::windows::CONTEXT`
   --> /data/mxe/usr/x86_64-pc-linux-gnu/lib/rustlib/src/rust/library/std/src/../../backtrace/src/backtrace/dbghelp.rs:172:57
    |
172 |             stack_frame_ex.AddrStack.Offset = context.0.Esp as u64;
    |                                                         ^^^ unknown field
    |
    = note: available fields are: `ContextFlags`, `R0`, `R1`, `R2`, `R3` ... and 21 others

error[E0609]: no field `Ebp` on type `backtrace_rs::windows::CONTEXT`
   --> /data/mxe/usr/x86_64-pc-linux-gnu/lib/rustlib/src/rust/library/std/src/../../backtrace/src/backtrace/dbghelp.rs:174:57
    |
174 |             stack_frame_ex.AddrFrame.Offset = context.0.Ebp as u64;
    |                                                         ^^^ unknown field
    |
    = note: available fields are: `ContextFlags`, `R0`, `R1`, `R2`, `R3` ... and 21 others

error[E0609]: no field `Eip` on type `backtrace_rs::windows::CONTEXT`
   --> /data/mxe/usr/x86_64-pc-linux-gnu/lib/rustlib/src/rust/library/std/src/../../backtrace/src/backtrace/dbghelp.rs:208:53
    |
208 |             stack_frame64.AddrPC.Offset = context.0.Eip as u64;
    |                                                     ^^^ unknown field
    |
    = note: available fields are: `ContextFlags`, `R0`, `R1`, `R2`, `R3` ... and 21 others

error[E0609]: no field `Esp` on type `backtrace_rs::windows::CONTEXT`
   --> /data/mxe/usr/x86_64-pc-linux-gnu/lib/rustlib/src/rust/library/std/src/../../backtrace/src/backtrace/dbghelp.rs:210:56
    |
210 |             stack_frame64.AddrStack.Offset = context.0.Esp as u64;
    |                                                        ^^^ unknown field
    |
    = note: available fields are: `ContextFlags`, `R0`, `R1`, `R2`, `R3` ... and 21 others

error[E0609]: no field `Ebp` on type `backtrace_rs::windows::CONTEXT`
   --> /data/mxe/usr/x86_64-pc-linux-gnu/lib/rustlib/src/rust/library/std/src/../../backtrace/src/backtrace/dbghelp.rs:212:56
    |
212 |             stack_frame64.AddrFrame.Offset = context.0.Ebp as u64;
    |                                                        ^^^ unknown field
    |
    = note: available fields are: `ContextFlags`, `R0`, `R1`, `R2`, `R3` ... and 21 others

Looking at these logs, I think this also affects the thumbv7a-pc-windows-msvc and thumbv7a-uwp-windows-msvc targets. However, since no one's actively working on these targets1 and the fact that is untested/unsupported territory2, feel free to close this as invalid.

Footnotes

  1. https://github.com/rust-lang/rust/issues/109030#issuecomment-1465051133

  2. https://github.com/rust-lang/rust/issues/112265#issuecomment-1575468455

@ChrisDenton
Copy link
Member

Thanks for the report! While support for Windows 32-bit arm is ambiguous at best, we'd certainly accept patches to fix small issues. In this case I think it should just be a matter of using Sp, Pc and Lr for arm in src/backtrace/dbghelp.rs.

@kleisauke
Copy link
Contributor Author

Great! I just opened PR #573 for this.

kleisauke added a commit to libvips/build-win64-mxe that referenced this issue Nov 4, 2023
kleisauke added a commit to kleisauke/backtrace-rs that referenced this issue Nov 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants