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

template: fix build failure #1217

Merged
merged 1 commit into from
Jun 25, 2024
Merged

template: fix build failure #1217

merged 1 commit into from
Jun 25, 2024

Conversation

JeffLi01
Copy link
Contributor

@JeffLi01 JeffLi01 commented Jun 25, 2024

The template failed to build when built with cmds below:

cd template
cargo build --target x86_64-unknown-uefi

We'll get error:

error: no global memory allocator found but one is required; link to std or add `#[global_allocator]` to a static item that implements the GlobalAlloc trait

error: `#[panic_handler]` function required, but not found

error: could not compile `uefi_app` (bin "uefi_app") due to 2 previous errors

As the Rust UEFI Book shown, the template succeeds to build with uefi-rs feature panic_handler enabled.

@JeffLi01 JeffLi01 marked this pull request as ready for review June 25, 2024 14:15
@phip1611
Copy link
Contributor

Yikes, sorry that you ran into that. The proper solution is #1170

ping @nicholasbishop

@nicholasbishop
Copy link
Member

Thanks for the fix. I'll go ahead and merge, we can revisit after resolving 1170.

@nicholasbishop nicholasbishop added this pull request to the merge queue Jun 25, 2024
Merged via the queue into rust-osdev:main with commit b07b468 Jun 25, 2024
12 checks passed
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 this pull request may close these issues.

3 participants