LLDB  mainline
LocateSymbolFile.h
Go to the documentation of this file.
1 //===-- LocateSymbolFile.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_SYMBOL_LOCATESYMBOLFILE_H
10 #define LLDB_SYMBOL_LOCATESYMBOLFILE_H
11 
12 #include <cstdint>
13 
14 #include "lldb/Core/FileSpecList.h"
15 #include "lldb/Utility/FileSpec.h"
16 #include "lldb/Utility/Status.h"
17 
18 namespace lldb_private {
19 
20 class ArchSpec;
21 class ModuleSpec;
22 class UUID;
23 
24 class Symbols {
25 public:
26  // Locate the executable file given a module specification.
27  //
28  // Locating the file should happen only on the local computer or using the
29  // current computers global settings.
30  static ModuleSpec LocateExecutableObjectFile(const ModuleSpec &module_spec);
31 
32  // Locate the symbol file given a module specification.
33  //
34  // Locating the file should happen only on the local computer or using the
35  // current computers global settings.
36  static FileSpec
37  LocateExecutableSymbolFile(const ModuleSpec &module_spec,
38  const FileSpecList &default_search_paths);
39 
40  static FileSpec FindSymbolFileInBundle(const FileSpec &dsym_bundle_fspec,
41  const lldb_private::UUID *uuid,
42  const ArchSpec *arch);
43 
44  // Locate the object and symbol file given a module specification.
45  //
46  // Locating the file can try to download the file from a corporate build
47  // repository, or using any other means necessary to locate both the
48  // unstripped object file and the debug symbols. The force_lookup argument
49  // controls whether the external program is called unconditionally to find
50  // the symbol file, or if the user's settings are checked to see if they've
51  // enabled the external program before calling.
52  //
53  static bool DownloadObjectAndSymbolFile(ModuleSpec &module_spec,
54  Status &error,
55  bool force_lookup = true);
56 };
57 
58 } // namespace lldb_private
59 
60 #endif // LLDB_SYMBOL_LOCATESYMBOLFILE_H
lldb_private::UUID
Definition: UUID.h:23
lldb_private::ArchSpec
Definition: ArchSpec.h:33
lldb_private::Symbols::LocateExecutableObjectFile
static ModuleSpec LocateExecutableObjectFile(const ModuleSpec &module_spec)
Definition: LocateSymbolFile.cpp:234
lldb_private::FileSpec
Definition: FileSpec.h:56
error
static llvm::raw_ostream & error(Stream &strm)
Definition: CommandReturnObject.cpp:17
lldb_private::Symbols::LocateExecutableSymbolFile
static FileSpec LocateExecutableSymbolFile(const ModuleSpec &module_spec, const FileSpecList &default_search_paths)
Definition: LocateSymbolFile.cpp:260
lldb_private::Symbols::FindSymbolFileInBundle
static FileSpec FindSymbolFileInBundle(const FileSpec &dsym_bundle_fspec, const lldb_private::UUID *uuid, const ArchSpec *arch)
Definition: LocateSymbolFile.cpp:402
FileSpecList.h
lldb_private::Symbols::DownloadObjectAndSymbolFile
static bool DownloadObjectAndSymbolFile(ModuleSpec &module_spec, Status &error, bool force_lookup=true)
Definition: LocateSymbolFile.cpp:409
lldb_private::ModuleSpec
Definition: ModuleSpec.h:27
lldb_private::Status
Definition: Status.h:44
Status.h
lldb_private
A class that represents a running process on the host machine.
Definition: SBCommandInterpreterRunOptions.h:16
lldb_private::Symbols
Definition: LocateSymbolFile.h:24
FileSpec.h