#include "ObjectContainerUniversalMachO.h"
#include "lldb/Core/Module.h"
#include "lldb/Core/ModuleSpec.h"
#include "lldb/Core/PluginManager.h"
#include "lldb/Symbol/ObjectFile.h"
#include "lldb/Target/Target.h"
#include "lldb/Utility/ArchSpec.h"
#include "lldb/Utility/DataBuffer.h"
#include "lldb/Utility/Stream.h"
usingnamespacelldb;
usingnamespacelldb_private;
usingnamespacellvm::MachO;
LLDB_PLUGIN_DEFINE_ADV(ObjectContainerUniversalMachO,
ObjectContainerMachOArchive)
void ObjectContainerUniversalMachO::Initialize() { … }
void ObjectContainerUniversalMachO::Terminate() { … }
ObjectContainer *ObjectContainerUniversalMachO::CreateInstance(
const lldb::ModuleSP &module_sp, DataBufferSP &data_sp,
lldb::offset_t data_offset, const FileSpec *file,
lldb::offset_t file_offset, lldb::offset_t length) { … }
bool ObjectContainerUniversalMachO::MagicBytesMatch(const DataExtractor &data) { … }
ObjectContainerUniversalMachO::ObjectContainerUniversalMachO(
const lldb::ModuleSP &module_sp, DataBufferSP &data_sp,
lldb::offset_t data_offset, const FileSpec *file,
lldb::offset_t file_offset, lldb::offset_t length)
: … { … }
ObjectContainerUniversalMachO::~ObjectContainerUniversalMachO() = default;
bool ObjectContainerUniversalMachO::ParseHeader() { … }
bool ObjectContainerUniversalMachO::ParseHeader(
lldb_private::DataExtractor &data, llvm::MachO::fat_header &header,
std::vector<FatArch> &fat_archs) { … }
size_t ObjectContainerUniversalMachO::GetNumArchitectures() const { … }
bool ObjectContainerUniversalMachO::GetArchitectureAtIndex(
uint32_t idx, ArchSpec &arch) const { … }
ObjectFileSP
ObjectContainerUniversalMachO::GetObjectFile(const FileSpec *file) { … }
size_t ObjectContainerUniversalMachO::GetModuleSpecifications(
const lldb_private::FileSpec &file, lldb::DataBufferSP &data_sp,
lldb::offset_t data_offset, lldb::offset_t file_offset,
lldb::offset_t file_size, lldb_private::ModuleSpecList &specs) { … }