VirtualBox

source: vbox/trunk/src/VBox/Installer/linux/Makefile.kmk@ 34456

Last change on this file since 34456 was 34456, checked in by vboxsync, 14 years ago

Main/linux/USB and Installer/linux: switch to using our own device tree under /dev

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 14.8 KB
Line 
1# $Id: Makefile.kmk 34456 2010-11-29 12:20:42Z vboxsync $
2## @file
3# Makefile for the Linux installer.
4#
5
6#
7# Copyright (C) 2006-2010 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
21ifneq ($(KBUILD_HOST),linux)
22 $(error "The Linux installer can only be built on Linux!")
23endif
24
25#
26# Globals and targets.
27#
28VBOX_PATH_LNX_INST_SRC := $(PATH_SUB_CURRENT)
29VBOX_LNX_INST_OUT_DIR := $(PATH_TARGET)/Installer/linux
30VBOX_LNX_INST_STAGE_DIR := $(PATH_TARGET)/Installer/linux/install
31VBOX_LNX_DBG_PATH := usr/lib/debug/opt/VirtualBox
32VBOX_LNX_PACKAGE_NAME = VirtualBox-$(VBOX_VERSION_STRING)-r$(VBOX_SVN_REV).run
33
34# Unset this to speed up things during makefile hacking.
35VBOX_LNX_INST_DEP_ON_MAKEFILE := $(MAKEFILE_CURRENT)
36
37BLDDIRS += $(VBOX_LNX_INST_OUT_DIR) $(VBOX_LNX_INST_STAGE_DIR)
38PACKING += $(PATH_BIN)/VirtualBox.tar.bz2
39if !defined(VBOX_NO_LINUX_RUN_INSTALLER)
40 PACKING += $(PATH_BIN)/$(VBOX_LNX_PACKAGE_NAME) \
41 $(PATH_BIN)/VirtualBox-dbg.tar.bz2
42endif
43
44OTHER_CLEAN += \
45 $(addprefix $(VBOX_LNX_INST_STAGE_DIR)/,\
46 install.sh \
47 uninstall.sh \
48 deffiles \
49 routines.sh \
50 vboxdrv.sh \
51 vboxweb-service.sh \
52 VirtualBox.tar.bz2 \
53 LICENSE) \
54 $(wildcard $(VBOX_LNX_INST_OUT_DIR)/VirtualBox-*) \
55 $(addprefix $(VBOX_LNX_INST_OUT_DIR)/,\
56 vboxdrv.sh \
57 vboxweb-service.sh \
58 install.sh)
59
60#
61# Linux installs.
62#
63INSTALLS += linux-bin
64linux-bin_INST = bin/
65linux-bin_MODE = a+rx,u+w
66linux-bin_SOURCES = \
67 VBoxSysInfo.sh \
68 VBoxCreateUSBNode.sh \
69 VBox.sh=>VBox.sh \
70 $(if $(VBOX_WITH_PYTHON),$(PATH_ROOT)/src/VBox/Frontends/VBoxShell/vboxshell.py=>vboxshell.py,)
71
72INSTALLS += linux-misc
73linux-misc_INST = bin/
74linux-misc_MODE = a+r,u+w
75linux-misc_SOURCES = \
76 $(PATH_ROOT)/src/VBox/Frontends/VirtualBox/images/$(if $(VBOX_OSE),OSE,NonOSE)/VirtualBox_32px.png=>VBox.png \
77 $(if $(VBOX_OSE),,$(VBOX_BRAND_LICENSE_TXT)=>LICENSE) \
78 $(if $(VBOX_WITH_QTGUI),$(PATH_linux-misc)/virtualbox.desktop,)
79linux-misc_CLEAN = $(PATH_linux-misc)/virtualbox.desktop
80
81$$(PATH_linux-misc)/virtualbox.desktop: $(PATH_SUB_CURRENT)/virtualbox.desktop $(VBOX_VERSION_STAMP) | $$(dir $$@)
82 $(call MSG_GENERATE,,$@,$<)
83ifdef VBOX_PATH_PACKAGE_DOCS
84 $(QUIET)$(SED) -e "s+\$$VBOX_DOC_PATH+$(VBOX_PATH_PACKAGE_DOCS)+" --output $@ $<
85else
86 $(QUIET)$(SED) -e "s+\$$VBOX_DOC_PATH+/opt/VirtualBox+" --output $@ $<
87endif
88
89
90
91#
92# The files residing in bin/ that we'll ship.
93#
94
95# Strip these binaries
96VBOX_LNX_STRIP_BIN = \
97 VBoxDD.so \
98 VBoxDD2.so \
99 VBoxREM.so \
100 VBoxDDU.so \
101 VBoxVMM.so \
102 $(if $(eq $(KBUILD_TARGET_ARCH),x86),VBoxREM32.so,) \
103 $(if $(eq $(KBUILD_TARGET_ARCH),x86),VBoxREM64.so,) \
104 VBoxRT.so \
105 $(if $(VBOX_WITH_VBOXSDL),VBoxSDL $(if $(VBOX_WITH_HARDENING),VBoxSDL.so),) \
106 $(if $(VBOX_WITH_SHARED_CLIPBOARD), VBoxSharedClipboard.so,) \
107 $(if $(VBOX_WITH_SHARED_FOLDERS), VBoxSharedFolders.so,) \
108 $(if $(VBOX_WITH_GUEST_PROPS),VBoxGuestPropSvc.so,) \
109 $(if $(VBOX_WITH_GUEST_CONTROL),VBoxGuestControlSvc.so,) \
110 $(if $(VBOX_WITH_MAIN), \
111 VBoxManage \
112 VBoxNetDHCP $(if $(VBOX_WITH_HARDENING),VBoxNetDHCP.so,) \
113 VBoxNetAdpCtl \
114 VBoxSVC \
115 VBoxXPCOM.so \
116 VBoxXPCOMC.so \
117 VBoxXPCOMIPCD \
118 components/VBoxXPCOMIPCC.so \
119 components/VBoxSVCM.so \
120 components/VBoxC.so,) \
121 $(if $(VBOX_WITH_CROGL),\
122 VBoxOGLhostcrutil.so \
123 VBoxOGLhosterrorspu.so \
124 VBoxOGLrenderspu.so \
125 VBoxTestOGL \
126 VBoxSharedCrOpenGL.so,) \
127 $(if $(VBOX_WITH_PYTHON),$(notdir $(wildcard $(PATH_BIN)/VBoxPython*.so)),) \
128 $(if $(VBOX_WITH_JXPCOM),libvboxjxpcom.so,) \
129 VBoxTunctl
130
131# Do not remove relocation information of these binaries
132VBOX_LNX_STRIP_OBJ = \
133 VBoxDD2GC.gc \
134 VBoxDD2R0.r0 \
135 VBoxDDGC.gc \
136 VBoxDDR0.r0 \
137 VMMGC.gc \
138 VMMR0.r0
139
140# Do not strip anything of these files
141VBOX_LNX_NO_STRIP = \
142 $(if $(VBOX_OSE),,LICENSE) \
143 $(if $(VBOX_WITH_MAIN), \
144 components/VBoxXPCOMBase.xpt \
145 components/VirtualBox_XPCOM.xpt) \
146 $(if $(VBOX_WITH_PYTHON),vboxshell.py,) \
147 VBoxSysInfo.sh \
148 VBoxCreateUSBNode.sh \
149 VBox.sh \
150 VBox.png
151
152# Qt4 GUI
153ifdef VBOX_WITH_QTGUI
154 include $(PATH_ROOT)/src/VBox/Frontends/VirtualBox/nls/ApprovedLanguages.kmk
155 VBOX_LNX_STRIP_BIN += \
156 VBoxKeyboard.so \
157 VirtualBox \
158 $(if $(VBOX_WITH_HARDENING),VirtualBox.so) \
159 $(if $(VBOX_WITH_DEBUGGER_GUI),VBoxDbg.so)
160 VBOX_LNX_NO_STRIP += \
161 virtualbox.desktop \
162 $(VBOX_LICENSE_FILES) \
163 $(if $(VBOX_WITH_QT4_SUN),$(notdir $(wildcard $(PATH_BIN)/lib*VBox*)),) \
164 $(if $(VBOX_WITH_QT4_SUN),accessible/libqtaccessiblewidgets.so,) \
165 $(foreach f,$(VBOX_APPROVED_GUI_LANGUAGES),nls/VirtualBox_$(f).qm nls/qt_$(f).qm)
166endif
167
168# Guest Additions
169ifdef VBOX_WITH_ADDITIONS_PACKING
170 VBOX_LNX_NO_STRIP += \
171 additions/VBoxGuestAdditions.iso
172endif
173
174# Documentation
175ifdef VBOX_WITH_DOCS_PACKING
176 VBOX_LNX_NO_STRIP += \
177 UserManual.pdf \
178 $(foreach f,$(VBOX_MANUAL_ADD_LANGUAGES),UserManual_$(f).pdf)
179 ifdef VBOX_WITH_DOCS_CHM
180 VBOX_LNX_NO_STRIP += \
181 VirtualBox.chm \
182 $(foreach f,$(VBOX_MANUAL_ADD_LANGUAGES),VirtualBox_$(f).chm)
183 endif
184 VBOX_LNX_STRIP_BIN += \
185 $(if $(VBOX_WITH_KCHMVIEWER),kchmviewer,)
186endif
187
188# auth stuff
189VBOX_LNX_STRIP_BIN += \
190 VBoxAuth.so \
191 VBoxAuthSimple.so
192
193# VRDP
194ifdef VBOX_WITH_VRDP
195 VBOX_LNX_STRIP_BIN += \
196 VBoxVRDP.so
197 ifdef VBOX_WITH_VRDP_RDESKTOP
198 VBOX_LNX_NO_STRIP += \
199 rdesktop-vrdp.tar.gz
200 VBOX_LNX_NO_STRIP += \
201 rdesktop-vrdp-keymaps
202 VBOX_LNX_STRIP_BIN += \
203 rdesktop-vrdp
204 endif
205endif
206
207# Python XPCOM glue
208ifdef VBOX_WITH_PYTHON
209 VBOX_LNX_NO_STRIP += \
210 $(foreach f,$(notdir $(wildcard $(PATH_BIN)/sdk/bindings/xpcom/python/xpcom/*.py)),sdk/bindings/xpcom/python/xpcom/$(f)) \
211 sdk/bindings/xpcom/python/xpcom/client/__init__.py \
212 sdk/bindings/xpcom/python/xpcom/server/__init__.py \
213 sdk/bindings/xpcom/python/xpcom/server/enumerator.py \
214 sdk/bindings/xpcom/python/xpcom/server/factory.py \
215 sdk/bindings/xpcom/python/xpcom/server/loader.py \
216 sdk/bindings/xpcom/python/xpcom/server/module.py \
217 sdk/bindings/xpcom/python/xpcom/server/policy.py \
218 sdk/installer/vboxapisetup.py \
219 sdk/installer/vboxapi/__init__.py \
220 sdk/installer/vboxapi/VirtualBox_constants.py
221endif
222
223# Java XPCOM bridge
224ifdef VBOX_WITH_JXPCOM
225 VBOX_LNX_NO_STRIP += \
226 sdk/bindings/xpcom/java/vboxjxpcom.jar
227endif
228
229# Headless
230ifdef VBOX_WITH_HEADLESS
231 VBOX_LNX_STRIP_BIN += \
232 VBoxHeadless \
233 $(if $(VBOX_WITH_HARDENING),VBoxHeadless.so)
234endif
235
236# BFE
237ifdef VBOX_WITH_BFE
238 VBOX_LNX_STRIP_BIN += \
239 VBoxBFE \
240 $(if $(VBOX_WITH_HARDENING),VBoxBFE.so)
241endif
242
243# Webservices
244ifdef VBOX_WITH_WEBSERVICES
245 VBOX_LNX_STRIP_BIN += \
246 vboxwebsrv \
247 webtest
248endif
249
250# EFI firmware
251ifdef VBOX_WITH_EFIFW_PACKING
252 VBOX_LNX_NO_STRIP += \
253 VBoxEFI32.fd \
254 VBoxEFI64.fd
255endif
256
257#
258# All the bin files that goes into the archives.
259#
260VBOX_LNX_ARCH_FILES := $(VBOX_LNX_STRIP_BIN) $(VBOX_LNX_STRIP_OBJ) $(VBOX_LNX_NO_STRIP) src
261
262# Cleanup of the files we copy/symlink from bin.
263OTHER_CLEAN += $(addprefix $(VBOX_LNX_INST_OUT_DIR)/archive/,$(VBOX_LNX_ARCH_FILES)) \
264 $(addprefix $(VBOX_LNX_INST_OUT_DIR)/archive-dbg/$(VBOX_LNX_DBG_PATH)/,$(VBOX_LNX_STRIP_BIN))
265
266
267#
268# The generic installer.
269#
270$(PATH_BIN)/$(VBOX_LNX_PACKAGE_NAME): \
271 $(VBOX_LNX_INST_STAGE_DIR)/VirtualBox.tar.bz2 \
272 $(VBOX_VERSION_STAMP) \
273 $(VBOX_PATH_LNX_INST_SRC)/routines.sh \
274 $(VBOX_PATH_LNX_INST_SRC)/deffiles \
275 $(if $(VBOX_OSE),,$(VBOX_BRAND_LICENSE_TXT)) \
276 $(VBOX_LNX_INST_OUT_DIR)/vboxdrv.sh \
277 $(VBOX_LNX_INST_OUT_DIR)/vboxweb-service.sh \
278 $(VBOX_LNX_INST_OUT_DIR)/install.sh \
279 $(VBOX_PATH_LNX_INST_SRC)/vboxdrv-pardus.py \
280 $(VBOX_PATH_LNX_INST_SRC)/uninstall.sh \
281 $(wildcard $(PATH_BIN)/src/*) \
282 $(wildcard $(PATH_BIN)/src/*/*) \
283 $(wildcard $(PATH_BIN)/src/*/*/*) \
284 $(wildcard $(PATH_BIN)/src/*/*/*/*)
285 $(call MSG_TOOL,makeself,,$@)
286 $(QUIET)$(RM) -f $(wildcard $(PATH_BIN)/VirtualBox-*.run)
287 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_LNX_INST_SRC)/routines.sh $(VBOX_LNX_INST_STAGE_DIR)/
288 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_LNX_INST_SRC)/deffiles $(VBOX_LNX_INST_STAGE_DIR)/
289 $(QUIET)$(if $(VBOX_OSE),,$(INSTALL) -m 0644 $(VBOX_BRAND_LICENSE_TXT) $(VBOX_LNX_INST_STAGE_DIR)/LICENSE)
290 $(QUIET)$(INSTALL) -m 0755 $(VBOX_LNX_INST_OUT_DIR)/vboxdrv.sh $(VBOX_LNX_INST_STAGE_DIR)/
291 $(QUIET)$(INSTALL) -m 0755 $(VBOX_LNX_INST_OUT_DIR)/vboxweb-service.sh $(VBOX_LNX_INST_STAGE_DIR)/
292 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_LNX_INST_SRC)/vboxdrv-pardus.py $(VBOX_LNX_INST_STAGE_DIR)/
293 $(QUIET)$(INSTALL) -m 0755 $(VBOX_LNX_INST_OUT_DIR)/install.sh $(VBOX_LNX_INST_STAGE_DIR)/
294 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_LNX_INST_SRC)/uninstall.sh $(VBOX_LNX_INST_STAGE_DIR)/
295 $(QUIET)$(RM) -f $@
296 $(QUIET)$(VBOX_MAKESELF) --follow --nocomp $(VBOX_LNX_INST_STAGE_DIR) $@ \
297 "VirtualBox for Linux installation" ./install.sh "\$$0 1> /dev/null"
298
299# files that needs editing before they can be included in the generic installer.
300$(VBOX_LNX_INST_OUT_DIR)/vboxdrv.sh: $(VBOX_PATH_LNX_INST_SRC)/vboxdrv.sh.in | $$(dir $$@)
301 $(QUIET)$(SED_EXT) \
302 -e "s|%NOLSB%|yes|g" \
303 -e "s|%DEBIAN%||g" \
304 -e "s|%PACKAGE%|virtualbox|g" \
305 --output $@ \
306 $<
307
308$(VBOX_LNX_INST_OUT_DIR)/vboxweb-service.sh: $(VBOX_PATH_LNX_INST_SRC)/vboxweb-service.sh.in | $$(dir $$@)
309 $(QUIET)$(SED_EXT) \
310 -e "s|%NOLSB%|yes|g" \
311 -e "s|%DEBIAN%||g" \
312 -e "s|%PACKAGE%|virtualbox|g" \
313 --output $@ \
314 $<
315
316$(VBOX_LNX_INST_OUT_DIR)/install.sh: $(VBOX_PATH_LNX_INST_SRC)/install.sh $(VBOX_VERSION_STAMP) $(VBOX_SVN_REV_KMK).ts | $$(dir $$@)
317 $(QUIET)$(SED) \
318 -e "s;_VERSION_;$(VBOX_VERSION_STRING);g" \
319 -e "s;_SVNREV_;$(VBOX_SVN_REV);g" \
320 -e "s;_BUILD_;$(date-utc );g" \
321 -e "s;_ARCH_;$(KBUILD_TARGET_ARCH);g" \
322 -e "s;_HARDENED_;$(VBOX_WITH_HARDENING);g" \
323 -e "s;_PYTHON_;$(VBOX_WITH_PYTHON);g" \
324 --output $@ \
325 $<
326
327#
328# .tar.bz2 for converting into .run
329#
330$(VBOX_LNX_INST_STAGE_DIR)/VirtualBox.tar.bz2: \
331 $(addprefix $(VBOX_LNX_INST_OUT_DIR)/archive/, $(VBOX_LNX_ARCH_FILES)) \
332 $(VBOX_LNX_INST_DEP_ON_MAKEFILE) \
333 $(VBOX_VERSION_STAMP)
334 $(call MSG_L1,Packing $@)
335 $(QUIET)$(RM) -f -- $@ $(patsubst %.bz2,%,$@)
336 $(QUIET)$(MKDIR) -p $(@D)
337ifdef VBOX_USE_PBZIP2
338 $(QUIET)tar --owner 0 --group 0 -cRhf $(patsubst %.bz2,%,$@) -C $(VBOX_LNX_INST_OUT_DIR)/archive $(VBOX_LNX_ARCH_FILES)
339 $(QUIET)pbzip2 $(patsubst %.bz2,%,$@)
340else
341 $(QUIET)tar --owner 0 --group 0 -cjRhf $@ -C $(VBOX_LNX_INST_OUT_DIR)/archive $(VBOX_LNX_ARCH_FILES)
342endif
343 $(QUIET)$(CHMOD) 0644 $@
344
345#
346# .tar.bz2 for distribution with the files under VirtualBox-<ver>/.
347#
348$(PATH_BIN)/VirtualBox.tar.bz2: \
349 $(addprefix $(VBOX_LNX_INST_OUT_DIR)/archive/, $(VBOX_LNX_ARCH_FILES)) \
350 $(VBOX_LNX_INST_DEP_ON_MAKEFILE) \
351 $(VBOX_VERSION_STAMP)
352 $(call MSG_L1,Packing $@)
353 $(QUIET)$(RM) -f -- $(VBOX_LNX_INST_OUT_DIR)/VirtualBox-$(VBOX_VERSION_STRING) $@ $(patsubst %.bz2,%,$@)
354 $(QUIET)$(LN_SYMLINK) $(VBOX_LNX_INST_OUT_DIR)/archive/ $(VBOX_LNX_INST_OUT_DIR)/VirtualBox-$(VBOX_VERSION_STRING)
355ifdef VBOX_USE_PBZIP2
356 $(QUIET)tar --owner 0 --group 0 -cRhf $(patsubst %.bz2,%,$@) -C $(VBOX_LNX_INST_OUT_DIR) \
357 $(addprefix VirtualBox-$(VBOX_VERSION_STRING)/,$(VBOX_LNX_ARCH_FILES))
358 $(QUIET)pbzip2 $(patsubst %.bz2,%,$@)
359else
360 $(QUIET)tar --owner 0 --group 0 -cjRhf $@ -C $(VBOX_LNX_INST_OUT_DIR) \
361 $(addprefix VirtualBox-$(VBOX_VERSION_STRING)/,$(VBOX_LNX_ARCH_FILES))
362endif
363 $(QUIET)$(RM) -f -- $(VBOX_LNX_INST_OUT_DIR)/VirtualBox-$(VBOX_VERSION_STRING)
364
365
366# pattern rule for stripping and copying the VBOX_LNX_STRIP_BIN files to archive/
367$(addprefix $(VBOX_LNX_INST_OUT_DIR)/archive/,$(VBOX_LNX_STRIP_BIN)): \
368 $(VBOX_LNX_INST_OUT_DIR)/archive/% : $(PATH_BIN)/% \
369 $(if $(VBOX_NO_LINUX_RUN_INSTALLER),,\
370 $(VBOX_LNX_INST_OUT_DIR)/archive-dbg/$(VBOX_LNX_DBG_PATH)/%) \
371 | $$(dir $$@)
372 $(call MSG_INST_FILE,$<,$@)
373 $(QUIET)$(INSTALL) -m 0755 $(if $(VBOX_DO_STRIP),-s,) $< $@
374 $(QUIET)$(if $(VBOX_NO_LINUX_RUN_INSTALLER),,objcopy --add-gnu-debuglink=$(subst $(VBOX_LNX_INST_OUT_DIR)/archive,$(VBOX_LNX_INST_OUT_DIR)/archive-dbg/$(VBOX_LNX_DBG_PATH),$@) $@)
375
376# pattern rule for striping and copying the VBOX_LNX_STRIP_OBJ files to archive/
377$(addprefix $(VBOX_LNX_INST_OUT_DIR)/archive/,$(VBOX_LNX_STRIP_OBJ)): \
378 $(VBOX_LNX_INST_OUT_DIR)/archive/% : $(PATH_BIN)/% | $$(dir $$@)
379 $(call MSG_INST_FILE,$<,$@)
380ifeq ($(VBOX_DO_STRIP),)
381 $(QUIET)$(INSTALL) -m 0644 $< $@
382else # strip to temp file because of umask.
383 $(QUIET)objcopy --strip-unneeded -R .comment $< [email protected]
384 $(QUIET)$(INSTALL) -m 0644 [email protected] $@
385 $(QUIET)$(RM) -f -- [email protected]
386endif
387
388# special rule for the kernel modules
389$(VBOX_LNX_INST_OUT_DIR)/archive/src: $(PATH_BIN)/src | $(dir $@)
390 $(call MSG_INST_SYM,$<,$@)
391 $(QUIET)$(RM) -Rf $@
392 $(QUIET)$(MKDIR) $@
393 $(QUIET)$(LN_SYMLINK) $< $@/vboxhost
394
395# pattern rule for linking the VBOX_LNX_NO_STRIP into archive/
396$(addprefix $(VBOX_LNX_INST_OUT_DIR)/archive/,$(VBOX_LNX_NO_STRIP)): \
397 $(VBOX_LNX_INST_OUT_DIR)/archive/% : $(PATH_BIN)/% | $$(dir $$@)
398 $(call MSG_INST_SYM,$<,$@)
399 $(QUIET)$(RM) -f $@
400 $(QUIET)$(LN_SYMLINK) $< $@
401
402# rules for creating directories in archive (the pattern rules depends on these). ## @todo use BLDDIRS
403BLDDIRS += $(foreach d,\
404 archive \
405 archive/components \
406 archive/nls \
407 $(if $(VBOX_WITH_QT4_SUN),archive/accessible,) \
408 $(if $(VBOX_WITH_PYTHON),\
409 archive/sdk/installer \
410 archive/sdk/installer/vboxapi \
411 archive/sdk/bindings/xpcom/python/xpcom \
412 archive/sdk/bindings/xpcom/python/xpcom/client \
413 archive/sdk/bindings/xpcom/python/xpcom/server,) \
414 $(if $(VBOX_WITH_JXPCOM),\
415 archive/sdk/bindings/xpcom/java,) \
416 archive/additions \
417 install\
418,$(VBOX_LNX_INST_OUT_DIR)/$(d)/)
419
420
421#
422# .tar.bz2 for with the debug info.
423#
424$(PATH_BIN)/VirtualBox-dbg.tar.bz2: \
425 $(addprefix $(VBOX_LNX_INST_OUT_DIR)/archive-dbg/$(VBOX_LNX_DBG_PATH)/, $(VBOX_LNX_STRIP_BIN))
426 $(call MSG_L1,Packing $@)
427 $(QUIET)$(RM) -f -- $@ $(patsubst %.bz2,%,$@)
428ifdef VBOX_USE_PBZIP2
429 $(QUIET)tar --owner 0 --group 0 -cRhf $(patsubst %.bz2,%,$@) -C $(VBOX_LNX_INST_OUT_DIR)/archive-dbg \
430 $(addprefix $(VBOX_LNX_DBG_PATH)/,$(VBOX_LNX_STRIP_BIN))
431 $(QUIET)pbzip2 $(patsubst %.bz2,%,$@)
432else
433 $(QUIET)tar --owner 0 --group 0 -cjRhf $@ -C $(VBOX_LNX_INST_OUT_DIR)/archive-dbg \
434 $(addprefix $(VBOX_LNX_DBG_PATH)/,$(VBOX_LNX_STRIP_BIN))
435endif
436
437# pattern rule for copying the debug info from the VBOX_LNX_STRIP_BIN files into archive-dbg/$(VBOX_LNX_DBG_PATH)/
438$(addprefix $(VBOX_LNX_INST_OUT_DIR)/archive-dbg/$(VBOX_LNX_DBG_PATH)/,$(VBOX_LNX_STRIP_BIN)): \
439 $(VBOX_LNX_INST_OUT_DIR)/archive-dbg/$(VBOX_LNX_DBG_PATH)/% : $(PATH_BIN)/% | $$(dir $$@)
440 $(call MSG_TOOL,copydbg,$<,$@)
441 $(QUIET)objcopy --only-keep-debug $< $@
442
443# rules for creating directories in archive-dbg (the pattern rules depends on these). ## @todo use BLDDIRS
444BLDDIRS += $(foreach d,\
445 $(VBOX_LNX_DBG_PATH) \
446 $(VBOX_LNX_DBG_PATH)/components \
447,$(VBOX_LNX_INST_OUT_DIR)/archive-dbg/$(d)/)
448
449include $(KBUILD_PATH)/subfooter.kmk
450
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