1 | # $Id: Makefile.kmk 16012 2009-01-17 23:46:56Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Sub-Makefile for VBoxBFE (a basic frontend which doesn't make use of Main).
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2006-2007 Sun Microsystems, Inc.
|
---|
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 | # Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
|
---|
18 | # Clara, CA 95054 USA or visit http://www.sun.com if you need
|
---|
19 | # additional information or have any questions.
|
---|
20 | #
|
---|
21 |
|
---|
22 | SUB_DEPTH = ../../../..
|
---|
23 | include $(KBUILD_PATH)/subheader.kmk
|
---|
24 | if !defined(VBOX_WITH_HARDENING) || "$(KBUILD_TARGET)" != "darwin" # No hardened VBoxBFE on darwin (.m).
|
---|
25 |
|
---|
26 | #
|
---|
27 | # Targets.
|
---|
28 | #
|
---|
29 | ifdef VBOX_WITH_HARDENING
|
---|
30 | PROGRAMS += VBoxBFEHardened
|
---|
31 | DLLS += VBoxBFE
|
---|
32 | else
|
---|
33 | PROGRAMS += VBoxBFE
|
---|
34 | endif
|
---|
35 |
|
---|
36 |
|
---|
37 | #
|
---|
38 | # Hardened VBoxBFE.
|
---|
39 | #
|
---|
40 | VBoxBFEHardened_TEMPLATE = VBOXR3HARDENEDEXE
|
---|
41 | VBoxBFEHardened_SOURCES = VBoxBFEHardened.cpp
|
---|
42 | VBoxBFEHardened_NAME = VBoxBFE
|
---|
43 |
|
---|
44 |
|
---|
45 | #
|
---|
46 | # VBoxBFE
|
---|
47 | #
|
---|
48 | VBoxBFE_TEMPLATE =
|
---|
49 | VBoxBFE_TEMPLATE := $(if $(VBOX_WITH_HARDENING),VBOXR3NP,VBOXR3NPEXE)
|
---|
50 | #ifdef VBOX_WITH_SECURELABEL
|
---|
51 | #VBoxBFE_DEFS += VBOX_SECURELABEL
|
---|
52 | #endif
|
---|
53 | ifdef VBOX_WITH_VRDP
|
---|
54 | VBoxBFE_DEFS += VBOX_WITH_VRDP
|
---|
55 | endif
|
---|
56 | ifneq ($(KBUILD_TARGET).$(VBOX_WITHOUT_COM),win.)
|
---|
57 | VBoxBFE_DEFS += VBOXBFE_WITHOUT_COM
|
---|
58 | endif
|
---|
59 | ifdef VBOX_WITHOUT_LINUX_COMPILER_H
|
---|
60 | VBoxBFE_DEFS += VBOX_WITHOUT_LINUX_COMPILER_H
|
---|
61 | endif
|
---|
62 | VBoxBFE_DEFS.freebsd = VBOXBFE_WITH_X11
|
---|
63 | VBoxBFE_DEFS.l4 = _GNU_SOURCE
|
---|
64 | VBoxBFE_DEFS.linux = _GNU_SOURCE VBOXBFE_WITH_X11
|
---|
65 | VBoxBFE_DEFS.solaris = VBOXBFE_WITH_X11
|
---|
66 | ifdef VBOX_WITH_CROSSBOW
|
---|
67 | VBoxBFE_DEFS.solaris += VBOX_WITH_CROSSBOW
|
---|
68 | endif
|
---|
69 | VBoxBFE_DEFS.win.x86 = _WIN32_WINNT=0x0500
|
---|
70 |
|
---|
71 | VBoxBFE_SOURCES = \
|
---|
72 | VBoxBFE.cpp \
|
---|
73 | VMMDevInterface.cpp \
|
---|
74 | DisplayImpl.cpp \
|
---|
75 | MouseImpl.cpp \
|
---|
76 | KeyboardImpl.cpp \
|
---|
77 | StatusImpl.cpp \
|
---|
78 | MachineDebuggerImpl.cpp \
|
---|
79 | VMControl.cpp
|
---|
80 |
|
---|
81 | ifdef VBOX_WITH_HGCM
|
---|
82 | VBoxBFE_DEFS += VBOX_WITH_HGCM
|
---|
83 | VBoxBFE_SOURCES += \
|
---|
84 | HGCM.cpp \
|
---|
85 | HGCMThread.cpp \
|
---|
86 | HGCMObjects.cpp
|
---|
87 | endif
|
---|
88 |
|
---|
89 | VBoxBFE_SOURCES.darwin = \
|
---|
90 | VBoxBFEMain-darwin.m
|
---|
91 |
|
---|
92 | VBoxBFE_SOURCES.l4 = \
|
---|
93 | L4Console.cpp \
|
---|
94 | L4Framebuffer.cpp \
|
---|
95 | L4IDLInterface.cpp \
|
---|
96 | EmulCpp.cpp
|
---|
97 |
|
---|
98 | # SDL
|
---|
99 | ifneq ($(KBUILD_TARGET),l4)
|
---|
100 | VBoxBFE_SDKS += LIBSDL
|
---|
101 | VBoxBFE_DEFS += USE_SDL
|
---|
102 | VBoxBFE_SOURCES += \
|
---|
103 | SDLConsole.cpp \
|
---|
104 | SDLFramebuffer.cpp
|
---|
105 | endif
|
---|
106 |
|
---|
107 | # USB Support
|
---|
108 | if1of ($(KBUILD_TARGET), l4 win)
|
---|
109 | VBoxBFE_DEFS += VBOXBFE_WITH_USB
|
---|
110 | VBoxBFE_SOURCES += \
|
---|
111 | HostUSBImpl.cpp \
|
---|
112 | HostUSBDeviceImpl.cpp \
|
---|
113 | USBProxyService.cpp
|
---|
114 | VBoxBFE_SOURCES.l4 += \
|
---|
115 | USBProxyServiceLinux.cpp
|
---|
116 | VBoxBFE_SOURCES.linux += \
|
---|
117 | USBProxyServiceLinux.cpp
|
---|
118 | endif
|
---|
119 |
|
---|
120 | VBoxBFE_INCS = \
|
---|
121 | $(PATH_VBoxBFE) \
|
---|
122 | $(VBOX_PATH_SDK)/include
|
---|
123 | ifneq ($(filter-out win os2 l4 darwin,$(KBUILD_TARGET)),) # X11
|
---|
124 | VBoxBFE_INCS += \
|
---|
125 | $(VBOX_XCURSOR_INCS)
|
---|
126 | endif
|
---|
127 |
|
---|
128 | VBoxBFE_LIBS = \
|
---|
129 | $(LIB_RUNTIME) \
|
---|
130 | $(LIB_VMM)
|
---|
131 | ifneq ($(filter-out win os2 l4,$(KBUILD_TARGET)),)
|
---|
132 | VBoxBFE_LIBS += \
|
---|
133 | $(LIB_REM)
|
---|
134 | endif
|
---|
135 | ifneq ($(filter-out win os2 l4 darwin,$(KBUILD_TARGET)),) # X11
|
---|
136 | VBoxBFE_LIBS += \
|
---|
137 | $(VBOX_XCURSOR_LIBS) \
|
---|
138 | X11
|
---|
139 | VBoxBFE_LIBPATH += \
|
---|
140 | $(VBOX_LIBPATH_X11)
|
---|
141 | endif
|
---|
142 | ifndef VBOX_WITHOUT_COM
|
---|
143 | VBoxBFE_LIBS.win = \
|
---|
144 | $(PATH_TOOL_$(VBOX_VCC_TOOL)_ATLMFC_LIB)/atls.lib
|
---|
145 | endif
|
---|
146 | VBoxBFE_LIBS.l4 = \
|
---|
147 | $(L4_LIBDIR)/libl4con-idl.a \
|
---|
148 | $(L4_LIBDIR)/libconstream-server.a \
|
---|
149 | $(L4_LIBDIR)/libvboxctrl-server.a \
|
---|
150 | $(L4_LIBDIR)/libl4sys.a
|
---|
151 | VBoxBFE_LIBS.darwin = \
|
---|
152 | $(LIB_SDK_LIBSDL_SDLMAIN)
|
---|
153 | VBoxBFE_LDFLAGS.darwin = -framework Foundation -framework AppKit
|
---|
154 |
|
---|
155 | VBoxBFE_CXXFLAGS.win = \
|
---|
156 | -EHsc
|
---|
157 | VBoxBFE_DEFS.linux = \
|
---|
158 | NDEBUG TRIMMED
|
---|
159 | VBoxBFE_CXXFLAGS.linux = \
|
---|
160 | -fno-rtti -fno-exceptions -fshort-wchar -pthread
|
---|
161 | VBoxBFE_CXXFLAGS.l4 += -fno-rtti -nostdinc -Wno-non-virtual-dtor \
|
---|
162 | $(addprefix -I,$(VBOX_L4_GCC3_INCS) $(L4_INCDIR))
|
---|
163 |
|
---|
164 | VBoxBFE_CLEAN = $(PATH_VBoxBFE)/Ico64x01.h
|
---|
165 | VBoxBFE_SDLConsole.cpp_DEPS = $(PATH_VBoxBFE)/Ico64x01.h
|
---|
166 |
|
---|
167 | # Convert the pnm-file to a byte array.
|
---|
168 | $$(PATH_VBoxBFE)/Ico64x01.h: $(PATH_ROOT)/src/VBox/Frontends/VBoxBFE/ico64x01.pnm $(VBOX_BIN2C) | $$(dir $$@)
|
---|
169 | $(call MSG_TOOL,bin2c,VBoxBFE,$<,$@)
|
---|
170 | $(QUIET)$(VBOX_BIN2C) Ico64x01 $< $@
|
---|
171 |
|
---|
172 |
|
---|
173 | endif # !VBOX_WITH_HARDENING || !darwin
|
---|
174 | include $(KBUILD_PATH)/subfooter.kmk
|
---|
175 |
|
---|
176 |
|
---|