1 | # $Id: Makefile.kmk 2941 2007-05-30 17:18:11Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | # Top-level makefile for the VirtualBox Guest Additions.
|
---|
4 | #
|
---|
5 |
|
---|
6 | #
|
---|
7 | # Copyright (C) 2006 InnoTek Systemberatung GmbH
|
---|
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 as published by the Free Software Foundation,
|
---|
13 | # in version 2 as it comes in the "COPYING" file of the VirtualBox OSE
|
---|
14 | # distribution. VirtualBox OSE is distributed in the hope that it will
|
---|
15 | # be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
16 | #
|
---|
17 | # If you received this file as part of a commercial VirtualBox
|
---|
18 | # distribution, then only the terms of your commercial VirtualBox
|
---|
19 | # license agreement apply instead of the previous paragraph.
|
---|
20 | #
|
---|
21 |
|
---|
22 | DEPTH = ../../..
|
---|
23 | include $(PATH_KBUILD)/subheader.kmk
|
---|
24 |
|
---|
25 | # Include sub-makefiles.
|
---|
26 | include $(PATH_SUB_CURRENT)/common/Makefile.kmk
|
---|
27 | ifdef VBOX_WITH_WIN32_ADDITIONS
|
---|
28 | ifndef VBOX_REMOTE_BUILD_WIN32_ADDITIONS
|
---|
29 | include $(PATH_SUB_CURRENT)/WINNT/Makefile.kmk
|
---|
30 | endif
|
---|
31 | endif
|
---|
32 |
|
---|
33 | ifdef VBOX_WITH_LINUX_ADDITIONS
|
---|
34 | SUBDIRS += linux
|
---|
35 | LINUXINSTALLER = $(PATH_BIN)/additions/VBoxLinuxAdditions.run
|
---|
36 | endif
|
---|
37 | ifneq ($(VBOX_WITH_WIN32_ADDITIONS)$(VBOX_WITH_LINUX_ADDITIONS),)
|
---|
38 | PACKING += $(PATH_BIN)/additions/VBoxGuestAdditions.iso
|
---|
39 | endif
|
---|
40 |
|
---|
41 | LINUXINSTALLER_CROSS = $(PATH_ROOT)/out/linux.x86/$(BUILD_TYPE)/bin/additions/VBoxLinuxAdditions.run
|
---|
42 | # If the build (Windows host only, problem doesn't exist for Linux) should
|
---|
43 | # include Linux additions, set VBOX_ADDITIONS_LINUX_CROSS. This causes the
|
---|
44 | # Linux additions to be built via a ssh session (to the host specified in
|
---|
45 | # VBOX_ADDITIONS_LINUX_CROSS_HOST, usually set in LocalConfig.kmk. Needs
|
---|
46 | # eventually be generalized once more additions platforms are supported.
|
---|
47 | # This host has the Windows build box tree mounted, in order to make 100% sure
|
---|
48 | # that a complete build is created from a single consistent revision.
|
---|
49 | ifdef VBOX_ADDITIONS_LINUX_CROSS
|
---|
50 | OTHER_CLEAN += $(LINUXINSTALLER_CROSS)
|
---|
51 | LINUXINSTALLER = $(LINUXINSTALLER_CROSS)
|
---|
52 | endif
|
---|
53 |
|
---|
54 |
|
---|
55 | include $(PATH_KBUILD)/subfooter.kmk
|
---|
56 |
|
---|
57 |
|
---|
58 | ifdef VBOX_WITH_WIN32_ADDITIONS
|
---|
59 | GUESTADDITIONS_WIN32_DEPS = $(PATH_BIN)/additions/VBoxGuest.sys \
|
---|
60 | ./WINNT/VBoxGuest/VBoxGuest.inf \
|
---|
61 | $(PATH_BIN)/additions/VBoxService.exe \
|
---|
62 | $(PATH_BIN)/additions/VBoxControl.exe \
|
---|
63 | $(PATH_BIN)/additions/VBCoInst.dll \
|
---|
64 | $(PATH_BIN)/additions/VBoxMouse.sys \
|
---|
65 | ./WINNT/MouseFilter/VBoxMouse.inf \
|
---|
66 | $(PATH_BIN)/additions/VBoxVideo.sys \
|
---|
67 | ./WINNT/Graphics/Miniport/VBoxVideo.inf \
|
---|
68 | $(PATH_BIN)/additions/VBoxDisp.dll \
|
---|
69 | $(PATH_BIN)/additions/VBoxGINA.dll \
|
---|
70 | $(PATH_BIN)/additions/VBoxGuestAdditions.exe \
|
---|
71 | ./WINNT/Installer/AUTORUN.INF \
|
---|
72 | ./WINNT/Network/AMD/netamd.inf \
|
---|
73 | ./WINNT/Network/AMD/pcntpci5.cat \
|
---|
74 | ./WINNT/Network/AMD/PCNTPCI5.sys
|
---|
75 | GUESTADDITIONS_WIN32_FILESPEC = \
|
---|
76 | driver/VBoxGuest/VBoxGuest.sys=$(PATH_BIN)/additions/VBoxGuest.sys \
|
---|
77 | driver/VBoxGuest/VBoxGuest.inf=./WINNT/VBoxGuest/VBoxGuest.inf \
|
---|
78 | driver/VBoxGuest/VBoxService.exe=$(PATH_BIN)/additions/VBoxService.exe \
|
---|
79 | driver/VBoxGuest/VBoxControl.exe=$(PATH_BIN)/additions/VBoxControl.exe \
|
---|
80 | driver/VBoxGuest/VBCoInst.dll=$(PATH_BIN)/additions/VBCoInst.dll \
|
---|
81 | driver/VBoxGuest/VBoxMouse.sys=$(PATH_BIN)/additions/VBoxMouse.sys \
|
---|
82 | driver/VBoxGuest/VBoxMouse.inf=./WINNT/MouseFilter/VBoxMouse.inf \
|
---|
83 | driver/VBoxVideo/VBoxVideo.sys=$(PATH_BIN)/additions/VBoxVideo.sys \
|
---|
84 | driver/VBoxVideo/VBoxVideo.inf=./WINNT/Graphics/Miniport/VBoxVideo.inf \
|
---|
85 | driver/VBoxVideo/VBoxDisp.dll=$(PATH_BIN)/additions/VBoxDisp.dll \
|
---|
86 | gina/VBoxGINA.dll=$(PATH_BIN)/additions/VBoxGINA.dll \
|
---|
87 | AMD_PCnet/netamd.inf=./WINNT/Network/AMD/netamd.inf \
|
---|
88 | AMD_PCnet/pcntpci5.cat=./WINNT/Network/AMD/pcntpci5.cat \
|
---|
89 | AMD_PCnet/PCNTPCI5.sys=./WINNT/Network/AMD/PCNTPCI5.sys \
|
---|
90 | VBoxGuestAdditions.exe=$(PATH_BIN)/additions/VBoxGuestAdditions.exe \
|
---|
91 | AUTORUN.INF=./WINNT/Installer/AUTORUN.INF
|
---|
92 | endif
|
---|
93 |
|
---|
94 | ifdef LINUXINSTALLER
|
---|
95 | GUESTADDITIONS_LINUX_DEPS = $(LINUXINSTALLER)
|
---|
96 | GUESTADDITIONS_LINUX_FILESPEC = VBoxLinuxAdditions.run=$(LINUXINSTALLER)
|
---|
97 | endif
|
---|
98 |
|
---|
99 | #
|
---|
100 | # Build the Guest Additions ISO image.
|
---|
101 | #
|
---|
102 | $(PATH_BIN)/additions/VBoxGuestAdditions.iso: \
|
---|
103 | $(GUESTADDITIONS_WIN32_DEPS) $(GUESTADDITIONS_LINUX_DEPS) \
|
---|
104 | Makefile.kmk
|
---|
105 | $(call MSG_TOOL,mkisofs,,$@)
|
---|
106 | $(QUIET)$(VBOX_MKISOFS) -rational-rock -joliet -iso-level 4 -volid "VBOXADDITIONS" -l -graft-points -o $@ \
|
---|
107 | $(GUESTADDITIONS_WIN32_FILESPEC) $(GUESTADDITIONS_LINUX_FILESPEC)
|
---|
108 |
|
---|
109 | #
|
---|
110 | # Remote building.
|
---|
111 | #
|
---|
112 | ifdef VBOX_REMOTE_BUILD_WIN32_ADDITIONS
|
---|
113 | OTHER_CLEAN += $(PATH_TARGET)/ts-remote-build-win32-additions
|
---|
114 | $(GUESTADDITIONS_WIN32_DEPS): $(PATH_TARGET)/ts-remote-build-win32-additions
|
---|
115 | $(PATH_TARGET)/ts-remote-build-win32-additions:
|
---|
116 | $(RM) -f $@
|
---|
117 | $(VBOX_REMOTE_BUILD_WIN32_ADDITIONS)
|
---|
118 | $(APPEND) $@
|
---|
119 |
|
---|
120 | build-win32-additions:
|
---|
121 | $(KMK) VBOX_ADDITIONS_WIN32_ONLY=1 -C ../Runtime
|
---|
122 | $(KMK) VBOX_ADDITIONS_WIN32_ONLY=1 -C . all packing
|
---|
123 |
|
---|
124 | endif # VBOX_REMOTE_BUILD_WIN32_ADDITIONS
|
---|
125 |
|
---|
126 | # build the Linux installer on a remote machine
|
---|
127 | $(LINUXINSTALLER_CROSS):
|
---|
128 | ssh vbox@$(VBOX_ADDITIONS_LINUX_CROSS_HOST) "./enter-rhel3-jail /mnt/tinderwin_vbox/w32-rel/tools/env.sh --no-wine kmk -C src/VBox/Runtime BUILD_TYPE=release VBOX_ADDITIONS_LINUX_ONLY=1"
|
---|
129 | ssh vbox@$(VBOX_ADDITIONS_LINUX_CROSS_HOST) "./enter-rhel3-jail /mnt/tinderwin_vbox/w32-rel/tools/env.sh --no-wine kmk -C src/VBox/Additions/common BUILD_TYPE=release VBOX_ADDITIONS_LINUX_ONLY=1"
|
---|
130 | ssh vbox@$(VBOX_ADDITIONS_LINUX_CROSS_HOST) "./enter-rhel3-jail /mnt/tinderwin_vbox/w32-rel/tools/env.sh --no-wine kmk -C src/VBox/Additions/linux BUILD_TYPE=release all packing"
|
---|
131 |
|
---|