1 | #
|
---|
2 | # Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
---|
3 | # Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
|
---|
4 | # Portions copyright (c) 2011 - 2014, ARM Ltd. All rights reserved.<BR>
|
---|
5 | # Copyright (c) 2015, Hewlett-Packard Development Company, L.P.<BR>
|
---|
6 | # (C) Copyright 2016 Hewlett Packard Enterprise Development LP<BR>
|
---|
7 | #
|
---|
8 | # SPDX-License-Identifier: BSD-2-Clause-Patent
|
---|
9 | #
|
---|
10 |
|
---|
11 | IDENTIFIER = Default TOOL_CHAIN_CONF
|
---|
12 |
|
---|
13 | # common path macros
|
---|
14 | DEFINE VS2010_BIN = @PATH_VS2010@/bin
|
---|
15 | DEFINE VS2010_DLL = @PATH_VS2010@/bin
|
---|
16 | DEFINE VS2010_BINX64 = @PATH_VS2010_AMD64_BIN@
|
---|
17 | DEFINE VS2010_BIN64 = DEF(VS2010_BIN)\x86_ia64
|
---|
18 |
|
---|
19 | # Microsoft Visual Studio 2010
|
---|
20 | DEFINE WINSDK7_BIN = c:\no\such\directory
|
---|
21 |
|
---|
22 | # These defines are needed for certain Microsoft Visual Studio tools that
|
---|
23 | # are used by other toolchains. An example is that ICC on Windows normally
|
---|
24 | # uses Microsoft's nmake.exe.
|
---|
25 |
|
---|
26 | # Some MS_VS_BIN options: DEF(VS2008_BIN), DEF(VS2008x86_BIN)
|
---|
27 | DEFINE MS_VS_BIN = DEF(VS2010_BIN)
|
---|
28 | # Some MS_VS_DLL options: DEF(VS2008_DLL), DEF(VS2008x86_DLL)
|
---|
29 | DEFINE MS_VS_DLL = DEF(VS2010_DLL)
|
---|
30 |
|
---|
31 | DEFINE WINDDK_BIN16 = ENV(WINDDK3790_PREFIX)bin16
|
---|
32 | DEFINE WINDDK_BINX64 = ENV(WINDDK3790_PREFIX)win64\x86\amd64
|
---|
33 |
|
---|
34 | DEFINE EBC_BIN = C:\Program Files\Intel\EBC\Bin
|
---|
35 | DEFINE EBC_BINx86 = C:\Program Files (x86)\Intel\EBC\Bin
|
---|
36 |
|
---|
37 |
|
---|
38 | DEFINE GCC48_IA32_PREFIX = @VBOX_PATH_PREFIX_GCC32@
|
---|
39 | DEFINE GCC48_X64_PREFIX = @VBOX_PATH_PREFIX_GCC64@
|
---|
40 |
|
---|
41 | DEFINE UNIX_IASL_BIN = @VBOX_IASLCMD@
|
---|
42 | DEFINE WIN_IASL_BIN = @VBOX_IASLCMD@
|
---|
43 |
|
---|
44 | DEFINE IASL_FLAGS =
|
---|
45 | DEFINE IASL_OUTFLAGS = -p
|
---|
46 |
|
---|
47 | DEFINE DEFAULT_WIN_ASL_BIN = DEF(WIN_IASL_BIN)
|
---|
48 | DEFINE DEFAULT_WIN_ASL_FLAGS = DEF(IASL_FLAGS)
|
---|
49 | DEFINE DEFAULT_WIN_ASL_OUTFLAGS = DEF(IASL_OUTFLAGS)
|
---|
50 |
|
---|
51 | DEFINE MSFT_ASLPP_FLAGS = /nologo /E /C /FIAutoGen.h
|
---|
52 | DEFINE MSFT_ASLCC_FLAGS = /nologo /c /FIAutoGen.h /TC /Dmain=ReferenceAcpiTable
|
---|
53 | DEFINE MSFT_ASLDLINK_FLAGS = /NODEFAULTLIB /ENTRY:ReferenceAcpiTable /SUBSYSTEM:CONSOLE
|
---|
54 |
|
---|
55 | DEFINE DTCPP_BIN = ENV(DTCPP_PREFIX)cpp
|
---|
56 | DEFINE DTC_BIN = ENV(DTC_PREFIX)dtc
|
---|
57 |
|
---|
58 | ####################################################################################
|
---|
59 | #
|
---|
60 | # format: TARGET_TOOLCHAIN_ARCH_COMMANDTYPE_ATTRIBUTE = <string>
|
---|
61 | # priority:
|
---|
62 | # TARGET_TOOLCHAIN_ARCH_COMMANDTYPE_ATTRIBUTE (Highest)
|
---|
63 | # ******_TOOLCHAIN_ARCH_COMMANDTYPE_ATTRIBUTE
|
---|
64 | # TARGET_*********_ARCH_COMMANDTYPE_ATTRIBUTE
|
---|
65 | # ******_*********_ARCH_COMMANDTYPE_ATTRIBUTE
|
---|
66 | # TARGET_TOOLCHAIN_****_COMMANDTYPE_ATTRIBUTE
|
---|
67 | # ******_TOOLCHAIN_****_COMMANDTYPE_ATTRIBUTE
|
---|
68 | # TARGET_*********_****_COMMANDTYPE_ATTRIBUTE
|
---|
69 | # ******_*********_****_COMMANDTYPE_ATTRIBUTE
|
---|
70 | # TARGET_TOOLCHAIN_ARCH_***********_ATTRIBUTE
|
---|
71 | # ******_TOOLCHAIN_ARCH_***********_ATTRIBUTE
|
---|
72 | # TARGET_*********_ARCH_***********_ATTRIBUTE
|
---|
73 | # ******_*********_ARCH_***********_ATTRIBUTE
|
---|
74 | # TARGET_TOOLCHAIN_****_***********_ATTRIBUTE
|
---|
75 | # ******_TOOLCHAIN_****_***********_ATTRIBUTE
|
---|
76 | # TARGET_*********_****_***********_ATTRIBUTE
|
---|
77 | # ******_*********_****_***********_ATTRIBUTE (Lowest)
|
---|
78 | #
|
---|
79 | ####################################################################################
|
---|
80 | ####################################################################################
|
---|
81 | #
|
---|
82 | # Supported Tool Chains
|
---|
83 | # =====================
|
---|
84 | # VS2010 -win32- Requires:
|
---|
85 | # Microsoft Visual Studio 2010 Premium Edition
|
---|
86 | # Microsoft Windows Server 2003 Driver Development Kit (Microsoft WINDDK) version 3790.1830
|
---|
87 | # Optional:
|
---|
88 | # Required to build EBC drivers:
|
---|
89 | # Intel(r) Compiler for Efi Byte Code (Intel(r) EBC Compiler)
|
---|
90 | # Required to build platforms or ACPI tables:
|
---|
91 | # Intel(r) ACPI Compiler (iasl.exe) from
|
---|
92 | # https://acpica.org/downloads
|
---|
93 | # GCC48 -Linux,Windows- Requires:
|
---|
94 | # GCC 4.8 targeting x86_64-linux-gnu, aarch64-linux-gnu, or arm-linux-gnueabi
|
---|
95 | # Optional:
|
---|
96 | # Required to build platforms or ACPI tables:
|
---|
97 | # Intel(r) ACPI Compiler from
|
---|
98 | # https://acpica.org/downloads
|
---|
99 | ####################################################################################
|
---|
100 | ####################################################################################
|
---|
101 | #
|
---|
102 | # Supported Tool Chain Family
|
---|
103 | # ===========================
|
---|
104 | # MSFT - Microsoft
|
---|
105 | # GCC - GNU GCC
|
---|
106 | ####################################################################################
|
---|
107 |
|
---|
108 |
|
---|
109 |
|
---|
110 | ####################################################################################
|
---|
111 | #
|
---|
112 | # Microsoft Visual Studio 2010
|
---|
113 | #
|
---|
114 | # VS2010 - Microsoft Visual Studio 2010 Premium Edition with Intel ASL
|
---|
115 | # ASL - Intel ACPI Source Language Compiler
|
---|
116 | ####################################################################################
|
---|
117 | # VS2010 - Microsoft Visual Studio 2010 Premium Edition
|
---|
118 | *_VS2010_*_*_FAMILY = MSFT
|
---|
119 |
|
---|
120 | *_VS2010_*_MAKE_PATH = DEF(VS2010_BIN)/nmake.exe
|
---|
121 | *_VS2010_*_MAKE_FLAGS = /nologo
|
---|
122 | *_VS2010_*_RC_PATH = rc.exe
|
---|
123 |
|
---|
124 | *_VS2010_*_SLINK_FLAGS = /NOLOGO /LTCG
|
---|
125 | *_VS2010_*_APP_FLAGS = /nologo /E /TC
|
---|
126 | *_VS2010_*_PP_FLAGS = /nologo /E /TC /FIAutoGen.h
|
---|
127 | *_VS2010_*_VFRPP_FLAGS = /nologo /E /TC /DVFRCOMPILE /FI$(MODULE_NAME)StrDefs.h
|
---|
128 |
|
---|
129 | *_VS2010_*_ASM16_PATH = DEF(VS2010_BIN)\ml.exe
|
---|
130 |
|
---|
131 | ##################
|
---|
132 | # ASL definitions
|
---|
133 | ##################
|
---|
134 | *_VS2010_*_ASL_PATH = DEF(DEFAULT_WIN_ASL_BIN)
|
---|
135 | *_VS2010_*_ASL_FLAGS = DEF(DEFAULT_WIN_ASL_FLAGS)
|
---|
136 | *_VS2010_*_ASL_OUTFLAGS = DEF(DEFAULT_WIN_ASL_OUTFLAGS)
|
---|
137 | *_VS2010_*_ASLCC_FLAGS = DEF(MSFT_ASLCC_FLAGS)
|
---|
138 | *_VS2010_*_ASLPP_FLAGS = DEF(MSFT_ASLPP_FLAGS)
|
---|
139 | *_VS2010_*_ASLDLINK_FLAGS = DEF(MSFT_ASLDLINK_FLAGS)
|
---|
140 |
|
---|
141 | ##################
|
---|
142 | # IA32 definitions
|
---|
143 | ##################
|
---|
144 | *_VS2010_IA32_*_DLL = DEF(VS2010_DLL)
|
---|
145 |
|
---|
146 | *_VS2010_IA32_MAKE_PATH = DEF(VS2010_BIN)\nmake.exe
|
---|
147 | *_VS2010_IA32_CC_PATH = DEF(VS2010_BIN)\cl.exe
|
---|
148 | *_VS2010_IA32_VFRPP_PATH = DEF(VS2010_BIN)\cl.exe
|
---|
149 | *_VS2010_IA32_SLINK_PATH = DEF(VS2010_BIN)\lib.exe
|
---|
150 | *_VS2010_IA32_DLINK_PATH = DEF(VS2010_BIN)\link.exe
|
---|
151 | *_VS2010_IA32_APP_PATH = DEF(VS2010_BIN)\cl.exe
|
---|
152 | *_VS2010_IA32_PP_PATH = DEF(VS2010_BIN)\cl.exe
|
---|
153 | *_VS2010_IA32_ASM_PATH = DEF(VS2010_BIN)\ml.exe
|
---|
154 | *_VS2010_IA32_ASLCC_PATH = DEF(VS2010_BIN)\cl.exe
|
---|
155 | *_VS2010_IA32_ASLPP_PATH = DEF(VS2010_BIN)\cl.exe
|
---|
156 | *_VS2010_IA32_ASLDLINK_PATH = DEF(VS2010_BIN)\link.exe
|
---|
157 |
|
---|
158 | *_VS2010_IA32_MAKE_FLAGS = /nologo
|
---|
159 | DEBUG_VS2010_IA32_CC_FLAGS = /nologo /c /WX /GS- /W4 /Gs32768 /D UNICODE /O1b2 /GL /FIAutoGen.h /EHs-c- /GR- /GF /Gy /Z7 /MP
|
---|
160 | RELEASE_VS2010_IA32_CC_FLAGS = /nologo /c /WX /GS- /W4 /Gs32768 /D UNICODE /O1b2 /GL /FIAutoGen.h /EHs-c- /GR- /GF /MP
|
---|
161 | NOOPT_VS2010_IA32_CC_FLAGS = /nologo /c /WX /GS- /W4 /Gs32768 /D UNICODE /FIAutoGen.h /EHs-c- /GR- /GF /Gy /Zi /Gm /Od /MP
|
---|
162 |
|
---|
163 | DEBUG_VS2010_IA32_ASM_FLAGS = /nologo /c /WX /W3 /Cx /coff /Zd /Zi
|
---|
164 | RELEASE_VS2010_IA32_ASM_FLAGS = /nologo /c /WX /W3 /Cx /coff /Zd
|
---|
165 | NOOPT_VS2010_IA32_ASM_FLAGS = /nologo /c /WX /W3 /Cx /coff /Zd /Zi
|
---|
166 |
|
---|
167 | DEBUG_VS2010_IA32_NASM_FLAGS = -Ox -f win32 -g
|
---|
168 | RELEASE_VS2010_IA32_NASM_FLAGS = -Ox -f win32
|
---|
169 | NOOPT_VS2010_IA32_NASM_FLAGS = -O0 -f win32 -g
|
---|
170 |
|
---|
171 | DEBUG_VS2010_IA32_DLINK_FLAGS = /NOLOGO /NODEFAULTLIB /IGNORE:4001 /OPT:REF /OPT:ICF=10 /MAP /ALIGN:32 /SECTION:.xdata,D /SECTION:.pdata,D /MACHINE:X86 /LTCG /DLL /ENTRY:$(IMAGE_ENTRY_POINT) /SUBSYSTEM:EFI_BOOT_SERVICE_DRIVER /SAFESEH:NO /BASE:0 /DRIVER /DEBUG
|
---|
172 | RELEASE_VS2010_IA32_DLINK_FLAGS = /NOLOGO /NODEFAULTLIB /IGNORE:4001 /IGNORE:4254 /OPT:REF /OPT:ICF=10 /MAP /ALIGN:32 /SECTION:.xdata,D /SECTION:.pdata,D /MACHINE:X86 /LTCG /DLL /ENTRY:$(IMAGE_ENTRY_POINT) /SUBSYSTEM:EFI_BOOT_SERVICE_DRIVER /SAFESEH:NO /BASE:0 /DRIVER /MERGE:.rdata=.data /DEBUG
|
---|
173 | NOOPT_VS2010_IA32_DLINK_FLAGS = /NOLOGO /NODEFAULTLIB /IGNORE:4001 /OPT:REF /OPT:ICF=10 /MAP /ALIGN:32 /SECTION:.xdata,D /SECTION:.pdata,D /MACHINE:X86 /LTCG /DLL /ENTRY:$(IMAGE_ENTRY_POINT) /SUBSYSTEM:EFI_BOOT_SERVICE_DRIVER /SAFESEH:NO /BASE:0 /DRIVER /DEBUG
|
---|
174 |
|
---|
175 | ##################
|
---|
176 | # X64 definitions
|
---|
177 | ##################
|
---|
178 | *_VS2010_X64_*_DLL = DEF(VS2010_DLL)
|
---|
179 |
|
---|
180 | *_VS2010_X64_CC_PATH = DEF(VS2010_BINX64)\cl.exe
|
---|
181 | *_VS2010_X64_PP_PATH = DEF(VS2010_BINX64)\cl.exe
|
---|
182 | *_VS2010_X64_APP_PATH = DEF(VS2010_BINX64)\cl.exe
|
---|
183 | *_VS2010_X64_VFRPP_PATH = DEF(VS2010_BINX64)\cl.exe
|
---|
184 | *_VS2010_X64_ASM_PATH = DEF(VS2010_BINX64)\ml64.exe
|
---|
185 | *_VS2010_X64_SLINK_PATH = DEF(VS2010_BINX64)\lib.exe
|
---|
186 | *_VS2010_X64_DLINK_PATH = DEF(VS2010_BINX64)\link.exe
|
---|
187 | *_VS2010_X64_ASLCC_PATH = DEF(VS2010_BINX64)\cl.exe
|
---|
188 | *_VS2010_X64_ASLPP_PATH = DEF(VS2010_BINX64)\cl.exe
|
---|
189 | *_VS2010_X64_ASLDLINK_PATH = DEF(VS2010_BINX64)\link.exe
|
---|
190 |
|
---|
191 | DEBUG_VS2010_X64_CC_FLAGS = /nologo /c /WX /GS- /W4 /Gs32768 /D UNICODE /O1b2s /GL /Gy /FIAutoGen.h /EHs-c- /GR- /GF /Z7 /MP
|
---|
192 | RELEASE_VS2010_X64_CC_FLAGS = /nologo /c /WX /GS- /W4 /Gs32768 /D UNICODE /O1b2s /GL /Gy /FIAutoGen.h /EHs-c- /GR- /GF /MP
|
---|
193 | NOOPT_VS2010_X64_CC_FLAGS = /nologo /c /WX /GS- /W4 /Gs32768 /D UNICODE /Gy /FIAutoGen.h /EHs-c- /GR- /GF /Z7 /Od /MP
|
---|
194 |
|
---|
195 | DEBUG_VS2010_X64_ASM_FLAGS = /nologo /c /WX /W3 /Cx /Zd /Zi
|
---|
196 | RELEASE_VS2010_X64_ASM_FLAGS = /nologo /c /WX /W3 /Cx /Zd
|
---|
197 | NOOPT_VS2010_X64_ASM_FLAGS = /nologo /c /WX /W3 /Cx /Zd /Zi
|
---|
198 |
|
---|
199 | DEBUG_VS2010_X64_NASM_FLAGS = -Ox -f win64 -g
|
---|
200 | RELEASE_VS2010_X64_NASM_FLAGS = -Ox -f win64
|
---|
201 | NOOPT_VS2010_X64_NASM_FLAGS = -O0 -f win64 -g
|
---|
202 |
|
---|
203 | DEBUG_VS2010_X64_DLINK_FLAGS = /NOLOGO /NODEFAULTLIB /IGNORE:4001 /OPT:REF /OPT:ICF=10 /MAP /ALIGN:32 /SECTION:.xdata,D /SECTION:.pdata,D /Machine:X64 /LTCG /DLL /ENTRY:$(IMAGE_ENTRY_POINT) /SUBSYSTEM:EFI_BOOT_SERVICE_DRIVER /SAFESEH:NO /BASE:0 /DRIVER /DEBUG
|
---|
204 | RELEASE_VS2010_X64_DLINK_FLAGS = /NOLOGO /NODEFAULTLIB /IGNORE:4001 /IGNORE:4254 /OPT:REF /OPT:ICF=10 /MAP /ALIGN:32 /SECTION:.xdata,D /SECTION:.pdata,D /Machine:X64 /LTCG /DLL /ENTRY:$(IMAGE_ENTRY_POINT) /SUBSYSTEM:EFI_BOOT_SERVICE_DRIVER /SAFESEH:NO /BASE:0 /DRIVER /MERGE:.rdata=.data /DEBUG
|
---|
205 | NOOPT_VS2010_X64_DLINK_FLAGS = /NOLOGO /NODEFAULTLIB /IGNORE:4001 /OPT:REF /OPT:ICF=10 /MAP /ALIGN:32 /SECTION:.xdata,D /SECTION:.pdata,D /Machine:X64 /LTCG /DLL /ENTRY:$(IMAGE_ENTRY_POINT) /SUBSYSTEM:EFI_BOOT_SERVICE_DRIVER /SAFESEH:NO /BASE:0 /DRIVER /DEBUG
|
---|
206 |
|
---|
207 | ##################
|
---|
208 | # EBC definitions
|
---|
209 | ##################
|
---|
210 | *_VS2010_EBC_*_FAMILY = INTEL
|
---|
211 | *_VS2010_EBC_*_DLL = DEF(VS2010_DLL)
|
---|
212 |
|
---|
213 | *_VS2010_EBC_MAKE_PATH = DEF(VS2010_BIN)\nmake.exe
|
---|
214 | *_VS2010_EBC_PP_PATH = DEF(EBC_BIN)\iec.exe
|
---|
215 | *_VS2010_EBC_VFRPP_PATH = DEF(EBC_BIN)\iec.exe
|
---|
216 | *_VS2010_EBC_CC_PATH = DEF(EBC_BIN)\iec.exe
|
---|
217 | *_VS2010_EBC_SLINK_PATH = DEF(VS2010_BIN)\link.exe
|
---|
218 | *_VS2010_EBC_DLINK_PATH = DEF(VS2010_BIN)\link.exe
|
---|
219 |
|
---|
220 | *_VS2010_EBC_MAKE_FLAGS = /nologo
|
---|
221 | *_VS2010_EBC_PP_FLAGS = /nologo /E /TC /FIAutoGen.h
|
---|
222 | *_VS2010_EBC_CC_FLAGS = /nologo /c /WX /W3 /FIAutoGen.h /D$(MODULE_ENTRY_POINT)=$(ARCH_ENTRY_POINT)
|
---|
223 | *_VS2010_EBC_VFRPP_FLAGS = /nologo /E /TC /DVFRCOMPILE /FI$(MODULE_NAME)StrDefs.h
|
---|
224 | *_VS2010_EBC_SLINK_FLAGS = /lib /NOLOGO /MACHINE:EBC
|
---|
225 | *_VS2010_EBC_DLINK_FLAGS = "C:\Program Files\Intel\EBC\Lib\EbcLib.lib" /NOLOGO /NODEFAULTLIB /MACHINE:EBC /OPT:REF /ENTRY:$(IMAGE_ENTRY_POINT) /SUBSYSTEM:EFI_BOOT_SERVICE_DRIVER /MAP /ALIGN:32 /DRIVER
|
---|
226 |
|
---|
227 |
|
---|
228 | ####################################################################################
|
---|
229 | # GCC Common
|
---|
230 | ####################################################################################
|
---|
231 |
|
---|
232 | *_*_*_OBJCOPY_PATH = echo
|
---|
233 | *_*_*_OBJCOPY_FLAGS = objcopy not needed for
|
---|
234 | *_*_*_SYMRENAME_PATH = echo
|
---|
235 | *_*_*_SYMRENAME_FLAGS = Symbol renaming not needed for
|
---|
236 | DEBUG_*_*_OBJCOPY_ADDDEBUGFLAG = --add-gnu-debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
|
---|
237 | RELEASE_*_*_OBJCOPY_ADDDEBUGFLAG = --add-gnu-debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
|
---|
238 | NOOPT_*_*_OBJCOPY_ADDDEBUGFLAG = --add-gnu-debuglink=$(DEBUG_DIR)/$(MODULE_NAME).debug
|
---|
239 | *_*_*_DTC_FLAGS = -H epapr
|
---|
240 | *_*_*_DTCPP_PATH = DEF(DTCPP_BIN)
|
---|
241 | *_*_*_DTC_PATH = DEF(DTC_BIN)
|
---|
242 |
|
---|
243 | DEFINE GCC_ALL_CC_FLAGS = -g -Os -fshort-wchar -fno-builtin -fno-strict-aliasing -Wall -Wno-array-bounds -include AutoGen.h -fno-common
|
---|
244 | DEFINE GCC_IA32_CC_FLAGS = DEF(GCC_ALL_CC_FLAGS) -m32 -malign-double -freorder-blocks -freorder-blocks-and-partition -O2 -mno-stack-arg-probe @VBOX_MINGW32_Wno@
|
---|
245 | DEFINE GCC_X64_CC_FLAGS = DEF(GCC_ALL_CC_FLAGS) -mno-red-zone -Wno-address -mno-stack-arg-probe @VBOX_MINGW32_Wno@
|
---|
246 | DEFINE GCC_DLINK_FLAGS_COMMON = -nostdlib --pie
|
---|
247 | DEFINE GCC_DLINK2_FLAGS_COMMON = -Wl,--script=$(EDK_TOOLS_PATH)/Scripts/GccBase.lds
|
---|
248 | DEFINE GCC_IA32_X64_DLINK_COMMON = DEF(GCC_DLINK_FLAGS_COMMON) --gc-sections
|
---|
249 | DEFINE GCC_IA32_X64_ASLDLINK_FLAGS = DEF(GCC_IA32_X64_DLINK_COMMON) --entry _ReferenceAcpiTable -u $(IMAGE_ENTRY_POINT)
|
---|
250 | DEFINE GCC_IA32_X64_DLINK_FLAGS = DEF(GCC_IA32_X64_DLINK_COMMON) --entry _$(IMAGE_ENTRY_POINT) --file-alignment 0x20 --section-alignment 0x20 -Map $(DEST_DIR_DEBUG)/$(BASE_NAME).map
|
---|
251 | DEFINE GCC_ASM_FLAGS = -c -x assembler -imacros $(DEST_DIR_DEBUG)/AutoGen.h
|
---|
252 | DEFINE GCC_PP_FLAGS = -E -x assembler-with-cpp -include $(DEST_DIR_DEBUG)/AutoGen.h
|
---|
253 | DEFINE GCC_VFRPP_FLAGS = -x c -E -P -DVFRCOMPILE --include $(DEST_DIR_DEBUG)/$(MODULE_NAME)StrDefs.h
|
---|
254 | DEFINE GCC_ASLPP_FLAGS = -x c -E -include AutoGen.h
|
---|
255 | DEFINE GCC_ASLCC_FLAGS = -x c
|
---|
256 | DEFINE GCC_WINDRES_FLAGS = -J rc -O coff
|
---|
257 | DEFINE GCC_DTCPP_FLAGS = -E -x assembler-with-cpp -imacros $(DEST_DIR_DEBUG)/AutoGen.h -nostdinc -undef
|
---|
258 | DEFINE GCC_IA32_RC_FLAGS = -I binary -O elf32-i386 -B i386 --rename-section .data=.hii
|
---|
259 | DEFINE GCC_X64_RC_FLAGS = -I binary -O elf64-x86-64 -B i386 --rename-section .data=.hii
|
---|
260 |
|
---|
261 | DEFINE GCC48_ALL_CC_FLAGS = -g -fshort-wchar -fno-builtin -fno-strict-aliasing -Wall -Wno-array-bounds -ffunction-sections -fdata-sections -include AutoGen.h -fno-common -DSTRING_ARRAY_NAME=$(BASE_NAME)Strings
|
---|
262 | DEFINE GCC48_IA32_X64_DLINK_COMMON = -nostdlib -Wl,-n,-q,--gc-sections -z common-page-size=0x20
|
---|
263 | DEFINE GCC48_IA32_CC_FLAGS = DEF(GCC48_ALL_CC_FLAGS) -m32 -march=i586 -malign-double -fno-stack-protector -D EFI32 -fno-asynchronous-unwind-tables -Wno-address -fno-pie -fno-pic
|
---|
264 | DEFINE GCC48_X64_CC_FLAGS = DEF(GCC48_ALL_CC_FLAGS) -m64 -fno-stack-protector "-DEFIAPI=__attribute__((ms_abi))" -maccumulate-outgoing-args -mno-red-zone -Wno-address -mcmodel=small -fpie -fno-asynchronous-unwind-tables -Wno-address
|
---|
265 | DEFINE GCC48_IA32_X64_ASLDLINK_FLAGS = DEF(GCC48_IA32_X64_DLINK_COMMON) -Wl,--entry,ReferenceAcpiTable -u ReferenceAcpiTable
|
---|
266 | DEFINE GCC48_IA32_X64_DLINK_FLAGS = DEF(GCC48_IA32_X64_DLINK_COMMON) -Wl,--entry,$(IMAGE_ENTRY_POINT) -u $(IMAGE_ENTRY_POINT) -Wl,-Map,$(DEST_DIR_DEBUG)/$(BASE_NAME).map,--whole-archive
|
---|
267 | DEFINE GCC48_IA32_DLINK2_FLAGS = -Wl,--defsym=PECOFF_HEADER_SIZE=0x220 DEF(GCC_DLINK2_FLAGS_COMMON)
|
---|
268 | DEFINE GCC48_X64_DLINK_FLAGS = DEF(GCC48_IA32_X64_DLINK_FLAGS) -Wl,-melf_x86_64,--oformat=elf64-x86-64,-pie
|
---|
269 | DEFINE GCC48_X64_DLINK2_FLAGS = -Wl,--defsym=PECOFF_HEADER_SIZE=0x228 DEF(GCC_DLINK2_FLAGS_COMMON)
|
---|
270 | DEFINE GCC48_ASM_FLAGS = DEF(GCC_ASM_FLAGS)
|
---|
271 | DEFINE GCC48_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
|
---|
272 |
|
---|
273 | ####################################################################################
|
---|
274 | #
|
---|
275 | # GCC 4.8 - This configuration is used to compile under Linux to produce
|
---|
276 | # PE/COFF binaries using GCC 4.8.
|
---|
277 | #
|
---|
278 | ####################################################################################
|
---|
279 | *_GCC48_*_*_FAMILY = GCC
|
---|
280 |
|
---|
281 | *_GCC48_*_MAKE_PATH = @KMK@
|
---|
282 | *_GCC48_*_*_DLL = ENV(GCC48_DLL)
|
---|
283 | *_GCC48_*_ASL_PATH = DEF(UNIX_IASL_BIN)
|
---|
284 |
|
---|
285 | *_GCC48_*_PP_FLAGS = DEF(GCC_PP_FLAGS)
|
---|
286 | *_GCC48_*_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS)
|
---|
287 | *_GCC48_*_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
|
---|
288 | *_GCC48_*_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS)
|
---|
289 | *_GCC48_*_APP_FLAGS =
|
---|
290 | *_GCC48_*_ASL_FLAGS = DEF(IASL_FLAGS)
|
---|
291 | *_GCC48_*_ASL_OUTFLAGS = DEF(IASL_OUTFLAGS)
|
---|
292 |
|
---|
293 | ##################
|
---|
294 | # GCC48 IA32 definitions
|
---|
295 | ##################
|
---|
296 | *_GCC48_IA32_OBJCOPY_PATH = DEF(GCC48_IA32_PREFIX)objcopy
|
---|
297 | *_GCC48_IA32_CC_PATH = DEF(GCC48_IA32_PREFIX)gcc
|
---|
298 | *_GCC48_IA32_SLINK_PATH = DEF(GCC48_IA32_PREFIX)ar
|
---|
299 | *_GCC48_IA32_DLINK_PATH = DEF(GCC48_IA32_PREFIX)gcc
|
---|
300 | *_GCC48_IA32_ASLDLINK_PATH = DEF(GCC48_IA32_PREFIX)gcc
|
---|
301 | *_GCC48_IA32_ASM_PATH = DEF(GCC48_IA32_PREFIX)gcc
|
---|
302 | *_GCC48_IA32_PP_PATH = DEF(GCC48_IA32_PREFIX)gcc
|
---|
303 | *_GCC48_IA32_VFRPP_PATH = DEF(GCC48_IA32_PREFIX)gcc
|
---|
304 | *_GCC48_IA32_ASLCC_PATH = DEF(GCC48_IA32_PREFIX)gcc
|
---|
305 | *_GCC48_IA32_ASLPP_PATH = DEF(GCC48_IA32_PREFIX)gcc
|
---|
306 | *_GCC48_IA32_RC_PATH = DEF(GCC48_IA32_PREFIX)objcopy
|
---|
307 |
|
---|
308 | *_GCC48_IA32_ASLCC_FLAGS = DEF(GCC48_ASLCC_FLAGS) -m32
|
---|
309 | *_GCC48_IA32_ASLDLINK_FLAGS = DEF(GCC48_IA32_X64_ASLDLINK_FLAGS) -Wl,-m,elf_i386
|
---|
310 | *_GCC48_IA32_ASM_FLAGS = DEF(GCC48_ASM_FLAGS) -m32 -march=i386
|
---|
311 | *_GCC48_IA32_DLINK_FLAGS = DEF(GCC48_IA32_X64_DLINK_FLAGS) -Wl,-m,elf_i386,--oformat=elf32-i386
|
---|
312 | *_GCC48_IA32_DLINK2_FLAGS = DEF(GCC48_IA32_DLINK2_FLAGS)
|
---|
313 | *_GCC48_IA32_RC_FLAGS = DEF(GCC_IA32_RC_FLAGS)
|
---|
314 | *_GCC48_IA32_OBJCOPY_FLAGS =
|
---|
315 | *_GCC48_IA32_NASM_FLAGS = -f elf32
|
---|
316 |
|
---|
317 | DEBUG_GCC48_IA32_CC_FLAGS = DEF(GCC48_IA32_CC_FLAGS) -Os
|
---|
318 | RELEASE_GCC48_IA32_CC_FLAGS = DEF(GCC48_IA32_CC_FLAGS) -Os -Wno-unused-but-set-variable
|
---|
319 | NOOPT_GCC48_IA32_CC_FLAGS = DEF(GCC48_IA32_CC_FLAGS) -O0
|
---|
320 |
|
---|
321 | ##################
|
---|
322 | # GCC48 X64 definitions
|
---|
323 | ##################
|
---|
324 | *_GCC48_X64_OBJCOPY_PATH = DEF(GCC48_X64_PREFIX)objcopy
|
---|
325 | *_GCC48_X64_CC_PATH = DEF(GCC48_X64_PREFIX)gcc
|
---|
326 | *_GCC48_X64_SLINK_PATH = DEF(GCC48_X64_PREFIX)ar
|
---|
327 | *_GCC48_X64_DLINK_PATH = DEF(GCC48_X64_PREFIX)gcc
|
---|
328 | *_GCC48_X64_ASLDLINK_PATH = DEF(GCC48_X64_PREFIX)gcc
|
---|
329 | *_GCC48_X64_ASM_PATH = DEF(GCC48_X64_PREFIX)gcc
|
---|
330 | *_GCC48_X64_PP_PATH = DEF(GCC48_X64_PREFIX)gcc
|
---|
331 | *_GCC48_X64_VFRPP_PATH = DEF(GCC48_X64_PREFIX)gcc
|
---|
332 | *_GCC48_X64_ASLCC_PATH = DEF(GCC48_X64_PREFIX)gcc
|
---|
333 | *_GCC48_X64_ASLPP_PATH = DEF(GCC48_X64_PREFIX)gcc
|
---|
334 | *_GCC48_X64_RC_PATH = DEF(GCC48_X64_PREFIX)objcopy
|
---|
335 |
|
---|
336 | *_GCC48_X64_ASLCC_FLAGS = DEF(GCC48_ASLCC_FLAGS) -m64
|
---|
337 | *_GCC48_X64_ASLDLINK_FLAGS = DEF(GCC48_IA32_X64_ASLDLINK_FLAGS) -Wl,-m,elf_x86_64
|
---|
338 | *_GCC48_X64_ASM_FLAGS = DEF(GCC48_ASM_FLAGS) -m64
|
---|
339 | *_GCC48_X64_DLINK_FLAGS = DEF(GCC48_X64_DLINK_FLAGS)
|
---|
340 | *_GCC48_X64_DLINK2_FLAGS = DEF(GCC48_X64_DLINK2_FLAGS)
|
---|
341 | *_GCC48_X64_RC_FLAGS = DEF(GCC_X64_RC_FLAGS)
|
---|
342 | *_GCC48_X64_OBJCOPY_FLAGS =
|
---|
343 | *_GCC48_X64_NASM_FLAGS = -f elf64
|
---|
344 |
|
---|
345 | DEBUG_GCC48_X64_CC_FLAGS = DEF(GCC48_X64_CC_FLAGS) -Os
|
---|
346 | RELEASE_GCC48_X64_CC_FLAGS = DEF(GCC48_X64_CC_FLAGS) -Os -Wno-unused-but-set-variable
|
---|
347 | NOOPT_GCC48_X64_CC_FLAGS = DEF(GCC48_X64_CC_FLAGS) -O0
|
---|
348 |
|
---|
349 | #################
|
---|
350 | # ASM 16 linker definitions
|
---|
351 | #################
|
---|
352 | *_*_*_ASMLINK_PATH = DEF(WINDDK_BIN16)\link16.exe
|
---|
353 | *_*_*_ASMLINK_FLAGS = /nologo /tiny
|
---|
354 |
|
---|
355 | ##################
|
---|
356 | # VfrCompiler definitions
|
---|
357 | ##################
|
---|
358 | *_*_*_VFR_PATH = VfrCompile
|
---|
359 | *_*_*_VFR_FLAGS = -l -n
|
---|
360 |
|
---|
361 | ##################
|
---|
362 | # OptionRom tool definitions
|
---|
363 | ##################
|
---|
364 | *_*_*_OPTROM_PATH = EfiRom
|
---|
365 | *_*_*_OPTROM_FLAGS = -e
|
---|
366 |
|
---|
367 | ##################
|
---|
368 | # GenFw tool definitions
|
---|
369 | ##################
|
---|
370 | *_*_*_GENFW_PATH = GenFw
|
---|
371 | *_*_*_GENFW_FLAGS =
|
---|
372 |
|
---|
373 | ##################
|
---|
374 | # Asl Compiler definitions
|
---|
375 | ##################
|
---|
376 | *_*_*_ASLCC_FLAGS = /nologo /c /FIAutoGen.h /TC /Dmain=ReferenceAcpiTable
|
---|
377 | *_*_*_ASLDLINK_FLAGS = /NODEFAULTLIB /ENTRY:ReferenceAcpiTable /SUBSYSTEM:CONSOLE
|
---|
378 | *_*_*_ASLPP_FLAGS = /nologo /EP /C
|
---|
379 | *_*_*_ASL_FLAGS =
|
---|
380 |
|
---|
381 | ##################
|
---|
382 | # GenCrc32 tool definitions
|
---|
383 | ##################
|
---|
384 | *_*_*_CRC32_PATH = GenCrc32
|
---|
385 | *_*_*_CRC32_GUID = FC1BCDB0-7D31-49AA-936A-A4600D9DD083
|
---|
386 |
|
---|
387 | ##################
|
---|
388 | # Rsa2048Sha256Sign tool definitions
|
---|
389 | #
|
---|
390 | # Notes: This tool definition uses a test signing key for development purposes only.
|
---|
391 | # The tool Rsa2048Sha256GenerateKeys can be used to generate a new private/public key
|
---|
392 | # and the gEfiSecurityPkgTokenSpaceGuid.PcdRsa2048Sha256PublicKeyBuffer PCD value.
|
---|
393 | # A custom tool/script can be implemented using the new private/public key with
|
---|
394 | # the Rsa2048Sha256Sign tool and this tool definition can be updated to use a
|
---|
395 | # custom tool/script.
|
---|
396 | #
|
---|
397 | # Generate new private/public key and gEfiSecurityPkgTokenSpaceGuid.PcdRsa2048Sha256PublicKeyBuffer PCD value
|
---|
398 | #
|
---|
399 | # Rsa2048Sha256GenerateKeys.py -o MyKey.pem --public-key-hash-c MyKey.pcd
|
---|
400 | #
|
---|
401 | # Custom script example (MyRsa2048Sha256Sign.cmd):
|
---|
402 | #
|
---|
403 | # Rsa2048Sha256Sign --private-key MyKey.pem %1 %2 %3 %4 %5 %6 %7 %8 %9
|
---|
404 | #
|
---|
405 | # WARNING: Vendors that uses private keys are responsible for proper management and protection
|
---|
406 | # of private keys. Vendors may choose to use infrastructure such as signing servers
|
---|
407 | # or signing portals to support the management and protection of private keys.
|
---|
408 | #
|
---|
409 | ##################
|
---|
410 | *_*_*_RSA2048SHA256SIGN_PATH = Rsa2048Sha256Sign
|
---|
411 | *_*_*_RSA2048SHA256SIGN_GUID = A7717414-C616-4977-9420-844712A735BF
|
---|
412 |
|
---|
413 | ##################
|
---|
414 | # BrotliCompress tool definitions
|
---|
415 | ##################
|
---|
416 | *_*_*_BROTLI_PATH = BrotliCompress
|
---|
417 | *_*_*_BROTLI_GUID = 3D532050-5CDA-4FD0-879E-0F7F630D5AFB
|
---|
418 |
|
---|
419 | ##################
|
---|
420 | # LzmaCompress tool definitions
|
---|
421 | ##################
|
---|
422 | *_*_*_LZMA_PATH = LzmaCompress
|
---|
423 | *_*_*_LZMA_GUID = EE4E5898-3914-4259-9D6E-DC7BD79403CF
|
---|
424 |
|
---|
425 | ##################
|
---|
426 | # LzmaF86Compress tool definitions with converter for x86 code.
|
---|
427 | # It can improve the compression ratio if the input file is IA32 or X64 PE image.
|
---|
428 | ##################
|
---|
429 | *_*_*_LZMAF86_PATH = LzmaF86Compress
|
---|
430 | *_*_*_LZMAF86_GUID = D42AE6BD-1352-4bfb-909A-CA72A6EAE889
|
---|
431 |
|
---|
432 | ##################
|
---|
433 | # TianoCompress tool definitions
|
---|
434 | ##################
|
---|
435 | *_*_*_TIANO_PATH = TianoCompress
|
---|
436 | *_*_*_TIANO_GUID = A31280AD-481E-41B6-95E8-127F4C984779
|
---|
437 |
|
---|
438 | ##################
|
---|
439 | # BPDG tool definitions
|
---|
440 | ##################
|
---|
441 | *_*_*_VPDTOOL_PATH = BPDG
|
---|
442 | *_*_*_VPDTOOL_GUID = 8C3D856A-9BE6-468E-850A-24F7A8D38E08
|
---|
443 |
|
---|
444 | ##################
|
---|
445 | # Pkcs7Sign tool definitions
|
---|
446 | ##################
|
---|
447 | *_*_*_PKCS7SIGN_PATH = Pkcs7Sign
|
---|
448 | *_*_*_PKCS7SIGN_GUID = 4AAFD29D-68DF-49EE-8AA9-347D375665A7
|
---|
449 |
|
---|
450 | ##################
|
---|
451 | # NASM tool definitions
|
---|
452 | ##################
|
---|
453 | *_*_*_NASM_PATH = @VBOX_NASMCMD@
|
---|
454 | # NASMB uses NASM produce a .bin from a .nasmb NASM source file
|
---|
455 | *_*_*_NASMB_FLAGS = -f bin -DVBOX
|
---|
456 |
|
---|
457 | #################
|
---|
458 | # Build rule order
|
---|
459 | #################
|
---|
460 | *_*_*_*_BUILDRULEORDER = nasm asm Asm ASM S s nasmb asm16
|
---|