Skip to main content

Module write

Module write 

Source
Expand description

Interface for writing object files.

This module provides a unified write API for relocatable object files using Object. This does not support writing executable files. This supports the following file formats: COFF, ELF, Mach-O, and XCOFF.

The submodules define helpers for writing the raw structs. These support writing both relocatable and executable files. There are writers for the following file formats: COFF, ELF, and PE.

Re-exports§

pub use coff::CoffExportStyle;
pub use macho::MachOBuildVersion;

Modules§

coff
Support for writing COFF files.
elf
Support for writing ELF files.
macho
Support for writing Mach-O files.
pe
Helper for writing PE files.

Structs§

Comdat
A COMDAT section group.
ComdatId
An identifier used to reference a COMDAT section group.
CountingBuffer
Wraps a WritableBuffer and counts the number of bytes written.
Error
The error type used within the write module.
Object
A writable relocatable object file.
Permissions
Memory permissions for a segment.
Relocation
A relocation in an object file.
Section
A section in an object file.
SectionId
An identifier used to reference a section.
StreamingBuffer
A WritableBuffer that streams data to a Write implementation.
StringId
An identifier for an entry in a string table.
StringTable
A string table containing null terminated byte strings.
Symbol
A symbol in an object file.
SymbolId
An identifier used to reference a symbol.

Enums§

AddressSize
The size of an address value for an architecture.
Architecture
A CPU architecture.
BinaryFormat
A binary file format.
ComdatKind
The selection kind for a COMDAT section group.
FileFlags
File flags that are specific to each file format.
Mangling
The symbol name mangling scheme.
RelocationEncoding
Information about how the result of the relocation operation is encoded in the place.
RelocationFlags
Relocation fields that are specific to each file format and architecture.
RelocationKind
The operation used to calculate the result of the relocation.
SectionFlags
Section flags that are specific to each file format.
SectionKind
The kind of a section.
SegmentFlags
Segment flags that are specific to each file format.
StandardSection
A standard section kind.
StandardSegment
A standard segment kind.
SubArchitecture
A CPU sub-architecture.
SymbolFlags
Symbol flags that are specific to each file format.
SymbolKind
The kind of a symbol.
SymbolScope
A symbol scope.
SymbolSection
The section where a symbol is defined.

Traits§

GrowableBuffer
A WritableBuffer that can grow its capacity while writing.
WritableBuffer
Trait for writable buffer.
WritableBufferExt
Extension methods for WritableBuffer.

Type Aliases§

Result
The result type used within the write module.