VirtualBox

source: vbox/trunk/src/VBox/Additions/common/VBoxService/Makefile.kmk@ 47918

Last change on this file since 47918 was 46506, checked in by vboxsync, 12 years ago

Additions/VBoxService: Don't use VBOX_WITH_PAGE_SHARING here as this is a global defined symbol (VBox/param.h). Fixed warning.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 4.6 KB
Line 
1# $Id: Makefile.kmk 46506 2013-06-12 09:05:32Z vboxsync $
2## @file
3# Sub-Makefile for the Cross Platform Guest Addition Services.
4#
5
6#
7# Copyright (C) 2007-2013 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# Incldue testcases.
23#
24include $(PATH_SUB_CURRENT)/testcase/Makefile.kmk
25
26#
27# Target lists.
28#
29PROGRAMS += VBoxService
30PROGRAMS.win.x86 += VBoxServiceNT
31
32#
33# VBoxService
34#
35VBoxService_TEMPLATE = NewVBoxGuestR3Exe
36VBoxService_DEFS = VBOX_WITH_HGCM VBOXSERVICE_TIMESYNC VBOXSERVICE_MANAGEMENT VBOXSERVICE_TOOLBOX
37VBoxService_DEFS += \
38 VBOX_BUILD_TARGET=\"$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)\"
39VBoxService_DEFS.win += _WIN32_WINNT=0x0501
40VBoxService_DEFS.os2 = VBOX_WITH_HGCM VBOXSERVICE_CLIPBOARD
41ifdef VBOX_WITH_DBUS
42 VBoxService_DEFS += VBOX_WITH_DBUS
43endif
44ifdef VBOX_WITH_GUEST_PROPS
45 VBoxService_DEFS += VBOX_WITH_GUEST_PROPS VBOXSERVICE_VMINFO
46endif
47ifdef VBOX_WITH_GUEST_CONTROL
48 VBoxService_DEFS += VBOX_WITH_GUEST_CONTROL VBOXSERVICE_CONTROL
49endif
50ifdef VBOX_WITH_MEMBALLOON
51 VBoxService_DEFS += VBOX_WITH_MEMBALLOON
52endif
53if1of ($(KBUILD_TARGET), win)
54 VBoxService_DEFS += VBOXSERVICE_PAGE_SHARING
55 ifdef VBOX_WITH_MMR
56 VBoxService_DEFS += VBOX_WITH_MMR
57 endif
58endif
59if1of ($(KBUILD_TARGET), linux)
60 VBoxService_DEFS += VBOXSERVICE_CPUHOTPLUG
61endif
62ifdef VBOX_WITH_SHARED_FOLDERS
63 # darwin freebsd
64 if1of ($(KBUILD_TARGET), linux solaris)
65 VBoxService_DEFS += VBOX_WITH_SHARED_FOLDERS
66 endif
67endif
68
69VBoxService_SOURCES = \
70 VBoxService.cpp \
71 VBoxServiceTimeSync.cpp \
72 VBoxServiceUtils.cpp \
73 VBoxServiceStats.cpp \
74 VBoxServiceToolBox.cpp
75
76ifdef VBOX_WITH_GUEST_CONTROL
77 VBoxService_SOURCES += \
78 VBoxServiceControl.cpp \
79 VBoxServiceControlProcess.cpp \
80 VBoxServiceControlSession.cpp
81endif
82
83ifdef VBOX_WITH_MEMBALLOON
84 VBoxService_SOURCES += \
85 VBoxServiceBalloon.cpp
86endif
87if1of ($(KBUILD_TARGET), win)
88 VBoxService_SOURCES += \
89 VBoxServicePageSharing.cpp
90endif
91
92ifdef VBOX_WITH_GUEST_PROPS
93 VBoxService_SOURCES.win = \
94 VBoxServiceVMInfo-win.cpp
95 VBoxService_SOURCES += \
96 VBoxServiceVMInfo.cpp \
97 VBoxServicePropCache.cpp
98endif
99
100if1of ($(KBUILD_TARGET), linux)
101 VBoxService_SOURCES += \
102 VBoxServiceCpuHotPlug.cpp
103endif
104
105ifdef VBOX_WITH_SHARED_FOLDERS
106 if1of ($(KBUILD_TARGET), linux solaris)
107 VBoxService_SOURCES += \
108 VBoxServiceAutoMount.cpp
109 VBoxService_SOURCES.linux += \
110 ../../linux/sharedfolders/vbsfmount.c
111 endif
112endif
113
114VBoxService_SOURCES.win += \
115 VBoxService-win.rc \
116 VBoxService-win.cpp
117
118VBoxService_SOURCES.os2 = \
119 VBoxService-os2.def \
120 VBoxServiceClipboard-os2.cpp
121
122VBoxService_LDFLAGS.darwin = -framework IOKit
123
124if1of ($(KBUILD_TARGET), linux)
125 VBoxService_LIBS += \
126 crypt
127endif
128ifdef VBOX_WITH_DBUS
129 if1of ($(KBUILD_TARGET), linux solaris) # FreeBSD?
130 VBoxService_LIBS += \
131 dl
132 endif
133endif
134ifdef VBOX_WITH_GUEST_PROPS
135 VBoxService_LIBS.win += \
136 Secur32.lib \
137 WtsApi32.lib \
138 Psapi.lib
139 VBoxService_LIBS.solaris += \
140 nsl \
141 kstat \
142 contract
143endif
144
145# 32-bit version for the 64-bit Linux Additions
146ifeq ($(KBUILD_TARGET).$(KBUILD_TARGET_ARCH),linux.amd64)
147 ifneq ($(VBOX_WITH_COMPATIBLE_LINUX_GUEST_PACKAGE),)
148 PROGRAMS += VBoxService_32
149 VBoxService_32_EXTENDS = VBoxService
150 VBoxService_32_TEMPLATE = NewVBoxGuestR3Exe_X86
151 VBoxService_32_NAME = VBoxService
152 endif
153endif
154
155#
156# VBoxServiceNT - NT4 version of VBoxService.
157#
158VBoxServiceNT_TEMPLATE = NewVBoxGuestR3Exe
159VBoxServiceNT_EXTENDS = VBoxService
160VBoxServiceNT_DEFS.win = _WIN32_WINNT=0x0400 TARGET_NT4 VBOXSERVICE_MANAGEMENT
161
162VBoxServiceVMInfo.cpp_DEFS = VBOX_SVN_REV=$(VBOX_SVN_REV)
163VBoxServiceVMInfo.cpp_DEPS = $(VBOX_SVN_REV_KMK)
164
165#
166# The icon is configurable.
167#
168VBoxService-win.rc_INCS = $(VBoxService_0_OUTDIR)
169VBoxService-win.rc_DEPS = $(VBoxService_0_OUTDIR)/VBoxService-win-icon.rc
170VBoxService-win.rc_CLEAN = $(VBoxService_0_OUTDIR)/VBoxService-win-icon.rc
171
172# Icon include file.
173$$(VBoxService_0_OUTDIR)/VBoxService-win-icon.rc: $(VBOX_WINDOWS_ADDITIONS_ICON_FILE) $$(VBoxService_DEFPATH)/Makefile.kmk | $$(dir $$@)
174 $(RM) -f $@
175 $(APPEND) $@ 'IDI_VIRTUALBOX ICON DISCARDABLE "$(subst /,\\,$(VBOX_WINDOWS_ADDITIONS_ICON_FILE))"'
176
177include $(FILE_KBUILD_SUB_FOOTER)
178
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