Added support for an EFI X64 ABI compatible UnixPkg. With an internal only compiler I've been able to run checked in X64 EFI shell binary! We are hoping to get the open source LLVM compiler working for this... Since the SEC has to be UNIX ABI to make the POSIX calls it is compiled using a different compiler and the rest of the UnixPkg is compiled with UNIXPKG tool. You just need to point UNIXPKG at your EFI X64 ABI compiler of choice, it should work like MYTOOLS. Some one may want to port this to Linux at some point. To build cd into UnixPkg and ./build64.sh

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10806 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
andrewfish
2010-08-18 20:24:08 +00:00
parent 6989af7168
commit bb111c2346
18 changed files with 316 additions and 200 deletions

View File

@@ -48,18 +48,21 @@ char *gGdbWorkingFileName = NULL;
//
// Globals
//
UNIX_PEI_LOAD_FILE_PPI mSecUnixLoadFilePpi = { SecUnixPeiLoadFile };
PEI_UNIX_AUTOSCAN_PPI mSecUnixAutoScanPpi = { SecUnixPeiAutoScan };
PEI_UNIX_THUNK_PPI mSecUnixThunkPpi = { SecUnixUnixThunkAddress };
#ifdef __APPLE__
UNIX_PEI_LOAD_FILE_PPI mSecUnixLoadFilePpi = { GasketSecUnixPeiLoadFile };
PEI_UNIX_AUTOSCAN_PPI mSecUnixAutoScanPpi = { GasketSecUnixPeiAutoScan };
PEI_UNIX_THUNK_PPI mSecUnixThunkPpi = { GasketSecUnixUnixThunkAddress };
EFI_PEI_PROGRESS_CODE_PPI mSecStatusCodePpi = { GasketSecPeiReportStatusCode };
UNIX_FWH_PPI mSecFwhInformationPpi = { GasketSecUnixFdAddress };
TEMPORARY_RAM_SUPPORT_PPI mSecTemporaryRamSupportPpi = { GasketSecTemporaryRamSupport };
#else
UNIX_PEI_LOAD_FILE_PPI mSecUnixLoadFilePpi = { SecUnixPeiLoadFile };
PEI_UNIX_AUTOSCAN_PPI mSecUnixAutoScanPpi = { SecUnixPeiAutoScan };
PEI_UNIX_THUNK_PPI mSecUnixThunkPpi = { SecUnixUnixThunkAddress };
EFI_PEI_PROGRESS_CODE_PPI mSecStatusCodePpi = { SecPeiReportStatusCode };
UNIX_FWH_PPI mSecFwhInformationPpi = { SecUnixFdAddress };
TEMPORARY_RAM_SUPPORT_PPI mSecTemporaryRamSupportPpi = {SecTemporaryRamSupport};
TEMPORARY_RAM_SUPPORT_PPI mSecTemporaryRamSupportPpi = { SecTemporaryRamSupport };
#endif
EFI_PEI_PPI_DESCRIPTOR gPrivateDispatchTable[] = {
{
@@ -1068,13 +1071,20 @@ PrintLoadAddress (
IN PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext
)
{
fprintf (stderr,
"0x%08lx Loading %s with entry point 0x%08lx\n",
(unsigned long)(ImageContext->ImageAddress + ImageContext->SizeOfHeaders),
ImageContext->PdbPointer,
(unsigned long)ImageContext->EntryPoint
);
if (ImageContext->PdbPointer == NULL) {
fprintf (stderr,
"0x%08lx Loading NO DEBUG with entry point 0x%08lx\n",
(unsigned long)(ImageContext->ImageAddress),
(unsigned long)ImageContext->EntryPoint
);
} else {
fprintf (stderr,
"0x%08lx Loading %s with entry point 0x%08lx\n",
(unsigned long)(ImageContext->ImageAddress + ImageContext->SizeOfHeaders),
ImageContext->PdbPointer,
(unsigned long)ImageContext->EntryPoint
);
}
// Keep output synced up
fflush (stderr);
}