VirtualBox

source: vbox/trunk/src/VBox/Installer/solaris/Makefile.kmk@ 31635

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

Solaris/Installer: strip only debug symbols for relocatable objects.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 35.3 KB
Line 
1# $Id: Makefile.kmk 31390 2010-08-05 11:10:13Z vboxsync $
2## @file
3# Sub-Makefile for the Solaris installer.
4#
5
6#
7# Copyright (C) 2007-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),solaris)
22$(error "The Solaris installer can only be built on Solaris!") # yeah, right.
23endif
24
25# Unset this to speed up things during makefile hacking.
26VBOX_SOL_INST_DEP_ON_MAKEFILE := $(MAKEFILE_CURRENT)
27
28#
29# Globals
30#
31ifdef VBOX_WITH_COMBINED_SOLARIS_PACKAGE ## @todo remove this when tinderclient.pl is updated.
32 VBOX_WITH_COMBINED_PACKAGE := 1
33endif
34VBOX_PATH_SOL_INST_SRC := $(PATH_SUB_CURRENT)
35SOLARIS_DIR_NAME_64 := amd64
36SOLARIS_DIR_NAME_32 := i386
37SOLARIS_INST_OUT_DIR := $(PATH_TARGET)/Installer
38SOLARIS_BASEINST_DIR := $(PATH_TARGET)/Installer/BasePkg
39SOLARIS_VBOXINST_SUBDIR := opt/VirtualBox
40SOLARIS_VBOXINST_DIR := $(SOLARIS_BASEINST_DIR)/$(SOLARIS_VBOXINST_SUBDIR)
41SOLARIS_VBOXINST_DIR_32 := $(SOLARIS_VBOXINST_DIR)/$(SOLARIS_DIR_NAME_32)
42SOLARIS_VBOXINST_DIR_64 := $(SOLARIS_VBOXINST_DIR)/$(SOLARIS_DIR_NAME_64)
43SOLARIS_DRIVERINST_DIR := $(SOLARIS_BASEINST_DIR)/platform/i86pc/kernel/drv
44SOLARIS_DRIVERINST_DIR_32 := $(SOLARIS_DRIVERINST_DIR)
45SOLARIS_DRIVERINST_DIR_64 := $(SOLARIS_DRIVERINST_DIR)/amd64
46SOLARIS_USR_DIR := $(SOLARIS_BASEINST_DIR)/usr
47SOLARIS_USRBIN_DIR := $(SOLARIS_USR_DIR)/bin
48SOLARIS_USRSHR_APPS_DIR := $(SOLARIS_USR_DIR)/share/applications
49SOLARIS_USRSHR_PIXMAPS_DIR := $(SOLARIS_USR_DIR)/share/pixmaps
50SOLARIS_VBOXSMF_DIR := $(SOLARIS_BASEINST_DIR)/var/svc/manifest/application/virtualbox
51SOLARIS_ETC_DIR := $(SOLARIS_BASEINST_DIR)/etc
52
53SOLARIS_OUT_BIN_64 := $(PATH_OUT_BASE)/solaris.amd64/$(KBUILD_TYPE)/bin
54SOLARIS_OUT_BIN_32 := $(PATH_OUT_BASE)/solaris.x86/$(KBUILD_TYPE)/bin
55SOLARIS_OUT_BIN := $(PATH_BIN)
56
57SOLARIS_DBG_DIR := $(PATH_TARGET)/Installer/DebugPkg
58SOLARIS_DBG_DIR_32 := $(SOLARIS_DBG_DIR)/$(SOLARIS_DIR_NAME_32)
59SOLARIS_DBG_DIR_64 := $(SOLARIS_DBG_DIR)/$(SOLARIS_DIR_NAME_64)
60SOLARIS_VBI_DIR := $(PATH_TARGET)/Installer/KernelPkg
61
62ifeq ($(KBUILD_TARGET_ARCH),amd64)
63 SOLARIS_VBOXINST_DIR_ISA := $(SOLARIS_VBOXINST_DIR_64)
64 SOLARIS_DRIVERINST_DIR_ISA := $(SOLARIS_DRIVERINST_DIR_64)
65 SOLARIS_DBG_DIR_ISA := $(SOLARIS_DBG_DIR_64)
66 SOL_DBG_OBJCOPY := /usr/sfw/bin/gobjcopy --only-keep-debug
67 SOL64_PKG := 1
68else
69 SOLARIS_VBOXINST_DIR_ISA := $(SOLARIS_VBOXINST_DIR_32)
70 SOLARIS_DRIVERINST_DIR_ISA := $(SOLARIS_DRIVERINST_DIR_32)
71 SOLARIS_DBG_DIR_ISA := $(SOLARIS_DBG_DIR_32)
72 SOL_DBG_OBJCOPY := $(CP) -p # Solaris ld/gobjcopy(2.15) don't get along on x86, works only on amd64. So just using cp for now.
73endif
74SOL_OBJCOPY := /usr/sfw/bin/gobjcopy --strip-debug -R .comment
75SOL_GTAR := /usr/sfw/bin/gtar
76
77# Figure out the paths to the two platform specific Qt4 directories
78SOLARIS_PATH_QT_32 = $(subst solaris.$(KBUILD_TARGET_ARCH),solaris.x86,$(VBOX_PATH_QT4))
79SOLARIS_PATH_QT_64 = $(subst solaris.$(KBUILD_TARGET_ARCH),solaris.amd64,$(VBOX_PATH_QT4))
80
81# Base package
82PKGINFO_ARCH = $(shell uname -p)
83PKGINFO_REVSTAMP = $(date %Y.%m.%d.%H.%M)
84ifndef VBOX_WITH_COMBINED_PACKAGE
85 PKG_FILENAME = VirtualBox-$(VBOX_VERSION_STRING)-SunOS-$(KBUILD_TARGET_ARCH)-r$(VBOX_SVN_REV)
86else
87 PKG_FILENAME = VirtualBox-$(VBOX_VERSION_STRING)-SunOS-r$(VBOX_SVN_REV)
88endif
89
90# Debug package
91DBG_ARCHIVE = VirtualBoxDebug.tar.bz2
92
93# Kernel interface (vbi) package
94VBIPKG_FILENAME = VirtualBoxKern-$(VBOX_VERSION_STRING)-SunOS-r$(VBOX_SVN_REV)
95
96#
97# Targets
98#
99PROGRAMS += VBoxZoneAccess VBoxISAExec
100INSTALLS += solaris-doc solaris-bin solaris-drv-confs
101
102BLDDIRS += \
103 $(SOLARIS_INST_OUT_DIR) \
104 $(SOLARIS_BASEINST_DIR) \
105 $(SOLARIS_VBOXINST_DIR) \
106 $(SOLARIS_VBI_DIR) \
107 $(SOLARIS_DBG_DIR)
108
109BLDDIRS += $(addprefix $(SOLARIS_BASEINST_DIR)/,\
110 usr \
111 usr/bin \
112 platform \
113 platform/i86pc \
114 platform/i86pc/kernel \
115 platform/i86pc/kernel/drv \
116 platform/i86pc/kernel/drv/amd64 \
117)
118
119PACKING += $(PATH_BIN)/$(PKG_FILENAME).tar.gz $(PATH_BIN)/$(DBG_ARCHIVE)
120
121OTHER_CLEAN += $(addprefix $(SOLARIS_BASEINST_DIR)/,\
122 vbox.pkginfo vbox.copyright vbox.space vbox.depend vbox.pkgresponse \
123 makepackage.sh prototype postinstall.sh checkinstall.sh preremove.sh)
124
125#
126# VBoxZoneAccess
127#
128VBoxZoneAccess_TEMPLATE = VBOXR3EXE
129VBoxZoneAccess_DEPS = $(VBOX_SVN_REV_KMK)
130VBoxZoneAccess_SOURCES = VBoxZoneAccess.c
131VBoxZoneAccess_LIBS = $(LIB_RUNTIME)
132
133#
134# VBoxISAExec
135#
136VBoxISAExec_TEMPLATE = VBOXR3EXE
137VBoxISAExec_DEPS = $(VBOX_SVN_REV_KMK)
138VBoxISAExec_SOURCES = VBoxISAExec.c
139
140#
141# Solaris installs.
142#
143solaris-doc_INST = bin/
144solaris-doc_MODE = a+r,u+w
145solaris-doc_SOURCES = \
146 $(if $(VBOX_OSE),,$(VBOX_BRAND_LICENSE_TXT)=>LICENSE) \
147 $(PATH_ROOT)/src/VBox/Frontends/VirtualBox/images/$(if $(VBOX_OSE),OSE,NonOSE)/VirtualBox_64px.png=>VBox.png
148
149solaris-bin_INST = bin/
150solaris-bin_MODE = a+rx,u+w
151solaris-bin_SOURCES = \
152 $(if $(VBOX_WITH_PYTHON),$(PATH_ROOT)/src/VBox/Frontends/VBoxShell/vboxshell.py,) \
153 $(VBOX_PATH_SOL_INST_SRC)/vboxconfig.sh \
154 $(VBOX_PATH_SOL_INST_SRC)/VBox.sh \
155 $(VBOX_PATH_SOL_INST_SRC)/pkginstall.sh \
156 $(if $(VBOX_WITH_WEBSERVICES),$(VBOX_PATH_SOL_INST_SRC)/smf-vboxwebsrv.sh,)
157
158solaris-drv-confs_INST = bin/
159solaris-drv-confs_MODE = a+r,u+w
160solaris-drv-confs_SOURCES = \
161 $(PATH_ROOT)/src/VBox/HostDrivers/Support/solaris/vboxdrv.conf \
162 $(if $(VBOX_WITH_NETFLT),$(PATH_ROOT)/src/VBox/HostDrivers/VBoxNetFlt/solaris/vboxflt.conf) \
163 $(if $(VBOX_WITH_NETADP),$(PATH_ROOT)/src/VBox/HostDrivers/VBoxNetAdp/solaris/vboxnet.conf) \
164 $(if $(VBOX_WITH_USB),$(PATH_ROOT)/src/VBox/HostDrivers/VBoxUSB/solaris/vboxusbmon.conf) \
165 $(if $(VBOX_WITH_NEW_USB_CODE_ON_SOLARIS),$(PATH_ROOT)/src/VBox/HostDrivers/VBoxUSB/solaris/vboxusb.conf)
166
167#
168# Note: Other than the files produced during packing (.pkg, .gzip etc.) all files that
169# go into the temporary install folder $(SOLARIS_VBOXINST_DIR) should be part of $(SOLARIS_ARCH_FILES).
170# For the files produced during packing they should be cleaned up promptly when the work is done.
171#
172
173# Strip these executables
174SOLARIS_STRIP_EXES = \
175 VBoxZoneAccess \
176 $(if $(VBOX_WITH_QTGUI),VirtualBox,) \
177 VBoxManage \
178 $(if $(VBOX_WITH_VBOXBFE),VBoxBFE,) \
179 $(if $(VBOX_WITH_VBOXSDL),VBoxSDL,) \
180 $(if $(VBOX_WITH_NETADP),VBoxNetAdpCtl,) \
181 VBoxNetDHCP \
182 VBoxSVC \
183 $(if $(VBOX_WITH_CROGL),VBoxTestOGL,) \
184 VBoxXPCOMIPCD \
185 $(if $(VBOX_WITH_KCHMVIEWER),kchmviewer,)
186
187ifdef VBOX_WITH_USB
188 ifndef VBOX_WITH_NEW_USB_CODE_ON_SOLARIS
189 SOLARIS_STRIP_EXES += VBoxUSBHelper
190 endif
191endif
192
193SOLARIS_DRIVER_BINS = \
194 vboxdrv \
195 $(if $(VBOX_WITH_NETFLT),vboxflt,) \
196 $(if $(VBOX_WITH_NETADP),vboxnet,) \
197 $(if $(VBOX_WITH_USB),vboxusbmon,) \
198 $(if $(VBOX_WITH_NEW_USB_CODE_ON_SOLARIS),vboxusb,)
199
200SOLARIS_DRIVER_CONFS = \
201 vboxdrv.conf \
202 $(if $(VBOX_WITH_NETFLT),vboxflt.conf,) \
203 $(if $(VBOX_WITH_NETADP),vboxnet.conf,) \
204 $(if $(VBOX_WITH_USB),vboxusbmon.conf,) \
205 $(if $(VBOX_WITH_NEW_USB_CODE_ON_SOLARIS),vboxusb.conf,)
206
207# Strip these binaries
208SOLARIS_STRIP_BINS = \
209 VBoxDD.so \
210 VBoxDD2.so \
211 VBoxREM.so \
212 VBoxRT.so \
213 VBoxDDU.so \
214 VBoxVMM.so \
215 VBoxXPCOM.so \
216 VBoxXPCOMC.so \
217 $(if $(VBOX_WITH_SHARED_FOLDERS),VBoxSharedFolders.so,) \
218 $(if $(VBOX_WITH_SHARED_CLIPBOARD),VBoxSharedClipboard.so,) \
219 $(if $(VBOX_WITH_GUEST_PROPS),VBoxGuestPropSvc.so,) \
220 $(if $(VBOX_WITH_GUEST_CONTROL),VBoxGuestControlSvc.so,) \
221 $(if $(VBOX_WITH_JXPCOM),libvboxjxpcom.so,) \
222 $(if $(VBOX_WITH_QTGUI),\
223 VBoxKeyboard.so \
224 $(if $(VBOX_WITH_QT4_SUN),\
225 libQtCoreVBox.so.4 \
226 libQtGuiVBox.so.4 \
227 libQtNetworkVBox.so.4 \
228 $(if $(VBOX_GUI_USE_QGL),libQtOpenGLVBox.so.4,) \
229 accessible/libqtaccessiblewidgets.so,)) \
230 $(if $(VBOX_WITH_DEBUGGER_GUI),VBoxDbg.so,) \
231 $(if $(VBOX_WITH_CROGL),\
232 VBoxOGLhostcrutil.so \
233 VBoxOGLhosterrorspu.so \
234 VBoxOGLrenderspu.so \
235 VBoxSharedCrOpenGL.so) \
236 components/VBoxC.so \
237 components/VBoxSVCM.so \
238 components/VBoxXPCOMIPCC.so
239ifdef VBOX_WITH_HARDENING
240SOLARIS_STRIP_BINS += \
241 VBoxNetDHCP.so \
242 $(if $(VBOX_WITH_VBOXBFE),VBoxBFE.so,) \
243 $(if $(VBOX_WITH_VBOXSDL),VBoxSDL.so,) \
244 $(if $(VBOX_WITH_QTGUI),VirtualBox.so,)
245endif
246
247# Do not remove relocation information of these binaries
248SOLARIS_STRIP_OBJS = \
249 VBoxDD2GC.gc \
250 VBoxDD2R0.r0 \
251 VBoxDDGC.gc \
252 VBoxDDR0.r0 \
253 VMMGC.gc \
254 VMMR0.r0
255
256# Special differences between 32-bit and 64-bit
257SOLARIS_STRIP_BIN_32 = \
258 VBoxREM32.so \
259 VBoxREM64.so
260
261VBOX_SOL_PYTHON_DIR_64 = 64
262
263# Do not strip anything of these files
264SOLARIS_NO_STRIP = \
265 components/VBoxXPCOMBase.xpt \
266 components/VirtualBox_XPCOM.xpt \
267 $(if $(and $(VBOX_LICENSE_FILES),$(VBOX_WITH_QTGUI)),$(VBOX_LICENSE_FILES)) \
268
269SOLARIS_USRBIN_LINKS = \
270 $(if $(VBOX_WITH_QTGUI),VirtualBox,) \
271 $(if $(VBOX_WITH_HEADLESS),VBoxHeadless,) \
272 $(if $(VBOX_WITH_VBOXSDL),VBoxSDL,) \
273 VBoxManage
274
275SOLARIS_COMMON_EXES = \
276 vboxconfig.sh \
277 VBox.sh \
278 pkginstall.sh \
279 $(if $(VBOX_WITH_PYTHON),vboxshell.py,) \
280 $(if $(VBOX_WITH_WEBSERVICES),smf-vboxwebsrv.sh,) \
281
282# Things packed explicitly, not from $(PATH_BIN), track these to clean-up properly
283SOLARIS_EXTRAS = \
284 $(if $(VBOX_OSE),,LICENSE) \
285 VBox.png \
286 autoresponse \
287 $(if $(VBOX_WITH_VBOXSDL),libSDL-1.2.so.0,) \
288 $(if $(not $(VBOX_WITH_NETFLT))vnic_setup.sh,) \
289 $(if $(not $(VBOX_WITH_NETFLT))vnic_term.sh,) \
290 $(if $(VBOX_WITH_QTGUI),virtualbox.desktop,) \
291 virtualbox-webservice.xml \
292 virtualbox-zoneaccess.xml \
293 VBoxQtconfig \
294 VBoxISAExec \
295 vbox.copyright \
296 ReadMe.txt
297
298# These extra Qt libs are purely for running VBoxQtconfig
299ifdef VBOX_WITH_QTGUI
300 SOLARIS_QTLIBS = \
301 $(if $(VBOX_WITH_QT4_SUN),\
302 libQtXmlVBox.so.4 \
303 libQtSqlVBox.so.4 \
304 libQt3SupportVBox.so.4,)
305endif
306
307
308ifdef VBOX_WITH_QTGUI
309 include $(PATH_ROOT)/src/VBox/Frontends/VirtualBox/nls/ApprovedLanguages.kmk
310 SOLARIS_NO_STRIP += $(foreach f,$(VBOX_APPROVED_GUI_LANGUAGES),nls/VirtualBox_$(f).qm nls/qt_$(f).qm)
311endif
312
313# Documentation (packed as DOCS as they are arch. neutral)
314ifdef VBOX_WITH_DOCS_PACKING
315 SOLARIS_COMMON = \
316 VirtualBox.chm \
317 UserManual.pdf \
318 $(foreach f,$(VBOX_MANUAL_ADD_LANGUAGES),VirtualBox_$(f).chm UserManual_$(f).pdf)
319endif
320
321# Python XPCOM glue
322ifdef VBOX_WITH_PYTHON
323 SOLARIS_COMMON += \
324 $(foreach f,$(notdir $(wildcard $(PATH_BIN)/sdk/bindings/xpcom/python/xpcom/*.py)),sdk/bindings/xpcom/python/xpcom/$(f)) \
325 sdk/bindings/xpcom/python/xpcom/client/__init__.py \
326 sdk/bindings/xpcom/python/xpcom/server/__init__.py \
327 sdk/bindings/xpcom/python/xpcom/server/enumerator.py \
328 sdk/bindings/xpcom/python/xpcom/server/factory.py \
329 sdk/bindings/xpcom/python/xpcom/server/loader.py \
330 sdk/bindings/xpcom/python/xpcom/server/module.py \
331 sdk/bindings/xpcom/python/xpcom/server/policy.py \
332 sdk/installer/vboxapisetup.py \
333 sdk/installer/vboxapi/__init__.py \
334 sdk/installer/vboxapi/VirtualBox_constants.py
335endif
336
337ifdef VBOX_WITH_JXPCOM
338 SOLARIS_COMMON += \
339 sdk/bindings/xpcom/java/vboxjxpcom.jar
340endif
341
342# VRDP
343ifdef VBOX_WITH_VRDP
344 SOLARIS_STRIP_BINS += \
345 VBoxVRDP.so \
346 VRDPAuth.so \
347 VRDPAuthSimple.so
348 SOLARIS_COMMON += \
349 rdesktop-vrdp.tar.gz
350 ifdef VBOX_WITH_VRDP_RDESKTOP
351 SOLARIS_COMMON += $(addprefix rdesktop-vrdp-keymaps/,$(notdir $(wildcard $(SOLARIS_OUT_BIN)/rdesktop-vrdp-keymaps/*)))
352 SOLARIS_STRIP_EXES += \
353 rdesktop-vrdp
354 endif
355endif
356
357SOLARIS_STRIP_BINS += \
358 $(if $(and $(VBOX_WITH_HARDENING),$(VBOX_WITH_HEADLESS)),VBoxHeadless.so,)
359
360SOLARIS_STRIP_EXES += \
361 $(if $(VBOX_WITH_HEADLESS),VBoxHeadless) \
362 $(if $(VBOX_WITH_WEBSERVICES),vboxwebsrv) \
363 $(if $(VBOX_WITH_WEBSERVICES),webtest)
364
365# Guest Additions
366ifdef VBOX_WITH_ADDITIONS_PACKING
367 SOLARIS_COMMON += \
368 additions/VBoxGuestAdditions.iso
369endif
370
371
372# EFI firmware
373ifdef VBOX_WITH_EFIFW_PACKING
374 SOLARIS_COMMON += \
375 VBoxEFI32.fd \
376 VBoxEFI64.fd
377endif
378
379SOLARIS_ARCH_FILES := \
380 $(SOLARIS_STRIP_EXES) \
381 $(SOLARIS_DRIVER_BINS) \
382 $(SOLARIS_DRIVER_CONFS) \
383 $(SOLARIS_USRBIN_LINKS) \
384 $(SOLARIS_STRIP_BINS) \
385 $(SOLARIS_STRIP_OBJS) \
386 $(SOLARIS_NO_STRIP) \
387 $(SOLARIS_EXTRAS) \
388 $(SOLARIS_QTLIBS) \
389 $(SOLARIS_COMMON_EXES) \
390 $(SOLARIS_COMMON)
391
392SOLARIS_DBG_FILES := \
393 $(SOLARIS_STRIP_EXES) \
394 $(SOLARIS_STRIP_BINS) \
395 $(SOLARIS_DRIVER_BINS)
396
397OTHER_CLEAN += \
398 $(addprefix $(SOLARIS_VBOXINST_DIR)/, $(SOLARIS_ARCH_FILES)) \
399 $(SOLARIS_BASEINST_DIR)/$(PKG_FILENAME).tar.gz \
400 $(SOLARIS_BASEINST_DIR)/$(PKG_FILENAME).pkg \
401 $(addprefix $(SOLARIS_DBG_DIR)/,$(SOLARIS_STRIP_BINS)) \
402 $(addprefix $(SOLARIS_DBG_DIR)/,$(SOLARIS_DRIVER_BINS)) \
403 $(addprefix $(SOLARIS_DBG_DIR)/,$(SOLARIS_STRIP_EXES)) \
404 $(SOLARIS_DBG_DIR)/$(DBG_ARCHIVE) \
405 $(SOLARIS_VBI_DIR)/$(VBIPKG_FILENAME).tar.gz \
406 $(SOLARIS_VBI_DIR)/$(VBIPKG_FILENAME).pkg
407
408ifdef VBOX_WITH_COMBINED_PACKAGE
409 SOLARIS_ARCH_DEPFILES = $(addprefix $(SOLARIS_VBOXINST_DIR_64)/,$(SOLARIS_STRIP_EXES)) \
410 $(addprefix $(SOLARIS_VBOXINST_DIR_64)/,$(SOLARIS_STRIP_BINS)) \
411 $(addprefix $(SOLARIS_DRIVERINST_DIR_64)/,$(SOLARIS_DRIVER_BINS)) \
412 $(addprefix $(SOLARIS_VBOXINST_DIR_64)/,$(SOLARIS_STRIP_OBJS)) \
413 $(addprefix $(SOLARIS_VBOXINST_DIR_64)/,$(SOLARIS_NO_STRIP)) \
414 $(addprefix $(SOLARIS_VBOXINST_DIR_64)/,$(SOLARIS_QTLIBS)) \
415 $(addprefix $(SOLARIS_VBOXINST_DIR_32)/,$(SOLARIS_STRIP_EXES)) \
416 $(addprefix $(SOLARIS_VBOXINST_DIR_32)/,$(SOLARIS_STRIP_BINS)) \
417 $(addprefix $(SOLARIS_DRIVERINST_DIR_32)/,$(SOLARIS_DRIVER_BINS)) \
418 $(addprefix $(SOLARIS_VBOXINST_DIR_32)/,$(SOLARIS_STRIP_OBJS)) \
419 $(addprefix $(SOLARIS_VBOXINST_DIR_32)/,$(SOLARIS_NO_STRIP)) \
420 $(addprefix $(SOLARIS_VBOXINST_DIR_32)/,$(SOLARIS_QTLIBS)) \
421 $(addprefix $(SOLARIS_VBOXINST_DIR_32)/,$(SOLARIS_STRIP_BIN_32)) \
422 $(wildcard $(addprefix $(SOLARIS_OUT_BIN_32)/,VBoxPython*.so)) \
423 $(wildcard $(addprefix $(SOLARIS_OUT_BIN_64)/,VBoxPython*.so))
424 SOLARIS_DBG_DEPFILES = $(addprefix $(SOLARIS_DBG_DIR_64)/,$(SOLARIS_DBG_FILES)) \
425 $(addprefix $(SOLARIS_DBG_DIR_32)/,$(SOLARIS_DBG_FILES))
426else
427 SOLARIS_ARCH_DEPFILES = $(addprefix $(SOLARIS_VBOXINST_DIR_ISA)/,$(SOLARIS_STRIP_EXES)) \
428 $(addprefix $(SOLARIS_VBOXINST_DIR_ISA)/,$(SOLARIS_STRIP_BINS)) \
429 $(addprefix $(SOLARIS_DRIVERINST_DIR_ISA)/,$(SOLARIS_DRIVER_BINS)) \
430 $(addprefix $(SOLARIS_DRIVERINST_DIR)/,$(SOLARIS_DRIVER_CONFS)) \
431 $(ifeq ($(KBUILD_TARGET_ARCH),x86),$(addprefix $(SOLARIS_VBOXINST_DIR_ISA)/,$(SOLARIS_STRIP_BIN_32)),) \
432 $(ifeq ($(KBUILD_TARGET_ARCH),amd64),$(addprefix $(SOLARIS_VBOXINST_DIR_ISA)/,$(SOLARIS_STRIP_OBJ_64)),) \
433 $(addprefix $(SOLARIS_VBOXINST_DIR_ISA)/,$(SOLARIS_STRIP_OBJS)) \
434 $(addprefix $(SOLARIS_VBOXINST_DIR_ISA)/,$(SOLARIS_NO_STRIP)) \
435 $(addprefix $(SOLARIS_VBOXINST_DIR_ISA)/,$(SOLARIS_QTLIBS))
436 SOLARIS_DBG_DEPFILES = $(addprefix $(SOLARIS_DBG_DIR_ISA)/,$(SOLARIS_DBG_FILES))
437endif
438SOLARIS_ARCH_DEPFILES += $(addprefix $(SOLARIS_VBOXINST_DIR)/,$(SOLARIS_COMMON)) \
439 $(addprefix $(SOLARIS_DRIVERINST_DIR)/,$(SOLARIS_DRIVER_CONFS)) \
440 $(addprefix $(SOLARIS_VBOXINST_DIR)/,$(SOLARIS_COMMON_EXES)) \
441 $(addprefix $(SOLARIS_USRBIN_DIR)/,$(SOLARIS_USRBIN_LINKS))
442
443BLDDIRS += $(foreach d,\
444 additions \
445 rdesktop-vrdp-keymaps \
446 $(SOLARIS_DIR_NAME_64) \
447 $(SOLARIS_DIR_NAME_64)/components \
448 $(SOLARIS_DIR_NAME_64)/nls \
449 $(SOLARIS_DIR_NAME_64)/accessible \
450 $(VBOX_SOL_PYTHON_DIR_64) \
451 $(SOLARIS_DIR_NAME_32) \
452 $(SOLARIS_DIR_NAME_32)/components \
453 $(SOLARIS_DIR_NAME_32)/nls \
454 $(SOLARIS_DIR_NAME_32)/accessible \
455 $(if $(VBOX_WITH_PYTHON),\
456 sdk/ \
457 sdk/installer \
458 sdk/installer/vboxapi \
459 sdk/bindings/xpcom/python/xpcom \
460 sdk/bindings/xpcom/python/xpcom/server \
461 sdk/bindings/xpcom/python/xpcom/client,) \
462 $(if $(VBOX_WITH_JXPCOM), \
463 sdk/bindings/xpcom/java,) \
464,$(SOLARIS_VBOXINST_DIR)/$(d)/)
465
466BLDDIRS += $(foreach d,\
467 amd64 \
468,$(SOLARIS_VBI_DIR)/$(d)/)
469
470BLDDIRS += $(foreach d,\
471 additions \
472 components \
473 accessible \
474 $(SOLARIS_DIR_NAME_64) \
475 $(SOLARIS_DIR_NAME_64)/components \
476 $(SOLARIS_DIR_NAME_64)/accessible \
477 $(VBOX_SOL_PYTHON_DIR_64) \
478 $(SOLARIS_DIR_NAME_32) \
479 $(SOLARIS_DIR_NAME_32)/components \
480 $(SOLARIS_DIR_NAME_32)/nls \
481 $(SOLARIS_DIR_NAME_32)/accessible \
482,$(SOLARIS_DBG_DIR)/$(d))
483
484# List of files to be tar.gz'd, the files will be
485# installed in $(SOLARIS_BASEINST_DIR) and .gz'd from there.
486SOLARIS_TAR_GZ_FILES := \
487 $(PKG_FILENAME).pkg \
488 $(if $(VBOX_WITH_SOLARIS_VBI),$(VBIPKG_FILENAME).pkg,) \
489 $(if $(VBOX_OSE),,LICENSE) \
490 autoresponse \
491 ReadMe.txt
492
493include $(KBUILD_PATH)/subfooter.kmk
494
495#
496# -=-=-=-=-=-=-=- Main package -=-=-=-=-=-=-=-
497#
498
499## @todo r=bird: makepackage.sh packing a directory tree, right? So, there is no guarantee that it's not
500# containing any obsolete files the way packing is performed here. Consider recursivly
501# invoking $(MAKE) vbox_copy_sdk_files (or similar) to do the copying after $(RM) -Rf the
502# directory tree.
503$(PATH_BIN)/$(PKG_FILENAME).tar.gz: \
504 $(VBOX_VERSION_STAMP) \
505 $(VBOX_PATH_SOL_INST_SRC)/makepackage.sh \
506 $(VBOX_PATH_SOL_INST_SRC)/postinstall.sh \
507 $(VBOX_PATH_SOL_INST_SRC)/checkinstall.sh \
508 $(VBOX_PATH_SOL_INST_SRC)/preremove.sh \
509 $(VBOX_PATH_SOL_INST_SRC)/vbox.pkginfo \
510 $(VBOX_PATH_SOL_INST_SRC)/vbox.space \
511 $(VBOX_PATH_SOL_INST_SRC)/vbox.depend \
512 $(VBOX_PATH_SOL_INST_SRC)/vbox.pkgresponse \
513 $(VBOX_PATH_SOL_INST_SRC)/virtualbox.desktop \
514 $(PATH_ROOT)/doc/ReadMe-Solaris.txt \
515 $(VBOX_PATH_SOL_INST_SRC)/Makefile.kmk \
516 $(if $(VBOX_WITH_SOLARIS_VBI),$(SOLARIS_VBI_DIR)/$(VBIPKG_FILENAME).pkg,) \
517 $(if $(VBOX_OSE),,$(VBOX_BRAND_LICENSE_TXT)) \
518 $(if $(VBOX_OSE),,$(PATH_BIN)/LICENSE) \
519 $(if $(and $(VBOX_LICENSE_BINS),$(VBOX_WITH_QTGUI)),$(VBOX_LICENSE_BINS),) \
520 $(if $(VBOX_WITH_NETADP),$(PATH_ROOT)/src/VBox/HostDrivers/VBoxNetAdp/solaris/hostname.vboxnet0,) \
521 $(if $(not $(VBOX_WITH_NETFLT))$(PATH_ROOT)/src/VBox/Devices/Network/solaris/vnicinit_solaris.sh,) \
522 $(if $(not $(VBOX_WITH_NETFLT))$(PATH_ROOT)/src/VBox/Devices/Network/solaris/vnicterm_solaris.sh,) \
523 $(addprefix $(PATH_BIN)/,$(filter-out $(SOLARIS_EXTRAS) $(SOLARIS_QTLIBS),$(SOLARIS_ARCH_FILES))) \
524 VBoxISAExec \
525 $(SOLARIS_ARCH_DEPFILES)
526 $(QUIET)$(RM) -f $(wildcard $(PATH_BIN)/VirtualBox-*-r*.tar.gz)
527 $(call MSG_L1,Installing binaries $(SOLARIS_VBOXINST_DIR))
528ifdef VBOX_WITH_COMBINED_PACKAGE
529 $(QUIET)$(if $(VBOX_WITH_ADDITIONS_PACKING),$(INSTALL) -m 0644 $(SOLARIS_OUT_BIN_32)/additions/VBoxGuestAdditions.iso $(SOLARIS_VBOXINST_DIR)/additions/)
530else
531 $(QUIET)$(if $(VBOX_WITH_ADDITIONS_PACKING),$(INSTALL) -m 0644 $(SOLARIS_OUT_BIN)/additions/VBoxGuestAdditions.iso $(SOLARIS_VBOXINST_DIR)/additions/)
532endif
533 $(call MSG_L1,Installing files $(SOLARIS_VBOXINST_DIR))
534 $(QUIET)$(SED) \
535 -e "s/@VBOX_PRODUCT@/$(VBOX_PRODUCT)/g" \
536 -e "s/@VBOX_VENDOR@/$(VBOX_VENDOR)/g" \
537 -e "s/@VBOX_VERSION_STRING@/$(VBOX_VERSION_STRING)/g" \
538 -e "s/@VBOX_SVN_REV@/$(VBOX_SVN_REV)/g" \
539 -e "s/@VBOX_VERSION_REVSTAMP@/$(PKGINFO_REVSTAMP)/g" \
540 -e "s/@UNAME_P@/$(PKGINFO_ARCH)/g" \
541 --output $(SOLARIS_BASEINST_DIR)/vbox.pkginfo \
542 $(VBOX_PATH_SOL_INST_SRC)/vbox.pkginfo
543 @# @todo BLDDIRS doesn't do "-p" subdir creation; so create for now
544 $(QUIET)$(if $(VBOX_WITH_NETADP),$(MKDIR) -p $(SOLARIS_ETC_DIR),)
545 $(QUIET)$(MKDIR) -p $(SOLARIS_VBOXSMF_DIR)
546 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(MKDIR) -p $(SOLARIS_USRSHR_APPS_DIR),)
547 $(QUIET)$(MKDIR) -p $(SOLARIS_USRSHR_PIXMAPS_DIR)
548 $(QUIET)$(if $(VBOX_WITH_NETADP),$(INSTALL) -m 0644 $(PATH_ROOT)/src/VBox/HostDrivers/VBoxNetAdp/solaris/hostname.vboxnet0 $(SOLARIS_ETC_DIR)/hostname.vboxnet0,)
549 $(QUIET)$(if $(VBOX_OSE),,$(INSTALL) -m 0644 $(PATH_BIN)/LICENSE $(SOLARIS_VBOXINST_DIR)/LICENSE)
550 $(QUIET)$(if $(VBOX_OSE),,$(INSTALL) -m 0644 $(PATH_BIN)/LICENSE $(SOLARIS_BASEINST_DIR)/vbox.copyright)
551 $(QUIET)$(if $(VBOX_OSE),,$(INSTALL) -m 0644 $(PATH_BIN)/LICENSE $(SOLARIS_BASEINST_DIR)/LICENSE)
552ifdef VBOX_WITH_COMBINED_PACKAGE
553 ifndef VBOX_OSE
554 $(QUIET)$(if $(VBOX_WITH_VBOXSDL),$(INSTALL) -m 0644 $(PATH_DEVTOOLS)/solaris.x86/libSDL/v1.2.13/lib/libSDL-1.2.so.0.11.2 $(SOLARIS_VBOXINST_DIR_32)/libSDL-1.2.so.0,)
555 $(QUIET)$(if $(VBOX_WITH_VBOXSDL),$(INSTALL) -m 0644 $(PATH_DEVTOOLS)/solaris.amd64/libSDL/v1.2.13/lib/libSDL-1.2.so.0.11.2 $(SOLARIS_VBOXINST_DIR_64)/libSDL-1.2.so.0,)
556 endif
557 @# @todo -XXX- how to get rid of this manual MKDIR ?
558 $(QUIET)$(MKDIR) -p $(SOLARIS_VBOXINST_DIR)/$(VBOX_SOL_PYTHON_DIR_64)
559 $(QUIET)$(if $(VBOX_WITH_PYTHON),$(INSTALL) -m 0644 $(if $(VBOX_DO_STRIP),-s) $(wildcard $(SOLARIS_OUT_BIN_32)/VBoxPython*.so) $(SOLARIS_VBOXINST_DIR)/,)
560 $(QUIET)$(if $(VBOX_WITH_PYTHON),$(INSTALL) -m 0644 $(if $(VBOX_DO_STRIP),-s) $(wildcard $(SOLARIS_OUT_BIN_64)/VBoxPython*.so) $(SOLARIS_VBOXINST_DIR)/$(VBOX_SOL_PYTHON_DIR_64)/,)
561 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(if ($VBOX_WITH_QT4_SUN),$(INSTALL) -m 0755 $(SOLARIS_PATH_QT_32)/bin/qtconfig $(SOLARIS_VBOXINST_DIR_32)/VBoxQtconfig,),)
562 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(if $(VBOX_WITH_QT4_SUN),$(INSTALL) -m 0755 $(SOLARIS_PATH_QT_64)/bin/qtconfig $(SOLARIS_VBOXINST_DIR_64)/VBoxQtconfig,),)
563 $(QUIET)$(INSTALL) -m 0755 $(SOLARIS_OUT_BIN_32)/VBoxISAExec $(SOLARIS_VBOXINST_DIR)/VBoxISAExec
564 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(LN_SYMLINK) -f ../rdesktop-vrdp-keymaps $(SOLARIS_VBOXINST_DIR_32)/rdesktop-vrdp-keymaps,)
565 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(LN_SYMLINK) -f ../rdesktop-vrdp-keymaps $(SOLARIS_VBOXINST_DIR_64)/rdesktop-vrdp-keymaps,)
566 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(LN_SYMLINK) -f ../additions $(SOLARIS_VBOXINST_DIR_32)/additions,)
567 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(LN_SYMLINK) -f ../additions $(SOLARIS_VBOXINST_DIR_64)/additions,)
568 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(LN_SYMLINK) -f ../VirtualBox.chm $(SOLARIS_VBOXINST_DIR_32)/VirtualBox.chm,)
569 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(LN_SYMLINK) -f ../VirtualBox.chm $(SOLARIS_VBOXINST_DIR_64)/VirtualBox.chm,)
570 $(QUIET)$(if $(VBOX_WITH_EFIFW_PACKING),$(LN_SYMLINK) -f ../VBoxEFI32.fd $(SOLARIS_VBOXINST_DIR_64)/VBoxEFI32.fd,)
571 $(QUIET)$(if $(VBOX_WITH_EFIFW_PACKING),$(LN_SYMLINK) -f ../VBoxEFI32.fd $(SOLARIS_VBOXINST_DIR_32)/VBoxEFI32.fd,)
572 $(QUIET)$(if $(VBOX_WITH_EFIFW_PACKING),$(LN_SYMLINK) -f ../VBoxEFI64.fd $(SOLARIS_VBOXINST_DIR_64)/VBoxEFI64.fd,)
573 $(QUIET)$(if $(VBOX_WITH_EFIFW_PACKING),$(LN_SYMLINK) -f ../VBoxEFI64.fd $(SOLARIS_VBOXINST_DIR_32)/VBoxEFI64.fd,)
574else
575 ifndef VBOX_OSE
576 $(QUIET)$(if $(VBOX_WITH_VBOXSDL),$(INSTALL) -m 0644 $(PATH_DEVTOOLS_TRG)/libSDL/v1.2.13/lib/libSDL-1.2.so.0.11.2 $(SOLARIS_VBOXINST_DIR_ISA)/libSDL-1.2.so.0,)
577 endif
578 @# @todo -XXX- how to get rid of this manual MKDIR ?
579 ifdef VBOX_WITH_PYTHON
580 $(QUIET)$(if $(SOL64_PKG),$(MKDIR) -p $(SOLARIS_VBOXINST_DIR)/$(VBOX_SOL_PYTHON_DIR_64),)
581 $(QUIET)$(INSTALL) -m 0644 $(if $(VBOX_DO_STRIP),-s) $(wildcard $(SOLARIS_OUT_BIN)/VBoxPython*.so) $(SOLARIS_VBOXINST_DIR)/$(if $(SOL64_PKG),$(VBOX_SOL_PYTHON_DIR_64)/,)
582 endif
583 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(if $(VBOX_WITH_QT4_SUN),$(INSTALL) -m 0755 $(VBOX_PATH_QT4)/bin/qtconfig $(SOLARIS_VBOXINST_DIR_ISA)/VBoxQtconfig,),)
584 $(QUIET)$(INSTALL) -m 0755 $(SOLARIS_OUT_BIN)/VBoxISAExec $(SOLARIS_VBOXINST_DIR)/VBoxISAExec
585 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(LN_SYMLINK) -f ../rdesktop-vrdp-keymaps $(SOLARIS_VBOXINST_DIR_ISA)/rdesktop-vrdp-keymaps,)
586 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(LN_SYMLINK) -f ../additions $(SOLARIS_VBOXINST_DIR_ISA)/additions,)
587 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(LN_SYMLINK) -f ../VirtualBox.chm $(SOLARIS_VBOXINST_DIR_ISA)/VirtualBox.chm,)
588 $(QUIET)$(if $(VBOX_WITH_EFIFW_PACKING),$(LN_SYMLINK) -f ../VBoxEFI32.fd $(SOLARIS_VBOXINST_DIR_ISA)/VBoxEFI32.fd,)
589 $(QUIET)$(if $(VBOX_WITH_EFIFW_PACKING),$(LN_SYMLINK) -f ../VBoxEFI64.fd $(SOLARIS_VBOXINST_DIR_ISA)/VBoxEFI64.fd,)
590endif
591 $(QUIET)$(LN_SYMLINK) -f ./pkginstall.sh $(SOLARIS_VBOXINST_DIR)/ipsinstall.sh
592 $(QUIET)$(if $(VBOX_WITH_QTGUI),$(LN_SYMLINK) -f ../../$(SOLARIS_VBOXINST_SUBDIR)/VBox.sh $(SOLARIS_USRBIN_DIR)/VBoxQtconfig,)
593 $(QUIET)$(INSTALL) -m 0644 $(VBOX_PATH_SOL_INST_SRC)/virtualbox-zoneaccess.xml $(SOLARIS_VBOXSMF_DIR)/virtualbox-zoneaccess.xml
594 $(QUIET)$(if $(VBOX_WITH_WEBSERVICES),$(INSTALL) -m 0644 $(VBOX_PATH_SOL_INST_SRC)/virtualbox-webservice.xml $(SOLARIS_VBOXSMF_DIR)/virtualbox-webservice.xml,)
595 $(QUIET)$(if $(not $(VBOX_WITH_NETFLT))$(INSTALL) -m 0755 $(PATH_ROOT)/src/VBox/Devices/Network/solaris/vnicinit_solaris.sh $(SOLARIS_VBOXINST_DIR)/vnic_setup.sh,)
596 $(QUIET)$(if $(not $(VBOX_WITH_NETFLT))$(INSTALL) -m 0755 $(PATH_ROOT)/src/VBox/Devices/Network/solaris/vnicterm_solaris.sh $(SOLARIS_VBOXINST_DIR)/vnic_term.sh,)
597 $(QUIET)$(SED) \
598 -e "s/_HARDENED_/$(if $(VBOX_WITH_HARDENED),hardened,)/" \
599 --output $(SOLARIS_VBOXINST_DIR)/vboxconfig.sh.tmp \
600 $(PATH_BIN)/vboxconfig.sh
601 $(QUIET)$(INSTALL) -m 0755 $(SOLARIS_VBOXINST_DIR)/vboxconfig.sh.tmp $(SOLARIS_VBOXINST_DIR)/vboxconfig.sh
602 $(QUIET)$(RM) -f $(SOLARIS_VBOXINST_DIR)/vboxconfig.sh.tmp
603 $(QUIET)$(SED) \
604 -e "s/@VBOX_PRODUCT@/$(VBOX_PRODUCT)/g" \
605 --output $(SOLARIS_USRSHR_APPS_DIR)/virtualbox.desktop \
606 $(VBOX_PATH_SOL_INST_SRC)/virtualbox.desktop
607 $(QUIET)$(INSTALL) -m 0644 $(SOLARIS_OUT_BIN)/VBox.png $(SOLARIS_USRSHR_PIXMAPS_DIR)/VBox.png
608 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_SOL_INST_SRC)/postinstall.sh $(SOLARIS_BASEINST_DIR)/postinstall.sh
609 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_SOL_INST_SRC)/checkinstall.sh $(SOLARIS_BASEINST_DIR)/checkinstall.sh
610 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_SOL_INST_SRC)/preremove.sh $(SOLARIS_BASEINST_DIR)/preremove.sh
611 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_SOL_INST_SRC)/makepackage.sh $(SOLARIS_BASEINST_DIR)/makepackage.sh
612 $(QUIET)$(INSTALL) -m 0644 $(VBOX_PATH_SOL_INST_SRC)/vbox.pkgresponse $(SOLARIS_VBOXINST_DIR)/autoresponse
613 $(QUIET)$(INSTALL) -m 0644 $(VBOX_PATH_SOL_INST_SRC)/vbox.pkgresponse $(SOLARIS_BASEINST_DIR)/autoresponse
614 $(QUIET)$(INSTALL) -m 0644 $(VBOX_PATH_SOL_INST_SRC)/vbox.space $(SOLARIS_BASEINST_DIR)/vbox.space
615 @# Warning!! If we add NON-PYTHON dependencies to vbox.depend, remove the VBOX_WITH_PYTHON setting
616 $(QUIET)$(if $(VBOX_WITH_PYTHON),$(INSTALL) -m 0644 $(VBOX_PATH_SOL_INST_SRC)/vbox.depend $(SOLARIS_BASEINST_DIR)/vbox.depend,)
617 $(QUIET)$(SED) \
618 -e "s/@VBOX_PRODUCT@/$(VBOX_PRODUCT)/g" \
619 -e "s/@VBOX_VENDOR@/$(VBOX_VENDOR)/g" \
620 -e "s/@VBOX_VERSION_STRING@/$(VBOX_VERSION_STRING)/g" \
621 -e "s/@BUILD_TARGET_ARCH@/$(KBUILD_TARGET_ARCH)/g" \
622 -e "s/@VBOX_SVN_REV@/$(VBOX_SVN_REV)/g" \
623 --output $(SOLARIS_BASEINST_DIR)/ReadMe.txt \
624 $(PATH_ROOT)/doc/ReadMe-Solaris.txt
625 $(QUIET)$(if $(VBOX_WITH_SOLARIS_VBI),$(INSTALL) -m 0644 $(SOLARIS_VBI_DIR)/$(VBIPKG_FILENAME).pkg $(SOLARIS_BASEINST_DIR)/$(VBIPKG_FILENAME).pkg,)
626 $(call MSG_L1,Creating install package: $(PKG_FILENAME).tar.gz)
627 $(QUIET)$(REDIRECT) -C $(VBOX_PATH_SOL_INST_SRC) -- $(SOLARIS_BASEINST_DIR)/makepackage.sh $(if $(VBOX_WITH_HARDENING),--hardened) \
628 $(SOLARIS_BASEINST_DIR) \
629 $(PKG_FILENAME) \
630 $(if-expr defined(VBOX_WITH_COMBINED_PACKAGE),neutral,$(KBUILD_TARGET_ARCH)) \
631 $(VBOX_SVN_REV) \
632 $(if $(VBOX_WITH_SOLARIS_VBI),$(VBIPKG_FILENAME).pkg,)
633 $(call MSG_L1,Creating final tar.gz package)
634 $(QUIET)$(SOL_GTAR) -C $(SOLARIS_BASEINST_DIR) -zcvf $(SOLARIS_BASEINST_DIR)/$(PKG_FILENAME).tar.gz $(SOLARIS_TAR_GZ_FILES)
635 $(QUIET)$(INSTALL) -m 0644 $(SOLARIS_BASEINST_DIR)/$(PKG_FILENAME).tar.gz $(SOLARIS_OUT_BIN)
636 @# Clean up files emitted as side-effect or result of packing
637 $(QUIET)$(RM) -f $(SOLARIS_BASEINST_DIR)/$(PKG_FILENAME).tar.gz
638 $(QUIET)$(RM) -f $(SOLARIS_BASEINST_DIR)/$(PKG_FILENAME).pkg
639 $(QUIET)$(if $(VBOX_WITH_SOLARIS_VBI),$(RM) -f $(SOLARIS_BASEINST_DIR)/$(VBIPKG_FILENAME).pkg,)
640 $(call MSG_L1,Packaging completed.)
641
642
643#
644# 32-bit Main Package
645#
646$(addprefix $(SOLARIS_VBOXINST_DIR_32)/,$(SOLARIS_STRIP_BINS)): \
647 $(SOLARIS_VBOXINST_DIR_32)/% : $(SOLARIS_OUT_BIN_32)/% | $$(dir $$@)
648 $(INSTALL) -m 0644 $(if $(VBOX_DO_STRIP),-s,) $< $@
649
650$(addprefix $(SOLARIS_DRIVERINST_DIR_32)/,$(SOLARIS_DRIVER_BINS)): \
651 $(SOLARIS_DRIVERINST_DIR_32)/% : $(SOLARIS_OUT_BIN_32)/% | $$(dir $$@)
652 $(INSTALL) -m 0644 $(if $(VBOX_DO_STRIP),-s,) $< $@
653
654$(addprefix $(SOLARIS_VBOXINST_DIR_32)/,$(SOLARIS_STRIP_BIN_32)): \
655 $(SOLARIS_VBOXINST_DIR_32)/% : $(SOLARIS_OUT_BIN_32)/% | $$(dir $$@)
656 $(INSTALL) -m 0644 $(if $(VBOX_DO_STRIP),-s,) $< $@
657
658$(addprefix $(SOLARIS_VBOXINST_DIR_32)/,$(SOLARIS_STRIP_EXES)): \
659 $(SOLARIS_VBOXINST_DIR_32)/% : $(SOLARIS_OUT_BIN_32)/% | $$(dir $$@)
660 $(INSTALL) -m 0755 $(if $(VBOX_DO_STRIP),-s,) $< $@
661
662$(addprefix $(SOLARIS_VBOXINST_DIR_32)/,$(SOLARIS_STRIP_OBJS)): \
663 $(SOLARIS_VBOXINST_DIR_32)/% : $(SOLARIS_OUT_BIN_32)/% | $$(dir $$@)
664 $(if $(VBOX_DO_STRIP),$(SOL_OBJCOPY) $< $@, $(INSTALL) -m 0644 $< $@)
665
666$(addprefix $(SOLARIS_VBOXINST_DIR_32)/,$(SOLARIS_NO_STRIP)): \
667 $(SOLARIS_VBOXINST_DIR_32)/% : $(SOLARIS_OUT_BIN_32)/% | $$(dir $$@)
668 $(INSTALL) -m 0644 $< $@
669
670$(addprefix $(SOLARIS_VBOXINST_DIR_32)/,$(SOLARIS_QTLIBS)): \
671 $(SOLARIS_VBOXINST_DIR_32)/% : $(SOLARIS_PATH_QT_32)/lib/% | $$(dir $$@)
672 $(INSTALL) -m 0644 $(if $(VBOX_DO_STRIP),-s,) $< $@
673
674#
675# 64-bit Main Package
676#
677$(addprefix $(SOLARIS_VBOXINST_DIR_64)/,$(SOLARIS_STRIP_BINS)): \
678 $(SOLARIS_VBOXINST_DIR_64)/% : $(SOLARIS_OUT_BIN_64)/% | $$(dir $$@)
679 $(INSTALL) -m 0644 $(if $(VBOX_DO_STRIP),-s,) $< $@
680
681$(addprefix $(SOLARIS_DRIVERINST_DIR_64)/,$(SOLARIS_DRIVER_BINS)): \
682 $(SOLARIS_DRIVERINST_DIR_64)/% : $(SOLARIS_OUT_BIN_64)/% | $$(dir $$@)
683 $(INSTALL) -m 0644 $(if $(VBOX_DO_STRIP),-s,) $< $@
684
685$(addprefix $(SOLARIS_VBOXINST_DIR_64)/,$(SOLARIS_STRIP_EXES)): \
686 $(SOLARIS_VBOXINST_DIR_64)/% : $(SOLARIS_OUT_BIN_64)/% | $$(dir $$@)
687 $(INSTALL) -m 0755 $(if $(VBOX_DO_STRIP),-s,) $< $@
688
689$(addprefix $(SOLARIS_VBOXINST_DIR_64)/,$(SOLARIS_STRIP_OBJS)): \
690 $(SOLARIS_VBOXINST_DIR_64)/% : $(SOLARIS_OUT_BIN_64)/% | $$(dir $$@)
691 $(if $(VBOX_DO_STRIP),$(SOL_OBJCOPY) $< $@, $(INSTALL) -m 0644 $< $@)
692
693$(addprefix $(SOLARIS_VBOXINST_DIR_64)/,$(SOLARIS_STRIP_OBJ_64)): \
694 $(SOLARIS_VBOXINST_DIR_64)/% : $(SOLARIS_OUT_BIN_64)/% | $$(dir $$@)
695 $(if $(VBOX_DO_STRIP),$(SOL_OBJCOPY) $< $@, $(INSTALL) -m 0644 $< $@)
696
697$(addprefix $(SOLARIS_VBOXINST_DIR_64)/,$(SOLARIS_NO_STRIP)): \
698 $(SOLARIS_VBOXINST_DIR_64)/% : $(SOLARIS_OUT_BIN_64)/% | $$(dir $$@)
699 $(INSTALL) -m 0644 $< $@
700
701$(addprefix $(SOLARIS_VBOXINST_DIR_64)/,$(SOLARIS_QTLIBS)): \
702 $(SOLARIS_VBOXINST_DIR_64)/% : $(SOLARIS_PATH_QT_64)/lib/% | $$(dir $$@)
703 $(INSTALL) -m 0644 $(if $(VBOX_DO_STRIP),-s,) $< $@
704
705
706#
707# Common (32-bit and 64-bit)
708#
709$(addprefix $(SOLARIS_VBOXINST_DIR)/,$(SOLARIS_COMMON)): \
710 $(SOLARIS_VBOXINST_DIR)/% : $(PATH_BIN)/% | $$(dir $$@)
711 $(INSTALL) -m 0644 $< $@
712
713# Driver configuration files
714$(addprefix $(SOLARIS_DRIVERINST_DIR)/,$(SOLARIS_DRIVER_CONFS)): \
715 $(SOLARIS_DRIVERINST_DIR)/% : $(PATH_BIN)/% | $$(dir $$@)
716 $(INSTALL) -m 0644 $< $@
717
718# Common executables
719$(addprefix $(SOLARIS_VBOXINST_DIR)/,$(SOLARIS_COMMON_EXES)): \
720 $(SOLARIS_VBOXINST_DIR)/% : $(PATH_BIN)/% | $$(dir $$@)
721 $(INSTALL) -m 0755 $< $@
722
723
724
725#
726# Common (relative symlinks to /opt/VirtualBox/ from /usr/bin/)
727# Some symlinks are created manually in the prepackage steps above (eg. VBoxQtconfig)
728# as those binaries do not originate from $(PATH_BIN)
729#
730$(addprefix $(SOLARIS_USRBIN_DIR)/,$(SOLARIS_USRBIN_LINKS)): \
731 $(SOLARIS_USRBIN_DIR)/% : % | $$(dir $$@)
732 $(LN_SYMLINK) -f ../../$(SOLARIS_VBOXINST_SUBDIR)/VBox.sh $@
733
734
735#
736# -=-=-=-=-=-=-=- VBI package -=-=-=-=-=-=-=-
737#
738ifdef VBOX_WITH_SOLARIS_VBI
739$(SOLARIS_VBI_DIR)/$(VBIPKG_FILENAME).pkg: \
740 $(VBOX_VERSION_STAMP) \
741 $(if $(VBOX_OSE),,$(VBOX_BRAND_LICENSE_TXT)) \
742 $(if $(VBOX_OSE),,$(PATH_BIN)/LICENSE) \
743 $(VBOX_PATH_SOL_INST_SRC)/vbi/vboxkern.pkginfo \
744 $(VBOX_PATH_SOL_INST_SRC)/vbi/makepackage.sh \
745 $(VBOX_PATH_SOL_INST_SRC)/vbi/preremove.sh \
746 $(VBOX_PATH_SOL_INST_SRC)/Makefile.kmk \
747 $(PATH_ROOT)/src/VBox/Runtime/r0drv/solaris/vbi/32/vbi \
748 $(PATH_ROOT)/src/VBox/Runtime/r0drv/solaris/vbi/64/vbi
749 $(call MSG_L1,Installing vbi binaries $(SOLARIS_VBI_DIR))
750 $(QUIET)$(RM) -Rf $(SOLARIS_VBI_DIR)
751 $(QUIET)$(MKDIR) -p $(SOLARIS_VBI_DIR)/amd64
752 $(QUIET)$(INSTALL) -m 0644 $(PATH_ROOT)/src/VBox/Runtime/r0drv/solaris/vbi/32/vbi $(SOLARIS_VBI_DIR)/vbi
753 $(QUIET)$(INSTALL) -m 0644 $(PATH_ROOT)/src/VBox/Runtime/r0drv/solaris/vbi/64/vbi $(SOLARIS_VBI_DIR)/amd64/vbi
754 $(call MSG_L1,Installing other files $(SOLARIS_VBI_DIR))
755 $(QUIET)$(SED) \
756 -e "s/@VBOX_PRODUCT@/$(VBOX_PRODUCT)/g" \
757 -e "s/@VBOX_VERSION_STRING@/$(VBOX_VERSION_STRING)/g" \
758 -e "s/@VBOX_VERSION_REVSTAMP@/$(PKGINFO_REVSTAMP)/g" \
759 -e "s/@UNAME_P@/$(PKGINFO_ARCH)/g" \
760 --output $(SOLARIS_VBI_DIR)/vboxkern.pkginfo \
761 $(VBOX_PATH_SOL_INST_SRC)/vbi/vboxkern.pkginfo
762 $(QUIET)$(if $(VBOX_OSE),,$(INSTALL) -m 0644 $(PATH_BIN)/LICENSE $(SOLARIS_VBI_DIR)/vbox.copyright)
763 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_SOL_INST_SRC)/vbi/makepackage.sh $(SOLARIS_VBI_DIR)/makepackage.sh
764 $(QUIET)$(INSTALL) -m 0755 $(VBOX_PATH_SOL_INST_SRC)/vbi/preremove.sh $(SOLARIS_VBI_DIR)/preremove.sh
765 $(call MSG_L1,Creating install package: $(VBIPKG_FILENAME).pkg)
766 $(QUIET)$(REDIRECT) -C $(VBOX_PATH_SOL_INST_SRC) -- $(SOLARIS_VBI_DIR)/makepackage.sh $(SOLARIS_VBI_DIR) $(VBIPKG_FILENAME)
767endif
768
769
770#
771# -=-=-=-=-=-=-=- Debug package -=-=-=-=-=-=-=-
772#
773$(PATH_BIN)/$(DBG_ARCHIVE): \
774 $(VBOX_VERSION_STAMP) \
775 $(VBOX_PATH_SOL_INST_SRC)/Makefile.kmk \
776 $(SOLARIS_DBG_DEPFILES)
777 $(call MSG_L1,Installing debug binaries $(SOLARIS_DBG_DIR))
778 $(call MSG_L1,Packing $@)
779 $(QUIET)/usr/sfw/bin/gtar --owner 0 --group 0 -cjRhf $(PATH_BIN)/$(DBG_ARCHIVE) -C $(SOLARIS_DBG_DIR) $(SOLARIS_DBG_DEPFILES)
780 $(QUIET)$(CHMOD) 0644 $@
781
782#
783# 32-bit Debug package
784#
785$(addprefix $(SOLARIS_DBG_DIR_32)/,$(SOLARIS_STRIP_BINS) $(SOLARIS_STRIP_EXES)): \
786 $(SOLARIS_DBG_DIR_32)/% : $(SOLARIS_OUT_BIN_32)/% | $$(dir $$@)
787 $(SOL_DBG_OBJCOPY) $< $@
788
789$(addprefix $(SOLARIS_DBG_DIR_32)/,$(SOLARIS_DRIVER_BINS)): \
790 $(SOLARIS_DBG_DIR_32)/% : $(SOLARIS_OUT_BIN_32)/% | $$(dir $$@)
791 $(SOL_DBG_OBJCOPY) $< $@
792
793
794#
795# 64-bit Debug package
796#
797$(addprefix $(SOLARIS_DBG_DIR_64)/,$(SOLARIS_STRIP_BINS) $(SOLARIS_STRIP_EXES)): \
798 $(SOLARIS_DBG_DIR_64)/% : $(SOLARIS_OUT_BIN_64)/% | $$(dir $$@)
799 $(SOL_DBG_OBJCOPY) $< $@
800
801$(addprefix $(SOLARIS_DBG_DIR_64)/,$(SOLARIS_DRIVER_BINS)): \
802 $(SOLARIS_DBG_DIR_64)/% : $(SOLARIS_OUT_BIN_64)/% | $$(dir $$@)
803 $(SOL_DBG_OBJCOPY) $< $@
804
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