VirtualBox

source: vbox/trunk/src/VBox/Debugger/Makefile.kmk@ 86728

Last change on this file since 86728 was 86327, checked in by vboxsync, 4 years ago

Debugger: Allow for different I/O providers instead of only TCP

So far TCP was the only option to communicate remotely with the internal debugger, the other option
was to use the console from the GUI directly. This commit reworks basic I/O to allow for different
providers where TCP is just one option. The second one being introduced is an IPC provider using a local
socket or named pipe depending on the platform. This allows for Windows kernel debugging over a pipe
using the KD stub in VirtualBox and WinDbg running on the host (not tested yet).

Furthermore this commit allows multiple stubs to be listening for connections at the same time, so
one can have a GDB stub listening on one TCP port and the native VBox debugger listening on another one
or even using a different I/O provider. Only one session can be active at a time though, because sharing
debugger states is impossible. To configure this the following CFGM keys need to be set for each listener:

"DBGC/<Some unique ID>/Provider" "tcp|ipc"
"DBGC/<Some unique ID>/StubType" "native|gdb|kd"
"DBGC/<Some unique ID>/Address" "<ip>|<local named pipe or socket path>"
"DBGC/<Some unique ID>/Port" "<port>" (for TCP only)

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 3.5 KB
Line 
1# $Id: Makefile.kmk 86327 2020-09-28 16:20:50Z vboxsync $
2## @file
3# Makefile for the VBox debugger.
4#
5
6#
7# Copyright (C) 2006-2020 Oracle Corporation
8#
9# This file is part of VirtualBox Open Source Edition (OSE), as
10# available from http://www.virtualbox.org. This file is free software;
11# you can redistribute it and/or modify it under the terms of the GNU
12# General Public License (GPL) as published by the Free Software
13# Foundation, in version 2 as it comes in the "COPYING" file of the
14# VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15# hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16#
17
18SUB_DEPTH = ../../..
19include $(KBUILD_PATH)/subheader.kmk
20
21#
22# The targets.
23#
24ifdef VBOX_WITH_DEBUGGER
25 LIBRARIES += Debugger
26 ifdef VBOX_WITH_TESTCASES
27 PROGRAMS += tstDBGCParser
28 endif
29endif # VBOX_WITH_DEBUGGER
30
31
32#
33# Debugger library - linked into VBoxVMM.
34#
35Debugger_TEMPLATE = VBOXR3
36Debugger_DEFS = IN_VMM_R3 IN_DBG_R3 IN_DIS
37ifneq ($(KBUILD_TYPE),release)
38 Debugger_DEFS += VBOX_WITH_DEBUGGER_TCP_BY_DEFAULT
39endif
40Debugger_SOURCES = \
41 DBGConsole.cpp \
42 DBGCEval.cpp \
43 DBGCBuiltInSymbols.cpp \
44 DBGCCmdHlp.cpp \
45 DBGCCmdWorkers.cpp \
46 DBGCCommands.cpp \
47 DBGCDumpImage.cpp \
48 DBGCFunctions.cpp \
49 DBGCEmulateCodeView.cpp \
50 DBGCOps.cpp \
51 DBGCGdbRemoteStub.cpp \
52 DBGCRemoteKd.cpp \
53 DBGCIo.cpp \
54 DBGCIoProvTcp.cpp \
55 DBGCIoProvIpc.cpp \
56 DBGCScreenAscii.cpp
57
58#
59# The diggers plug-in.
60#
61DLLS += DbgPlugInDiggers
62DbgPlugInDiggers_TEMPLATE = VBOXR3
63DbgPlugInDiggers_DEFS = IN_DIS
64DbgPlugInDiggers_SOURCES = \
65 DBGPlugInDiggers.cpp \
66 DBGPlugInDarwin.cpp \
67 DBGPlugInLinux.cpp \
68 DBGPlugInSolaris.cpp \
69 DBGPlugInWinNt.cpp \
70 DBGPlugInOS2.cpp \
71 DBGPlugInFreeBsd.cpp \
72 DBGPlugInCommonELF.cpp
73DbgPlugInDiggers_LIBS = \
74 $(PATH_STAGE_LIB)/DisasmR3$(VBOX_SUFF_LIB) \
75 $(if-expr "$(LIB_VMM)" == "$(VBOX_LIB_VMM_LAZY)",$(LIB_REM),) \
76 $(VBOX_LIB_VMM_LAZY) \
77 $(LIB_RUNTIME)
78$(call VBOX_SET_VER_INFO_DLL,DbgPlugInDiggers,VirtualBox Debugger Guest OS Digger Plug-in)
79
80
81#
82# The DBGC parser testcase.
83# This stubs all the VBoxVMM APIs.
84#
85tstDBGCParser_TEMPLATE = VBOXR3TSTEXE
86tstDBGCParser_DEFS = IN_VMM_R3
87tstDBGCParser_CXXFLAGS = $(VBOX_C_CXX_FLAGS_NO_UNUSED_PARAMETERS)
88tstDBGCParser_SOURCES = \
89 testcase/tstDBGCParser.cpp \
90 testcase/tstDBGCStubs.cpp
91tstDBGCParser_LIBS = \
92 $(Debugger_1_TARGET) \
93 $(LIB_RUNTIME)
94
95
96if defined(VBOX_WITH_QTGUI) && defined(VBOX_WITH_DEBUGGER_GUI)
97#
98# Debugger GUI component (Qt).
99#
100USES += qt5
101DLLS += VBoxDbg
102VBoxDbg_TEMPLATE = VBOXQTGUI
103VBoxDbg_DEFS = IN_DBG_R3
104VBoxDbg_INCS = .
105VBoxDbg_QT_MODULES = Core Gui Widgets
106VBoxDbg_QT_MOCHDRS = \
107 VBoxDbgGui.h \
108 VBoxDbgConsole.h \
109 VBoxDbgStatsQt.h
110VBoxDbg_SOURCES = \
111 VBoxDbg.cpp \
112 VBoxDbgGui.cpp \
113 VBoxDbgBase.cpp \
114 VBoxDbgConsole.cpp \
115 VBoxDbgStatsQt.cpp
116VBoxDbg_LIBS = \
117 $(VBOX_LIB_VMM_LAZY)
118VBoxDbg_LDFLAGS.darwin = \
119 -install_name $(VBOX_DYLD_EXECUTABLE_PATH)/VBoxDbg.dylib
120$(call VBOX_SET_VER_INFO_DLL,VBoxDbg,VirtualBox Debugger GUI)
121
122 ifdef VBOX_WITH_TESTCASES
123#
124# The VBoxDbg testcase (Qt).
125#
126PROGRAMS += tstVBoxDbg
127tstVBoxDbg_TEMPLATE = VBOXQTGUIEXE
128tstVBoxDbg_USES = qt5
129tstVBoxDbg_QTTOOL = QT5
130tstVBoxDbg_QT_MODULES = Core Gui Widgets
131tstVBoxDbg_LIBS.linux += xcb
132tstVBoxDbg_LIBS.solaris += xcb
133tstVBoxDbg_LIBS.freebsd += xcb
134tstVBoxDbg_SOURCES = testcase/tstVBoxDbg.cpp
135tstVBoxDbg_LIBS = \
136 $(LIB_VMM) \
137 $(LIB_REM) \
138 $(LIB_RUNTIME)
139 ifeq ($(KBUILD_TARGET),win)
140tstVBoxDbg_LIBS += \
141 $(PATH_STAGE_LIB)/VBoxDbg.lib
142 else
143tstVBoxDbg_LIBS += \
144 $(PATH_STAGE_BIN)/VBoxDbg$(VBOX_SUFF_DLL)
145 endif
146 endif # TESTCASES
147endif # Qt
148
149
150include $(FILE_KBUILD_SUB_FOOTER)
151
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette