Index: lldb/source/Symbol/CMakeLists.txt =================================================================== --- lldb/source/Symbol/CMakeLists.txt +++ lldb/source/Symbol/CMakeLists.txt @@ -1,7 +1,9 @@ set(LLVM_OPTIONAL_SOURCES LocateSymbolFileMacOSX.cpp) if (CMAKE_SYSTEM_NAME MATCHES "Darwin") - set(PLATFORM_SOURCES LocateSymbolFileMacOSX.cpp) + set(PLATFORM_SOURCES + LocateSymbolFileMacOSX.cpp + ) endif() add_lldb_library(lldbSymbol Index: llvm/utils/gn/build/BUILD.gn =================================================================== --- llvm/utils/gn/build/BUILD.gn +++ llvm/utils/gn/build/BUILD.gn @@ -348,12 +348,15 @@ ] } } + + cflags_objcc = cflags_cc } config("no_exceptions") { if (host_os != "win") { cflags_cc = [ "-fno-exceptions" ] } + cflags_objcc = cflags_cc } config("no_rtti") { @@ -362,6 +365,7 @@ } else { cflags_cc = [ "-fno-rtti" ] } + cflags_objcc = cflags_cc } # To make an archive that can be distributed, you need to remove this config and @@ -416,6 +420,16 @@ } } +config("lldb_code") { + if (host_os != "win") { + cflags = [ "-fno-strict-aliasing" ] + } + include_dirs = [ + "//lldb/include", + "$root_gen_dir/lldb/include", + ] +} + config("warn_covered_switch_default") { if (is_clang) { cflags = [ "-Wcovered-switch-default" ] Index: llvm/utils/gn/build/toolchain/BUILD.gn =================================================================== --- llvm/utils/gn/build/toolchain/BUILD.gn +++ llvm/utils/gn/build/toolchain/BUILD.gn @@ -51,6 +51,14 @@ outputs = [ "{{source_out_dir}}/{{label_name}}.{{source_name_part}}.o" ] } + tool("objcxx") { + depfile = "{{output}}.d" + command = "$cxx -MMD -MF $depfile -o {{output}} -c {{source}} {{defines}} {{include_dirs}} {{cflags}} {{cflags_objcc}}" + depsformat = "gcc" + description = "OBJCXX {{output}}" + outputs = [ "{{source_out_dir}}/{{label_name}}.{{source_name_part}}.o" ] + } + tool("asm") { depfile = "{{output}}.d" command = "$cc -MMD -MF $depfile -o {{output}} -c {{source}} {{defines}} {{include_dirs}} {{asmflags}}" Index: llvm/utils/gn/secondary/BUILD.gn =================================================================== --- llvm/utils/gn/secondary/BUILD.gn +++ llvm/utils/gn/secondary/BUILD.gn @@ -20,6 +20,9 @@ "//libcxxabi", ] } + if (current_os == "mac") { + deps += [ "//lldb/test" ] + } if (current_os == "linux" || current_os == "android") { deps += [ "//compiler-rt/test/hwasan" ] } Index: llvm/utils/gn/secondary/lldb/include/lldb/Host/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/include/lldb/Host/BUILD.gn @@ -0,0 +1,58 @@ +import("//llvm/utils/gn/build/libs/xml/enable.gni") +import("//llvm/utils/gn/build/write_cmake_config.gni") +import("libedit.gni") + +# In lldb/cmake/modules/LLDBGenerateConfig.cmake, +# brought in by lldb/cmake/modules/LLDBConfig.cmake, +# brought in by lldb/CMakeLists.txt in the CMake build. +write_cmake_config("Config") { + input = "Config.h.cmake" + output = "$target_gen_dir/Config.h" + values = [ + # FIXME: Actual values for everything. + "LLDB_EDITLINE_USE_WCHAR=", + "LLDB_HAVE_EL_RFUNC_T=", + "HAVE_PPOLL=", + "HAVE_PTSNAME_R=", + "HAVE_PROCESS_VM_READV=", + "HAVE_NR_PROCESS_VM_READV=", + "LLDB_ENABLE_LZMA=", + "LLDB_ENABLE_CURSES=", + "CURSES_HAVE_NCURSES_CURSES_H=", + "LLDB_ENABLE_LUA=", + "LLDB_ENABLE_PYTHON=", + "LLDB_EMBED_PYTHON_HOME=", + + "LLDB_PYTHON_HOME=", + + "LLVM_LIBDIR_SUFFIX=", + + "HAVE_LIBCOMPRESSION=", + ] + + if (lldb_enable_libedit) { + values += [ "LLDB_ENABLE_LIBEDIT=1" ] + } else { + values += [ "LLDB_ENABLE_LIBEDIT=" ] + } + + if (llvm_enable_libxml2) { + values += [ "LLDB_ENABLE_LIBXML2=1" ] + } else { + values += [ "LLDB_ENABLE_LIBXML2=" ] + } + + if (current_os == "win") { + values += [ + "HAVE_SYS_EVENT_H=", + "LLDB_ENABLE_POSIX=", + "LLDB_ENABLE_TERMIOS=", + ] + } else { + values += [ + "HAVE_SYS_EVENT_H=1", + "LLDB_ENABLE_POSIX=1", + "LLDB_ENABLE_TERMIOS=1", + ] + } +} Index: llvm/utils/gn/secondary/lldb/include/lldb/Host/libedit.gni =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/include/lldb/Host/libedit.gni @@ -0,0 +1,9 @@ +declare_args() { + # Whether lldb links against libedit. Set to `true` or `false`, or to + # `"default"` to get the platform default. + lldb_enable_libedit = "default" +} + +if (lldb_enable_libedit == "default") { + lldb_enable_libedit = current_os == "mac" +} Index: llvm/utils/gn/secondary/lldb/source/API/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/API/BUILD.gn @@ -0,0 +1,105 @@ +static_library("liblldb") { + # XXX if win -DEXPORT_LIBLLDB + + # XXX LLDB_BUILD_FRAMEWORK + # XXX LLDB_ENABLE_PYTHON + # XXX LLDB_ENABLE_LUA + + output_name = "liblldb" # XXX lib prefix? + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + #"//lldb/include/lldb/Host:Config", + "//lldb/source:lldbBase", + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/DataFormatters", + "//lldb/source/Expression", + "//lldb/source/Host", + "//lldb/source/Initialization", + "//lldb/source/Interpreter", + "//lldb/source/Plugins:LldbAllPlugins", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//lldb/tools/argdumper:lldb-argdumper", + "//llvm/lib/Support", + ] + + # SBTarget.cpp includes Commands-internal header Commands/CommandObjectBreakpoint.h + include_dirs = [ ".." ] + sources = [ + "SBAddress.cpp", + "SBAttachInfo.cpp", + "SBBlock.cpp", + "SBBreakpoint.cpp", + "SBBreakpointLocation.cpp", + "SBBreakpointName.cpp", + "SBBreakpointOptionCommon.cpp", + "SBBroadcaster.cpp", + "SBCommandInterpreter.cpp", + "SBCommandInterpreterRunOptions.cpp", + "SBCommandReturnObject.cpp", + "SBCommunication.cpp", + "SBCompileUnit.cpp", + "SBData.cpp", + "SBDebugger.cpp", + "SBDeclaration.cpp", + "SBEnvironment.cpp", + "SBError.cpp", + "SBEvent.cpp", + "SBExecutionContext.cpp", + "SBExpressionOptions.cpp", + "SBFile.cpp", + "SBFileSpec.cpp", + "SBFileSpecList.cpp", + "SBFrame.cpp", + "SBFunction.cpp", + "SBHostOS.cpp", + "SBInstruction.cpp", + "SBInstructionList.cpp", + "SBLanguageRuntime.cpp", + "SBLaunchInfo.cpp", + "SBLineEntry.cpp", + "SBListener.cpp", + "SBMemoryRegionInfo.cpp", + "SBMemoryRegionInfoList.cpp", + "SBModule.cpp", + "SBModuleSpec.cpp", + "SBPlatform.cpp", + "SBProcess.cpp", + "SBProcessInfo.cpp", + "SBQueue.cpp", + "SBQueueItem.cpp", + "SBReproducer.cpp", + "SBSection.cpp", + "SBSourceManager.cpp", + "SBStream.cpp", + "SBStringList.cpp", + "SBStructuredData.cpp", + "SBSymbol.cpp", + "SBSymbolContext.cpp", + "SBSymbolContextList.cpp", + "SBTarget.cpp", + "SBThread.cpp", + "SBThreadCollection.cpp", + "SBThreadPlan.cpp", + "SBTrace.cpp", + "SBType.cpp", + "SBTypeCategory.cpp", + "SBTypeEnumMember.cpp", + "SBTypeFilter.cpp", + "SBTypeFormat.cpp", + "SBTypeNameSpecifier.cpp", + "SBTypeSummary.cpp", + "SBTypeSynthetic.cpp", + "SBUnixSignals.cpp", + "SBValue.cpp", + "SBValueList.cpp", + "SBVariablesOptions.cpp", + "SBWatchpoint.cpp", + "SystemInitializerFull.cpp", + ] + + # XXX liblldb.exports or liblldb-private.expoorts + # XXX dep on clang resource directory +} Index: llvm/utils/gn/secondary/lldb/source/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/BUILD.gn @@ -0,0 +1,30 @@ +import("//llvm/utils/gn/build/write_vcsrevision.gni") + +config("write_vcsrevision_config") { + # To pick up the generated inc file. + include_dirs = [ target_gen_dir ] + visibility = [ ":write_vcsrevision" ] +} + +write_vcsrevision("write_vcsversion") { + visibility = [ ":lldbBase" ] + header = "$target_gen_dir/VCSVersion.inc" + names = [ "LLDB" ] + public_configs = [ ":write_vcsrevision_config" ] +} + +static_library("lldbBase") { + configs += [ + "//llvm/utils/gn/build:lldb_code", + + # To pick up clang/Basic/Version.h. + "//llvm/utils/gn/build:clang_code", + ] + sources = [ "lldb.cpp" ] + deps = [ + ":write_vcsversion", + "//clang/lib/Basic", + ] + + # XXX define LLDB_VERSION_STRING +} Index: llvm/utils/gn/secondary/lldb/source/Breakpoint/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Breakpoint/BUILD.gn @@ -0,0 +1,40 @@ +static_library("Breakpoint") { + output_name = "lldbBreakpoint" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/include/lldb/Host:Config", + "//lldb/source/Core", + "//lldb/source/Expression", + "//lldb/source/Interpreter", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + sources = [ + "Breakpoint.cpp", + "BreakpointID.cpp", + "BreakpointIDList.cpp", + "BreakpointList.cpp", + "BreakpointLocation.cpp", + "BreakpointLocationCollection.cpp", + "BreakpointLocationList.cpp", + "BreakpointName.cpp", + "BreakpointOptions.cpp", + "BreakpointPrecondition.cpp", + "BreakpointResolver.cpp", + "BreakpointResolverAddress.cpp", + "BreakpointResolverFileLine.cpp", + "BreakpointResolverFileRegex.cpp", + "BreakpointResolverName.cpp", + "BreakpointResolverScripted.cpp", + "BreakpointSite.cpp", + "BreakpointSiteList.cpp", + "Stoppoint.cpp", + "StoppointCallbackContext.cpp", + "StoppointSite.cpp", + "Watchpoint.cpp", + "WatchpointList.cpp", + "WatchpointOptions.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Commands/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Commands/BUILD.gn @@ -0,0 +1,68 @@ +import("//lldb/utils/TableGen/lldb_tablegen.gni") + +lldb_tablegen("CommandOptions") { + args = [ "-gen-lldb-option-defs" ] + td_file = "Options.td" # FIXME: rename? +} + +static_library("Commands") { + output_name = "lldbCommands" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + ":CommandOptions", + "//llvm/lib/Support", + + # FIXME: + #"//lldb/source", # This is lldbBase. Why is this not a real lib? + + #"//lldb/source/Breakpoint", # FIXME: many-hop dependency cycle. + "//lldb/source/Core", + "//lldb/source/DataFormatters", + + #"//lldb/source/Expression", # FIXME: 2-hop dependency cycle. + "//lldb/source/Host", + + #"//lldb/source/Interpreter", # FIXME: Dependency cycle. + #"//lldb/source/Symbol", # FIXME: many-hop dependency cycle. + #"//lldb/source/Target", # FIXME: 2-hop dependency cycle. + "//lldb/source/Utility", + ] + sources = [ + "CommandCompletions.cpp", + "CommandObjectApropos.cpp", + "CommandObjectBreakpoint.cpp", + "CommandObjectBreakpointCommand.cpp", + "CommandObjectCommands.cpp", + "CommandObjectDisassemble.cpp", + "CommandObjectExpression.cpp", + "CommandObjectFrame.cpp", + "CommandObjectGUI.cpp", + "CommandObjectHelp.cpp", + "CommandObjectLanguage.cpp", + "CommandObjectLog.cpp", + "CommandObjectMemory.cpp", + "CommandObjectMemoryTag.cpp", + "CommandObjectMultiword.cpp", + "CommandObjectPlatform.cpp", + "CommandObjectPlugin.cpp", + "CommandObjectProcess.cpp", + "CommandObjectQuit.cpp", + "CommandObjectRegexCommand.cpp", + "CommandObjectRegister.cpp", + "CommandObjectReproducer.cpp", + "CommandObjectScript.cpp", + "CommandObjectSession.cpp", + "CommandObjectSettings.cpp", + "CommandObjectSource.cpp", + "CommandObjectStats.cpp", + "CommandObjectTarget.cpp", + "CommandObjectThread.cpp", + "CommandObjectThreadUtil.cpp", + "CommandObjectTrace.cpp", + "CommandObjectType.cpp", + "CommandObjectVersion.cpp", + "CommandObjectWatchpoint.cpp", + "CommandObjectWatchpointCommand.cpp", + "CommandOptionsProcessLaunch.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Core/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Core/BUILD.gn @@ -0,0 +1,94 @@ +import("//lldb/utils/TableGen/lldb_tablegen.gni") + +lldb_tablegen("CoreProperties") { + args = [ "-gen-lldb-property-defs" ] +} + +lldb_tablegen("CorePropertiesEnum") { + args = [ "-gen-lldb-property-enum-defs" ] + td_file = "CoreProperties.td" +} + +static_library("Core") { + output_name = "lldbCore" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + ":CoreProperties", + ":CorePropertiesEnum", + "//clang/lib/Driver", + + #"//lldb/source/Breakpoint", # Dependency cycle. + #"//lldb/source/DataFormatters", # Dependency cycle. + #"//lldb/source/Expression", # Dependency cycle. + "//lldb/source/Host", + + #"//lldb/source/Interpreter", # Dependency cycle. + #"//lldb/source/Symbol", # Dependency cycle. + #"//lldb/source/Target", # Dependency cycle. + "//lldb/source/Utility", + "//llvm/lib/Demangle", + "//llvm/lib/Support", + + #"//lldb/source/Plugins/Language/CPlusPlus", # 3-hop dependency cycle. + #"//lldb/source/Plugins/Language/ObjC", # Many-hop dependency cycle. + + # FIXME: + # ${LLDB_CURSES_LIBS} + ] + + # FIXME: Link curses, libedit if neededdit if needed. + include_dirs = [ ".." ] + sources = [ + "Address.cpp", + "AddressRange.cpp", + "AddressResolver.cpp", + "AddressResolverFileLine.cpp", + "Communication.cpp", + "Debugger.cpp", + "Declaration.cpp", + "Disassembler.cpp", + "DumpDataExtractor.cpp", + "DumpRegisterValue.cpp", + "DynamicLoader.cpp", + "EmulateInstruction.cpp", + "FileLineResolver.cpp", + "FileSpecList.cpp", + "FormatEntity.cpp", + "Highlighter.cpp", + "IOHandler.cpp", + "IOHandlerCursesGUI.cpp", + "Mangled.cpp", + "Module.cpp", + "ModuleChild.cpp", + "ModuleList.cpp", + "Opcode.cpp", + "PluginManager.cpp", + "Progress.cpp", + "RichManglingContext.cpp", + "SearchFilter.cpp", + "Section.cpp", + "SourceLocationSpec.cpp", + "SourceManager.cpp", + "StreamAsynchronousIO.cpp", + "StreamFile.cpp", + "UserSettingsController.cpp", + "Value.cpp", + "ValueObject.cpp", + "ValueObjectCast.cpp", + "ValueObjectChild.cpp", + "ValueObjectConstResult.cpp", + "ValueObjectConstResultCast.cpp", + "ValueObjectConstResultChild.cpp", + "ValueObjectConstResultImpl.cpp", + "ValueObjectDynamicValue.cpp", + "ValueObjectList.cpp", + "ValueObjectMemory.cpp", + "ValueObjectRegister.cpp", + "ValueObjectSyntheticFilter.cpp", + "ValueObjectUpdater.cpp", + "ValueObjectVariable.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/DataFormatters/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/DataFormatters/BUILD.gn @@ -0,0 +1,31 @@ +static_library("DataFormatters") { + output_name = "lldbDataFormatters" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + + #"//lldb/source/Interpreter", # FIXME: Dependency cycle. + #"//lldb/source/Symbol", # FIXME: 3-hop Dependency cycle (DataFormatters->Symbol->Expression->Interpreter->DataFormatters) + #"//lldb/source/Target", # FIXME: 3-hop Dependency cycle (DataFormatters->Target->Expression->Interpreter->DataFormatters) + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + sources = [ + "CXXFunctionPointer.cpp", + "DataVisualization.cpp", + "DumpValueObjectOptions.cpp", + "FormatCache.cpp", + "FormatClasses.cpp", + "FormatManager.cpp", + "FormattersHelpers.cpp", + "LanguageCategory.cpp", + "StringPrinter.cpp", + "TypeCategory.cpp", + "TypeCategoryMap.cpp", + "TypeFormat.cpp", + "TypeSummary.cpp", + "TypeSynthetic.cpp", + "ValueObjectPrinter.cpp", + "VectorType.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Expression/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Expression/BUILD.gn @@ -0,0 +1,39 @@ +static_library("Expression") { + output_name = "lldbExpression" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Interpreter", + "//lldb/source/Plugins/ObjectFile/JIT", + + #"//lldb/source/Symbol", # FIXME: Dependency cycle. + #"//lldb/source/Target", # FIXME: Dependency cycle. + "//lldb/source/Utility", + "//llvm/lib/ExecutionEngine", + "//llvm/lib/IR", + "//llvm/lib/Support", + + #"//lldb/source/Plugins/Language/CPlusPlus", # 4-hop dependency cycle. + + # FIXME: + # DEPENDS + # intrinsics_gen + ] + include_dirs = [ ".." ] + sources = [ + "DWARFExpression.cpp", + "DiagnosticManager.cpp", + "Expression.cpp", + "ExpressionVariable.cpp", + "FunctionCaller.cpp", + "IRExecutionUnit.cpp", + "IRInterpreter.cpp", + "IRMemoryMap.cpp", + "LLVMUserExpression.cpp", + "Materializer.cpp", + "REPL.cpp", + "UserExpression.cpp", + "UtilityFunction.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Host/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Host/BUILD.gn @@ -0,0 +1,155 @@ +import("//lldb/include/lldb/Host/libedit.gni") + +static_library("Host") { + output_name = "lldbHost" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Utility", + "//llvm/lib/Object", + "//llvm/lib/Support", + "//llvm/utils/gn/build/libs/xml", + + # FIXME: + # LINK_LIBS + # ${EXTRA_LIBS} + # ${LLDBObjCLibs} + ] + sources = [ + "common/File.cpp", + "common/FileAction.cpp", + "common/FileCache.cpp", + "common/FileSystem.cpp", + "common/GetOptInc.cpp", + "common/Host.cpp", + "common/HostInfoBase.cpp", + "common/HostNativeThreadBase.cpp", + "common/HostProcess.cpp", + "common/HostThread.cpp", + "common/LZMA.cpp", + "common/LockFileBase.cpp", + "common/MainLoop.cpp", + "common/MonitoringProcessLauncher.cpp", + "common/NativeProcessProtocol.cpp", + "common/NativeRegisterContext.cpp", + "common/NativeThreadProtocol.cpp", + "common/NativeWatchpointList.cpp", + "common/OptionParser.cpp", + "common/PipeBase.cpp", + "common/ProcessLaunchInfo.cpp", + "common/ProcessRunLock.cpp", + "common/PseudoTerminal.cpp", + "common/Socket.cpp", + "common/SocketAddress.cpp", + "common/StringConvert.cpp", + "common/TCPSocket.cpp", + "common/Terminal.cpp", + "common/ThreadLauncher.cpp", + "common/UDPSocket.cpp", + "common/XML.cpp", + ] + + if (lldb_enable_libedit) { + libs = [ "edit" ] + sources += [ "common/Editline.cpp" ] + if (host_os == "mac") { + libs += [ "curses" ] # For USE_SETUPTERM_WORKAROUND :/ + } + } + + # XXX why is this separate + sources += [ "posix/ConnectionFileDescriptorPosix.cpp" ] + + if (current_os == "win") { + sources += [ + "windows/ConnectionGenericFileWindows.cpp", + "windows/FileSystem.cpp", + "windows/Host.cpp", + "windows/HostInfoWindows.cpp", + "windows/HostProcessWindows.cpp", + "windows/HostThreadWindows.cpp", + "windows/LockFileWindows.cpp", + "windows/PipeWindows.cpp", + "windows/ProcessLauncherWindows.cpp", + "windows/ProcessRunLock.cpp", + "windows/Windows.cpp", + ] + } else { + sources += [ + "posix/DomainSocket.cpp", + "posix/FileSystemPosix.cpp", + "posix/HostInfoPosix.cpp", + "posix/HostProcessPosix.cpp", + "posix/HostThreadPosix.cpp", + "posix/LockFilePosix.cpp", + "posix/PipePosix.cpp", + "posix/ProcessLauncherPosixFork.cpp", + ] + } + + if (current_os == "mac") { + sources += [ + "macosx/cfcpp/CFCBundle.cpp", + "macosx/cfcpp/CFCData.cpp", + "macosx/cfcpp/CFCMutableArray.cpp", + "macosx/cfcpp/CFCMutableDictionary.cpp", + "macosx/cfcpp/CFCMutableSet.cpp", + "macosx/cfcpp/CFCString.cpp", + ] + deps += [ "macosx/objcxx" ] + + # FIXME: Maybe define NO_XPC_SERVICES + } + + if (current_os == "linux" || current_os == "android") { + sources += [ + "linux/AbstractSocket.cpp", + "linux/Host.cpp", + "linux/HostInfoLinux.cpp", + "linux/LibcGlue.cpp", + "linux/Support.cpp", + ] + } + if (current_os == "android") { + sources += [ + "android/HostInfoAndroid.cpp", + "android/LibcGlue.cpp", + ] + } + + if (current_os == "freebsd") { + sources += [ + "freebsd/Host.cpp", + "freebsd/HostInfoFreeBSD.cpp", + ] + } + if (current_os == "netbsd") { + sources += [ + "netbsd/HostInfoNetBSD.cpp", + "netbsd/HostNetBSD.cpp", + ] + } + if (current_os == "openbsd") { + sources += [ + "openbsd/Host.cpp", + "openbsd/HostInfoOpenBSD.cpp", + ] + } + + # FIXME: + # set(EXTRA_LIBS) + # if (CMAKE_SYSTEM_NAME MATCHES "NetBSD") + # list(APPEND EXTRA_LIBS kvm) + # endif() + # if (HAVE_LIBDL) + # list(APPEND EXTRA_LIBS ${CMAKE_DL_LIBS}) + # endif() + # if (LLDB_ENABLE_LIBEDIT) + # list(APPEND EXTRA_LIBS ${LibEdit_LIBRARIES}) + # endif() + # if (LLDB_ENABLE_LZMA) + # list(APPEND EXTRA_LIBS ${LIBLZMA_LIBRARIES}) + # endif() + # if (WIN32) + # list(APPEND LLDB_SYSTEM_LIBS psapi) + # endif() +} Index: llvm/utils/gn/secondary/lldb/source/Host/macosx/objcxx/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Host/macosx/objcxx/BUILD.gn @@ -0,0 +1,20 @@ +static_library("objcxx") { + output_name = "lldbHostMacOSXObjCXX" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + include_dirs = [ "//lldb/source" ] # Includes internal headers from Utility. + cflags_objcc = [ "-fno-objc-exceptions" ] + sources = [ + "Host.mm", + "HostInfoMacOSX.mm", + "HostThreadMacOSX.mm", + ] + frameworks = [ + "Foundation.framework", + "CoreServices.framework", + "Security.framework", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Initialization/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Initialization/BUILD.gn @@ -0,0 +1,22 @@ +static_library("Initialization") { + output_name = "lldbInitialization" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Plugins/Process/gdb-remote", + + # XXX: + # lldbPluginProcessPOSIX on linux/android + # lldbPluginProcessWindowsCommon on win + "//llvm/lib/Support", + ] + + # SystemInitializerCommon.cpp includes headers from Plugins/Process/.... + include_dirs = [ ".." ] + sources = [ + "SystemInitializer.cpp", + "SystemInitializerCommon.cpp", + "SystemLifetimeManager.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Interpreter/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Interpreter/BUILD.gn @@ -0,0 +1,76 @@ +import("//lldb/utils/TableGen/lldb_tablegen.gni") + +lldb_tablegen("InterpreterProperties") { + args = [ "-gen-lldb-property-defs" ] +} + +lldb_tablegen("InterpreterPropertiesEnum") { + args = [ "-gen-lldb-property-enum-defs" ] + td_file = "InterpreterProperties.td" +} + +static_library("Interpreter") { + output_name = "lldbInterpreter" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + ":InterpreterProperties", + ":InterpreterPropertiesEnum", + "//lldb/source/Commands", + "//lldb/source/Core", + "//lldb/source/DataFormatters", + "//lldb/source/Host", + + #"//lldb/source/Target", # FIXME: 2-hop dependency cyle (Interpreter->Target->Expression->Interpreter) + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Reaches into source/Commands implementation details. + include_dirs = [ ".." ] + sources = [ + "CommandAlias.cpp", + "CommandHistory.cpp", + "CommandInterpreter.cpp", + "CommandObject.cpp", + "CommandOptionValidators.cpp", + "CommandReturnObject.cpp", + "OptionArgParser.cpp", + "OptionGroupArchitecture.cpp", + "OptionGroupBoolean.cpp", + "OptionGroupFile.cpp", + "OptionGroupFormat.cpp", + "OptionGroupOutputFile.cpp", + "OptionGroupPlatform.cpp", + "OptionGroupPythonClassWithDict.cpp", + "OptionGroupString.cpp", + "OptionGroupUInt64.cpp", + "OptionGroupUUID.cpp", + "OptionGroupValueObjectDisplay.cpp", + "OptionGroupVariable.cpp", + "OptionGroupWatchpoint.cpp", + "OptionValue.cpp", + "OptionValueArch.cpp", + "OptionValueArgs.cpp", + "OptionValueArray.cpp", + "OptionValueBoolean.cpp", + "OptionValueChar.cpp", + "OptionValueDictionary.cpp", + "OptionValueEnumeration.cpp", + "OptionValueFileColonLine.cpp", + "OptionValueFileSpec.cpp", + "OptionValueFileSpecList.cpp", + "OptionValueFormat.cpp", + "OptionValueFormatEntity.cpp", + "OptionValueLanguage.cpp", + "OptionValuePathMappings.cpp", + "OptionValueProperties.cpp", + "OptionValueRegex.cpp", + "OptionValueSInt64.cpp", + "OptionValueString.cpp", + "OptionValueUInt64.cpp", + "OptionValueUUID.cpp", + "Options.cpp", + "Property.cpp", + "ScriptInterpreter.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/ABI/X86/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/ABI/X86/BUILD.gn @@ -0,0 +1,20 @@ +static_library("X86") { + output_name = "lldbPluginABIX86" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//llvm/lib/Support", + ] + + # Uses source-relative paths for own includes. + include_dirs = [ "//lldb/source" ] + sources = [ + "ABIMacOSX_i386.cpp", + "ABISysV_i386.cpp", + "ABISysV_x86_64.cpp", + "ABIWindows_x86_64.cpp", + "ABIX86.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Architecture/PPC64/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Architecture/PPC64/BUILD.gn @@ -0,0 +1,15 @@ +static_library("PPC64") { + output_name = "lldbPluginArchitecturePPC64" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Plugins/Process/Utility", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Uses source-relative paths for own includes. + include_dirs = [ "//lldb/source" ] + sources = [ "ArchitecturePPC64.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/BUILD.gn @@ -0,0 +1,230 @@ +import("//llvm/lib/Target/targets.gni") +import("//llvm/utils/gn/build/write_cmake_config.gni") + +# In the CMake build, each plugin calls `add_lldb_library(name PLUGIN ...)`, +# which implicitly adds the plugin name to the LLDB_PLUGINS list. +# A few places then query that list and add dependencies on it. +# lldb/source/Plugins/CMakeList.txt then does string munging on the list of +# plugin names to generate Plugins.def. +# In the GN build, we instead have an explicit list of all plugins here. +# Every entry in this list is a (GN target, LLDB_PLUGIN Plugins.def name) pair. +lldb_plugins = [] +if (llvm_build_X86) { + lldb_plugins += [ [ + "//lldb/source/Plugins/ABI/X86", + "ABIX86", + ] ] +} +lldb_plugins += [ + [ + "//lldb/source/Plugins/Architecture/PPC64", + "ArchitecturePPC64", + ], + [ + "//lldb/source/Plugins/Disassembler/LLVMC", + "DisassemblerLLVMC", + ], + [ + "//lldb/source/Plugins/DynamicLoader/Darwin-Kernel", + "DynamicLoaderDarwinKernel", + ], + [ + "//lldb/source/Plugins/DynamicLoader/MacOSX-DYLD", + "DynamicLoaderMacOSXDYLD", + ], + [ + "//lldb/source/Plugins/DynamicLoader/POSIX-DYLD", + "DynamicLoaderPosixDYLD", + ], + [ + "//lldb/source/Plugins/DynamicLoader/Static", + "DynamicLoaderStatic", + ], + [ + "//lldb/source/Plugins/Instruction/ARM", + "InstructionARM", + ], + [ + "//lldb/source/Plugins/JITLoader/GDB", + "JITLoaderGDB", + ], + [ + "//lldb/source/Plugins/Language/CPlusPlus", + "CPlusPlusLanguage", + ], + [ + "//lldb/source/Plugins/Language/ObjC", + "ObjCLanguage", + ], + [ + "//lldb/source/Plugins/Language/ObjCPlusPlus", + "ObjCPlusPlusLanguage", + ], + [ + "//lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI", + "CXXItaniumABI", + ], + [ + "//lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime", + "AppleObjCRuntime", + ], + [ + "//lldb/source/Plugins/LanguageRuntime/RenderScript/RenderScriptRuntime", + "RenderScriptRuntime", + ], + [ + "//lldb/source/Plugins/ObjectContainer/BSD-Archive", + "ObjectContainerBSDArchive", + ], + [ + "//lldb/source/Plugins/ObjectContainer/Universal-Mach-O", + "ObjectContainerMachOArchive", + ], + [ + "//lldb/source/Plugins/ObjectFile/Breakpad", + "ObjectFileBreakpad", + ], + [ + "//lldb/source/Plugins/ObjectFile/ELF", + "ObjectFileELF", + ], + [ + "//lldb/source/Plugins/ObjectFile/JIT", + "ObjectFileJIT", + ], + [ + "//lldb/source/Plugins/ObjectFile/Mach-O", + "ObjectFileMachO", + ], + [ + "//lldb/source/Plugins/ObjectFile/PDB", + "ObjectFilePDB", + ], + [ + "//lldb/source/Plugins/ObjectFile/PECOFF", + "ObjectFilePECOFF", + ], + [ + "//lldb/source/Plugins/ObjectFile/wasm", + "ObjectFileWasm", + ], + [ + "//lldb/source/Plugins/Platform/MacOSX", + "PlatformMacOSX", + ], + [ + "//lldb/source/Plugins/Platform/Windows", + "PlatformWindows", + ], + [ + "//lldb/source/Plugins/Process/elf-core", + "ProcessElfCore", + ], + [ + "//lldb/source/Plugins/Process/gdb-remote", + "", # Uses LLDB_PROCESS_GDB_PLUGIN instead. + ], + [ + "//lldb/source/Plugins/Process/mach-core", + "ProcessMachCore", + ], + [ + "//lldb/source/Plugins/Process/minidump", + "ProcessMinidump", + ], + [ + "//lldb/source/Plugins/ScriptInterpreter/None", + "", # Uses LLDB_SCRIPT_PLUGIN instead. + ], + [ + "//lldb/source/Plugins/SymbolFile/Breakpad", + "SymbolFileBreakpad", + ], + [ + "//lldb/source/Plugins/SymbolFile/DWARF", + "SymbolFileDWARF", + ], + [ + "//lldb/source/Plugins/SymbolFile/PDB", + "SymbolFilePDB", + ], + [ + "//lldb/source/Plugins/SymbolFile/Symtab", + "SymbolFileSymtab", + ], +] +if (current_os == "mac") { + lldb_plugins += [ [ + "//lldb/source/Plugins/SymbolVendor/MacOSX", + "SymbolVendorMacOSX", + ] ] +} +lldb_plugins += [ + [ + "//lldb/source/Plugins/SymbolVendor/ELF", + "SymbolVendorELF", + ], + + [ + "//lldb/source/Plugins/SymbolVendor/wasm", + "SymbolVendorWasm", + ], + + [ + "//lldb/source/Plugins/TypeSystem/Clang", + "TypeSystemClang", + ], + + [ + "//lldb/source/Plugins/UnwindAssembly/InstEmulation", + "UnwindAssemblyInstEmulation", + ], + [ + "//lldb/source/Plugins/UnwindAssembly/x86", + "UnwindAssemblyX86", + ], +] + +write_cmake_config("Plugins.def") { + input = "Plugins.def.in" + output = "$target_gen_dir/Plugins.def" + + enum_plugins = "" + foreach(plugin, lldb_plugins) { + plugin_id = plugin[1] + if (plugin_id != "") { + # \n is a literal '\' followed by a literal 'n', not a newline character. + # write_cmake_config.py replaces it with a real newline. + enum_plugins += "LLDB_PLUGIN(" + plugin_id + ")\n" + } + } + + deps = [ "//lldb/source/Plugins/ScriptInterpreter/None" ] + enum_plugins += "LLDB_SCRIPT_PLUGIN(ScriptInterpreterNone)" + + values = [ "LLDB_ENUM_PLUGINS=" + enum_plugins ] + + # These are in separate variables to make sure ProcessWindowsCommon is + # initalized after all plugins, but before ProcessGDBRemote. + if (current_os == "win") { + values += [ "LLDB_PROCESS_WINDOWS_PLUGIN=LLDB_PLUGIN(XXX)" ] + } else { + values += [ "LLDB_PROCESS_WINDOWS_PLUGIN=" ] + } + values += [ "LLDB_PROCESS_GDB_PLUGIN=LLDB_PLUGIN(ProcessGDBRemote)" ] +} + +config("AllLldbPlugins_config") { + visibility = [ ":AllLldbPlugins" ] + + # To pick up Plugins.def. + include_dirs = [ "$root_gen_dir/lldb/source" ] +} + +group("LldbAllPlugins") { + deps = [ ":Plugins.def" ] + foreach(plugin, lldb_plugins) { + deps += [ plugin[0] ] + } + public_configs = [ ":AllLldbPlugins_config" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Disassembler/LLVMC/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Disassembler/LLVMC/BUILD.gn @@ -0,0 +1,15 @@ +static_library("LLVMC") { + output_name = "lldbPluginDisassemblerLLVMC" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//llvm/lib/ExecutionEngine/RuntimeDyld", + "//llvm/lib/MC", + "//llvm/lib/MC/MCDisassembler", + "//llvm/lib/Support", + "//llvm/lib/Target:TargetsToBuild", + ] + sources = [ "DisassemblerLLVMC.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/DynamicLoader/Darwin-Kernel/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/DynamicLoader/Darwin-Kernel/BUILD.gn @@ -0,0 +1,32 @@ +import("//lldb/utils/TableGen/lldb_tablegen.gni") + +lldb_tablegen("DynamicLoaderDarwinKernelProperties") { + args = [ "-gen-lldb-property-defs" ] +} + +lldb_tablegen("DynamicLoaderDarwinKernelPropertiesEnum") { + args = [ "-gen-lldb-property-enum-defs" ] + td_file = "DynamicLoaderDarwinKernelProperties.td" +} + +static_library("Darwin-Kernel") { + output_name = "lldbPluginDynamicLoaderDarwinKernel" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + ":DynamicLoaderDarwinKernelProperties", + ":DynamicLoaderDarwinKernelPropertiesEnum", + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Interpreter", + "//lldb/source/Plugins/Platform/MacOSX", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/Platform/MacOSX. + include_dirs = [ "//lldb/source" ] + sources = [ "DynamicLoaderDarwinKernel.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/BUILD.gn @@ -0,0 +1,26 @@ +static_library("MacOSX-DYLD") { + output_name = "lldbPluginDynamicLoaderMacOSXDYLD" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/Expression", + "//lldb/source/Host", + "//lldb/source/Plugins/TypeSystem/Clang", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/LanguageRuntime/ObjC. + include_dirs = [ "//lldb/source" ] + sources = [ + "DynamicLoaderDarwin.cpp", + "DynamicLoaderMacOS.cpp", + "DynamicLoaderMacOSXDYLD.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/DynamicLoader/POSIX-DYLD/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/DynamicLoader/POSIX-DYLD/BUILD.gn @@ -0,0 +1,25 @@ +static_library("POSIX-DYLD") { + output_name = "lldbPluginDynamicLoaderPosixDYLD" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/Host", + + #"//lldb/source/Plugins/Process/elf-core", # Dependency cycle. + "//lldb/source/Plugins/Process/Utility", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/Process/Utility. + include_dirs = [ "//lldb/source" ] + sources = [ + "DYLDRendezvous.cpp", + "DynamicLoaderPOSIXDYLD.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/DynamicLoader/Static/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/DynamicLoader/Static/BUILD.gn @@ -0,0 +1,12 @@ +static_library("Static") { + output_name = "lldbPluginDynamicLoaderStatic" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + ] + sources = [ "DynamicLoaderStatic.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/ExpressionParser/Clang/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/ExpressionParser/Clang/BUILD.gn @@ -0,0 +1,68 @@ +static_library("Clang") { + output_name = "lldbPluginExpressionParserClang" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//clang/lib/AST", + "//clang/lib/CodeGen", + "//clang/lib/Driver", + "//clang/lib/Edit", + "//clang/lib/Frontend", + "//clang/lib/Frontend/Rewrite", + "//clang/lib/Lex", + "//clang/lib/Parse", + "//clang/lib/Rewrite", + "//clang/lib/Sema", + "//clang/lib/Serialization", + "//lldb/source/Core", + "//lldb/source/Expression", + "//lldb/source/Host", + "//lldb/source/Interpreter", + + #"//lldb/source/Plugins/Language/CPlusPlus", # 3-hop dependency cycle + "//lldb/source/Plugins/LanguageRuntime/CPlusPlus", + "//lldb/source/Plugins/LanguageRuntime/ObjC", + "//lldb/source/Plugins/LanguageRuntime/RenderScript/RenderScriptRuntime", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/ExecutionEngine", + "//llvm/lib/ExecutionEngine/MCJIT", + + #"//lldb/source/Plugins/TypeSystem/Clang", # Dependency cycle + "//llvm/lib/IR", + "//llvm/lib/Support", + "//llvm/lib/Transforms/IPO", + ] + + # Uses source-relative paths for own includes (!) + include_dirs = [ "//lldb/source" ] + sources = [ + "ASTResultSynthesizer.cpp", + "ASTStructExtractor.cpp", + "ASTUtils.cpp", + "ClangASTImporter.cpp", + "ClangASTMetadata.cpp", + "ClangASTSource.cpp", + "ClangDeclVendor.cpp", + "ClangExpressionDeclMap.cpp", + "ClangExpressionParser.cpp", + "ClangExpressionSourceCode.cpp", + "ClangExpressionVariable.cpp", + "ClangExternalASTSourceCallbacks.cpp", + "ClangFunctionCaller.cpp", + "ClangHost.cpp", + "ClangModulesDeclVendor.cpp", + "ClangPersistentVariables.cpp", + "ClangUserExpression.cpp", + "ClangUtil.cpp", + "ClangUtilityFunction.cpp", + "CppModuleConfiguration.cpp", + "CxxModuleHandler.cpp", + "IRDynamicChecks.cpp", + "IRForTarget.cpp", + "NameSearchContext.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Instruction/ARM/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Instruction/ARM/BUILD.gn @@ -0,0 +1,20 @@ +static_library("ARM") { + output_name = "lldbPluginInstructionARM" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Interpreter", + "//lldb/source/Plugins/Process/Utility", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/Process/Utility. + include_dirs = [ "//lldb/source" ] + sources = [ + "EmulateInstructionARM.cpp", + "EmulationStateARM.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/JITLoader/GDB/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/JITLoader/GDB/BUILD.gn @@ -0,0 +1,31 @@ +import("//lldb/utils/TableGen/lldb_tablegen.gni") + +lldb_tablegen("JITLoaderGDBProperties") { + args = [ "-gen-lldb-property-defs" ] +} + +lldb_tablegen("JITLoaderGDBPropertiesEnum") { + args = [ "-gen-lldb-property-enum-defs" ] + td_file = "JITLoaderGDBProperties.td" +} + +static_library("GDB") { + output_name = "lldbPluginJITLoaderGDB" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + ":JITLoaderGDBProperties", + ":JITLoaderGDBPropertiesEnum", + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/Interpreter", + "//lldb/source/Plugins/ObjectFile/Mach-O", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/ObjectFile/Mach-O. + include_dirs = [ "//lldb/source" ] + sources = [ "JITLoaderGDB.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Language/CPlusPlus/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Language/CPlusPlus/BUILD.gn @@ -0,0 +1,44 @@ +static_library("CPlusPlus") { + output_name = "lldbPluginCPlusPlusLanguage" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//lldb/source/Core", + "//lldb/source/DataFormatters", + "//lldb/source/Host", + "//lldb/source/Plugins/Language/ClangCommon", + "//lldb/source/Plugins/LanguageRuntime/CPlusPlus", + "//lldb/source/Plugins/TypeSystem/Clang", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/Language/ClangCommon. + include_dirs = [ "//lldb/source" ] + sources = [ + "BlockPointer.cpp", + "CPlusPlusLanguage.cpp", + "CPlusPlusNameParser.cpp", + "CxxStringTypes.cpp", + "LibCxx.cpp", + "LibCxxAtomic.cpp", + "LibCxxBitset.cpp", + "LibCxxInitializerList.cpp", + "LibCxxList.cpp", + "LibCxxMap.cpp", + "LibCxxOptional.cpp", + "LibCxxQueue.cpp", + "LibCxxTuple.cpp", + "LibCxxUnorderedMap.cpp", + "LibCxxVariant.cpp", + "LibCxxVector.cpp", + "LibStdcpp.cpp", + "LibStdcppTuple.cpp", + "LibStdcppUniquePointer.cpp", + "MSVCUndecoratedNameParser.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Language/ClangCommon/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Language/ClangCommon/BUILD.gn @@ -0,0 +1,13 @@ +static_library("ClangCommon") { + output_name = "lldbPluginClangCommon" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + sources = [ "ClangHighlighter.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Language/ObjC/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Language/ObjC/BUILD.gn @@ -0,0 +1,39 @@ +static_library("ObjC") { + output_name = "lldbPluginObjCLanguage" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//clang/lib/AST", + "//lldb/source/Core", + "//lldb/source/DataFormatters", + "//lldb/source/Expression", + "//lldb/source/Host", + "//lldb/source/Plugins/Language/ClangCommon", + "//lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + + #"//lldb/source/Plugins/TypeSystem/Clang", # 3-hop dependency cycle. + "//llvm/lib/Support", + ] + + # Uses source-relative includes for own headers. + include_dirs = [ "//lldb/source" ] + sources = [ + "CF.cpp", + "CFBasicHash.cpp", + "Cocoa.cpp", + "CoreMedia.cpp", + "NSArray.cpp", + "NSDictionary.cpp", + "NSError.cpp", + "NSException.cpp", + "NSIndexPath.cpp", + "NSSet.cpp", + "NSString.cpp", + "ObjCLanguage.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Language/ObjCPlusPlus/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Language/ObjCPlusPlus/BUILD.gn @@ -0,0 +1,16 @@ +static_library("ObjCPlusPlus") { + output_name = "lldbPluginObjCPlusPlusLanguage" + configs += [ + #"//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Plugins/Language/ClangCommon", + "//lldb/source/Target", + ] + + # Reaches into Plugins/Language/ClangCommon. + include_dirs = [ "//lldb/source" ] + sources = [ "ObjCPlusPlusLanguage.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/LanguageRuntime/CPlusPlus/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/LanguageRuntime/CPlusPlus/BUILD.gn @@ -0,0 +1,10 @@ +static_library("CPlusPlus") { + output_name = "lldbPluginCPPRuntime" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Symbol", + "//lldb/source/Target", + ] + sources = [ "CPPLanguageRuntime.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/BUILD.gn @@ -0,0 +1,20 @@ +static_library("ItaniumABI") { + output_name = "lldbPluginCXXItaniumABI" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/Interpreter", + "//lldb/source/Plugins/LanguageRuntime/CPlusPlus", + "//lldb/source/Plugins/TypeSystem/Clang", + "//lldb/source/Symbol", + "//lldb/source/Target", + ] + + # Reaches into Plugins/LanguageRuntime/CPlusPlus. + include_dirs = [ "//lldb/source" ] + sources = [ "ItaniumABILanguageRuntime.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/BUILD.gn @@ -0,0 +1,36 @@ +static_library("AppleObjCRuntime") { + output_name = "lldbPluginAppleObjCRuntime" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//clang/lib/AST", + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/Expression", + "//lldb/source/Host", + "//lldb/source/Interpreter", + "//lldb/source/Plugins/ExpressionParser/Clang", + "//lldb/source/Plugins/LanguageRuntime/CPlusPlus", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + + #"//lldb/source/Plugins/TypeSystem/Clang", # 4-hop dependency cycle. + "//llvm/lib/Support", + ] + + # Reaches into Plugins/ExpressionParser/Clang. + include_dirs = [ "//lldb/source" ] + sources = [ + "AppleObjCClassDescriptorV2.cpp", + "AppleObjCDeclVendor.cpp", + "AppleObjCRuntime.cpp", + "AppleObjCRuntimeV1.cpp", + "AppleObjCRuntimeV2.cpp", + "AppleObjCTrampolineHandler.cpp", + "AppleObjCTypeEncodingParser.cpp", + "AppleThreadPlanStepThroughObjCTrampoline.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/LanguageRuntime/ObjC/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/LanguageRuntime/ObjC/BUILD.gn @@ -0,0 +1,17 @@ +static_library("ObjC") { + output_name = "lldbPluginObjCRuntime" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + ] + + # Reaches into Plugins/TypeSystem/Clang. + include_dirs = [ "//lldb/source" ] + sources = [ "ObjCLanguageRuntime.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/LanguageRuntime/RenderScript/RenderScriptRuntime/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/LanguageRuntime/RenderScript/RenderScriptRuntime/BUILD.gn @@ -0,0 +1,31 @@ +static_library("RenderScriptRuntime") { + output_name = "lldbPluginRenderScriptRuntime" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//clang/lib/Basic", + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/DataFormatters", + "//lldb/source/Expression", + "//lldb/source/Host", + "//lldb/source/Interpreter", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//llvm/lib/IR", + "//llvm/lib/IRReader", + "//llvm/lib/Support", + "//llvm/lib/Target", + ] + + # Reaches into Plugins/LanguageRuntime/CPlusPlus. + include_dirs = [ "//lldb/source" ] + sources = [ + "RenderScriptExpressionOpts.cpp", + "RenderScriptRuntime.cpp", + "RenderScriptScriptGroup.cpp", + "RenderScriptx86ABIFixups.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/ObjectContainer/BSD-Archive/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/ObjectContainer/BSD-Archive/BUILD.gn @@ -0,0 +1,11 @@ +static_library("BSD-Archive") { + output_name = "lldbPluginObjectContainerBSDArchive" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Symbol", + "//llvm/lib/Support", + ] + sources = [ "ObjectContainerBSDArchive.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/ObjectContainer/Universal-Mach-O/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/ObjectContainer/Universal-Mach-O/BUILD.gn @@ -0,0 +1,12 @@ +static_library("Universal-Mach-O") { + output_name = "lldbPluginObjectContainerMachOArchive" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + ] + sources = [ "ObjectContainerUniversalMachO.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/Breakpad/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/Breakpad/BUILD.gn @@ -0,0 +1,18 @@ +static_library("Breakpad") { + output_name = "lldbPluginObjectFileBreakpad" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Symbol", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/Process/Utility. + include_dirs = [ "//lldb/source" ] + sources = [ + "BreakpadRecords.cpp", + "ObjectFileBreakpad.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/ELF/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/ELF/BUILD.gn @@ -0,0 +1,17 @@ +static_library("ELF") { + output_name = "lldbPluginObjectFileELF" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//llvm/lib/BinaryFormat", + "//llvm/lib/Object", + "//llvm/lib/Support", + ] + sources = [ + "ELFHeader.cpp", + "ObjectFileELF.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/JIT/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/JIT/BUILD.gn @@ -0,0 +1,13 @@ +static_library("JIT") { + output_name = "lldbPluginObjectFileJIT" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + + #"//lldb/source/Symbol", # 2-hop dependency cycle. + #"//lldb/source/Target", # 2-hop dependency cycle. + "//llvm/lib/Support", + ] + sources = [ "ObjectFileJIT.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/Mach-O/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/Mach-O/BUILD.gn @@ -0,0 +1,17 @@ +static_library("Mach-O") { + output_name = "lldbPluginObjectFileMachO" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Plugins/Process/Utility", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/Process/Utility. + include_dirs = [ "//lldb/source" ] + sources = [ "ObjectFileMachO.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/PDB/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/PDB/BUILD.gn @@ -0,0 +1,11 @@ +static_library("PDB") { + output_name = "lldbPluginObjectFilePDB" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Symbol", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + sources = [ "ObjectFilePDB.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/PECOFF/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/PECOFF/BUILD.gn @@ -0,0 +1,25 @@ +static_library("PECOFF") { + output_name = "lldbPluginObjectFilePECOFF" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//llvm/lib/BinaryFormat", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/Process/Utility. + include_dirs = [ "//lldb/source" ] + sources = [ + "ObjectFilePECOFF.cpp", + "PECallFrameInfo.cpp", + "WindowsMiniDump.cpp", + ] + + if (current_os == "win") { + # Dbghelp is used on windows for writing minidump files. + libs = [ "dbghelp" ] + } +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/wasm/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/ObjectFile/wasm/BUILD.gn @@ -0,0 +1,12 @@ +static_library("wasm") { + output_name = "lldbPluginObjectFileWasm" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Symbol", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + sources = [ "ObjectFileWasm.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Platform/MacOSX/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Platform/MacOSX/BUILD.gn @@ -0,0 +1,50 @@ +import("//lldb/utils/TableGen/lldb_tablegen.gni") + +lldb_tablegen("PlatformMacOSXProperties") { + args = [ "-gen-lldb-property-defs" ] +} + +lldb_tablegen("PlatformMacOSXPropertiesEnum") { + args = [ "-gen-lldb-property-enum-defs" ] + td_file = "PlatformMacOSXProperties.td" +} + +static_library("MacOSX") { + output_name = "lldbPluginPlatformMacOSX" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + ":PlatformMacOSXProperties", + ":PlatformMacOSXPropertiesEnum", + "//clang/lib/Basic", + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Interpreter", + "//lldb/source/Plugins/Platform/POSIX", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/Platform/POSIX. + include_dirs = [ "//lldb/source" ] + sources = [ + "PlatformDarwin.cpp", + "PlatformDarwinKernel.cpp", + "PlatformMacOSX.cpp", + "PlatformRemoteAppleBridge.cpp", + "PlatformRemoteAppleTV.cpp", + "PlatformRemoteAppleWatch.cpp", + "PlatformRemoteDarwinDevice.cpp", + "PlatformRemoteMacOSX.cpp", + "PlatformRemoteiOS.cpp", + ] + if (host_os == "mac") { + deps += [ "objcxx" ] + sources += [ "PlatformAppleSimulator.cpp" ] + } +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Platform/MacOSX/objcxx/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Platform/MacOSX/objcxx/BUILD.gn @@ -0,0 +1,14 @@ +static_library("objcxx") { + output_name = "lldbPluginPlatformMacOSXObjCXX" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Object", + "//llvm/lib/Support", + ] + cflags_objcc = [ "-fno-objc-exceptions" ] + sources = [ "PlatformiOSSimulatorCoreSimulatorSupport.mm" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Platform/POSIX/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Platform/POSIX/BUILD.gn @@ -0,0 +1,19 @@ +static_library("POSIX") { + output_name = "lldbPluginPlatformPOSIX" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Expression", + "//lldb/source/Host", + "//lldb/source/Interpreter", + "//lldb/source/Plugins/TypeSystem/Clang", + "//lldb/source/Target", + ] + + # Reaches into Plugins/TypeSystem/Clang. + include_dirs = [ "//lldb/source" ] + sources = [ "PlatformPOSIX.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Platform/Windows/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Platform/Windows/BUILD.gn @@ -0,0 +1,14 @@ +static_library("Windows") { + output_name = "lldbPluginPlatformWindows" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Target", + ] + + # Reaches into Plugins/TypeSystem/Clang. + #include_dirs = [ "//lldb/source" ] + sources = [ "PlatformWindows.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Process/Utility/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Process/Utility/BUILD.gn @@ -0,0 +1,74 @@ +static_library("Utility") { + output_name = "lldbPluginProcessUtility" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + #"//lldb/source/Breakpoint", # 3-hop dependency cycle. + "//lldb/source/Core", + "//lldb/source/DataFormatters", + "//lldb/source/Expression", + "//lldb/source/Host", + "//lldb/source/Symbol", + + #"//lldb/source/Target", # Dependency cycle. + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Uses source-relative includes for own headers. + include_dirs = [ "//lldb/source" ] + sources = [ + "AuxVector.cpp", + "DynamicRegisterInfo.cpp", + "FreeBSDSignals.cpp", + "GDBRemoteSignals.cpp", + "HistoryThread.cpp", + "HistoryUnwind.cpp", + "InferiorCallPOSIX.cpp", + "LinuxProcMaps.cpp", + "LinuxSignals.cpp", + "MemoryTagManagerAArch64MTE.cpp", + "MipsLinuxSignals.cpp", + "NativeProcessSoftwareSingleStep.cpp", + "NativeRegisterContextDBReg_arm64.cpp", + "NativeRegisterContextDBReg_x86.cpp", + "NativeRegisterContextRegisterInfo.cpp", + "NetBSDSignals.cpp", + "RegisterContextDarwin_arm.cpp", + "RegisterContextDarwin_arm64.cpp", + "RegisterContextDarwin_i386.cpp", + "RegisterContextDarwin_x86_64.cpp", + "RegisterContextDummy.cpp", + "RegisterContextFreeBSD_i386.cpp", + "RegisterContextFreeBSD_mips64.cpp", + "RegisterContextFreeBSD_powerpc.cpp", + "RegisterContextFreeBSD_x86_64.cpp", + "RegisterContextHistory.cpp", + "RegisterContextLinux_i386.cpp", + "RegisterContextLinux_s390x.cpp", + "RegisterContextLinux_x86_64.cpp", + "RegisterContextMach_arm.cpp", + "RegisterContextMach_i386.cpp", + "RegisterContextMach_x86_64.cpp", + "RegisterContextMemory.cpp", + "RegisterContextNetBSD_i386.cpp", + "RegisterContextNetBSD_x86_64.cpp", + "RegisterContextOpenBSD_i386.cpp", + "RegisterContextOpenBSD_x86_64.cpp", + "RegisterContextPOSIX_arm.cpp", + "RegisterContextPOSIX_arm64.cpp", + "RegisterContextPOSIX_mips64.cpp", + "RegisterContextPOSIX_powerpc.cpp", + "RegisterContextPOSIX_ppc64le.cpp", + "RegisterContextPOSIX_s390x.cpp", + "RegisterContextPOSIX_x86.cpp", + "RegisterContextThreadMemory.cpp", + "RegisterContextWindows_i386.cpp", + "RegisterContextWindows_x86_64.cpp", + "RegisterContext_x86.cpp", + "RegisterInfoPOSIX_arm.cpp", + "RegisterInfoPOSIX_arm64.cpp", + "RegisterInfoPOSIX_ppc64le.cpp", + "StopInfoMachException.cpp", + "ThreadMemory.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Process/elf-core/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Process/elf-core/BUILD.gn @@ -0,0 +1,28 @@ +static_library("elf-core") { + output_name = "lldbPluginProcessElfCore" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Plugins/DynamicLoader/POSIX-DYLD", + "//lldb/source/Plugins/ObjectFile/ELF", + "//lldb/source/Plugins/Process/Utility", + "//lldb/source/Target", + "//llvm/lib/BinaryFormat", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/DynamicLoader/POSIX-DYLD. + include_dirs = [ "//lldb/source" ] + sources = [ + "ProcessElfCore.cpp", + "RegisterContextPOSIXCore_arm.cpp", + "RegisterContextPOSIXCore_arm64.cpp", + "RegisterContextPOSIXCore_mips64.cpp", + "RegisterContextPOSIXCore_powerpc.cpp", + "RegisterContextPOSIXCore_ppc64le.cpp", + "RegisterContextPOSIXCore_s390x.cpp", + "RegisterContextPOSIXCore_x86_64.cpp", + "RegisterUtilities.cpp", + "ThreadElfCore.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Process/gdb-remote/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Process/gdb-remote/BUILD.gn @@ -0,0 +1,49 @@ +import("//lldb/utils/TableGen/lldb_tablegen.gni") + +lldb_tablegen("ProcessGDBRemoteProperties") { + args = [ "-gen-lldb-property-defs" ] +} + +lldb_tablegen("ProcessGDBRemotePropertiesEnum") { + args = [ "-gen-lldb-property-enum-defs" ] + td_file = "ProcessGDBRemoteProperties.td" +} + +static_library("gdb-remote") { + output_name = "lldbPluginProcessGDBRemote" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + ":ProcessGDBRemoteProperties", + ":ProcessGDBRemotePropertiesEnum", + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/DataFormatters", + "//lldb/source/Host", + "//lldb/source/Interpreter", + "//lldb/source/Plugins/Platform/MacOSX", + "//lldb/source/Plugins/Process/Utility", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # XXX if (have_libcompression) { deps += [ compression } } + # Reaches into Plugins/Process/Utility. + include_dirs = [ "//lldb/source" ] + sources = [ + "GDBRemoteClientBase.cpp", + "GDBRemoteCommunication.cpp", + "GDBRemoteCommunicationClient.cpp", + "GDBRemoteCommunicationHistory.cpp", + "GDBRemoteCommunicationReplayServer.cpp", + "GDBRemoteCommunicationServer.cpp", + "GDBRemoteCommunicationServerCommon.cpp", + "GDBRemoteCommunicationServerLLGS.cpp", + "GDBRemoteCommunicationServerPlatform.cpp", + "GDBRemoteRegisterContext.cpp", + "ProcessGDBRemote.cpp", + "ProcessGDBRemoteLog.cpp", + "ThreadGDBRemote.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Process/mach-core/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Process/mach-core/BUILD.gn @@ -0,0 +1,23 @@ +static_library("mach-core") { + output_name = "lldbPluginProcessMachCore" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Plugins/DynamicLoader/Darwin-Kernel", + "//lldb/source/Plugins/DynamicLoader/MacOSX-DYLD", + "//lldb/source/Plugins/ObjectFile/Mach-O", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/Process/Utility. + include_dirs = [ "//lldb/source" ] + sources = [ + "ProcessMachCore.cpp", + "ThreadMachCore.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/Process/minidump/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/Process/minidump/BUILD.gn @@ -0,0 +1,27 @@ +static_library("minidump") { + output_name = "lldbPluginProcessMinidump" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Plugins/Process/Utility", + "//lldb/source/Plugins/Process/elf-core", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/BinaryFormat", + "//llvm/lib/Object", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/Process/Utility. + include_dirs = [ "//lldb/source" ] + sources = [ + "MinidumpParser.cpp", + "MinidumpTypes.cpp", + "ProcessMinidump.cpp", + "RegisterContextMinidump_ARM.cpp", + "RegisterContextMinidump_ARM64.cpp", + "RegisterContextMinidump_x86_32.cpp", + "RegisterContextMinidump_x86_64.cpp", + "ThreadMinidump.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/ScriptInterpreter/None/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/ScriptInterpreter/None/BUILD.gn @@ -0,0 +1,9 @@ +static_library("None") { + output_name = "lldbPluginScriptInterpreterNone" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Interpreter", + ] + sources = [ "ScriptInterpreterNone.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/SymbolFile/Breakpad/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/SymbolFile/Breakpad/BUILD.gn @@ -0,0 +1,16 @@ +static_library("Breakpad") { + output_name = "lldbPluginSymbolFileBreakpad" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Plugins/ObjectFile/Breakpad", + "//lldb/source/Symbol", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/SymbolFile/Breakpad. + include_dirs = [ "//lldb/source" ] + sources = [ "SymbolFileBreakpad.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/SymbolFile/DWARF/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/SymbolFile/DWARF/BUILD.gn @@ -0,0 +1,76 @@ +import("//lldb/utils/TableGen/lldb_tablegen.gni") + +lldb_tablegen("SymbolFileDWARFProperties") { + args = [ "-gen-lldb-property-defs" ] +} + +lldb_tablegen("SymbolFileDWARFPropertiesEnum") { + args = [ "-gen-lldb-property-enum-defs" ] + td_file = "SymbolFileDWARFProperties.td" +} + +static_library("DWARF") { + output_name = "lldbPluginSymbolFileDWARF" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + ":SymbolFileDWARFProperties", + ":SymbolFileDWARFPropertiesEnum", + "//clang/lib/AST", + "//clang/lib/Basic", + "//lldb/source/Core", + "//lldb/source/Expression", + "//lldb/source/Host", + "//lldb/source/Interpreter", + "//lldb/source/Plugins/ExpressionParser/Clang", + + #"//lldb/source/Plugins/Language/CPlusPlus", # 3-hop dependency cycle. + "//lldb/source/Plugins/Language/ObjC", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + + #"//lldb/source/Plugins/TypeSystem/Clang", # Dependency cycle. + "//llvm/lib/DebugInfo/DWARF", + "//llvm/lib/Support", + ] + + # Uses source-relative includes for own headers. + include_dirs = [ "//lldb/source" ] + sources = [ + "AppleDWARFIndex.cpp", + "DIERef.cpp", + "DWARFASTParserClang.cpp", + "DWARFAbbreviationDeclaration.cpp", + "DWARFAttribute.cpp", + "DWARFBaseDIE.cpp", + "DWARFCompileUnit.cpp", + "DWARFContext.cpp", + "DWARFDIE.cpp", + "DWARFDataExtractor.cpp", + "DWARFDebugAbbrev.cpp", + "DWARFDebugArangeSet.cpp", + "DWARFDebugAranges.cpp", + "DWARFDebugInfo.cpp", + "DWARFDebugInfoEntry.cpp", + "DWARFDebugMacro.cpp", + "DWARFDebugRanges.cpp", + "DWARFDeclContext.cpp", + "DWARFDefines.cpp", + "DWARFFormValue.cpp", + "DWARFIndex.cpp", + "DWARFTypeUnit.cpp", + "DWARFUnit.cpp", + "DebugNamesDWARFIndex.cpp", + "HashedNameToDIE.cpp", + "LogChannelDWARF.cpp", + "ManualDWARFIndex.cpp", + "NameToDIE.cpp", + "SymbolFileDWARF.cpp", + "SymbolFileDWARFDebugMap.cpp", + "SymbolFileDWARFDwo.cpp", + "UniqueDWARFASTType.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/SymbolFile/NativePDB/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/SymbolFile/NativePDB/BUILD.gn @@ -0,0 +1,35 @@ +static_library("NativePDB") { + output_name = "lldbPluginSymbolFileNativePDB" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//clang/lib/AST", + "//clang/lib/Lex", + "//lldb/source/Core", + "//lldb/source/Plugins/ObjectFile/PDB", + "//lldb/source/Symbol", + "//lldb/source/Utility", + + #"//lldb/source/Plugins/TypeSystem/Clang", # 3-hop dependency cycle. + "//llvm/lib/DebugInfo/CodeView", + "//llvm/lib/DebugInfo/PDB", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/ExpressionParser. + include_dirs = [ "//lldb/source" ] + sources = [ + "CodeViewRegisterMapping.cpp", + "CompileUnitIndex.cpp", + "DWARFLocationExpression.cpp", + "PdbAstBuilder.cpp", + "PdbFPOProgramToDWARFExpression.cpp", + "PdbIndex.cpp", + "PdbSymUid.cpp", + "PdbUtil.cpp", + "SymbolFileNativePDB.cpp", + "UdtRecordCompleter.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/SymbolFile/PDB/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/SymbolFile/PDB/BUILD.gn @@ -0,0 +1,27 @@ +static_library("PDB") { + output_name = "lldbPluginSymbolFilePDB" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//clang/lib/AST", + "//clang/lib/Lex", + "//lldb/source/Core", + "//lldb/source/Plugins/SymbolFile/NativePDB", + "//lldb/source/Symbol", + "//lldb/source/Utility", + + #"//lldb/source/Plugins/TypeSystem/Clang", # Dependency cycle. + "//llvm/lib/DebugInfo/PDB", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/ExpressionParser/Clang. + include_dirs = [ "//lldb/source" ] + sources = [ + "PDBASTParser.cpp", + "PDBLocationToDWARFExpression.cpp", + "SymbolFilePDB.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/SymbolFile/Symtab/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/SymbolFile/Symtab/BUILD.gn @@ -0,0 +1,9 @@ +static_library("Symtab") { + output_name = "lldbPluginSymbolFileSymtab" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Symbol", + ] + sources = [ "SymbolFileSymtab.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/SymbolVendor/ELF/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/SymbolVendor/ELF/BUILD.gn @@ -0,0 +1,14 @@ +static_library("ELF") { + output_name = "lldbPluginSymbolVendorELF" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Plugins/ObjectFile/ELF", + "//lldb/source/Symbol", + ] + + # Reaches into Plugins/ObjectFile/ELF. + include_dirs = [ "//lldb/source" ] + sources = [ "SymbolVendorELF.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/SymbolVendor/MacOSX/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/SymbolVendor/MacOSX/BUILD.gn @@ -0,0 +1,14 @@ +static_library("MacOSX") { + output_name = "lldbPluginSymbolVendorMacOSX" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Plugins/ObjectFile/Mach-O", + "//lldb/source/Symbol", + ] + + # Reaches into Plugins/ObjectFile/Mach-O. + include_dirs = [ "//lldb/source" ] + sources = [ "SymbolVendorMacOSX.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/SymbolVendor/wasm/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/SymbolVendor/wasm/BUILD.gn @@ -0,0 +1,14 @@ +static_library("wasm") { + output_name = "lldbPluginSymbolVendorWasm" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Host", + "//lldb/source/Plugins/ObjectFile/wasm", + "//lldb/source/Symbol", + ] + + # Reaches into Plugins/ObjectFile/wasm. + include_dirs = [ "//lldb/source" ] + sources = [ "SymbolVendorWasm.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/TypeSystem/Clang/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/TypeSystem/Clang/BUILD.gn @@ -0,0 +1,26 @@ +static_library("Clang") { + output_name = "lldbPluginTypeSystemClang" + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//clang/lib/AST", + "//clang/lib/Basic", + "//clang/lib/Frontend", + "//clang/lib/Sema", + "//lldb/source/Core", + "//lldb/source/Plugins/ExpressionParser/Clang", + "//lldb/source/Plugins/LanguageRuntime/ObjC", + "//lldb/source/Plugins/SymbolFile/DWARF", + "//lldb/source/Plugins/SymbolFile/PDB", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # Reaches into Plugins/ExpressionParser/Clang. + include_dirs = [ "//lldb/source" ] + sources = [ "TypeSystemClang.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/UnwindAssembly/InstEmulation/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/UnwindAssembly/InstEmulation/BUILD.gn @@ -0,0 +1,10 @@ +static_library("InstEmulation") { + output_name = "lldbPluginUnwindAssemblyInstEmulation" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Symbol", + "//lldb/source/Target", + ] + sources = [ "UnwindAssemblyInstEmulation.cpp" ] +} Index: llvm/utils/gn/secondary/lldb/source/Plugins/UnwindAssembly/x86/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Plugins/UnwindAssembly/x86/BUILD.gn @@ -0,0 +1,17 @@ +static_library("x86") { + output_name = "lldbPluginUnwindAssemblyX86" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/MC", + "//llvm/lib/MC/MCDisassembler", + "//llvm/lib/Support", + ] + sources = [ + "UnwindAssembly-x86.cpp", + "x86AssemblyInspectionEngine.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Symbol/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Symbol/BUILD.gn @@ -0,0 +1,49 @@ +static_library("Symbol") { + output_name = "lldbSymbol" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//lldb/source/Core", + "//lldb/source/Expression", + "//lldb/source/Host", + + #"//lldb/source/Target", # FIXME: Dependency cycle. + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + include_dirs = [ ".." ] # FIXME: Reaches into Utility and Host internals. + sources = [ + "ArmUnwindInfo.cpp", + "Block.cpp", + "CompactUnwindInfo.cpp", + "CompileUnit.cpp", + "CompilerDecl.cpp", + "CompilerDeclContext.cpp", + "CompilerType.cpp", + "DWARFCallFrameInfo.cpp", + "DebugMacros.cpp", + "DeclVendor.cpp", + "FuncUnwinders.cpp", + "Function.cpp", + "LineEntry.cpp", + "LineTable.cpp", + "LocateSymbolFile.cpp", + "ObjectFile.cpp", + "PostfixExpression.cpp", + "Symbol.cpp", + "SymbolContext.cpp", + "SymbolFile.cpp", + "SymbolVendor.cpp", + "Symtab.cpp", + "Type.cpp", + "TypeList.cpp", + "TypeMap.cpp", + "TypeSystem.cpp", + "UnwindPlan.cpp", + "UnwindTable.cpp", + "Variable.cpp", + "VariableList.cpp", + ] + if (current_os == "mac") { + sources += [ "LocateSymbolFileMacOSX.cpp" ] + } +} Index: llvm/utils/gn/secondary/lldb/source/Target/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Target/BUILD.gn @@ -0,0 +1,100 @@ +import("//lldb/utils/TableGen/lldb_tablegen.gni") + +lldb_tablegen("TargetProperties") { + args = [ "-gen-lldb-property-defs" ] +} + +lldb_tablegen("TargetPropertiesEnum") { + args = [ "-gen-lldb-property-enum-defs" ] + td_file = "TargetProperties.td" +} + +static_library("Target") { + output_name = "lldbTarget" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + ":TargetProperties", + ":TargetPropertiesEnum", + + #"//lldb/source/Breakpoint", # FIXME: Dependency cycle + "//lldb/source/Core", + "//lldb/source/Core", + "//lldb/source/Expression", + "//lldb/source/Host", + "//lldb/source/Interpreter", + "//lldb/source/Plugins/Process/Utility", + "//lldb/source/Symbol", + "//lldb/source/Utility", + "//llvm/lib/MC", + "//llvm/lib/Support", + ] + include_dirs = [ ".." ] # FIXME: Reaches into Plugins internals. + sources = [ + "ABI.cpp", + "AssertFrameRecognizer.cpp", + "ExecutionContext.cpp", + "InstrumentationRuntime.cpp", + "InstrumentationRuntimeStopInfo.cpp", + "JITLoader.cpp", + "JITLoaderList.cpp", + "Language.cpp", + "LanguageRuntime.cpp", + "Memory.cpp", + "MemoryHistory.cpp", + "MemoryRegionInfo.cpp", + "ModuleCache.cpp", + "OperatingSystem.cpp", + "PathMappingList.cpp", + "Platform.cpp", + "Process.cpp", + "ProcessTrace.cpp", + "Queue.cpp", + "QueueItem.cpp", + "QueueList.cpp", + "RegisterContext.cpp", + "RegisterContextUnwind.cpp", + "RegisterNumber.cpp", + "RemoteAwarePlatform.cpp", + "SectionLoadHistory.cpp", + "SectionLoadList.cpp", + "StackFrame.cpp", + "StackFrameList.cpp", + "StackFrameRecognizer.cpp", + "StackID.cpp", + "StopInfo.cpp", + "StructuredDataPlugin.cpp", + "SystemRuntime.cpp", + "Target.cpp", + "TargetList.cpp", + "Thread.cpp", + "ThreadCollection.cpp", + "ThreadList.cpp", + "ThreadPlan.cpp", + "ThreadPlanBase.cpp", + "ThreadPlanCallFunction.cpp", + "ThreadPlanCallFunctionUsingABI.cpp", + "ThreadPlanCallOnFunctionExit.cpp", + "ThreadPlanCallUserExpression.cpp", + "ThreadPlanPython.cpp", + "ThreadPlanRunToAddress.cpp", + "ThreadPlanShouldStopHere.cpp", + "ThreadPlanStack.cpp", + "ThreadPlanStepInRange.cpp", + "ThreadPlanStepInstruction.cpp", + "ThreadPlanStepOut.cpp", + "ThreadPlanStepOverBreakpoint.cpp", + "ThreadPlanStepOverRange.cpp", + "ThreadPlanStepRange.cpp", + "ThreadPlanStepThrough.cpp", + "ThreadPlanStepUntil.cpp", + "ThreadPlanTracer.cpp", + "ThreadSpec.cpp", + "Trace.cpp", + "TraceCursor.cpp", + "TraceExporter.cpp", + "TraceInstructionDumper.cpp", + "UnixSignals.cpp", + "UnwindAssembly.cpp", + "UnwindLLDB.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/source/Utility/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/source/Utility/BUILD.gn @@ -0,0 +1,85 @@ +static_library("Utility") { + output_name = "lldbUtility" + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + "//llvm/lib/BinaryFormat", + "//llvm/lib/Support", + ] + sources = [ + "ArchSpec.cpp", + "Args.cpp", + "Baton.cpp", + "Broadcaster.cpp", + "CompletionRequest.cpp", + "Connection.cpp", + "ConstString.cpp", + "DataBufferHeap.cpp", + "DataBufferLLVM.cpp", + "DataEncoder.cpp", + "DataExtractor.cpp", + "Environment.cpp", + "Event.cpp", + "FileSpec.cpp", + "GDBRemote.cpp", + "IOObject.cpp", + "LLDBAssert.cpp", + "Listener.cpp", + "Log.cpp", + "Logging.cpp", + "NameMatches.cpp", + "ProcessInfo.cpp", + "RegisterValue.cpp", + "RegularExpression.cpp", + "Reproducer.cpp", + "ReproducerInstrumentation.cpp", + "ReproducerProvider.cpp", + "Scalar.cpp", + "SelectHelper.cpp", + "State.cpp", + "Status.cpp", + "Stream.cpp", + "StreamCallback.cpp", + "StreamString.cpp", + "StringExtractor.cpp", + "StringExtractorGDBRemote.cpp", + "StringLexer.cpp", + "StringList.cpp", + "StructuredData.cpp", + "TildeExpressionResolver.cpp", + "Timer.cpp", + "TraceGDBRemotePackets.cpp", + "TraceIntelPTGDBRemotePackets.cpp", + "UUID.cpp", + "UnimplementedError.cpp", + "UriParser.cpp", + "UserID.cpp", + "UserIDResolver.cpp", + "VASprintf.cpp", + "VMRange.cpp", + "XcodeSDK.cpp", + ] + + # FIXME: + # if (APPLE) + # list(APPEND LLDB_SYSTEM_LIBS + # ${FOUNDATION_LIBRARY} + # ${CORE_FOUNDATION_LIBRARY} + # ${CORE_SERVICES_LIBRARY} + # ${SECURITY_LIBRARY} + # ${DEBUG_SYMBOLS_LIBRARY}) + # endif() + # + # if(NOT PURE_WINDOWS) + # list(APPEND LLDB_SYSTEM_LIBS ${CMAKE_THREAD_LIBS_INIT}) + # endif() + # + # list(APPEND LLDB_SYSTEM_LIBS ${CMAKE_DL_LIBS}) + # + # if (CMAKE_SYSTEM_NAME MATCHES "Windows") + # list(APPEND LLDB_SYSTEM_LIBS ws2_32 rpcrt4) + # endif () + # + # if (NOT HAVE_CXX_ATOMICS64_WITHOUT_LIB ) + # list(APPEND LLDB_SYSTEM_LIBS atomic) + # endif() +} Index: llvm/utils/gn/secondary/lldb/test/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/test/BUILD.gn @@ -0,0 +1,197 @@ +import("//llvm/triples.gni") + +#import("//llvm/utils/gn/build/libs/xar/enable.gni") +import("//llvm/utils/gn/build/libs/xml/enable.gni") +import("//llvm/utils/gn/build/libs/zlib/enable.gni") +import("//llvm/utils/gn/build/write_cmake_config.gni") +import("lldb_lit_site_cfg_files.gni") + +# The bits common to writing lit.site.cfg.py.in, API/lit.site.cfg.py, +# Shell/lit.site.cfg.py, and Unit/lit.site.cfg.py.in. +template("write_lit_cfg") { + write_cmake_config(target_name) { + input = invoker.input + output = invoker.output + values = [ + "LIT_SITE_CFG_IN_HEADER=## Autogenerated from $input, do not edit", + "LLDB_BINARY_DIR=" + + rebase_path(get_label_info("//lldb", "target_out_dir")), + "LLDB_SOURCE_DIR=" + rebase_path("//lldb"), + "LLVM_BINARY_DIR=" + + rebase_path(get_label_info("//llvm", "target_out_dir")), + "LLVM_LIBS_DIR=", # needed only for shared builds + "LLVM_LIT_TOOLS_DIR=", # Intentionally empty, matches cmake build. + "LLVM_SOURCE_DIR=" + rebase_path("//llvm"), + "LLVM_TOOLS_DIR=" + rebase_path("$root_out_dir/bin"), + "Python3_EXECUTABLE=$python_path", + "TARGET_TRIPLE=$llvm_target_triple", + ] + values += invoker.extra_values + } +} + +write_cmake_config("lit-lldb-init") { + input = "//lldb/test/Shell/lit-lldb-init.in" + + # XXX nicer way to get this path + output = "$root_out_dir/obj/lldb/test/Shell/lit-lldb-init" + values = [ "LLDB_TEST_MODULE_CACHE_LLDB=" + + rebase_path( + "$target_gen_dir/lldb-test-build.noindex/module-cache-lldb") ] +} + +write_lit_cfg("lit_site_cfg") { + # Fully-qualified instead of relative for LIT_SITE_CFG_IN_HEADER. + input = "//lldb/test/lit.site.cfg.py.in" + output = lldb_lit_site_cfg_file + extra_values = [ "LLVM_BUILD_MODE=." ] +} + +write_lit_cfg("lit_api_site_cfg") { + # Fully-qualified instead of relative for LIT_SITE_CFG_IN_HEADER. + input = "//lldb/test/API/lit.site.cfg.py.in" + output = lldb_lit_api_site_cfg_file + extra_values = [ + "LLDB_BUILD_INTEL_PT=0", + "LLDB_DOTEST_ARGS=", + "LLDB_ENABLE_PYTHON=0", + "LLDB_LIBS_DIR=", # FIXME: for shared builds only (?) + "LLDB_TEST_ARCH=$current_cpu", + "LLDB_TEST_COMPILER=" + rebase_path("$root_build_dir/bin/clang"), + "LLDB_TEST_BUILD_DIRECTORY=" + rebase_path("$target_gen_dir/test_build"), + "LLDB_TEST_DSYMUTIL=" + rebase_path("$root_build_dir/bin/dsymutil"), + "LLDB_TEST_EXECUTABLE=" + rebase_path("$root_build_dir/bin/lldb"), + "LLDB_TEST_MODULE_CACHE_CLANG=" + + rebase_path( + "$target_gen_dir/lldb-test-build.noindex/module-cache-clang"), + "LLDB_TEST_MODULE_CACHE_LLDB=" + + rebase_path( + "$target_gen_dir/lldb-test-build.noindex/module-cache-lldb"), + "LLVM_BUILD_MODE=.", + "LLVM_ENABLE_SHARED_LIBS=0", + "LLVM_HOST_TRIPLE=$llvm_current_triple", + "LLVM_USE_SANITIZER=", + + "LLDB_FRAMEWORK_DIR=XXX_framework_dir", + "CMAKE_CXX_COMPILER=c++", # XXX use bin/clang++ instead? + "HOST_OS=$host_os", # XXX + ] + + dir = get_path_info(output, "dir") + if (host_os == "win") { + # See comment for Windows solink in llvm/utils/gn/build/toolchain/BUILD.gn + extra_values += [ "SHLIBDIR=" + rebase_path("$root_out_dir/bin", dir) ] + } else { + extra_values += [ "SHLIBDIR=" + rebase_path("$root_out_dir/lib", dir) ] + } +} + +write_lit_cfg("lit_shell_site_cfg") { + # Fully-qualified instead of relative for LIT_SITE_CFG_IN_HEADER. + input = "//lldb/test/Shell/lit.site.cfg.py.in" + output = lldb_lit_shell_site_cfg_file + extra_values = [ + "LLDB_ENABLE_LUA=0", # FIXME: gn arg, use in Config.h + "LLDB_ENABLE_LZMA=0", # FIXME: gn arg, use in Config.h + "LLDB_ENABLE_PYTHON=0", # FIXME: gn arg, use in Config.h + "LLDB_IS_64_BITS=1", + "LLDB_LIBS_DIR=", # FIXME: for shared builds only (?) + "LLDB_LIT_TOOLS_DIR=", # Intentionally empty, matches cmake build. + "LLDB_TEST_BUILD_DIRECTORY=" + rebase_path("$target_gen_dir/test_build"), + "LLDB_TEST_MODULE_CACHE_CLANG=" + + rebase_path( + "$target_gen_dir/lldb-test-build.noindex/module-cache-clang"), + "LLDB_TEST_MODULE_CACHE_LLDB=" + + rebase_path( + "$target_gen_dir/lldb-test-build.noindex/module-cache-lldb"), + "LLDB_TOOLS_DIR=" + rebase_path("$root_out_dir/bin"), + "LLDB_USE_SYSTEM_DEBUGSERVER=1", # XXX port //lldb/tools/debugserver (?) + "LLVM_HOST_TRIPLE=$llvm_current_triple", + ] + + if (llvm_enable_zlib) { + extra_values += [ "LLVM_ENABLE_ZLIB=1" ] + } else { + extra_values += [ "LLVM_ENABLE_ZLIB=0" ] # Must be 0. + } + + dir = get_path_info(output, "dir") + if (host_os == "win") { + # See comment for Windows solink in llvm/utils/gn/build/toolchain/BUILD.gn + extra_values += [ "SHLIBDIR=" + rebase_path("$root_out_dir/bin", dir) ] + } else { + extra_values += [ "SHLIBDIR=" + rebase_path("$root_out_dir/lib", dir) ] + } +} + +write_lit_cfg("lit_unit_site_cfg") { + # Fully-qualified instead of relative for LIT_SITE_CFG_IN_HEADER. + input = "//lldb/test/Unit/lit.site.cfg.py.in" + output = lldb_lit_unit_site_cfg_file + extra_values = [ "LLVM_BUILD_MODE=." ] +} + +# This target should contain all dependencies of check-lldb. +# //:default depends on it, so that ninja's default target builds all +# prerequisites for check-lldb but doesn't run check-lldb itself. +group("test") { + deps = [ + ":lit-lldb-init", + ":lit_api_site_cfg", + ":lit_shell_site_cfg", + ":lit_site_cfg", + ":lit_unit_site_cfg", + "//clang/tools/driver:clang", + "//lld/tools/lld:symlinks", + "//lldb/tools/driver:lldb", + + # XXX lldb-instr, darwin-debug, etc + "//lldb/tools/lldb-server", + "//lldb/tools/lldb-test", + "//lldb/tools/lldb-vscode", + "//lldb/utils/lit-cpuid", + + #"//lldb/unittests", + "//llvm/tools/dsymutil", + "//llvm/tools/llc", + "//llvm/tools/lli", + "//llvm/tools/llvm-config", + "//llvm/tools/llvm-dwarfdump", + "//llvm/tools/llvm-dwp", + "//llvm/tools/llvm-mc", + "//llvm/tools/llvm-nm:symlinks", + "//llvm/tools/llvm-objcopy:symlinks", + "//llvm/tools/llvm-pdbutil", + "//llvm/tools/llvm-readobj:symlinks", + "//llvm/tools/split-file", + "//llvm/tools/yaml2obj", + "//llvm/utils/FileCheck", + "//llvm/utils/count", + "//llvm/utils/llvm-lit", + "//llvm/utils/not", + ] + testonly = true +} + +# This is the action that runs all of lldb's tests, check-lldb. +action("check-lldb") { + script = "$root_out_dir/bin/llvm-lit" + if (host_os == "win") { + script += ".py" + } + args = [ + "-sv", + rebase_path(".", root_out_dir), + ] + outputs = [ "$target_gen_dir/run-lit" ] # Non-existing, so that ninja runs it + # each time. + + # Since check-lldb is always dirty, //:default doesn't depend on it so that + # it's not part of the default ninja target. Hence, check-lld shouldn't + # have any deps except :test, so that the default target is sure to build + # all the deps. + deps = [ ":test" ] + testonly = true + + pool = "//:console" +} Index: llvm/utils/gn/secondary/lldb/test/lldb_lit_site_cfg_files.gni =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/test/lldb_lit_site_cfg_files.gni @@ -0,0 +1,4 @@ +lldb_lit_site_cfg_file = "$root_gen_dir/lldb/test/lit.site.cfg.py" +lldb_lit_api_site_cfg_file = "$root_gen_dir/lldb/test/API/lit.site.cfg.py" +lldb_lit_shell_site_cfg_file = "$root_gen_dir/lldb/test/Shell/lit.site.cfg.py" +lldb_lit_unit_site_cfg_file = "$root_gen_dir/lldb/test/Unit/lit.site.cfg.py" Index: llvm/utils/gn/secondary/lldb/tools/argdumper/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/tools/argdumper/BUILD.gn @@ -0,0 +1,7 @@ +executable("lldb-argdumper") { + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ "//llvm/lib/Support" ] + sources = [ "argdumper.cpp" ] + + # XXX ADD_TO_FRAMEWORK +} Index: llvm/utils/gn/secondary/lldb/tools/driver/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/tools/driver/BUILD.gn @@ -0,0 +1,42 @@ +import("//llvm/utils/TableGen/tablegen.gni") +import("//llvm/utils/gn/build/write_cmake_config.gni") +import("//llvm/version.gni") + +tablegen("Options") { + visibility = [ ":lldb" ] + args = [ "-gen-opt-parser-defs" ] +} + +if (host_os == "mac") { + write_cmake_config("write_info_plist") { + input = "lldb-Info.plist.in" + output = "$target_gen_dir/lldb-Info.plist" + values = [ "LLDB_VERSION=$llvm_version" ] + } +} + +executable("lldb") { + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + ":Options", + "//lldb/include/lldb/Host:Config", + "//lldb/source/API:liblldb", + "//llvm/lib/Option", + "//llvm/lib/Support", + "//llvm/utils/gn/build/libs/xar", + ] + if (host_os == "mac") { + deps += [ ":write_info_plist" ] + plist = get_target_outputs(":write_info_plist") + ldflags = [ "-Wl,-sectcreate,__TEXT,__info_plist," + + rebase_path(plist[0], root_out_dir) ] + } + + sources = [ + "Driver.cpp", + "Platform.cpp", + ] + + # XXX if win -DIMPORT_LIBLLDB + # XXX LLDB_BUILD_FRAMEWORK rpath stuff +} Index: llvm/utils/gn/secondary/lldb/tools/lldb-server/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/tools/lldb-server/BUILD.gn @@ -0,0 +1,60 @@ +import("//llvm/utils/TableGen/tablegen.gni") + +tablegen("LLGSOptions") { + visibility = [ ":lldb-server" ] + args = [ "-gen-opt-parser-defs" ] +} + +executable("lldb-server") { + configs += [ + #"//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + ":LLGSOptions", + + #"//lldb/include/lldb/Host:Config", + "//lldb/source:lldbBase", + "//lldb/source/Host", + "//lldb/source/Initialization", + + #"//lldb/source/Plugins/Instruction/ARM", # XXX + #"//lldb/source/Plugins/Instruction/MIPS", # XXX + #"//lldb/source/Plugins/Instruction/MIPS64", # XXX + "//llvm/lib/Option", + "//llvm/lib/Support", + + # Dep of //lldb/source/Core, but omitted there due to a + # dependency cyle. Need to add dep here. + "//lldb/source/Plugins/Language/CPlusPlus", + ] + + if (current_os == "android" || current_os == "linux") { + deps += [ "//lldb/source/Plugins/Process/Linux" ] + #} else if (current_os == "freebsd") { + #deps += [ "//lldb/source/Plugins/Process/FreeBSD" ] + #} else if (current_os == "netbsd") { + #deps += [ "//lldb/source/Plugins/Process/NetBSD" ] + } + + if (current_os == "mac") { + deps += [ "//lldb/source/Plugins/ObjectFile/Mach-O" ] + } else if (current_os == "win") { + deps += [ "//lldb/source/Plugins/ObjectFile/PECOFF" ] + } else { + deps += [ "//lldb/source/Plugins/ObjectFile/ELF" ] + } + + # FIXME: codesign stuff on macos; default to "lldb_codesign" + + # Reaches into Plugins/ObjectFile/Mach-O. + include_dirs = [ "//lldb/source" ] + sources = [ + "Acceptor.cpp", + "LLDBServerUtilities.cpp", + "SystemInitializerLLGS.cpp", + "lldb-gdbserver.cpp", + "lldb-platform.cpp", + "lldb-server.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/tools/lldb-test/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/tools/lldb-test/BUILD.gn @@ -0,0 +1,29 @@ +executable("lldb-test") { + configs += [ + "//llvm/utils/gn/build:clang_code", + "//llvm/utils/gn/build:lldb_code", + ] + deps = [ + "//lldb/source:lldbBase", + "//lldb/source/Breakpoint", + "//lldb/source/Core", + "//lldb/source/DataFormatters", + "//lldb/source/Expression", + "//lldb/source/Host", + "//lldb/source/Initialization", + "//lldb/source/Interpreter", + "//lldb/source/Plugins:LldbAllPlugins", + "//lldb/source/Symbol", + "//lldb/source/Target", + "//lldb/source/Utility", + "//llvm/lib/Support", + ] + + # XXX commment + include_dirs = [ "//lldb/source" ] + sources = [ + "FormatUtil.cpp", + "SystemInitializerTest.cpp", + "lldb-test.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/tools/lldb-vscode/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/tools/lldb-vscode/BUILD.gn @@ -0,0 +1,52 @@ +import("//llvm/utils/TableGen/tablegen.gni") +import("//llvm/utils/gn/build/write_cmake_config.gni") +import("//llvm/version.gni") + +tablegen("Options") { + visibility = [ ":lldb-vscode" ] + args = [ "-gen-opt-parser-defs" ] +} + +if (host_os == "mac") { + write_cmake_config("write_info_plist") { + input = "lldb-vscode-Info.plist.in" + output = "$target_gen_dir/lldb-vscode-Info.plist" + values = [ "LLDB_VERSION=$llvm_version" ] + } +} + +executable("lldb-vscode") { + configs += [ "//llvm/utils/gn/build:lldb_code" ] + deps = [ + ":Options", + "//lldb/source/API:liblldb", + "//llvm/lib/Option", + "//llvm/lib/Support", + ] + if (host_os == "mac") { + deps += [ ":write_info_plist" ] + plist = get_target_outputs(":write_info_plist") + ldflags = [ "-Wl,-sectcreate,__TEXT,__info_plist," + + rebase_path(plist[0], root_out_dir) ] + } + + # FIXME: link in //lldb/source/Host on Win (and netbsd) + # FIXME: link in pthread + # FIXME: rpath/install_name stuff on macOS for framework on macOS + + sources = [ + "BreakpointBase.cpp", + "ExceptionBreakpoint.cpp", + "FifoFiles.cpp", + "FunctionBreakpoint.cpp", + "IOStream.cpp", + "JSONUtils.cpp", + "LLDBUtils.cpp", + "OutputRedirector.cpp", + "ProgressEvent.cpp", + "RunInTerminal.cpp", + "SourceBreakpoint.cpp", + "VSCode.cpp", + "lldb-vscode.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/utils/TableGen/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/utils/TableGen/BUILD.gn @@ -0,0 +1,12 @@ +executable("lldb-tblgen") { + deps = [ + "//llvm/lib/Support", + "//llvm/lib/TableGen", + ] + sources = [ + "LLDBOptionDefEmitter.cpp", + "LLDBPropertyDefEmitter.cpp", + "LLDBTableGen.cpp", + "LLDBTableGenUtils.cpp", + ] +} Index: llvm/utils/gn/secondary/lldb/utils/TableGen/lldb_tablegen.gni =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/utils/TableGen/lldb_tablegen.gni @@ -0,0 +1,43 @@ +# This file introduces a template for running lldb-tblgen. +# +# Parameters: +# +# args (required) +# [list of strings] Flags to pass to lldb-tblgen. +# +# output_name (optional) +# Basename of the generated output file. +# Defaults to target name with ".inc" appended. +# +# td_file (optional) +# The .td file to pass to llvm-tblgen. +# Defaults to target name with ".td" appended. +# +# visibility (optional) +# GN's regular visibility attribute, see `gn help visibility`. +# +# Example of usage: +# +# lldb_tablegen("CorePropertiesEnum") { +# args = [ "-gen-lldb-property-enum-defs" ] +# td_file = "CoreProperties.td" +# } + +import("//llvm/utils/TableGen/tablegen.gni") + +template("lldb_tablegen") { + tablegen(target_name) { + forward_variables_from(invoker, + [ + "output_name", + "td_file", + "visibility", + ]) + + args = [ + #"-I", + #rebase_path("//lldb/include", root_build_dir), + ] + invoker.args + tblgen_target = "//lldb/utils/TableGen:lldb-tblgen" + } +} Index: llvm/utils/gn/secondary/lldb/utils/lit-cpuid/BUILD.gn =================================================================== --- /dev/null +++ llvm/utils/gn/secondary/lldb/utils/lit-cpuid/BUILD.gn @@ -0,0 +1,4 @@ +executable("lit-cpuid") { + deps = [ "//llvm/lib/Support" ] + sources = [ "lit-cpuid.cpp" ] +} Index: llvm/utils/gn/secondary/llvm/utils/llvm-lit/BUILD.gn =================================================================== --- llvm/utils/gn/secondary/llvm/utils/llvm-lit/BUILD.gn +++ llvm/utils/gn/secondary/llvm/utils/llvm-lit/BUILD.gn @@ -2,6 +2,7 @@ import("//clang-tools-extra/test/clang_tools_extra_lit_site_cfg_files.gni") import("//clang/test/clang_lit_site_cfg_files.gni") import("//lld/test/lld_lit_site_cfg_files.gni") +import("//lldb/test/lldb_lit_site_cfg_files.gni") import("//llvm/test/llvm_lit_site_cfg_files.gni") import("//llvm/utils/gn/build/write_cmake_config.gni") import("//llvm/utils/llvm-lit/lit_path_function.gni") @@ -25,6 +26,10 @@ "//clang/test:lit_unit_site_cfg", "//lld/test:lit_site_cfg", "//lld/test:lit_unit_site_cfg", + "//lldb/test:lit_api_site_cfg", + "//lldb/test:lit_shell_site_cfg", + "//lldb/test:lit_site_cfg", + "//lldb/test:lit_unit_site_cfg", "//llvm/test:lit_site_cfg", "//llvm/test:lit_unit_site_cfg", ] @@ -62,6 +67,22 @@ "//lld/test/Unit/lit.cfg.py", lld_lit_unit_site_cfg_file, ], + [ + "//lldb/test/lit.cfg.py", + lldb_lit_site_cfg_file, + ], + [ + "//lldb/test/API/lit.cfg.py", + lldb_lit_api_site_cfg_file, + ], + [ + "//lldb/test/Shell/lit.cfg.py", + lldb_lit_shell_site_cfg_file, + ], + [ + "//lldb/test/Unit/lit.cfg.py", + lldb_lit_unit_site_cfg_file, + ], [ "//llvm/test/lit.cfg.py", llvm_lit_site_cfg_file,