VirtualBox

source: vbox/trunk/src/VBox/Additions/Makefile.kmk@ 9639

Last change on this file since 9639 was 9639, checked in by vboxsync, 17 years ago

Removed VBOX_WITH_LINUX_ADDITIONS, VBOX_WITH_WIN32_ADDITIONS, VBOX_ADDITIONS_LINUX_ONLY, VBOX_ADDITIONS_WIN32_ONLY and some other obsolete bits from ssh crossbuilding days.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 9.1 KB
Line 
1# $Id: Makefile.kmk 9639 2008-06-12 00:20:23Z vboxsync $
2## @file
3# Top-level makefile for the VirtualBox Guest Additions.
4#
5# Cross building of the additions is generally done by remote building
6# by means of smbfs, cifs, VBOX_ONLY_ADDITIONS=1 and setting KBUILD_TARGET
7# to the desired target.
8#
9# Limited support for cross building the windows additions using wine
10# is provided. There are a couple of issues with the approach (lack of
11# signing, no VC++ 8 support, ++) that makes it unsuitable for releases.
12#
13# Building the linux additions as part of the l4 build is ok because
14# l4 is built on a linux platform. This is why we have to check if
15# KBUILD_TARGET is l4 or linux in some places, though most of the magic
16# is done in the templates (Config.kmk).
17#
18
19#
20# Copyright (C) 2006-2007 Sun Microsystems, Inc.
21#
22# This file is part of VirtualBox Open Source Edition (OSE), as
23# available from http://www.virtualbox.org. This file is free software;
24# you can redistribute it and/or modify it under the terms of the GNU
25# General Public License (GPL) as published by the Free Software
26# Foundation, in version 2 as it comes in the "COPYING" file of the
27# VirtualBox OSE distribution. VirtualBox OSE is distributed in the
28# hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
29#
30# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
31# Clara, CA 95054 USA or visit http://www.sun.com if you need
32# additional information or have any questions.
33#
34
35DEPTH = ../../..
36include $(KBUILD_PATH)/subheader.kmk
37
38#
39# Note! VBOX_WITH_ADDITIONS is checked for by our parent makefile.
40#
41# Note! VBOX_WITH_X11_ADDITIONS is set in Config.kmk
42#
43# Note! The additions build box will set the VBOX_WITH_ADDITIONS_ISO.win.x86
44# variables before invoking us from the root makefile.
45#
46# ==> All we have to worry about is what to do on the target we're on.
47#
48VBOX_WITH_ADDITIONS_ISO.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) = 1
49
50# Include sub-makefiles.
51include $(PATH_SUB_CURRENT)/common/Makefile.kmk
52
53ifdef VBOX_WITH_X11_ADDITIONS
54 include $(PATH_SUB_CURRENT)/x11/Makefile.kmk
55endif
56
57ifeq ($(KBUILD_TARGET),freebsd)
58 include $(PATH_SUB_CURRENT)/freebsd/Makefile.kmk
59endif
60ifeq ($(KBUILD_TARGET),linux)
61 include $(PATH_SUB_CURRENT)/linux/Makefile.kmk
62endif
63#ifeq ($(KBUILD_TARGET),os2)
64# include $(PATH_SUB_CURRENT)/os2/Makefile.kmk
65#endif
66ifeq ($(KBUILD_TARGET),solaris)
67 include $(PATH_SUB_CURRENT)/solaris/Makefile.kmk
68endif
69ifeq ($(KBUILD_TARGET),win)
70 include $(PATH_SUB_CURRENT)/WINNT/Makefile.kmk
71endif
72
73# The packing target rule, but only if we're on the local build box.
74# (VBOX_WITHOUT_ADDITIONS_ISO is used by the additions build box, see the root makefile.)
75ifndef VBOX_WITHOUT_ADDITIONS_ISO
76 PACKING += $(PATH_BIN)/additions/VBoxGuestAdditions.iso
77endif
78
79include $(KBUILD_PATH)/subfooter.kmk
80
81#
82# File per-OS/arch file specs for the additions iso (alphabetical order).
83#
84# We test for the VBOX_WITH_ADDITIONS_ISO.os.arch so that we don't have to
85# do the $(if )'ing down where the GUESTADDITIONS_FILESPEC.os.arch down
86# in the dependency list and mkisofs command.
87#
88
89ifdef VBOX_WITH_ADDITIONS_ISO.freebsd.amd64
90 VBOX_PATH_ADDITIONS.freebsd.amd64 = $(PATH_OUT_BASE)/freebsd.amd64/$(KBUILD_TYPE)/bin/additions
91 GUESTADDITIONS_FILESPEC.freebsd.amd64 = \
92 VBoxFreeBSDAdditions-amd64.tbz=$(VBOX_PATH_ADDITIONS.freebsd.amd64)/VBoxFreeBSDAdditions.tbz
93endif
94ifdef VBOX_WITH_ADDITIONS_ISO.freebsd.x86
95 VBOX_PATH_ADDITIONS.freebsd.x86 = $(PATH_OUT_BASE)/freebsd.x86/$(KBUILD_TYPE)/bin/additions
96 GUESTADDITIONS_FILESPEC.freebsd.x86 = \
97 VBoxFreeBSDAdditions-x86.tbz=$(VBOX_PATH_ADDITIONS.freebsd.x86)/VBoxFreeBSDAdditions.tbz
98endif
99
100
101ifdef VBOX_WITH_ADDITIONS_ISO.os2.x86
102 VBOX_PATH_ADDITIONS.os2.x86 = $(PATH_OUT_BASE)/os2.x86/$(KBUILD_TYPE)/bin/additions
103 GUESTADDITIONS_FILESPEC.os2.x86 = \
104 os2/VBoxGuest.sys=$(VBOX_PATH_ADDITIONS.os2.x86)/VBoxGuest.sys \
105 os2/VBoxService.exe=$(VBOX_PATH_ADDITIONS.os2.x86)/VBoxService.exe \
106 os2/gengradd.dll=$(VBOX_PATH_ADDITIONS.os2.x86)/gengradd.dll \
107 os2/libc063.dll=./os2/Bin/libc063.dll \
108 os2/readme.txt=./os2/Bin/readme.txt \
109 os2/vboxmouse.sys=$(VBOX_PATH_ADDITIONS.os2.x86)/vboxmouse.sys
110else ifdef VBOX_WITH_OS2_ADDITIONS_BIN
111 GUESTADDITIONS_FILESPEC.os2.x86 = \
112 os2/VBoxGuest.sys=./os2/Bin/VBoxGuest.sys \
113 os2/VBoxService.exe=./os2/Bin/VBoxService.exe \
114 os2/gengradd.dll=./os2/Bin/gengradd.dll \
115 os2/libc063.dll=./os2/Bin/libc063.dll \
116 os2/readme.txt=./os2/Bin/readme.txt \
117 os2/vboxmouse.sys=./os2/Bin/vboxmouse.sys
118endif
119
120
121ifdef VBOX_WITH_ADDITIONS_ISO.linux.amd64
122 VBOX_PATH_ADDITIONS.linux.amd64 = $(PATH_OUT_BASE)/linux.amd64/$(KBUILD_TYPE)/bin/additions
123 GUESTADDITIONS_FILESPEC.linux.amd64 = \
124 VBoxLinuxAdditions-amd64.run=$(VBOX_PATH_ADDITIONS.linux.amd64)/VBoxLinuxAdditions.run
125endif
126ifdef VBOX_WITH_ADDITIONS_ISO.linux.x86
127 VBOX_PATH_ADDITIONS.linux.x86 = $(PATH_OUT_BASE)/linux.x86/$(KBUILD_TYPE)/bin/additions
128## @todo 64-bit additions: rename this package, update docs (?) and tests (?). create wrapper? create gnome/kde autorun app (xplatform) ?
129 GUESTADDITIONS_FILESPEC.linux.x86 = \
130 VBoxLinuxAdditions.run=$(VBOX_PATH_ADDITIONS.linux.x86)/VBoxLinuxAdditions.run
131endif
132
133
134ifdef VBOX_WITH_ADDITIONS_ISO.solaris.amd64
135 VBOX_PATH_ADDITIONS.solaris.amd64 = $(PATH_OUT_BASE)/solaris.amd64/$(KBUILD_TYPE)/bin/additions
136 GUESTADDITIONS_FILESPEC.solaris.amd64 = \
137 VBoxSolarisAdditions-amd64.pkg=$(VBOX_PATH_ADDITIONS.solaris.amd64)/VBoxSolarisAdditions.pkg
138endif
139ifdef VBOX_WITH_ADDITIONS_ISO.solaris.x86
140 VBOX_PATH_ADDITIONS.solaris.x86 = $(PATH_OUT_BASE)/solaris.x86/$(KBUILD_TYPE)/bin/additions
141## @todo 64-bit additions: rename this package, update docs (?) and tests (?).
142 GUESTADDITIONS_FILESPEC.solaris.x86 = \
143 VBoxSolarisAdditions.pkg=$(VBOX_PATH_ADDITIONS.solaris.x86)/VBoxSolarisAdditions.pkg
144endif
145
146
147ifdef VBOX_WITH_ADDITIONS_ISO.win.amd64
148 ## @todo 64-bit windows additions:
149 # It's going to be most of the files from above, except they must not have the same name on
150 # the iso (left hand side).
151 # We probably an autorun wrapper which launches the right installer, unless there is
152 # some Autorun.inf magic for this or that it can be done from the x86 installer.
153 # Also, we MUST fix the .inf / .cat problem mentioned in the todo above.
154endif
155ifdef VBOX_WITH_ADDITIONS_ISO.win.x86
156 ## @todo We're missing the .cat files and using the wrong .inf files here! This is kind of serious...
157 VBOX_PATH_ADDITIONS.win.x86 = $(PATH_OUT_BASE)/win.x86/$(KBUILD_TYPE)/bin/additions
158 GUESTADDITIONS_FILESPEC.win.x86 = \
159 driver/VBoxGuest/VBoxGuest.sys=$(VBOX_PATH_ADDITIONS.win.x86)/VBoxGuest.sys \
160 driver/VBoxGuest/VBoxGuest.inf=./WINNT/VBoxGuest/VBoxGuest.inf \
161 driver/VBoxGuest/VBoxTray.exe=$(VBOX_PATH_ADDITIONS.win.x86)/VBoxTray.exe \
162 driver/VBoxGuest/VBoxHook.dll=$(VBOX_PATH_ADDITIONS.win.x86)/VBoxHook.dll \
163 driver/VBoxGuest/VBoxControl.exe=$(VBOX_PATH_ADDITIONS.win.x86)/VBoxControl.exe \
164 driver/VBoxGuest/VBCoInst.dll=$(VBOX_PATH_ADDITIONS.win.x86)/VBCoInst.dll \
165 driver/VBoxGuest/VBoxMouse.sys=$(VBOX_PATH_ADDITIONS.win.x86)/VBoxMouse.sys \
166 driver/VBoxGuest/VBoxMouse.inf=./WINNT/MouseFilter/VBoxMouse.inf \
167 driver/VBoxVideo/VBoxVideo.sys=$(VBOX_PATH_ADDITIONS.win.x86)/VBoxVideo.sys \
168 driver/VBoxVideo/VBoxVideo.inf=./WINNT/Graphics/Miniport/VBoxVideo.inf \
169 driver/VBoxVideo/VBoxDisp.dll=$(VBOX_PATH_ADDITIONS.win.x86)/VBoxDisp.dll \
170 gina/VBoxGINA.dll=$(VBOX_PATH_ADDITIONS.win.x86)/VBoxGINA.dll \
171 AMD_PCnet/netamd.inf=./WINNT/Network/AMD/netamd.inf \
172 AMD_PCnet/pcntpci5.cat=./WINNT/Network/AMD/pcntpci5.cat \
173 AMD_PCnet/PCNTPCI5.sys=./WINNT/Network/AMD/PCNTPCI5.sys \
174 VBoxGuestAdditions.exe=$(VBOX_PATH_ADDITIONS.win.x86)/VBoxGuestAdditions.exe \
175 AUTORUN.INF=./WINNT/Installer/AUTORUN.INF
176 ifdef VBOX_WITH_WIN32_ADDITIONS_SHAREDFOLDERS
177 GUESTADDITIONS_FILESPEC.win.x86 += \
178 driver/VBoxSF/VBoxSF.sys=$(VBOX_PATH_ADDITIONS.win.x86)/VBoxSF.sys \
179 driver/VBoxSF/VBoxMRXNP.dll=$(VBOX_PATH_ADDITIONS.win.x86)/VBoxMRXNP.dll
180 endif
181endif # win.x86
182
183
184#
185# Build the Guest Additions ISO image.
186#
187ifndef VBOX_WITHOUT_ADDITIONS_ISO
188$(VBOX_PATH_ADDITIONS)/VBoxGuestAdditions.iso: \
189 $(filter-out %=deleteme=,\
190 $(subst =,=deleteme= ,\
191 $(GUESTADDITIONS_FILESPEC.win.x86) \
192 $(GUESTADDITIONS_FILESPEC.win.amd64) \
193 $(GUESTADDITIONS_FILESPEC.solaris.x86) \
194 $(GUESTADDITIONS_FILESPEC.solaris.amd64) \
195 $(GUESTADDITIONS_FILESPEC.os2.x86) \
196 $(GUESTADDITIONS_FILESPEC.linux.x86) \
197 $(GUESTADDITIONS_FILESPEC.linux.amd64) \
198 $(GUESTADDITIONS_FILESPEC.freebsd.x86) \
199 $(GUESTADDITIONS_FILESPEC.freebsd.amd64) \
200 )\
201 ) \
202 $(VBOX_SVN_REV_KMK) \
203 Makefile.kmk
204 $(call MSG_TOOL,mkisofs,,$@)
205 $(QUIET)$(MKDIR) -p $(@D)
206 @# use iso-level 3 which is the most ISO conforming level with least restrictions; iso-level 4 maps to iso-level 2
207 @# with some extra restrictions removal (not conforming to ISO9660) which some platforms like Solaris 10 does not like.
208 $(VBOX_MKISOFS) -rational-rock -joliet -iso-level 3 \
209 -volid "VBOXADDITIONS_$(VBOX_VERSION_STRING)_$(VBOX_SVN_REV)" -l -graft-points -o $@ \
210 $(GUESTADDITIONS_FILESPEC.win.x86) \
211 $(GUESTADDITIONS_FILESPEC.win.amd64) \
212 $(GUESTADDITIONS_FILESPEC.solaris.x86) \
213 $(GUESTADDITIONS_FILESPEC.solaris.amd64) \
214 $(GUESTADDITIONS_FILESPEC.os2.x86) \
215 $(GUESTADDITIONS_FILESPEC.linux.x86) \
216 $(GUESTADDITIONS_FILESPEC.linux.amd64) \
217 $(GUESTADDITIONS_FILESPEC.freebsd.x86) \
218 $(GUESTADDITIONS_FILESPEC.freebsd.amd64)
219endif
220
221
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