LLDB mainline
PlatformRemoteDarwinDevice.h
Go to the documentation of this file.
1//===-- PlatformRemoteDarwinDevice.h ----------------------------*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8
9#ifndef LLDB_SOURCE_PLUGINS_PLATFORM_MACOSX_PLATFORMREMOTEDARWINDEVICE_H
10#define LLDB_SOURCE_PLUGINS_PLATFORM_MACOSX_PLATFORMREMOTEDARWINDEVICE_H
11
16#include "lldb/Utility/Status.h"
18#include "lldb/lldb-forward.h"
19#include "llvm/ADT/SmallVector.h"
20#include "llvm/ADT/StringRef.h"
21#include "llvm/Support/FileSystem.h"
22#include "llvm/Support/VersionTuple.h"
23
24#include <mutex>
25#include <string>
26#include <vector>
27
28namespace lldb_private {
29class FileSpecList;
30class ModuleSpec;
31class Process;
32class Stream;
33class Target;
34class UUID;
35
37public:
39
41
42 // Platform functions
43 void GetStatus(Stream &strm) override;
44
45 virtual Status GetSymbolFile(const FileSpec &platform_file,
46 const UUID *uuid_ptr, FileSpec &local_file);
47
48 Status GetSharedModule(const ModuleSpec &module_spec, Process *process,
49 lldb::ModuleSP &module_sp,
50 const FileSpecList *module_search_paths_ptr,
52 bool *did_create_ptr) override;
53
54 void
56 std::vector<std::string> &options) override {
58 target, options, XcodeSDK::Type::iPhoneOS);
59 }
60
61protected:
62 std::string m_build_update;
65
66 bool GetFileInSDK(const char *platform_file_path, uint32_t sdk_idx,
67 FileSpec &local_file);
68
69 uint32_t GetConnectedSDKIndex();
70
71 // Get index of SDK in SDKDirectoryInfoCollection by its pointer and return
72 // UINT32_MAX if that SDK not found.
73 uint32_t GetSDKIndexBySDKDirectoryInfo(const SDKDirectoryInfo *sdk_info);
74
75private:
79};
80
81} // namespace lldb_private
82
83#endif // LLDB_SOURCE_PLUGINS_PLATFORM_MACOSX_PLATFORMREMOTEDARWINDEVICE_H
A file collection class.
Definition: FileSpecList.h:91
A file utility class.
Definition: FileSpec.h:56
Abstract Darwin platform with a potential device support directory.
void AddClangModuleCompilationOptionsForSDKType(Target *target, std::vector< std::string > &options, XcodeSDK::Type sdk_type)
virtual Status GetSymbolFile(const FileSpec &platform_file, const UUID *uuid_ptr, FileSpec &local_file)
bool GetFileInSDK(const char *platform_file_path, uint32_t sdk_idx, FileSpec &local_file)
PlatformRemoteDarwinDevice(const PlatformRemoteDarwinDevice &)=delete
const PlatformRemoteDarwinDevice & operator=(const PlatformRemoteDarwinDevice &)=delete
Status GetSharedModule(const ModuleSpec &module_spec, Process *process, lldb::ModuleSP &module_sp, const FileSpecList *module_search_paths_ptr, llvm::SmallVectorImpl< lldb::ModuleSP > *old_modules, bool *did_create_ptr) override
void AddClangModuleCompilationOptions(Target *target, std::vector< std::string > &options) override
uint32_t GetSDKIndexBySDKDirectoryInfo(const SDKDirectoryInfo *sdk_info)
void GetStatus(Stream &strm) override
Report the current status for this platform.
~PlatformRemoteDarwinDevice() override
Destructor.
A plug-in interface definition class for debugging a process.
Definition: Process.h:343
An error handling class.
Definition: Status.h:115
A stream class that can stream formatted output to a file.
Definition: Stream.h:28
#define UINT32_MAX
Definition: lldb-defines.h:19
A class that represents a running process on the host machine.
std::shared_ptr< lldb_private::Module > ModuleSP
Definition: lldb-forward.h:373