1#/*++
2#
3# Copyright (c) 2004 - 2007, Intel Corporation. All rights reserved.<BR>
4# This program and the accompanying materials
5# are licensed and made available under the terms and conditions of the BSD License
6# which accompanies this distribution.  The full text of the license may be found at
7# http://opensource.org/licenses/bsd-license.php
8#
9# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
11#
12#  Module Name:
13#
14#   CommonIpf.dsc
15#
16#  Abstract:
17#
18#    This is the build description file containing the processor architecture
19#    dependent build instructions.
20#
21#  Notes:
22#
23#    The info in this file is broken down into sections. The start of a section
24#    is designated by a "[" in the first column. So the [=====] separater ends
25#    a section.
26#
27#--*/
28
29
30[=============================================================================]
31#
32# These are the package descriptions. They are tagged as
33# [Package.$(COMPONENT_TYPE).$(PACKAGE)], where COMPONENT_TYPE is typically
34# defined in the component INF file, and PACKAGE is typically specified
35# in the components section in the main DSC file. Main DSC file can also define
36# platform specific package descriptions.
37#
38
39[=============================================================================]
40[Package.APPLICATION.Default]
41PACKAGE.INF
42\[.]
43BASE_NAME                   = $(BASE_NAME)
44FFS_FILEGUID                = $(FILE_GUID)
45FFS_FILETYPE                = EFI_FV_FILETYPE_APPLICATION
46FFS_ATTRIB_CHECKSUM         = TRUE
47
48IMAGE_SCRIPT =
49{
50  Compress ($(COMPRESS_METHOD)) {
51    Tool (
52      $(OEMTOOLPATH)\GenCRC32Section
53      ARGS= -i $(DEST_DIR)\$(BASE_NAME).pe32
54               $(DEST_DIR)\$(BASE_NAME).ui
55               $(DEST_DIR)\$(BASE_NAME).ver
56            -o $(DEST_DIR)\$(BASE_NAME).crc32
57      OUTPUT = $(DEST_DIR)\$(BASE_NAME).crc32
58    )
59  }
60}
61
62[=============================================================================]
63[Package.Apriori.Default,Package.FILE.Default]
64PACKAGE.INF
65\[.]
66BASE_NAME                   = $(BASE_NAME)
67FFS_FILEGUID                = $(FILE_GUID)
68FFS_FILETYPE                = EFI_FV_FILETYPE_FREEFORM
69FFS_ATTRIB_CHECKSUM         = TRUE
70
71IMAGE_SCRIPT =
72{
73  $(BASE_NAME).sec
74}
75
76[=============================================================================]
77[Package.RAWFILE.Default,Package.Config.Default|Config]
78PACKAGE.INF
79\[.]
80BASE_NAME                   = $(BASE_NAME)
81FFS_FILEGUID                = $(FILE_GUID)
82FFS_FILETYPE                = EFI_FV_FILETYPE_RAW
83FFS_ATTRIB_CHECKSUM         = TRUE
84
85IMAGE_SCRIPT =
86{
87  $(BASE_NAME).Bin
88}
89
90[=============================================================================]
91[Package.BINARY.Default,Package.Legacy16.Default,Package.Logo.Default|Logo]
92PACKAGE.INF
93\[.]
94BASE_NAME                   = $(BASE_NAME)
95FFS_FILEGUID                = $(FILE_GUID)
96FFS_FILETYPE                = EFI_FV_FILETYPE_FREEFORM
97FFS_ATTRIB_CHECKSUM         = TRUE
98
99IMAGE_SCRIPT =
100{
101  Compress ($(COMPRESS_METHOD)) {
102    Tool ( $(OEMTOOLPATH)\GenCRC32Section
103      ARGS = -i $(DEST_DIR)\$(BASE_NAME).sec
104             -o $(DEST_DIR)\$(BASE_NAME).crc32
105      OUTPUT = $(DEST_DIR)\$(BASE_NAME).crc32
106    )
107  }
108}
109
110[=============================================================================]
111#
112# Package definition for TE files
113#
114[Package.PE32_PEIM.TE_PEIM]
115PACKAGE.INF
116\[.]
117BASE_NAME                   = $(BASE_NAME)
118FFS_FILEGUID                = $(FILE_GUID)
119FFS_FILETYPE                = EFI_FV_FILETYPE_PEIM
120FFS_ATTRIB_CHECKSUM         = TRUE
121
122IMAGE_SCRIPT =
123{
124  $(BASE_NAME).dpx
125  $(BASE_NAME).tes
126  $(BASE_NAME).ui
127  $(BASE_NAME).ver
128}
129
130[=============================================================================]
131#
132# Package definition to put the IFR data in a separate section in the
133# FFS file.
134#
135[Package.BS_DRIVER.Ifr_Bin]
136PACKAGE.INF
137\[.]
138BASE_NAME                   = $(BASE_NAME)
139FFS_FILEGUID                = $(FILE_GUID)
140FFS_FILETYPE                = EFI_FV_FILETYPE_DRIVER
141FFS_ATTRIB_CHECKSUM         = TRUE
142
143IMAGE_SCRIPT =
144{
145  Compress ($(COMPRESS_METHOD)) {
146    Tool (
147      $(OEMTOOLPATH)\GenCRC32Section
148      ARGS= -i $(DEST_DIR)\$(BASE_NAME).dpx
149               $(DEST_DIR)\$(BASE_NAME).pe32
150               $(DEST_DIR)\$(BASE_NAME).ui
151               $(DEST_DIR)\$(BASE_NAME).ver
152               $(DEST_DIR)\$(BASE_NAME)IfrBin.sec
153            -o $(DEST_DIR)\$(BASE_NAME).crc32
154      OUTPUT = $(DEST_DIR)\$(BASE_NAME).crc32
155    )
156  }
157}
158
159[=============================================================================]
160[Package.SECURITY_CORE.Default]
161PACKAGE.INF
162\[.]
163BASE_NAME                   = $(BASE_NAME)
164FFS_FILEGUID                = $(FILE_GUID)
165FFS_FILETYPE                = EFI_FV_FILETYPE_SECURITY_CORE
166FFS_ATTRIB_CHECKSUM         = TRUE
167FFS_ALIGNMENT               = 0x1
168
169IMAGE_SCRIPT =
170{          \
171  Blank.pad \
172  $(BASE_NAME).pe32 \
173  $(BASE_NAME).ui \
174  $(BASE_NAME).ver \
175}
176
177[=============================================================================]
178[Package.PEI_CORE.Default]
179PACKAGE.INF
180\[.]
181BASE_NAME                   = $(BASE_NAME)
182FFS_FILEGUID                = $(FILE_GUID)
183FFS_FILETYPE                = EFI_FV_FILETYPE_PEI_CORE
184FFS_ATTRIB_CHECKSUM         = TRUE
185FFS_ALIGNMENT               = 0x1
186
187IMAGE_SCRIPT =
188{          \
189  Blank.pad \
190  $(BASE_NAME).pe32 \
191  $(BASE_NAME).ui \
192  $(BASE_NAME).ver \
193}
194
195[=============================================================================]
196[Package.PE32_PEIM.Default]
197PACKAGE.INF
198\[.]
199BASE_NAME                   = $(BASE_NAME)
200FFS_FILEGUID                = $(FILE_GUID)
201FFS_FILETYPE                = EFI_FV_FILETYPE_PEIM
202FFS_ATTRIB_CHECKSUM         = TRUE
203FFS_ALIGNMENT               = 0x1
204
205IMAGE_SCRIPT =
206{ \
207  Blank.pad \
208  $(BASE_NAME).pe32 \
209  $(BASE_NAME).dpx \
210  $(BASE_NAME).ui \
211  $(BASE_NAME).ver \
212}
213
214[=============================================================================]
215[Package.PE32_PEIM.CompressPEIM]
216PACKAGE.INF
217\[.]
218BASE_NAME                   = $(BASE_NAME)
219FFS_FILEGUID                = $(FILE_GUID)
220FFS_FILETYPE                = EFI_FV_FILETYPE_PEIM
221FFS_ATTRIB_CHECKSUM         = TRUE
222
223IMAGE_SCRIPT =
224{
225  $(BASE_NAME).dpx
226  Compress ($(COMPRESS_METHOD)) {
227    $(BASE_NAME).pe32
228    $(BASE_NAME).ui
229    $(BASE_NAME).ver
230  }
231}
232
233[=============================================================================]
234[Package.COMBINED_PEIM_DRIVER.Default]
235PACKAGE.INF
236\[.]
237BASE_NAME                   = $(BASE_NAME)
238FFS_FILEGUID                = $(FILE_GUID)
239FFS_FILETYPE                = EFI_FV_FILETYPE_COMBINED_PEIM_DRIVER
240FFS_ATTRIB_CHECKSUM         = TRUE
241FFS_ALIGNMENT               = 0x1
242
243IMAGE_SCRIPT =
244{ \
245  Blank.pad \
246  $(BASE_NAME).pe32 \
247  $(BASE_NAME).dpx \
248  $(BASE_NAME).dpxd \
249  $(BASE_NAME).ui \
250  $(BASE_NAME).ver \
251}
252
253[=============================================================================]
254[Package.PIC_PEIM.Default]
255PACKAGE.INF
256\[.]
257BASE_NAME                   = $(BASE_NAME)
258FFS_FILEGUID                = $(FILE_GUID)
259FFS_FILETYPE                = EFI_FV_FILETYPE_PEIM
260FFS_ATTRIB_CHECKSUM         = TRUE
261FFS_ALIGNMENT               = 0x1
262
263IMAGE_SCRIPT =
264{ \
265  Blank.pad \
266  $(BASE_NAME).dpx \
267  $(BASE_NAME).pic \
268  $(BASE_NAME).ui \
269  $(BASE_NAME).ver \
270}
271
272[=============================================================================]
273[Package.DxeIplPad.Default]
274PACKAGE.INF
275\[.]
276BASE_NAME                   = $(BASE_NAME)
277FFS_FILEGUID                = $(FILE_GUID)
278FFS_FILETYPE                = EFI_FV_FILETYPE_RAW
279FFS_ATTRIB_CHECKSUM         = TRUE
280FFS_ALIGNMENT               = 0x7
281
282IMAGE_SCRIPT =
283{ \
284  $(BASE_NAME).pad \
285}
286
287[=============================================================================]
288[Package.BS_DRIVER.DxeMain]
289PACKAGE.INF
290\[.]
291BASE_NAME                   = $(BASE_NAME)
292FFS_FILEGUID                = $(FILE_GUID)
293FFS_FILETYPE                = EFI_FV_FILETYPE_DXE_CORE
294FFS_ATTRIB_CHECKSUM         = TRUE
295
296IMAGE_SCRIPT =
297{
298  Compress ($(COMPRESS_METHOD)) {
299    $(BASE_NAME).pe32
300    $(BASE_NAME).ui
301    $(BASE_NAME).ver
302  }
303}
304
305[=============================================================================]
306[Package.BS_DRIVER.Default,Package.RT_DRIVER.Default,Package.SAL_RT_DRIVER.Default]
307PACKAGE.INF
308\[.]
309BASE_NAME                   = $(BASE_NAME)
310FFS_FILEGUID                = $(FILE_GUID)
311FFS_FILETYPE                = EFI_FV_FILETYPE_DRIVER
312FFS_ATTRIB_CHECKSUM         = TRUE
313
314IMAGE_SCRIPT =
315{
316  Compress ($(COMPRESS_METHOD)) {
317    Tool (
318      $(OEMTOOLPATH)\GenCRC32Section
319      ARGS= -i $(DEST_DIR)\$(BASE_NAME).dpx
320               $(DEST_DIR)\$(BASE_NAME).pe32
321               $(DEST_DIR)\$(BASE_NAME).ui
322               $(DEST_DIR)\$(BASE_NAME).ver
323            -o $(DEST_DIR)\$(BASE_NAME).crc32
324      OUTPUT = $(DEST_DIR)\$(BASE_NAME).crc32
325    )
326  }
327}
328
329[=============================================================================]
330[Package.FvImageFile.Default]
331PACKAGE.INF
332\[.]
333BASE_NAME                   = $(BASE_NAME)
334FFS_FILEGUID                = $(FILE_GUID)
335FFS_FILETYPE                = EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE
336FFS_ATTRIB_CHECKSUM         = TRUE
337
338IMAGE_SCRIPT =
339{
340  Compress ($(COMPRESS_METHOD)) {
341    Tool (
342      $(OEMTOOLPATH)\GenCRC32Section
343      ARGS= -i $(DEST_DIR)\$(SOURCE_FV)Fv.sec
344            -o $(DEST_DIR)\$(BASE_NAME)fv.crc32
345      OUTPUT = $(DEST_DIR)\$(BASE_NAME)fv.crc32
346    )
347  }
348}
349
350[=============================================================================]
351#
352# Define a package that "signs" our capsule cargo FV
353#
354[Package.FvImageFile.SignedFVPackage]
355PACKAGE.INF
356\[.]
357BASE_NAME                   = $(BASE_NAME)
358FFS_FILEGUID                = $(FILE_GUID)
359FFS_FILETYPE                = EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE
360FFS_ATTRIB_CHECKSUM         = TRUE
361
362IMAGE_SCRIPT =
363{
364    Tool (
365      $(OEMTOOLPATH)\GenCRC32Section
366      ARGS= -i $(DEST_DIR)\$(SOURCE_FV)Fv.sec
367            -o $(DEST_DIR)\$(BASE_NAME).crc32
368      OUTPUT = $(DEST_DIR)\$(BASE_NAME).crc32
369    )
370}
371
372[=============================================================================]
373[Package.FvImageFile.FvMainCompact]
374PACKAGE.INF
375\[.]
376BASE_NAME                   = $(BASE_NAME)
377FFS_FILEGUID                = $(FILE_GUID)
378FFS_FILETYPE                = EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE
379FFS_ATTRIB_CHECKSUM         = TRUE
380
381IMAGE_SCRIPT =
382{
383  Compress ($(COMPRESS_METHOD)) {
384    Blank.pad
385    $(SOURCE_FV)Fv.sec
386  }
387}
388
389[=============================================================================]
390[Package.AcpiTable.Default]
391PACKAGE.INF
392\[.]
393BASE_NAME                   = $(BASE_NAME)
394FFS_FILEGUID                = $(FILE_GUID)
395FFS_FILETYPE                = EFI_FV_FILETYPE_FREEFORM
396FFS_ATTRIB_CHECKSUM         = TRUE
397
398IMAGE_SCRIPT =
399{
400  Compress ($(COMPRESS_METHOD)) {
401    Tool (
402      $(OEMTOOLPATH)\GenCRC32Section
403      ARGS= -i $(SECTION_TARGETS)
404               $(DEST_DIR)\$(BASE_NAME).ui
405            -o $(DEST_DIR)\$(BASE_NAME).crc32
406      OUTPUT = $(DEST_DIR)\$(BASE_NAME).crc32
407    )
408  }
409}
410
411[=============================================================================]
412