1 import("//lldb/include/lldb/Host/libedit.gni")
3 static_library("Host") {
4 output_name = "lldbHost"
5 configs += [ "//llvm/utils/gn/build:lldb_code" ]
7 "//lldb/include/lldb/Host:Config",
8 "//lldb/source/Utility",
17 public_deps = [ "//llvm/utils/gn/build/libs/xml" ]
20 "common/FileAction.cpp",
21 "common/FileCache.cpp",
22 "common/FileSystem.cpp",
23 "common/GetOptInc.cpp",
25 "common/HostInfoBase.cpp",
26 "common/HostNativeThreadBase.cpp",
27 "common/HostProcess.cpp",
28 "common/HostThread.cpp",
30 "common/LockFileBase.cpp",
31 "common/MainLoopBase.cpp",
32 "common/MonitoringProcessLauncher.cpp",
33 "common/NativeProcessProtocol.cpp",
34 "common/NativeRegisterContext.cpp",
35 "common/NativeThreadProtocol.cpp",
36 "common/NativeWatchpointList.cpp",
37 "common/OptionParser.cpp",
38 "common/PipeBase.cpp",
39 "common/ProcessLaunchInfo.cpp",
40 "common/ProcessRunLock.cpp",
41 "common/PseudoTerminal.cpp",
43 "common/SocketAddress.cpp",
44 "common/TCPSocket.cpp",
45 "common/Terminal.cpp",
46 "common/ThreadLauncher.cpp",
47 "common/UDPSocket.cpp",
51 if (lldb_enable_libedit) {
53 sources += [ "common/Editline.cpp" ]
54 if (host_os == "mac") {
55 libs += [ "curses" ] # For USE_SETUPTERM_WORKAROUND :/
59 sources += [ "posix/ConnectionFileDescriptorPosix.cpp" ]
61 if (current_os == "win") {
63 "windows/ConnectionGenericFileWindows.cpp",
64 "windows/FileSystem.cpp",
66 "windows/HostInfoWindows.cpp",
67 "windows/HostProcessWindows.cpp",
68 "windows/HostThreadWindows.cpp",
69 "windows/LockFileWindows.cpp",
70 "windows/MainLoopWindows.cpp",
71 "windows/PipeWindows.cpp",
72 "windows/ProcessLauncherWindows.cpp",
73 "windows/ProcessRunLock.cpp",
77 "posix/DomainSocket.cpp",
78 "posix/FileSystemPosix.cpp",
79 "posix/HostInfoPosix.cpp",
80 "posix/HostProcessPosix.cpp",
81 "posix/HostThreadPosix.cpp",
82 "posix/LockFilePosix.cpp",
83 "posix/MainLoopPosix.cpp",
84 "posix/PipePosix.cpp",
85 "posix/ProcessLauncherPosixFork.cpp",
89 if (current_os == "mac") {
91 "macosx/cfcpp/CFCBundle.cpp",
92 "macosx/cfcpp/CFCData.cpp",
93 "macosx/cfcpp/CFCMutableArray.cpp",
94 "macosx/cfcpp/CFCMutableDictionary.cpp",
95 "macosx/cfcpp/CFCMutableSet.cpp",
96 "macosx/cfcpp/CFCString.cpp",
98 deps += [ "macosx/objcxx" ]
100 # FIXME: Maybe define NO_XPC_SERVICES
103 if (current_os == "linux" || current_os == "android") {
105 "linux/AbstractSocket.cpp",
107 "linux/HostInfoLinux.cpp",
108 "linux/LibcGlue.cpp",
112 if (current_os == "android") {
114 "android/HostInfoAndroid.cpp",
115 "android/LibcGlue.cpp",
119 if (current_os == "freebsd") {
122 "freebsd/HostInfoFreeBSD.cpp",
125 if (current_os == "netbsd") {
127 "netbsd/HostInfoNetBSD.cpp",
128 "netbsd/HostNetBSD.cpp",
131 if (current_os == "openbsd") {
134 "openbsd/HostInfoOpenBSD.cpp",
140 # if (CMAKE_SYSTEM_NAME MATCHES "NetBSD")
141 # list(APPEND EXTRA_LIBS kvm)
144 # list(APPEND EXTRA_LIBS ${CMAKE_DL_LIBS})
146 # if (LLDB_ENABLE_LIBEDIT)
147 # list(APPEND EXTRA_LIBS LibEdit::LibEdit)
149 # if (LLDB_ENABLE_LZMA)
150 # list(APPEND EXTRA_LIBS ${LIBLZMA_LIBRARIES})
153 # list(APPEND LLDB_SYSTEM_LIBS psapi)