Author Topic: Re: How do I write an EFI application in NASM?  (Read 1981 times)

Offline Franciswalser

  • Jr. Member
  • *
  • Posts: 7
Re: How do I write an EFI application in NASM?
« on: December 27, 2022, 11:03:25 AM »
I'm trying to write a 'Hello_world' EFI application in NASM but can't seem to be able to get it working. When I run the application (in VirtualBox), it doesn't print anything. It just hangs.

Offline debs3759

  • Global Moderator
  • Full Member
  • *****
  • Posts: 221
  • Country: gb
    • GPUZoo
Re: How do I write an EFI application in NASM?
« Reply #1 on: December 27, 2022, 03:27:23 PM »
Can you show us what you have written so far? Then someone may be able to help you fix your code, and it may help others who are new to EFI (like me :) )
My graphics card database: www.gpuzoo.com

Offline Craw85ford

  • Jr. Member
  • *
  • Posts: 3
Re: How do I write an EFI application in NASM?
« Reply #2 on: January 16, 2023, 04:27:14 AM »
I'm trying to write a 'Hello_world' EFI application in NASM but can't seem to be able to get it working. When I run the application (in VirtualBox), it doesn't print anything. It just hangs. PFMLogin


I was able to resolve this thanks to the guys at the osdev forum. .HEADERS_SIZE should include the Section Headers and should be a multiple of .FILE_ALIGNMENT. This means the line HEADER_END: should come just after times 4096-($-PE)   db 0 since I am calculating .HEADERS_SIZE by doing HEADER_END - HEADER_START.

Thanks,