aboutsummaryrefslogtreecommitdiff
path: root/source/Plugins/Platform/MacOSX/PlatformRemoteAppleTV.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'source/Plugins/Platform/MacOSX/PlatformRemoteAppleTV.cpp')
-rw-r--r--source/Plugins/Platform/MacOSX/PlatformRemoteAppleTV.cpp44
1 files changed, 15 insertions, 29 deletions
diff --git a/source/Plugins/Platform/MacOSX/PlatformRemoteAppleTV.cpp b/source/Plugins/Platform/MacOSX/PlatformRemoteAppleTV.cpp
index 47b1c8f07dfa..05d1bd49dafe 100644
--- a/source/Plugins/Platform/MacOSX/PlatformRemoteAppleTV.cpp
+++ b/source/Plugins/Platform/MacOSX/PlatformRemoteAppleTV.cpp
@@ -18,17 +18,17 @@
#include "lldb/Breakpoint/BreakpointLocation.h"
#include "lldb/Core/ArchSpec.h"
-#include "lldb/Core/Error.h"
-#include "lldb/Core/Log.h"
#include "lldb/Core/Module.h"
#include "lldb/Core/ModuleList.h"
#include "lldb/Core/ModuleSpec.h"
#include "lldb/Core/PluginManager.h"
-#include "lldb/Core/StreamString.h"
-#include "lldb/Host/FileSpec.h"
#include "lldb/Host/Host.h"
#include "lldb/Target/Process.h"
#include "lldb/Target/Target.h"
+#include "lldb/Utility/Error.h"
+#include "lldb/Utility/FileSpec.h"
+#include "lldb/Utility/Log.h"
+#include "lldb/Utility/StreamString.h"
using namespace lldb;
using namespace lldb_private;
@@ -250,7 +250,7 @@ Error PlatformRemoteAppleTV::ResolveExecutable(
FileSpec::EnumerateDirectoryResult
PlatformRemoteAppleTV::GetContainedFilesIntoVectorOfStringsCallback(
- void *baton, FileSpec::FileType file_type, const FileSpec &file_spec) {
+ void *baton, llvm::sys::fs::file_type ft, const FileSpec &file_spec) {
((PlatformRemoteAppleTV::SDKDirectoryInfoCollection *)baton)
->push_back(PlatformRemoteAppleTV::SDKDirectoryInfo(file_spec));
return FileSpec::eEnumerateDirectoryResultNext;
@@ -497,18 +497,15 @@ const char *PlatformRemoteAppleTV::GetDeviceSupportDirectoryForOSVersion() {
uint32_t
PlatformRemoteAppleTV::FindFileInAllSDKs(const char *platform_file_path,
FileSpecList &file_list) {
- Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_HOST |
- LIBLLDB_LOG_VERBOSE);
+ Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_HOST);
if (platform_file_path && platform_file_path[0] &&
UpdateSDKDirectoryInfosIfNeeded()) {
const uint32_t num_sdk_infos = m_sdk_directory_infos.size();
lldb_private::FileSpec local_file;
// First try for an exact match of major, minor and update
for (uint32_t sdk_idx = 0; sdk_idx < num_sdk_infos; ++sdk_idx) {
- if (log) {
- log->Printf("Searching for %s in sdk path %s", platform_file_path,
- m_sdk_directory_infos[sdk_idx].directory.GetPath().c_str());
- }
+ LLDB_LOGV(log, "Searching for {0} in sdk path {1}", platform_file_path,
+ m_sdk_directory_infos[sdk_idx].directory);
if (GetFileInSDK(platform_file_path, sdk_idx, local_file)) {
file_list.Append(local_file);
}
@@ -619,8 +616,7 @@ Error PlatformRemoteAppleTV::GetSharedModule(
// then we attempt to get a shared module for the right architecture
// with the right UUID.
const FileSpec &platform_file = module_spec.GetFileSpec();
- Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_HOST |
- LIBLLDB_LOG_VERBOSE);
+ Log *log = lldb_private::GetLogIfAllCategoriesSet(LIBLLDB_LOG_HOST);
Error error;
char platform_file_path[PATH_MAX];
@@ -637,12 +633,8 @@ Error PlatformRemoteAppleTV::GetSharedModule(
// using the OS build.
const uint32_t connected_sdk_idx = GetConnectedSDKIndex();
if (connected_sdk_idx < num_sdk_infos) {
- if (log) {
- log->Printf("Searching for %s in sdk path %s", platform_file_path,
- m_sdk_directory_infos[connected_sdk_idx]
- .directory.GetPath()
- .c_str());
- }
+ LLDB_LOGV(log, "Searching for {0} in sdk path {1}", platform_file,
+ m_sdk_directory_infos[connected_sdk_idx].directory);
if (GetFileInSDK(platform_file_path, connected_sdk_idx,
platform_module_spec.GetFileSpec())) {
module_sp.reset();
@@ -658,12 +650,8 @@ Error PlatformRemoteAppleTV::GetSharedModule(
// Try the last SDK index if it is set as most files from an SDK
// will tend to be valid in that same SDK.
if (m_last_module_sdk_idx < num_sdk_infos) {
- if (log) {
- log->Printf("Searching for %s in sdk path %s", platform_file_path,
- m_sdk_directory_infos[m_last_module_sdk_idx]
- .directory.GetPath()
- .c_str());
- }
+ LLDB_LOGV(log, "Searching for {0} in sdk path {1}", platform_file_path,
+ m_sdk_directory_infos[m_last_module_sdk_idx].directory);
if (GetFileInSDK(platform_file_path, m_last_module_sdk_idx,
platform_module_spec.GetFileSpec())) {
module_sp.reset();
@@ -682,10 +670,8 @@ Error PlatformRemoteAppleTV::GetSharedModule(
// it above
continue;
}
- if (log) {
- log->Printf("Searching for %s in sdk path %s", platform_file_path,
- m_sdk_directory_infos[sdk_idx].directory.GetPath().c_str());
- }
+ LLDB_LOGV(log, "Searching for {0} in sdk path {1}", platform_file_path,
+ m_sdk_directory_infos[sdk_idx].directory);
if (GetFileInSDK(platform_file_path, sdk_idx,
platform_module_spec.GetFileSpec())) {
// printf ("sdk[%u]: '%s'\n", sdk_idx, local_file.GetPath().c_str());