VirtualBox

source: vbox/trunk/src/VBox/ExtPacks/VBoxDTrace/Makefile.kmk@ 85959

Last change on this file since 85959 was 85507, checked in by vboxsync, 4 years ago

SUP,*: Some changes to the SUP_IOCTL_LDR_OPEN and SUP_IOCTL_LDR_LOAD interfaces adding memory protection regions for better WX compliance. Preps for linux 5.8 where we'll be using RTR0MemObjAllocPage rather than RTMemExecAlloc for images, switch from relocatable ELF files to shared objects. bugref:9801

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 14.5 KB
Line 
1# $Id: Makefile.kmk 85507 2020-07-29 10:10:49Z vboxsync $
2## @file
3# Sub-makefile for VBoxDTrace.
4#
5# Contributed by: bird
6#
7
8#
9# Copyright (C) 2012-2020 Oracle Corporation
10#
11# This file is part of VirtualBox Open Source Edition (OSE), as
12# available from http://www.virtualbox.org. This file is free software;
13# you can redistribute it and/or modify it under the terms of the Common
14# Development and Distribution License Version 1.0 (CDDL) only, as it
15# comes in the "COPYING.CDDL" file of the VirtualBox OSE distribution.
16# VirtualBox OSE is distributed in the hope that it will be useful, but
17# WITHOUT ANY WARRANTY of any kind.
18#
19
20SUB_DEPTH = ../../../../
21include $(KBUILD_PATH)/subheader.kmk
22
23
24#
25# Globals.
26#
27VBOX_EXTPACK_VBOXDTRACE_NAME := Oracle VBoxDTrace Extension Pack
28VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME := Oracle_VBoxDTrace_Extension_Pack
29VBOX_PATH_EXTPACK_VBOXDTRACE = $(PATH_STAGE)/$(INST_EXTPACK)$(VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME)
30INST_EXTPACK_VBOXDTRACE = $(INST_EXTPACK)$(VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME)/
31
32VBOXDT_PATH := $(PATH_ROOT)/src/VBox/ExtPacks/VBoxDTrace
33VBOXDT_PATH_ONNV := $(VBOXDT_PATH)/onnv
34VBOXDT_PATH_UTS := $(VBOXDT_PATH_ONNV)/uts
35VBOXDT_PATH_CMD := $(VBOXDT_PATH_ONNV)/cmd
36VBOXDT_PATH_LIBCTF := $(VBOXDT_PATH_ONNV)/lib/libctf
37VBOXDT_PATH_CMN_CTF := $(VBOXDT_PATH_ONNV)/common/ctf
38VBOXDT_PATH_LIBDTRACE := $(VBOXDT_PATH_ONNV)/lib/libdtrace
39VBOXDT_PATH_CMN_DTRACE := $(VBOXDT_PATH_ONNV)/common/dtrace
40
41
42ifndef VBOX_ONLY_EXTPACKS
43 #
44 # The generic wrapper that selects native or extpack dtrace cmd and adds our
45 # library path to the command line.
46 #
47 # Note! This is not installed as part of the extension pack, but always shipped
48 # with the base VBox installation.
49 #
50 PROGRAMS += VBoxDTrace
51 VBoxDTrace_TEMPLATE := VBOXR3EXE
52 VBoxDTrace_SOURCES := VBoxDTraceWrapper.cpp
53 VBoxDTrace_LIBS = $(LIB_RUNTIME)
54 $(call VBOX_SET_VER_INFO_DLL,VBoxDTrace,VirtualBox DTrace Chooser)
55endif
56
57
58if defined(VBOX_WITH_EXTPACK_VBOXDTRACE) && defined(VBOX_WITH_EXTPACK)
59
60 #
61 # Extend the extension pack templates.
62 #
63 TEMPLATE_VBoxR3ExtPackDTrace = For the ring-3 context modules in the VBoxDTrace extension pack.
64 TEMPLATE_VBoxR3ExtPackDTrace_EXTENDS = VBoxR3ExtPack
65 TEMPLATE_VBoxR3ExtPackDTrace_INST = $(INST_EXTPACK_VBOXDTRACE)$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)/
66 TEMPLATE_VBoxR3ExtPackDTrace_DEFS = $(TEMPLATE_VBoxR3ExtPack_DEFS) VBOX_IN_DTRACE_EXTPACK
67 if "$(VBOX_VCC_TOOL_STEM)" >= "VCC140"
68 # -wd4456: declaration of 'rval' hides previous local declaration
69 # -wd4477: 'fprintf' : format string '%02lu' requires an argument of type 'unsigned long', but variadic argument 1 has type 'ulong_t'
70 # -wd4457: warning C4457: declaration of 'arg' hides function parameter
71 TEMPLATE_VBoxR3ExtPackDTrace_CFLAGS.win = $(TEMPLATE_VBoxR3ExtPack_CFLAGS.win) -wd4456 -wd4477 -wd4457
72 endif
73
74 TEMPLATE_VBoxR0ExtPackDTrace = For the ring-0 context modules in the VBoxDTrace extension pack.
75 TEMPLATE_VBoxR0ExtPackDTrace_EXTENDS = VBoxR0ExtPack
76 TEMPLATE_VBoxR0ExtPackDTrace_INST = $(INST_EXTPACK_VBOXDTRACE)$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)/
77 TEMPLATE_VBoxR0ExtPackDTrace_DEFS = $(TEMPLATE_VBoxR0ExtPack_DEFS) VBOX_IN_DTRACE_EXTPACK
78
79 TEMPLATE_VBoxInsExtPackDTrace = For the install targets for the VBoxDTrace extension pack.
80 TEMPLATE_VBoxInsExtPackDTrace_EXTENDS = VBoxR0ExtPack
81 TEMPLATE_VBoxInsExtPackDTrace_INST = $(INST_EXTPACK_VBOXDTRACE)
82
83
84 #
85 # Install the description.
86 #
87 INSTALLS += VBoxDTraceIns
88 VBoxDTraceIns_TEMPLATE = VBoxInsExtPackDTrace
89 VBoxDTraceIns_SOURCES = \
90 $(VBoxDTraceIns_0_OUTDIR)/ExtPack.xml \
91 COPYING=>ExtPack-SourceCodeLicense.txt
92 $(call VBOX_EDIT_VERSION_RULE_FN,VBoxDTraceIns,ExtPack.xml)
93
94
95 #
96 # VBoxDTraceMain - The module which the VirtualBox Main API talks to.
97 #
98 DLLS += VBoxDTraceMain
99 VBoxDTraceMain_TEMPLATE = VBoxR3ExtPackDTrace
100 VBoxDTraceMain_SOURCES = VBoxDTraceMain.cpp
101 $(call VBOX_SET_VER_INFO_DLL,VBoxDTraceMain,VBoxDTrace Main module)
102
103
104 #
105 # The ring-3 VBoxDTrace command implementation (library).
106 #
107 ifneq ($(KBUILD_TARGET),solaris) # Temporarily disabled on Solaris (not really needed)...
108 DLLS += VBoxDTraceCmd
109 VBoxDTraceCmd_TEMPLATE = VBoxR3ExtPackDTrace
110 ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
111 VBoxDTraceCmd_DEFS = RTMEM_WRAP_TO_EF_APIS VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME="$(VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME)"
112 else
113 VBoxDTraceCmd_DEFS = RTMEM_WRAP_TO_EF_APIS VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME=\"$(VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME)\"
114 endif
115 #VBoxDTraceCmd_DEFS += YYDEBUG
116 VBoxDTraceCmd_DEFS.linux = _XOPEN_SOURCE=700 _LARGEFILE64_SOURCE
117 VBoxDTraceCmd_DEFS.win = YY_USE_PROTOS=1 YYENABLE_NLS=0 YYLTYPE_IS_TRIVIAL=0
118 VBoxDTraceCmd_SDKS = VBOX_ZLIB
119 ifn1of ($(KBUILD_TARGET), win)
120 VBoxDTraceCmd_CFLAGS = -Wno-format $(VBOX_GCC_Wno-overlength-strings) -Wno-sign-compare -Wno-strict-prototypes -Wno-missing-prototypes -Wno-missing-declarations -Wno-shadow
121 endif
122 VBoxDTraceCmd_INCS = \
123 include \
124 $(VBOXDT_PATH_UTS)/common \
125 $(VBOXDT_PATH_LIBCTF)/common \
126 $(VBOXDT_PATH_LIBDTRACE)/common \
127 $(VBOXDT_PATH_CMN_CTF)
128 VBoxDTraceCmd_SOURCES = \
129 $(VBOXDT_PATH_CMD)/dtrace/dtrace.c \
130 \
131 $(VBOXDT_PATH_LIBDTRACE)/common/dt_as.c \
132 $(VBOXDT_PATH_LIBDTRACE)/common/dt_aggregate.c \
133 $(VBOXDT_PATH_LIBDTRACE)/common/dt_buf.c \
134 $(VBOXDT_PATH_LIBDTRACE)/common/dt_cc.c \
135 $(VBOXDT_PATH_LIBDTRACE)/common/dt_cg.c \
136 $(VBOXDT_PATH_LIBDTRACE)/common/dt_consume.c \
137 $(VBOXDT_PATH_LIBDTRACE)/common/dt_decl.c \
138 $(VBOXDT_PATH_LIBDTRACE)/common/dt_dis.c \
139 $(VBOXDT_PATH_LIBDTRACE)/common/dt_dof.c \
140 $(VBOXDT_PATH_LIBDTRACE)/common/dt_error.c \
141 $(VBOXDT_PATH_LIBDTRACE)/common/dt_handle.c \
142 $(VBOXDT_PATH_LIBDTRACE)/common/dt_ident.c \
143 $(VBOXDT_PATH_LIBDTRACE)/common/dt_inttab.c \
144 $(VBOXDT_PATH_LIBDTRACE)/common/dt_list.c \
145 $(VBOXDT_PATH_LIBDTRACE)/common/dt_map.c \
146 $(VBOXDT_PATH_LIBDTRACE)/common/dt_module.c \
147 $(VBOXDT_PATH_LIBDTRACE)/common/dt_program.c \
148 $(VBOXDT_PATH_LIBDTRACE)/common/dt_open.c \
149 $(VBOXDT_PATH_LIBDTRACE)/common/dt_options.c \
150 $(VBOXDT_PATH_LIBDTRACE)/common/dt_parser.c \
151 $(VBOXDT_PATH_LIBDTRACE)/common/dt_pcb.c \
152 $(VBOXDT_PATH_LIBDTRACE)/common/dt_pragma.c \
153 $(VBOXDT_PATH_LIBDTRACE)/common/dt_printf.c \
154 $(VBOXDT_PATH_LIBDTRACE)/common/dt_proc.c \
155 $(VBOXDT_PATH_LIBDTRACE)/common/dt_provider.c \
156 $(VBOXDT_PATH_LIBDTRACE)/common/dt_regset.c \
157 $(VBOXDT_PATH_LIBDTRACE)/common/dt_string.c \
158 $(VBOXDT_PATH_LIBDTRACE)/common/dt_strtab.c \
159 $(VBOXDT_PATH_LIBDTRACE)/common/dt_subr.c \
160 $(VBOXDT_PATH_LIBDTRACE)/common/dt_work.c \
161 $(VBOXDT_PATH_LIBDTRACE)/common/dt_xlator.c \
162 \
163 $(VBoxDTraceCmd_0_OUTDIR)/dt_errtags.c \
164 $(VBoxDTraceCmd_0_OUTDIR)/dt_names.c \
165 \
166 $(VBOXDT_PATH_CMN_CTF)/ctf_create.c \
167 $(VBOXDT_PATH_CMN_CTF)/ctf_error.c \
168 $(VBOXDT_PATH_CMN_CTF)/ctf_decl.c \
169 $(VBOXDT_PATH_CMN_CTF)/ctf_hash.c \
170 $(VBOXDT_PATH_CMN_CTF)/ctf_labels.c \
171 $(VBOXDT_PATH_CMN_CTF)/ctf_lookup.c \
172 $(VBOXDT_PATH_CMN_CTF)/ctf_open.c \
173 $(VBOXDT_PATH_CMN_CTF)/ctf_types.c \
174 $(VBOXDT_PATH_CMN_CTF)/ctf_util.c \
175 \
176 $(VBOXDT_PATH_LIBCTF)/common/ctf_subr.c \
177 $(VBOXDT_PATH_LIBCTF)/common/ctf_lib.c
178
179 # Source not used or wanted:
180 # $(VBOXDT_PATH_LIBDTRACE)/common/dt_link.c
181 # $(VBOXDT_PATH_LIBDTRACE)/common/dt_pid.c
182
183 # Generate sources
184 VBoxDTraceCmd_CLEAN = \
185 $(VBoxDTraceCmd_0_OUTDIR)/dt_errtags.c \
186 $(VBoxDTraceCmd_0_OUTDIR)/dt_names.c
187
188 $$(VBoxDTraceCmd_0_OUTDIR)/dt_errtags.c: \
189 $(VBOXDT_PATH_LIBDTRACE)/common/dt_errtags.h \
190 $(VBOXDT_PATH_LIBDTRACE)/common/mkerrtags.sed \
191 | $$(dir $$@)
192 $(MSG_GENERATE,VBoxDTraceCmd,$@,$<)
193 $(SED) -n -f $(VBOXDT_PATH_LIBDTRACE)/common/mkerrtags.sed --output $@ $<
194
195 $$(VBoxDTraceCmd_0_OUTDIR)/dt_names.c: \
196 $(VBOXDT_PATH_UTS)/common/sys/dtrace.h \
197 $(VBOXDT_PATH_LIBDTRACE)/common/mknames.sed \
198 | $$(dir $$@)
199 $(MSG_GENERATE,VBoxDTraceCmd,$@,$<)
200 $(SED) -n -f $(VBOXDT_PATH_LIBDTRACE)/common/mknames.sed --output $@ $<
201
202 ifdef VBOX_HAVE_BISON
203 USES += yacc
204 VBoxDTraceCmd_USES += yacc
205 VBoxDTraceCmd_YACCTOOL = BISON
206 VBoxDTraceCmd_YACCFLAGS = -d -y
207 VBoxDTraceCmd_SOURCES += \
208 $(VBOXDT_PATH_LIBDTRACE)/common/dt_grammar.y
209 VBoxDTraceCmd_INCS += $(VBoxDTraceCmd_0_OUTDIR)/src/VBox/ExtPacks/VBoxDTrace/onnv/lib/libdtrace/common
210 else
211 VBoxDTraceCmd_SOURCES += \
212 $(VBOXDT_PATH)/generated/dt_grammar.c
213 VBoxDTraceCmd_INCS += \
214 $(VBOXDT_PATH)/generated/
215 endif
216
217 ifdef VBOX_HAVE_FLEX
218 USES += lex
219 VBoxDTraceCmd_USES += lex
220 VBoxDTraceCmd_LEXTOOL = FLEX
221 VBoxDTraceCmd_LEXFLAGS = -l -B #-d -T
222 VBoxDTraceCmd_SOURCES += \
223 $(VBOXDT_PATH_LIBDTRACE)/common/dt_lex.l
224 else
225 VBoxDTraceCmd_SOURCES += \
226 $(VBOXDT_PATH)/generated/dt_lex.c
227 endif
228 ifeq ($(KBUILD_HOST),linux)
229 if $(VBOX_GCC_VERSION_CXX) >= 70000
230 VBoxDTraceCmd_CFLAGS += -Wno-implicit-fallthrough
231 endif
232 endif
233 VBoxDTraceCmd_DEFS += USING_FLEX
234 $(call VBOX_SET_VER_INFO_DLL,VBoxDTraceCmd,VBoxDTrace Command Implementation)
235
236 #
237 # Updates the sources generated by flex and biosn.
238 # The SED processing removes the paths the from #line statements.
239 #
240 vboxdtrace-update-generated-sources: \
241 $$(VBoxDTraceCmd_0_OUTDIR)/src/VBox/ExtPacks/VBoxDTrace/onnv/lib/libdtrace/common/dt_grammar.c \
242 $$(VBoxDTraceCmd_0_OUTDIR)/src/VBox/ExtPacks/VBoxDTrace/onnv/lib/libdtrace/common/dt_grammar.h \
243 $$(VBoxDTraceCmd_0_OUTDIR)/src/VBox/ExtPacks/VBoxDTrace/onnv/lib/libdtrace/common/dt_lex.c
244 $(foreach file,dt_grammar.c dt_grammar.h dt_lex.c \
245 ,$(NLTAB)$(SED) -e 's,$(VBOXDT_PATH_LIBDTRACE)/common/,,g'\
246 -e 's,$(VBoxDTraceCmd_0_OUTDIR)/src/VBox/ExtPacks/VBoxDTrace/onnv/lib/libdtrace/common/,,g' \
247 --output $(VBOXDT_PATH)/generated/$(file) \
248 $(VBoxDTraceCmd_0_OUTDIR)/src/VBox/ExtPacks/VBoxDTrace/onnv/lib/libdtrace/common/$(file))
249 endif # Temporarily disabled on Solaris.
250
251 #
252 # The ring-0 part of VBoxDTrace.
253 #
254 ifneq ($(KBUILD_TARGET),solaris) # disabled on solaris - neiter needed nor currently able to build it here.
255 $(if-expr defined(VBOX_WITH_VBOXR0_AS_DLL),DLLS,SYSMODS) += VBoxDTraceR0
256 endif
257 VBoxDTraceR0_TEMPLATE = VBoxR0ExtPackDTrace
258 VBoxDTraceR0_DEFS = IN_VBOXDTRACE_R0 IN_RT_R0
259 ifeq ($(VBOX_LDR_FMT),elf)
260 VBoxDTraceR0_LDFLAGS = -e ModuleInit
261 endif
262 VBoxDTraceR0_INCS = \
263 include \
264 $(VBOXDT_PATH_UTS)/common
265 VBoxDTraceR0_SOURCES = \
266 VBoxDTraceR0.cpp \
267 VBoxDTraceR0A.asm \
268 $(VBOXDT_PATH_UTS)/common/dtrace/dtrace.c
269 VBoxDTraceR0_LIBS = \
270 $(PATH_STAGE_LIB)/RuntimeR0$(VBOX_SUFF_LIB)
271 ifneq ($(filter pe lx,$(VBOX_LDR_FMT)),)
272 VBoxDTraceR0_LIBS += \
273 $(PATH_STAGE_LIB)/SUPR0$(VBOX_SUFF_LIB)
274 endif
275 $(call VBOX_SET_VER_INFO_R0,VBoxDTraceR0,VBoxDTrace Core (ring-0))
276
277
278 #
279 # Packing.
280 #
281 ifndef VBOX_WITHOUT_EXTPACK_VBOXDTRACE_PACKING
282 PACKING += $(VBOX_PATH_PACKAGES)/$(VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME)-$(VBOX_VERSION_STRING)r$(VBOX_SVN_REV).vbox-extpack
283 endif
284
285 ifndef VBOX_WITH_EXTPACK_OS_ARCHS
286 ifeq ($(USER),bird) # for now
287 VBOX_WITH_EXTPACK_OS_ARCHS = $(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)
288 endif
289 endif
290
291 # Build the file list. The macro takes 1=darwin.x86, 2=dist/VirtualBox.app/Contents/MacOS, 3=dylib
292 VBOX_VBOXDTRACE_FILES_MACRO = \
293 $(PATH_OUT_BASE)/$(1)/$(KBUILD_TYPE)/$(2)/ExtensionPacks/$(VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME)/$(1)/VBoxDTraceMain.$(3)=>$(1)/VBoxDTraceMain.$(3) \
294 $(if $(intersects $1, solaris.x86 solaris.amd64),, \
295 $(PATH_OUT_BASE)/$(1)/$(KBUILD_TYPE)/$(2)/ExtensionPacks/$(VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME)/$(1)/VBoxDTraceCmd.$(3)=>$(1)/VBoxDTraceCmd.$(3) \
296 $(PATH_OUT_BASE)/$(1)/$(KBUILD_TYPE)/$(2)/ExtensionPacks/$(VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME)/$(1)/VBoxDTraceR0.r0=>$(1)/VBoxDTraceR0.r0 \
297 )
298
299 VBOX_VBOXDTRACE_FILES := \
300 $(VBOX_PATH_EXTPACK_VBOXDTRACE)/ExtPack.xml=>ExtPack.xml \
301 $(VBOX_PATH_EXTPACK_VBOXDTRACE)/ExtPack-SourceCodeLicense.txt=>ExtPack-SourceCodeLicense.txt
302
303 if1of (darwin.amd64, $(VBOX_WITH_EXTPACK_OS_ARCHS))
304 VBOX_VBOXDTRACE_FILES += $(call VBOX_VBOXDTRACE_FILES_MACRO,darwin.amd64,dist/VirtualBox.app/Contents/MacOS,dylib)
305 endif
306 if1of (darwin.x86, $(VBOX_WITH_EXTPACK_OS_ARCHS))
307 VBOX_VBOXDTRACE_FILES += $(call VBOX_VBOXDTRACE_FILES_MACRO,darwin.x86,dist/VirtualBox.app/Contents/MacOS,dylib)
308 endif
309 if1of (freebsd.amd64, $(VBOX_WITH_EXTPACK_OS_ARCHS))
310 VBOX_VBOXDTRACE_FILES += $(call VBOX_VBOXDTRACE_FILES_MACRO,freebsd.amd64,bin,so)
311 endif
312 if1of (freebsd.x86, $(VBOX_WITH_EXTPACK_OS_ARCHS))
313 VBOX_VBOXDTRACE_FILES += $(call VBOX_VBOXDTRACE_FILES_MACRO,freebsd.x86,bin,so)
314 endif
315 if1of (linux.amd64, $(VBOX_WITH_EXTPACK_OS_ARCHS))
316 VBOX_VBOXDTRACE_FILES += $(call VBOX_VBOXDTRACE_FILES_MACRO,linux.amd64,bin,so)
317 endif
318 if1of (linux.x86, $(VBOX_WITH_EXTPACK_OS_ARCHS))
319 VBOX_VBOXDTRACE_FILES += $(call VBOX_VBOXDTRACE_FILES_MACRO,linux.x86,bin,so)
320 endif
321 if1of (os2.x86, $(VBOX_WITH_EXTPACK_OS_ARCHS))
322 VBOX_VBOXDTRACE_FILES += $(call VBOX_VBOXDTRACE_FILES_MACRO,os2.x86,bin,so)
323 endif
324 if1of (solaris.amd64, $(VBOX_WITH_EXTPACK_OS_ARCHS))
325 VBOX_VBOXDTRACE_FILES += $(call VBOX_VBOXDTRACE_FILES_MACRO,solaris.amd64,bin,so)
326 endif
327 if1of (solaris.x86, $(VBOX_WITH_EXTPACK_OS_ARCHS))
328 VBOX_VBOXDTRACE_FILES += $(call VBOX_VBOXDTRACE_FILES_MACRO,solaris.x86,bin,so)
329 endif
330 if1of (win.amd64, $(VBOX_WITH_EXTPACK_OS_ARCHS))
331 VBOX_VBOXDTRACE_FILES += $(call VBOX_VBOXDTRACE_FILES_MACRO,win.amd64,bin,dll)
332 endif
333 if1of (win.x86, $(VBOX_WITH_EXTPACK_OS_ARCHS))
334 VBOX_VBOXDTRACE_FILES += $(call VBOX_VBOXDTRACE_FILES_MACRO,win.x86,bin,dll)
335 endif
336
337 # Pack it all up using a temporary staging directory.
338 $(VBOX_PATH_PACKAGES)/$(VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME)-$(VBOX_VERSION_STRING)r$(VBOX_SVN_REV).vbox-extpack: \
339 $$(foreach file, $$(VBOX_VBOXDTRACE_FILES), $$(firstword $$(subst =>,$$(SP),$$(file)))) \
340 | $(VBOX_PATH_PACKAGES)/
341 $(RM) -f $(wildcard $(VBOX_PATH_PACKAGES)/$(VBOX_EXTPACK_VBOXDTRACE_MANGLED_NAME)-*.vbox-extpack) \
342 $(VBoxDTraceIns_0_OUTDIR)/ExtPack.manifest \
343 $(VBoxDTraceIns_0_OUTDIR)/ExtPack.signature
344 # Stage all the files
345 $(RM) -Rf $(VBoxDTraceIns_0_OUTDIR)/Stage/
346 $(foreach file, $(VBOX_VBOXDTRACE_FILES),\
347 $(NLTAB)$(MKDIR) -p $(dir $(lastword $(subst =>,$(SP)$(VBoxDTraceIns_0_OUTDIR)/Stage/,$(file)))) \
348 $(NLTAB)$(CP) $(subst =>,$(SP)$(VBoxDTraceIns_0_OUTDIR)/Stage/,$(file)) )
349 # Create the manifest
350 $(VBOX_RTMANIFEST) \
351 --manifest $(VBoxDTraceIns_0_OUTDIR)/Stage/ExtPack.manifest \
352 --chdir $(VBoxDTraceIns_0_OUTDIR)/Stage/ \
353 $(foreach file, $(VBOX_VBOXDTRACE_FILES), $(lastword $(subst =>,$(SP),$(file))))
354 $(APPEND) $(VBoxDTraceIns_0_OUTDIR)/Stage/ExtPack.signature "todo"
355 $(CHMOD) a+r \
356 $(VBoxDTraceIns_0_OUTDIR)/Stage/ExtPack.manifest \
357 $(VBoxDTraceIns_0_OUTDIR)/Stage/ExtPack.signature
358 # Tar it up.
359 tar -cvf - -C $(VBoxDTraceIns_0_OUTDIR)/Stage/ . | gzip -9c > $@
360 # Clean up
361 $(RM) -Rf $(VBoxDTraceIns_0_OUTDIR)/Stage/
362
363 BLDDIRS += $(VBOX_PATH_PACKAGES)/
364
365endif # VBOX_WITH_EXTPACK_VBOXDTRACE
366
367
368include $(FILE_KBUILD_SUB_FOOTER)
369
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