VirtualBox

source: vbox/trunk/src/VBox/Devices/EFI/Firmware/Makefile.kmk@ 48730

Last change on this file since 48730 was 48727, checked in by vboxsync, 12 years ago

EFI: EFI image load events, EFI debug points, always disabled frame-pointer optimizations on MSFT. Some cleanups.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 14.7 KB
Line 
1# $Id: Makefile.kmk 48727 2013-09-27 11:03:53Z vboxsync $
2## @file
3# Toplevel sub-makefile for the EFI firmwares.
4#
5# Note! kBuild is only used for the build tools, the rest is handled by the
6# very custom EFI build system.
7#
8
9#
10# Copyright (C) 2013 Oracle Corporation
11#
12# This file is part of VirtualBox Open Source Edition (OSE), as
13# available from http://www.virtualbox.org. This file is free software;
14# you can redistribute it and/or modify it under the terms of the GNU
15# General Public License (GPL) as published by the Free Software
16# Foundation, in version 2 as it comes in the "COPYING" file of the
17# VirtualBox OSE distribution. VirtualBox OSE is distributed in the
18# hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
19#
20# The contents of this file may alternatively be used under the terms
21# of the Common Development and Distribution License Version 1.0
22# (CDDL) only, as it comes in the "COPYING.CDDL" file of the
23# VirtualBox OSE distribution, in which case the provisions of the
24# CDDL are applicable instead of those of the GPL.
25#
26# You may elect to license modified versions of this file under the
27# terms and conditions of either the GPL or the CDDL or both.
28#
29
30SUB_DEPTH = ../../../../..
31include $(KBUILD_PATH)/subheader.kmk
32
33#
34# Make sure our Config.kmk is included.
35#
36ifndef VBOX_EFI_FIRMWARE_CONFIG_KMK_INCLUDED
37 include $(PATH_SUB_CURRENT)/Config.kmk
38endif
39
40
41#
42# Include sub-makefiles.
43#
44VBOX_EFI_BLDPROGS := $(BLDPROGS)
45include $(PATH_SUB_CURRENT)/BaseTools/Makefile.kmk
46VBOX_EFI_BLDPROGS := $(filter-out $(VBOX_EFI_BLDPROGS),$(BLDPROGS)) VBoxEfiBldPythonWrappers
47
48#
49# Binary wrappers for python scripts.
50#
51VBOX_EFI_PYTHON_WRAPPERS = \
52 BPDG \
53 build \
54 Ecc \
55 GenFds \
56 GenPatchPcdTable \
57 PatchPcdValue \
58 Trim \
59 TargetTool \
60 UPT
61
62INSTALLS += VBoxEfiBldPythonWrappers
63VBoxEfiBldPythonWrappers_TEMPLATE = VBoxEfiBldProg
64if1of ($(KBUILD_HOST), win os2)
65 VBoxEfiBldPythonWrappers_EXEC_SOURCES = \
66 $(foreach PyWrap,$(VBOX_EFI_PYTHON_WRAPPERS),$(VBoxEfiBldPythonWrappers_0_OUTDIR)/$(PyWrap).cmd)
67else
68 VBoxEfiBldPythonWrappers_EXEC_SOURCES = \
69 $(addprefix $(VBoxEfiBldPythonWrappers_0_OUTDIR)/,$(VBOX_EFI_PYTHON_WRAPPERS))
70endif
71VBoxEfiBldPythonWrappers_CLEAN = $(VBoxEfiBldPythonWrappers_SOURCES)
72
73if1of ($(KBUILD_HOST), win os2)
74 define VBoxEfiBldPythonWrappersRuleTemplate
75 $$$$(VBoxEfiBldPythonWrappers_0_OUTDIR)/$(PyWrap).cmd: | $$$$(dir $$$$@)
76 $$(APPEND) -tn "$$@" \
77 '@SET PYTHONPATH=$$(VBOX_PATH_EFI_FIRMWARE)/BaseTools/Source/Python' \
78 '@"$$(VBOX_BLD_PYTHON)" "$$(VBOX_PATH_EFI_FIRMWARE)/BaseTools/Source/Python/$(PyWrap)/$(PyWrap).py" %*'
79 endef
80else
81 define VBoxEfiBldPythonWrappersRuleTemplate
82 $$$$(VBoxEfiBldPythonWrappers_0_OUTDIR)/$(PyWrap): | $$$$(dir $$$$@)
83 $$(APPEND) -tn "$$@" \
84 '#!$(ASH)' \
85 'export PYTHONPATH="$$(VBOX_PATH_EFI_FIRMWARE)/BaseTools/Source/Python"' \
86 'exec "$$(VBOX_BLD_PYTHON)" "$$(VBOX_PATH_EFI_FIRMWARE)/BaseTools/Source/Python/$(PyWrap)/$(PyWrap).py" "$$(DOLLAR)@"'
87 $$(CHMOD) a+x "$$@"
88 endef
89endif
90$(foreach PyWrap,$(VBOX_EFI_PYTHON_WRAPPERS),$(eval $(VBoxEfiBldPythonWrappersRuleTemplate)))
91
92#
93# Rules for building and installing the VBox EFI firmware images.
94#
95INSTALLS += VBoxEfiFirmware
96VBoxEfiFirmware_INST = $(INST_BIN)
97VBoxEfiFirmware_MODE = 0644
98VBoxEfiFirmware_SOURCES = \
99 $(VBoxEfiFirmware_0_OUTDIR)/x86/$(VBOX_EFI_OUTPUT_SUBDIR)/FV/OVMF.fd=>VBoxEFI32.fd \
100 $(VBoxEfiFirmware_0_OUTDIR)/amd64/$(VBOX_EFI_OUTPUT_SUBDIR)/FV/OVMF.fd=>VBoxEFI64.fd
101VBoxEfiFirmware_BLDDIRS = \
102 $(VBoxEfiFirmware_0_OUTDIR)/x86/ \
103 $(VBoxEfiFirmware_0_OUTDIR)/x86/Conf/ \
104 $(VBoxEfiFirmware_0_OUTDIR)/amd64/ \
105 $(VBoxEfiFirmware_0_OUTDIR)/amd64/Conf/
106VBoxEfiFirmware_CLEAN = \
107 $(VBoxEfiFirmware_0_OUTDIR)/x86/Conf/target.txt \
108 $(VBoxEfiFirmware_0_OUTDIR)/x86/Conf/tools_def.txt \
109 $(VBoxEfiFirmware_0_OUTDIR)/amd64/Conf/target.txt \
110 $(VBoxEfiFirmware_0_OUTDIR)/amd64/Conf/tools_def.txt
111
112# Install the debug info.
113INSTALLS += VBoxEfiFirmwareDbg32
114VBoxEfiFirmwareDbg32_INST = $(INST_VBOXDBG_SYMS)x86/
115VBoxEfiFirmwareDbg32_MODE = 0644
116if1of ($(KBUILD_HOST), win)
117 VBoxEfiFirmwareDbg32_SOURCES = \
118 $(foreach mod,$(VBOX_EFI_MODULES),$(VBoxEfiFirmware_0_OUTDIR)/x86/$(VBOX_EFI_OUTPUT_SUBDIR)/IA32/$(mod).pdb)
119else
120 VBoxEfiFirmwareDbg32_SOURCES = \
121 $(foreach mod,$(VBOX_EFI_MODULES_FLAT),$(VBoxEfiFirmware_0_OUTDIR)/x86/$(VBOX_EFI_OUTPUT_SUBDIR)/IA32/$(mod).debug)
122endif
123
124INSTALLS += VBoxEfiFirmwareDbg64
125VBoxEfiFirmwareDbg64_INST = $(INST_VBOXDBG_SYMS)amd64/
126VBoxEfiFirmwareDbg64_MODE = 0644
127if1of ($(KBUILD_HOST), win)
128 VBoxEfiFirmwareDbg64_SOURCES = \
129 $(foreach mod,$(VBOX_EFI_MODULES),$(VBoxEfiFirmware_0_OUTDIR)/amd64/$(VBOX_EFI_OUTPUT_SUBDIR)/X64/$(mod).pdb)
130else
131 VBoxEfiFirmwareDbg64_SOURCES = \
132 $(foreach mod,$(VBOX_EFI_MODULES_FLAT),$(VBoxEfiFirmware_0_OUTDIR)/amd64/$(VBOX_EFI_OUTPUT_SUBDIR)/X64/$(mod).debug)
133endif
134
135
136#
137# Install a custom clean up rule for dealing with the EFI build system output.
138#
139PASS_CLEAN_trgs += VBoxEfiFirmwareCleanup
140VBoxEfiFirmwareCleanup:
141 $(if $(VBoxEfiFirmware_0_OUTDIR),,exit 1)
142 $(RM) -Rf -- "$(VBoxEfiFirmware_0_OUTDIR)/amd64/" "$(VBoxEfiFirmware_0_OUTDIR)/x86/"
143.PHONY: VBoxEfiFirmwareCleanup
144
145
146#
147# The reset vector code.
148#
149
150# Dummy Linker.
151TOOL_VBoxEfiResetVectorLd = Dummy linker for the EFI reset vectors.
152TOOL_VBoxEfiResetVectorLd_LINK_MISCBIN_OUTPUT =
153TOOL_VBoxEfiResetVectorLd_LINK_MISCBIN_DEPEND =
154TOOL_VBoxEfiResetVectorLd_LINK_MISCBIN_DEPORD =
155define TOOL_VBoxEfiResetVectorLd_LINK_MISCBIN_CMDS
156 $(VBOX_BLD_PYTHON) $(VBOX_PATH_EFI_FIRMWARE)/UefiCpuPkg/ResetVector/Vtf0/Tools/FixupForRawSection.py \
157 "--only-padd-image" \
158 "$(objs)" \
159 "$(out)"
160endef
161
162# Makes a boot sector test image.
163TEMPLATE_VBoxEfiResetVectorRaw = kBuild tool config for building the EFI reset vectors.
164TEMPLATE_VBoxEfiResetVectorRaw_INSTTYPE = none
165TEMPLATE_VBoxEfiResetVectorRaw_BINSUFF = .raw
166TEMPLATE_VBoxEfiResetVectorRaw_MODE = 0644
167TEMPLATE_VBoxEfiResetVectorRaw_ASTOOL = YASM
168TEMPLATE_VBoxEfiResetVectorRaw_ASFLAGS:= -f bin $(VBOX_YASM_Wno-segreg-in-64bit) --mapfile
169TEMPLATE_VBoxEfiResetVectorRaw_ASDEFS = ASM_FORMAT_BIN __YASM__
170TEMPLATE_VBoxEfiResetVectorRaw_LDTOOL = VBoxEfiResetVectorLd
171
172MISCBINS += VBoxEfiResetVector-x86
173VBoxEfiResetVector-x86_TEMPLATE = VBoxEfiResetVectorRaw
174VBoxEfiResetVector-x86_DEFS = ARCH_IA32 RT_ARCH_X86 DEBUG_NONE
175VBoxEfiResetVector-x86_SOURCES = UefiCpuPkg/ResetVector/Vtf0/ResetVectorCode.asm
176
177MISCBINS += VBoxEfiResetVector-amd64
178VBoxEfiResetVector-amd64_TEMPLATE = VBoxEfiResetVectorRaw
179VBoxEfiResetVector-amd64_DEFS = ARCH_X64 RT_ARCH_AMD64 DEBUG_NONE
180VBoxEfiResetVector-amd64_SOURCES = UefiCpuPkg/ResetVector/Vtf0/ResetVectorCode.asm
181
182
183#
184# Include the footer early so that we can use VBoxEfiFirmware_0_OUTDIR below.
185#
186include $(FILE_KBUILD_SUB_FOOTER)
187
188#
189# Incomplete list of dependencies relative.
190#
191VBOX_EFI_DEPENDENCIES = \
192 $(VBOX_PATH_EFI_FIRMWARE)/../DevEFI.h \
193 $(VBOX_PATH_EFI_FIRMWARE)/VBoxPkg/Library/VBoxDebugAgentLib/VBoxDebugAgentLib.c \
194 $(VBOX_PATH_EFI_FIRMWARE)/VBoxPkg/Library/VBoxDebugAgentLib/VBoxDebugAgentLib.inf \
195 $(VBOX_PATH_EFI_FIRMWARE)/VBoxPkg/Library/VBoxPeCoffExtraActionLib/VBoxPeCoffExtraActionLib.c \
196 $(VBOX_PATH_EFI_FIRMWARE)/VBoxPkg/Library/VBoxPeCoffExtraActionLib/VBoxPeCoffExtraActionLib.inf \
197 $(VBOX_PATH_EFI_FIRMWARE)/VBoxPkg/VBoxPkg.dec \
198 \
199 $(VBOX_PATH_EFI_FIRMWARE)/OvmfPkg/OvmfPkg.dec \
200
201#
202# The common build.py invocation part.
203#
204if1of ($(KBUILD_HOST), win)
205 VBOX_EFI_REDIRECT_E_EQUAL:=$(EQUAL)
206 VBOX_EFI_BUILD_CMD = $(REDIRECT) \
207 -E 'PATH=$(VBOX_PATH_STAGE_EFI_BLDPROGS)$(VBOX_SEP)$(PATH)' \
208 -E 'INCLUDE=$(PATH_ROOT)/include$(VBOX_SEP)$(PATH_OUT)$(VBOX_SEP)$(VBOX_SEP)$(PATH_TOOL_$(VBOX_VCC_TOOL)_INC)$(INCLUDE)' \
209 -E 'COMSPEC=$(windir)\system32\cmd.exe'
210else
211 VBOX_EFI_REDIRECT_E_EQUAL:=
212VBOX_EFI_BUILD_CMD = $(REDIRECT) \
213 -E "PATH=$(VBOX_PATH_STAGE_EFI_BLDPROGS)$(VBOX_SEP)$(PATH)" \
214 -E "C_INCLUDE_PATH=$(PATH_ROOT)/include$(VBOX_SEP)$(PATH_OUT)$(VBOX_SEP)$(C_INCLUDE_PATH)" \
215 -E "CPLUS_INCLUDE_PATH=$(PATH_ROOT)/include$(VBOX_SEP)$(PATH_OUT)$(VBOX_SEP)$(C_INCLUDE_PATH)"
216endif
217VBOX_EFI_BUILD_CMD += \
218 -E 'PYTHONPATH=$(VBOX_PATH_EFI_FIRMWARE)/BaseTools/Source/Python' \
219 -E 'PYTHONDONTWRITEBYTECODE=1' \
220 -E 'IASL_BIN=$(VBOX_IASLCMD)' \
221 -E 'WORKSPACE=$(VBOX_PATH_EFI_FIRMWARE)' \
222 -E 'EDK_TOOLS_PATH=$(VBOX_PATH_EFI_FIRMWARE)/BaseTools' \
223 -E 'EFI_SOURCE$(VBOX_EFI_REDIRECT_E_EQUAL)' \
224 -E 'ECP_SOURCE$(VBOX_EFI_REDIRECT_E_EQUAL)' \
225 -E 'EDK_SOURCE$(VBOX_EFI_REDIRECT_E_EQUAL)' \
226 -E 'X64_PETOOLS_PREFIX$(VBOX_EFI_REDIRECT_E_EQUAL)' \
227 -E 'ARCH$(VBOX_EFI_REDIRECT_E_EQUAL)' \
228 -E 'IPF_PETOOLS_PREFIX=__no_ipf__' \
229 -E $(if-expr "$(EFI_QUIET)" != "" || "$(KBUILD_VERBOSE)" != "",'EFI_QUIET=','EFI_QUIET=@') \
230 -C '$(VBOX_PATH_EFI_FIRMWARE)' \
231 -- $(VBOX_BLD_PYTHON) "$(VBOX_PATH_EFI_FIRMWARE)/BaseTools/Source/Python/build/build.py" \
232 -D VBOX_WITH_EDK2_REV=13361 \
233 -D VBOX=1 \
234 -D VBOX_WITH_OVMF=1 \
235 -D BUILD_NEW_SHELL=1 \
236 -D VBOX_REV=$(VBOX_SVN_REV) \
237 -D "VBOX_OUTPUT_BASE_DIR=$(VBoxEfiFirmware_0_OUTDIR)" \
238 -D "VBOX_PATH_ROOT=$(PATH_ROOT)" \
239 -D "VBOX_RESET_VECTOR_X86=$(VBoxEfiResetVector-x86_1_TARGET)" \
240 -D "VBOX_RESET_VECTOR_AMD64=$(VBoxEfiResetVector-amd64_1_TARGET)" \
241 $(if $(VBOX_OSE),-D "VBOX_OSE=1") \
242 --no-cache \
243 --buildtarget $(VBOX_EFI_BUILD_TARGET) \
244 --tagname $(VBOX_EFI_TOOL_CHAIN)
245
246
247#
248# VBoxEFI32
249#
250
251$(VBoxEfiFirmware_0_OUTDIR)/x86/Conf/target.txt: $(MAKEFILE) | $$(dir $$@) $(VBOX_EFI_BLDPROGS)
252 $(APPEND) -tn "$@" \
253 "# Automatically generated, do not edit" \
254 "" \
255 "# These variables cannot be overriden by the build.py command line." \
256 "TOOL_CHAIN_CONF = $(VBoxEfiFirmware_0_OUTDIR)/x86/Conf/tools_def.txt" \
257 "BUILD_RULE_CONF = BaseTools/Conf/build_rule.template" \
258 "" \
259 "# These variables are overridden and this is just for show." \
260 "ACTIVE_PLATFORM = OvmfPkg/OvmfPkgIa32.dsc" \
261 "TARGET = $(VBOX_EFI_BUILD_TARGET)" \
262 "TARGET_ARCH = IA32" \
263 "TOOL_CHAIN_TAG = $(VBOX_EFI_TOOL_CHAIN)" \
264 "MAX_CONCURRENT_THREAD_NUMBER = 1"
265
266$(VBoxEfiFirmware_0_OUTDIR)/x86/Conf/tools_def.txt: \
267 $(VBOX_PATH_EFI_FIRMWARE)/BaseTools/Conf/tools_def.template \
268 $(MAKEFILE) | $$(dir $$@)
269 $(RM) -f -- "$@"
270ifeq ($(VBOX_EFI_TOOL_CHAIN),UNIXGCC)
271 $(SED) \
272 -e 's,^DEFINE UNIXGCC_IA32_PETOOLS_PREFIX.*$(DOLLAR),DEFINE UNIXGCC_IA32_PETOOLS_PREFIX = $(VBOX_PATH_PREFIX_MINGW32),' \
273 -e 's,^DEFINE UNIXGCC_X64_PETOOLS_PREFIX.*$(DOLLAR),DEFINE UNIXGCC_X64_PETOOLS_PREFIX = $(VBOX_PATH_PREFIX_MINGW64),' \
274 -e 's,^DEFINE UNIX_IASL_BIN.*$(DOLLAR),DEFINE UNIX_IASL_BIN = $(VBOX_IASLCMD),' \
275 -e 's,^\(DEFINE GCC_ALL_CC_FLAGS.*$(DOLLAR)\),\1 -Wno-address $(VBOX_MINGW32_Wno-unused-but-set-variable) $(VBOX_MINGW32_Wno-maybe-uninitialized),' \
276 $(if $(VBOX_MINGW32_Wno-array-bounds),,-e 's,-Wno-array-bounds,,g') \
277 -e 's,=[[:space:]]*make$(DOLLAR),= $(MAKE),' \
278 $(if-expr "$(VBOX_EFI_BUILD_TARGET)" == "DEBUG", -e 's/ -O2 / /g',) \
279 --output $@ $<
280else if ($(VBOX_EFI_TOOL_CHAIN),VS2010)
281 $(SED) \
282 -e 's,^DEFINE VS2010_BIN[[:space:]]*=.*$(DOLLAR),DEFINE VS2010_BIN = $(PATH_TOOL_$(VBOX_VCC_TOOL))/bin,' \
283 -e 's,^DEFINE VS2010_DLL[[:space:]]*=.*$(DOLLAR),DEFINE VS2010_DLL = DEF(VS2010_BIN),' \
284 -e 's,^\([^=]*_VS2010[a-zA-Z_0-9]*_CC_FLAGS[[:space:]]*=.*\)$(DOLLAR),\1 /Oy-,' \
285 --output $@ $<
286# -e 's,^\([^=]*_VS2010[a-zA-Z_0-9]*_CC_FLAGS[[:space:]]*=.*\) /O1ib2 \(.*\)$(DOLLAR),\1 /Osi /GF /Gy \2 /Oy-,'
287else
288 $(error Unexpected VBOX_EFI_TOOL_CHAIN value "$(VBOX_EFI_TOOL_CHAIN)")
289endif
290
291## @todo 32-bit DEBUG is busted, image to big.
292$(VBoxEfiFirmware_0_OUTDIR)/x86/$(VBOX_EFI_OUTPUT_SUBDIR)/FV/OVMF.fd \
293+ $(VBoxEfiFirmwareDbg32_SOURCES): \
294 $(VBoxEfiFirmware_0_OUTDIR)/x86/Conf/target.txt \
295 $(VBoxEfiFirmware_0_OUTDIR)/x86/Conf/tools_def.txt \
296 $$(VBoxEfiResetVector-x86_1_TARGET) \
297 $(VBOX_EFI_DEPENDENCIES) \
298 $(VBOX_PATH_EFI_FIRMWARE)/OvmfPkg/OvmfPkgIa32.dsc \
299 $(VBOX_PATH_EFI_FIRMWARE)/OvmfPkg/OvmfPkgIa32.fdf
300 + $(VBOX_EFI_BUILD_CMD) \
301 --vbox-target-conf "$(VBoxEfiFirmware_0_OUTDIR)/x86/Conf/target.txt" \
302 --arch IA32 \
303 --platform OvmfPkg/OvmfPkgIa32.dsc \
304 -n 1 # -v
305
306#
307# VBoxEFI64
308#
309
310$(VBoxEfiFirmware_0_OUTDIR)/amd64/Conf/target.txt: $(MAKEFILE) | $$(dir $$@) $(VBOX_EFI_BLDPROGS)
311 $(APPEND) -tn "$@" \
312 "# Automatically generated, do not edit" \
313 "" \
314 "# These variables cannot be overriden by the build.py command line." \
315 "TOOL_CHAIN_CONF = $(VBoxEfiFirmware_0_OUTDIR)/amd64/Conf/tools_def.txt" \
316 "BUILD_RULE_CONF = BaseTools/Conf/build_rule.template" \
317 "" \
318 "# These variables are overridden and this is just for show." \
319 "ACTIVE_PLATFORM = OvmfPkg/OvmfPkgX64.dsc" \
320 "TARGET = $(VBOX_EFI_BUILD_TARGET)" \
321 "TARGET_ARCH = X64" \
322 "TOOL_CHAIN_TAG = $(VBOX_EFI_TOOL_CHAIN)" \
323 "MAX_CONCURRENT_THREAD_NUMBER = 1"
324
325# Hack! Drop an underscore from the entrypoint, or SecMain won't work.
326$(VBoxEfiFirmware_0_OUTDIR)/amd64/Conf/tools_def.txt: \
327 $(VBOX_PATH_EFI_FIRMWARE)/BaseTools/Conf/tools_def.template \
328 $(MAKEFILE) | $$(dir $$@)
329 $(RM) -f -- "$@"
330ifeq ($(VBOX_EFI_TOOL_CHAIN),UNIXGCC)
331 $(SED) \
332 -e 's,^DEFINE UNIXGCC_IA32_PETOOLS_PREFIX.*$(DOLLAR),DEFINE UNIXGCC_IA32_PETOOLS_PREFIX = $(VBOX_PATH_PREFIX_MINGW32),' \
333 -e 's,^DEFINE UNIXGCC_X64_PETOOLS_PREFIX.*$(DOLLAR),DEFINE UNIXGCC_X64_PETOOLS_PREFIX = $(VBOX_PATH_PREFIX_MINGW64),' \
334 -e 's,^DEFINE UNIX_IASL_BIN.*$(DOLLAR),DEFINE UNIX_IASL_BIN = $(VBOX_IASLCMD),' \
335 -e 's,^\(DEFINE GCC_ALL_CC_FLAGS.*$(DOLLAR)\),\1 -Wno-address $(VBOX_MINGW64_Wno-unused-but-set-variable) $(VBOX_MINGW64_Wno-maybe-uninitialized),' \
336 $(if $(VBOX_MINGW64_Wno-array-bounds),,-e 's,-Wno-array-bounds,,g') \
337 -e 's,=[[:space:]]*make$(DOLLAR),= $(MAKE),' \
338 -e 's,^\(DEFINE GCC_IA32_X64_DLINK_COMMON.*\)$(DOLLAR),\1 --fatal-warnings,' \
339 $(if $(VBOX_MINGW64_USER_LABEL_PREFIX),,-e 's,^\(DEFINE GCC_IA32_X64_DLINK_FLAGS.* --entry \)_,\1,') \
340 --output $@ $<
341else if ($(VBOX_EFI_TOOL_CHAIN),VS2010)
342 $(SED) \
343 -e 's,^DEFINE VS2010_BIN[[:space:]]*=.*$(DOLLAR),DEFINE VS2010_BIN = $(PATH_TOOL_$(VBOX_VCC_TOOL))/bin,' \
344 -e 's,^DEFINE VS2010_DLL[[:space:]]*=.*$(DOLLAR),DEFINE VS2010_DLL = DEF(VS2010_BIN),' \
345 -e 's,^\([^=]*_VS2010[a-zA-Z_0-9]*_CC_FLAGS[[:space:]]*=.*\) /X \(.*\)$(DOLLAR),\1 \2 /Oy-,' \
346 --output $@ $<
347else
348 $(error Unexpected VBOX_EFI_TOOL_CHAIN value "$(VBOX_EFI_TOOL_CHAIN)")
349endif
350
351$(VBoxEfiFirmware_0_OUTDIR)/amd64/$(VBOX_EFI_OUTPUT_SUBDIR)/FV/OVMF.fd \
352+ $(VBoxEfiFirmwareDbg64_SOURCES): \
353 $(VBoxEfiFirmware_0_OUTDIR)/amd64/Conf/target.txt \
354 $(VBoxEfiFirmware_0_OUTDIR)/amd64/Conf/tools_def.txt \
355 $$(VBoxEfiResetVector-amd64_1_TARGET) \
356 $(VBOX_EFI_DEPENDENCIES) \
357 $(VBOX_PATH_EFI_FIRMWARE)/OvmfPkg/OvmfPkgX64.dsc \
358 $(VBOX_PATH_EFI_FIRMWARE)/OvmfPkg/OvmfPkgX64.fdf
359 + $(VBOX_EFI_BUILD_CMD) \
360 --vbox-target-conf "$(VBoxEfiFirmware_0_OUTDIR)/amd64/Conf/target.txt" \
361 --arch X64 \
362 --platform OvmfPkg/OvmfPkgX64.dsc \
363 -n 1 # -v
364
365#
366# Some aliases.
367#
368build-efi-x86: $$(filter %VBoxEFI32.fd,$$(VBoxEfiFirmware_2_STAGE_TARGETS))
369build-efi-amd64: $$(filter %VBoxEFI64.fd,$$(VBoxEfiFirmware_2_STAGE_TARGETS))
370
Note: See TracBrowser for help on using the repository browser.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette