mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-12-14 11:39:35 +00:00
Repair the build when LLDB_DISABLE_PYTHON is set
Summary: If LLDB_DISABLE_PYTHON is set, some functions are unavailable but SBReproducer assumes they are. Let's conditionally register those functions since they are conditionally declared. Differential Revision: https://reviews.llvm.org/D59056 llvm-svn: 355575
This commit is contained in:
parent
c56d2afc63
commit
03df653f71
@ -818,12 +818,14 @@ SBRegistry::SBRegistry() {
|
||||
());
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeFormat, SBDebugger, GetFormatForType,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
#ifndef LLDB_DISABLE_PYTHON
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeSummary, SBDebugger, GetSummaryForType,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeFilter, SBDebugger, GetFilterForType,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeSynthetic, SBDebugger, GetSyntheticForType,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
#endif
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeFilter, SBDebugger, GetFilterForType,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(bool, SBDebugger, EnableLog,
|
||||
(const char *, const char **));
|
||||
}
|
||||
@ -2436,47 +2438,49 @@ SBRegistry::SBRegistry() {
|
||||
LLDB_REGISTER_METHOD(uint32_t, SBTypeCategory, GetNumFormats, ());
|
||||
LLDB_REGISTER_METHOD(uint32_t, SBTypeCategory, GetNumSummaries, ());
|
||||
LLDB_REGISTER_METHOD(uint32_t, SBTypeCategory, GetNumFilters, ());
|
||||
#ifndef LLDB_DISABLE_PYTHON
|
||||
LLDB_REGISTER_METHOD(uint32_t, SBTypeCategory, GetNumSynthetics, ());
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeNameSpecifier, SBTypeCategory,
|
||||
GetTypeNameSpecifierForFilterAtIndex, (uint32_t));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeNameSpecifier, SBTypeCategory,
|
||||
GetTypeNameSpecifierForFormatAtIndex, (uint32_t));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeNameSpecifier, SBTypeCategory,
|
||||
GetTypeNameSpecifierForSummaryAtIndex, (uint32_t));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeNameSpecifier, SBTypeCategory,
|
||||
GetTypeNameSpecifierForSyntheticAtIndex, (uint32_t));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeFilter, SBTypeCategory, GetFilterForType,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeFormat, SBTypeCategory, GetFormatForType,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeSummary, SBTypeCategory, GetSummaryForType,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeSynthetic, SBTypeCategory,
|
||||
GetSyntheticForType, (lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeFilter, SBTypeCategory, GetFilterAtIndex,
|
||||
(uint32_t));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeFormat, SBTypeCategory, GetFormatAtIndex,
|
||||
(uint32_t));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeSummary, SBTypeCategory, GetSummaryAtIndex,
|
||||
(uint32_t));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeSynthetic, SBTypeCategory,
|
||||
GetSyntheticAtIndex, (uint32_t));
|
||||
LLDB_REGISTER_METHOD(bool, SBTypeCategory, AddTypeSummary,
|
||||
(lldb::SBTypeNameSpecifier, lldb::SBTypeSummary));
|
||||
LLDB_REGISTER_METHOD(bool, SBTypeCategory, AddTypeSynthetic,
|
||||
(lldb::SBTypeNameSpecifier, lldb::SBTypeSynthetic));
|
||||
LLDB_REGISTER_METHOD(bool, SBTypeCategory, DeleteTypeSynthetic,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
#endif
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeNameSpecifier, SBTypeCategory,
|
||||
GetTypeNameSpecifierForFilterAtIndex, (uint32_t));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeNameSpecifier, SBTypeCategory,
|
||||
GetTypeNameSpecifierForFormatAtIndex, (uint32_t));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeNameSpecifier, SBTypeCategory,
|
||||
GetTypeNameSpecifierForSummaryAtIndex, (uint32_t));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeFilter, SBTypeCategory, GetFilterForType,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeFormat, SBTypeCategory, GetFormatForType,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeFormat, SBTypeCategory, GetFormatAtIndex,
|
||||
(uint32_t));
|
||||
LLDB_REGISTER_METHOD(bool, SBTypeCategory, AddTypeFormat,
|
||||
(lldb::SBTypeNameSpecifier, lldb::SBTypeFormat));
|
||||
LLDB_REGISTER_METHOD(bool, SBTypeCategory, DeleteTypeFormat,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(bool, SBTypeCategory, AddTypeSummary,
|
||||
(lldb::SBTypeNameSpecifier, lldb::SBTypeSummary));
|
||||
LLDB_REGISTER_METHOD(bool, SBTypeCategory, DeleteTypeSummary,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(bool, SBTypeCategory, AddTypeFilter,
|
||||
(lldb::SBTypeNameSpecifier, lldb::SBTypeFilter));
|
||||
LLDB_REGISTER_METHOD(bool, SBTypeCategory, DeleteTypeFilter,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(bool, SBTypeCategory, AddTypeSynthetic,
|
||||
(lldb::SBTypeNameSpecifier, lldb::SBTypeSynthetic));
|
||||
LLDB_REGISTER_METHOD(bool, SBTypeCategory, DeleteTypeSynthetic,
|
||||
(lldb::SBTypeNameSpecifier));
|
||||
LLDB_REGISTER_METHOD(bool, SBTypeCategory, GetDescription,
|
||||
(lldb::SBStream &, lldb::DescriptionLevel));
|
||||
LLDB_REGISTER_METHOD(
|
||||
@ -2628,6 +2632,7 @@ SBRegistry::SBRegistry() {
|
||||
LLDB_REGISTER_METHOD(bool,
|
||||
SBTypeSummary, operator!=,(lldb::SBTypeSummary &));
|
||||
}
|
||||
#ifndef LLDB_DISABLE_PYTHON
|
||||
{
|
||||
LLDB_REGISTER_CONSTRUCTOR(SBTypeSynthetic, ());
|
||||
LLDB_REGISTER_STATIC_METHOD(lldb::SBTypeSynthetic, SBTypeSynthetic,
|
||||
@ -2655,6 +2660,7 @@ SBRegistry::SBRegistry() {
|
||||
LLDB_REGISTER_METHOD(bool,
|
||||
SBTypeSynthetic, operator!=,(lldb::SBTypeSynthetic &));
|
||||
}
|
||||
#endif
|
||||
{
|
||||
LLDB_REGISTER_CONSTRUCTOR(SBUnixSignals, ());
|
||||
LLDB_REGISTER_CONSTRUCTOR(SBUnixSignals, (const lldb::SBUnixSignals &));
|
||||
@ -2710,7 +2716,9 @@ SBRegistry::SBRegistry() {
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeFormat, SBValue, GetTypeFormat, ());
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeSummary, SBValue, GetTypeSummary, ());
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeFilter, SBValue, GetTypeFilter, ());
|
||||
#ifndef LLDB_DISABLE_PYTHON
|
||||
LLDB_REGISTER_METHOD(lldb::SBTypeSynthetic, SBValue, GetTypeSynthetic, ());
|
||||
#endif
|
||||
LLDB_REGISTER_METHOD(lldb::SBValue, SBValue, CreateChildAtOffset,
|
||||
(const char *, uint32_t, lldb::SBType));
|
||||
LLDB_REGISTER_METHOD(lldb::SBValue, SBValue, Cast, (lldb::SBType));
|
||||
|
Loading…
Reference in New Issue
Block a user