pub struct Header {
pub os_abi: u8,
pub abi_version: u8,
pub e_type: u16,
pub e_machine: u16,
pub e_entry: u64,
pub e_flags: u32,
pub e_phoff: u64,
}
Expand description
ELF file header.
This corresponds to fields in elf::FileHeader32
or elf::FileHeader64
.
This only contains the ELF file header fields that can be modified.
The other fields are automatically calculated.
Fields§
§os_abi: u8
The OS ABI field in the file header.
One of the ELFOSABI*
constants.
abi_version: u8
The ABI version field in the file header.
The meaning of this field depends on the os_abi
value.
e_type: u16
The object file type in the file header.
One of the ET_*
constants.
e_machine: u16
The architecture in the file header.
One of the EM_*
constants.
e_entry: u64
Entry point virtual address in the file header.
e_flags: u32
The processor-specific flags in the file header.
A combination of the EF_*
constants.
e_phoff: u64
The file offset of the program header table.
Writing will fail if the program header table cannot be placed at this offset.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Header
impl RefUnwindSafe for Header
impl Send for Header
impl Sync for Header
impl Unpin for Header
impl UnwindSafe for Header
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more