Do not link against libxtos if not needed
Some checks failed
Builds / ExectOS (amd64) (push) Successful in 29s
Builds / ExectOS (i686) (push) Failing after 15s

This commit is contained in:
Rafal Kupiec 2024-01-10 19:55:20 +01:00
parent c4450e88ab
commit c98007a4a5
Signed by: belliash
GPG Key ID: 4E829243E0CFE6B4
3 changed files with 7 additions and 7 deletions

View File

@ -15,7 +15,7 @@ list(APPEND XTLDR_FB_O_SOURCE
add_executable(fb_o ${XTLDR_FB_O_SOURCE})
# Add linker libraries
target_link_libraries(fb_o libxtos libxtldr)
target_link_libraries(fb_o libxtldr)
# Set proper binary name and install target
set_target_properties(fb_o PROPERTIES SUFFIX .efi)

View File

@ -14,7 +14,7 @@ list(APPEND XTLDR_PECOFF_O_SOURCE
add_executable(pecoff_o ${XTLDR_PECOFF_O_SOURCE})
# Add linker libraries
target_link_libraries(pecoff_o libxtos libxtldr)
target_link_libraries(pecoff_o libxtldr)
# Set proper binary name and install target
set_target_properties(pecoff_o PROPERTIES SUFFIX .efi)

View File

@ -283,7 +283,7 @@ PeLoadImage(IN PEFI_FILE_HANDLE FileHandle,
}
/* Copy all sections */
RtlCopyMemory(ImageData->Data, Data, ImageData->PeHeader->OptionalHeader.SizeOfHeaders);
XtLdrProtocol->Memory.CopyMemory(ImageData->Data, Data, ImageData->PeHeader->OptionalHeader.SizeOfHeaders);
/* Find section header */
SectionHeader = (PPECOFF_IMAGE_SECTION_HEADER)((PUCHAR)&ImageData->PeHeader->OptionalHeader +
@ -308,7 +308,7 @@ PeLoadImage(IN PEFI_FILE_HANDLE FileHandle,
if(SectionSize > 0 && SectionHeader[Index].PointerToRawData != 0)
{
/* Copy section */
RtlCopyMemory((PUINT8)ImageData->Data + SectionHeader[Index].VirtualAddress,
XtLdrProtocol->Memory.CopyMemory((PUINT8)ImageData->Data + SectionHeader[Index].VirtualAddress,
Data + SectionHeader[Index].PointerToRawData, SectionSize);
}
@ -316,7 +316,7 @@ PeLoadImage(IN PEFI_FILE_HANDLE FileHandle,
if(SectionSize < SectionHeader[Index].Misc.VirtualSize)
{
/* Fill remaining space with zeroes */
RtlZeroMemory((PUINT8)ImageData->Data + SectionHeader[Index].VirtualAddress + SectionSize,
XtLdrProtocol->Memory.ZeroMemory((PUINT8)ImageData->Data + SectionHeader[Index].VirtualAddress + SectionSize,
SectionHeader[Index].Misc.VirtualSize - SectionSize);
}
}