- ATTRIBUTES (header fields)
- ATTRIBUTES (user)
- COPYRIGHT AND LICENSE
ELF::Writer::Segment - Object representing the fields of one program segment in an ELF file.
The following are elf program header fields:
Type of segment:
"phdr". Defaults to
Offset of this segment within the elf file
Address where this segment should be memory-mapped
Address where this segment should be loaded
Size of the segment within the elf file
Size of the segment after loaded into memory
32-bit flags. Use the accessors below to access the defined bits. Defaults to readable and executable.
readable bit of flags
writable bit of flags
executable bit of flags.
Page size, for both the file and when loaded into memory (I think?)
The payload of this segment (machine code, or etc)
Used for auto-aligning segments within the elf file. This is the number of bytes in the file which should come between "offset" and your data. Typical use of this feature is to have the first segment start at offset 0 and include the elf header, with data starting somehwere beyond it. If this is zero (or just less than the size of your elf header) then nearly a whole page will be wasted within the file as it aligns the start of the data to a page boundary.
Standard Moo constructor. Pass any attributes, including the flag bit aliases.
$thing if it is an instance of
$class, or passes $thing to the constructor otherwise.
Clone this instance.
Michael Conrad <firstname.lastname@example.org>
This software is copyright (c) 2017 by Michael Conrad.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.