Declaration¶
Source position: machoreader.pp line 36
type
TMachOResourceReader = class(TAbstractResourceReader)
protected
function GetExtensions : string;
function GetDescription : string;
procedure Load;
function CheckMagic : Boolean;
function FindBestFatArchOffset : Int64;
public
constructor Create; overload;
constructor Create(AMachineType: TMachOMachineType;
ASubMachineType: TMachOSubMachineType);
destructor Destroy;
property MachineType: TMachOMachineType; {r}
property SubMachineType: TMachOSubMachineType; {r}
end;
Inheritance¶
Description¶
This class provides a reader for Mach-O object files and images containing resources.
Mach-O is the file format used by Darwin and Mac OS X for object files and image files (executables, dynamic libraries and so on). Free Pascal can store resources in Mach-O files in its own format.
After an object file has been read, MachineType property holds the machine type the object file was built for.
Remark:
This reader can't read multiple-architecture Mach-O files (like universal binary). To read a particular Mach-O file in a multiple-architecture file, extract it with lipo command.
Properties¶
| Member | Visibility | Description |
|---|---|---|
| MachineType read only | public | The machine type of the object file |
| SubMachineType read only | public |
Methods¶
| Member | Visibility | Description |
|---|---|---|
| CheckMagic | protected | |
| Create | public | |
| Destroy | public | |
| FindBestFatArchOffset | protected | |
| GetDescription | protected | |
| GetExtensions | protected | |
| Load | protected |
See also¶
| Name | Description |
|---|---|
| TMachOResourceReader.MachineType | The machine type of the object file |
| TAbstractResourceReader | Base abstract resource reader class |
| TMachOResourceWriter | Mach-O resource writer |
| Format of resources in object files | Format of resources in object files |