A few more fixes for your review.
- support for generating X64, ARM64, IA32 (untested) and ARM (untested) UEFI images.
The UEFI stuff was tested by building the following simple app (you need Tiano edk2 for the headers).
$ ./x86_64-win32-tcc -I ../edk2/MdePkg/Include/ -I ../edk2/MdePkg/Include/X64/ ../efitest.c -Wl,-subsystem=efiapp -nostdlib -o ../efitest.x64.efi -v
$ ./arm64-win32-tcc -I ../edk2/MdePkg/Include/ -I ../edk2/MdePkg/Include/AArch64/ ../efitest.c -Wl,-subsystem=efiapp -nostdlib -o ../efitest.aa64.efi
-->
#include <Uefi.h>
CHAR16 *gHello = L"Hello from a TinyCC compiled UEFI binary!\r\n";
EFI_STATUS EFIAPI
_start(EFI_HANDLE Handle,
EFI_SYSTEM_TABLE *SystemTable)
{
CHAR16 *StackString = L"String pointer on the stack\r\n";
SystemTable->ConOut->OutputString(SystemTable->ConOut, StackString);
SystemTable->ConOut->OutputString(SystemTable->ConOut, gHello);
return EFI_SUCCESS;
}
-->
--
A