summaryrefslogtreecommitdiffstats
path: root/BaseTools/Conf/XMLSchema/WorkspaceContent.xsd
blob: 8809792ac48e432059d324fa53cb18bbcb47dc92 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
<?xml version="1.0" encoding="UTF-8"?>
<!--
    Filename: WorkspaceContent.xsd
    
    Copyright (c) 2008, Intel Corp.  All rights reserved.
    
    This program and the accompanying materials are licensed and made available 
    under the terms and conditions of the BSD License which may be found at 
    http://opensource.org/licenses/bsd-license.php
    
    THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    
-->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
	elementFormDefault="qualified"
	targetNamespace="http://edk2.TianoCore.org/2008/1.0"
	xmlns="http://edk2.TianoCore.org/2008/1.0">
	<xs:annotation>
		<xs:documentation xml:lang="en-us">This document covers the
			WorkspaceContent.xml file that tracks what has been installed into an EDK
			II development WORKSPACE.</xs:documentation>
	</xs:annotation>
	<xs:element name="WorkspaceContent">
		<xs:annotation>
			<xs:documentation xml:lang="en-us"> This file describes the distributions,
				packages, stand-alone (non-package) modules and miscellaneous files that
				have been installed in THIS WORKSPACE. Additionally, any tools that are
				installed as part of a distribution are tracked (tools are not required
				to be installed within a WORKSPACE.) </xs:documentation>
		</xs:annotation>
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="Header" minOccurs="1" maxOccurs="1">
					<xs:annotation>
						<xs:documentation xml:lang="en-us"> This section tracks required
							information about this WORKSPACE. </xs:documentation>
					</xs:annotation>
				</xs:element>
				<xs:element ref="DistributionPackage" minOccurs="1"
					maxOccurs="unbounded">
					<xs:annotation>
						<xs:documentation xml:lang="en-us"> The list of UEFI/PI distribution
							packages that have been installed in this WORKSPACE.
						</xs:documentation>
					</xs:annotation>
				</xs:element>
			</xs:sequence>
		</xs:complexType>
	</xs:element>

	<xs:element name="Header">
		<xs:complexType>
			<xs:sequence>
				<xs:element minOccurs="0" maxOccurs="1" name="Name"
					type="xs:normalizedString">
					<xs:annotation>
						<xs:documentation xml:lang="en-us"> This User Interface Name can be
							entered during initialization of a WORKSPACE to permit a developer
							to uniquely identify a WORKSPACE. </xs:documentation>
						<xs:documentation xml:lang="en-us"> This value can be used by report
							generators. </xs:documentation>
					</xs:annotation>
				</xs:element>
				<xs:element minOccurs="1" maxOccurs="1" name="AbsolutePath"
					type="xs:anyURI">
					<xs:annotation>
						<xs:documentation xml:lang="en-us"> When the WORKSPACE is first
							initialized, this is the absolute path to the WORKSPACE. If the
							user moves or re-names the directory, the RmPkg tool will need to
							verify the content of this WORKSPACE before removing any content.
						</xs:documentation>
					</xs:annotation>
				</xs:element>
				<xs:element minOccurs="1" maxOccurs="1" name="LastModifiedDate"
					type="xs:dateTime">
					<xs:annotation>
						<xs:documentation xml:lang="en-us"> The date and time of the last
							Package Installation or Removal. The format is:
							YYYY-MM-DDThh:mm:ss, for example: 2001-01-31T13:30:00 (note the T
							character separator between the calendar date and the time.
						</xs:documentation>
					</xs:annotation>
				</xs:element>
				<xs:element minOccurs="1" maxOccurs="1"
					name="WorkspaceContentSpecification" default="1.0" type="xs:decimal"
				 />
			</xs:sequence>
		</xs:complexType>
	</xs:element>



	<xs:element name="ModuleList">
		<xs:complexType>
			<xs:sequence>
				<xs:element minOccurs="1" maxOccurs="unbounded" name="Module">
					<xs:complexType>
						<xs:sequence>
							<xs:element name="Name" minOccurs="1" maxOccurs="1">
								<xs:annotation>
									<xs:documentation xml:lang="en-us"> The User Interface Name of
										the module. </xs:documentation>
								</xs:annotation>
								<xs:complexType>
									<xs:simpleContent>
										<xs:extension base="xs:normalizedString">
											<xs:attribute name="BaseName" type="xs:NCName"
												use="required">
												<xs:annotation>
													<xs:documentation xml:lang="en-us"> The BaseName is
														used to create files and folders during a build, and
														is used by packaging tools as a keyword to create
														the INF file. </xs:documentation>
												</xs:annotation>
											</xs:attribute>
										</xs:extension>
									</xs:simpleContent>
								</xs:complexType>
							</xs:element>
							<xs:element ref="GUID" minOccurs="1" maxOccurs="1">
								<xs:annotation>
									<xs:documentation xml:lang="en-us"> This is the GUID of the
										module. Backward compatible versions of a module can use the
										same GUID, however the version attribute must be changed
										(incrementally.) Non-backward compatible versions of a
										module must also provide a new GUID, while resetting the
										version attribute is optional. </xs:documentation>
								</xs:annotation>
							</xs:element>
							<xs:element name="InstalledFolder" minOccurs="1" maxOccurs="1"
								type="xs:anyURI">
								<xs:annotation>
									<xs:documentation xml:lang="en-us"> This is the WORKSPACE
										relative path that the Module was installed in.
									</xs:documentation>
								</xs:annotation>
							</xs:element>
							<xs:element name="InfFilename" minOccurs="1" maxOccurs="1"
								type="xs:anyURI">
								<xs:annotation>
									<xs:documentation xml:lang="en-us"> This is filename of the
										INF file created in the InstalledFolder (listed above)
										during installation. </xs:documentation>
								</xs:annotation>
							</xs:element>
						</xs:sequence>
					</xs:complexType>
				</xs:element>
			</xs:sequence>
		</xs:complexType>
	</xs:element>

	<xs:element name="DistributionPackage">
		<xs:complexType>
			<xs:sequence>
				<xs:element minOccurs="1" maxOccurs="1" name="Name">
					<xs:annotation>
						<xs:documentation xml:lang="en-us"> The User Interface Name of the
							distribution. </xs:documentation>
					</xs:annotation>
					<xs:complexType>
						<xs:simpleContent>
							<xs:extension base="xs:normalizedString">
								<xs:attribute name="BaseName" type="xs:NCName" use="required">
									<xs:annotation>
										<xs:documentation xml:lang="en-us"> This is the actual
											BaseName used during the installation. Since users may
											change the Distribution Package's default BaseName (used
											to create the PKG and MANIFEST files) this is the real
											name used to create the files. </xs:documentation>
									</xs:annotation>
								</xs:attribute>
							</xs:extension>
						</xs:simpleContent>
					</xs:complexType>
				</xs:element>
				<xs:element ref="GUID" minOccurs="1" maxOccurs="1">
					<xs:annotation>
						<xs:documentation xml:lang="en-us"> This is the GUID of the
							distribution, backward compatible versions of a distribution can
							use the same GUID, however the version attribute must be changed
							(incrementally.) Non-backward compatible versions of a
							distribution must also provide a new GUID, while resetting the
							version attribute is optional. </xs:documentation>
					</xs:annotation>
				</xs:element>
				<xs:element minOccurs="1" maxOccurs="1" name="PkgFilename"
					type="xs:anyURI">
					<xs:annotation>
						<xs:documentation xml:lang="en-us"> This is the filename of the XML
							distribution package surface area (PKG) file that was stored in
							the Conf/Pkgs folder of the WORKSPACE for this distribution
							package. </xs:documentation>
					</xs:annotation>
				</xs:element>
				<xs:element minOccurs="1" maxOccurs="1" name="ManifestFilename"
					type="xs:anyURI">
					<xs:annotation>
						<xs:documentation xml:lang="en-us"> This is the filename of the
							distribution package manifest (.manifest) file that was created
							and stored in the Conf/Pkgs folder of the WORKSPACE for this
							distribution package. The InstallPkg tool must create this file
							using the extracted locations of the content zip file (or,
							alternatively, the user can create the file by redirecting the
							output of the zip -Tv Contents.zip.) </xs:documentation>
					</xs:annotation>
				</xs:element>
				<xs:element minOccurs="1" maxOccurs="1" name="InstalledDate"
					type="xs:dateTime" />
				<xs:element name="DistributionProperties" minOccurs="0" maxOccurs="1"
					nillable="true">
					<xs:annotation>
						<xs:documentation xml:lang="en-us"> This section tracks information
							and content that is not associated with either packages or
							modules, or is not required for building packages or modules.
						</xs:documentation>
					</xs:annotation>
					<xs:complexType>
						<xs:attribute name="ReadOnly" type="xs:boolean" default="false"
							use="optional">
							<xs:annotation>
								<xs:documentation xml:lang="en-us">If set to true, all content
									within this distribution package should NOT be
								modified.</xs:documentation>
							</xs:annotation>
						</xs:attribute>
						<xs:attribute name="RePackage" type="xs:boolean" default="false"
							use="optional">
							<xs:annotation>
								<xs:documentation xml:lang="en-us">If set to true, then the
									content can be repackaged into another distribution
								package.</xs:documentation>
							</xs:annotation>
						</xs:attribute>
						<xs:attribute name="ModifiedToolsDef" type="xs:boolean"
							default="false" use="optional">
							<xs:annotation>
								<xs:documentation xml:lang="en-us">If set to true, then either
									the distribution or one of its packages has a user extensions
									section that modified the tools_def.txt file.
								</xs:documentation>
							</xs:annotation>
						</xs:attribute>
						<xs:attribute name="ProvidesTools" type="xs:boolean" default="false"
							use="optional">
							<xs:annotation>
								<xs:documentation xml:lang="en-us"> This is used to identify a
									distribution that provides tools that may or may not be
									installed in a WORKSPACE. </xs:documentation>
							</xs:annotation>
						</xs:attribute>
						<xs:attribute name="ProvidesMiscellaneousFiles" type="xs:boolean"
							default="false" use="optional">
							<xs:annotation>
								<xs:documentation xml:lang="en-us"> This is used to identify a
									distribution that provides miscellaneous files that must be
									installed in a WORKSPACE. </xs:documentation>
							</xs:annotation>
						</xs:attribute>
						<xs:attribute name="UnknownUserExtensions" type="xs:boolean"
							default="false" use="optional">
							<xs:annotation>
								<xs:documentation xml:lang="en-us"> This is used to identify a
									distribution that has a UserExtensions section at the
									Distribution, Package or Module level that uses an Identifier
									other than BuildOptions, ToolsDef or DistributionPackage.
								</xs:documentation>
							</xs:annotation>
						</xs:attribute>
					</xs:complexType>
				</xs:element>
				<xs:element name="PackageList" minOccurs="0" maxOccurs="1">
					<xs:annotation>
						<xs:documentation xml:lang="en-us"> This section tracks individual
							packages (collections of related items.) Each package listed in
							this section must have a DEC file associated with it.
						</xs:documentation>
					</xs:annotation>
					<xs:complexType>
						<xs:sequence>
							<xs:element name="Package" minOccurs="1" maxOccurs="unbounded">
								<xs:complexType>
									<xs:sequence>
										<xs:element name="Name" minOccurs="1" maxOccurs="1">
											<xs:annotation>
												<xs:documentation xml:lang="en-us"> The User Interface
													Name of the package. </xs:documentation>
											</xs:annotation>
											<xs:complexType>
												<xs:simpleContent>
													<xs:extension base="xs:normalizedString">
														<xs:attribute name="BaseName" type="xs:NCName"
															use="required">
															<xs:annotation>
																<xs:documentation xml:lang="en-us"> The BaseName
																	is used to create files and folders during a
																	build, and is used by packaging tools as a
																	keyword to create the DEC file.
																</xs:documentation>
															</xs:annotation>
														</xs:attribute>
													</xs:extension>
												</xs:simpleContent>
											</xs:complexType>
										</xs:element>
										<xs:element ref="GUID" minOccurs="1" maxOccurs="1">
											<xs:annotation>
												<xs:documentation xml:lang="en-us"> This is the GUID of
													the package, backward compatible versions of a package
													can use the same GUID, however the version attribute
													must be changed (incrementally.) Non-backward
													compatible versions of a package must also provide a
													new GUID, while resetting the version attribute is
													optional. </xs:documentation>
											</xs:annotation>
										</xs:element>
										<xs:element name="InstalledFolder" type="xs:anyURI"
											minOccurs="1" maxOccurs="1">
											<xs:annotation>
												<xs:documentation xml:lang="en-us"> This is used to
													track the actual installation location, relative to
													the WORKSPACE. During an installation, the user may be
													presented with an option to relocate package content
													from the ZIP portion of the archive into a different
													location. </xs:documentation>
												<xs:documentation> Any installation tools must modify
													this value if the location is different from the
													default location. </xs:documentation>
												<xs:documentation> Any removal tools must check this
													value to locate correctly, the items that will be
													removed. </xs:documentation>
											</xs:annotation>
										</xs:element>
										<xs:element name="DecFilename" minOccurs="1" maxOccurs="1"
											type="xs:anyURI">
											<xs:annotation>
												<xs:documentation xml:lang="en-us"> This is the filename
													of the package declaration (DEC) filename created
													during installation in the InstalledFolder listed
													above. </xs:documentation>
											</xs:annotation>
										</xs:element>
										<xs:element ref="ModuleList" minOccurs="0" maxOccurs="1">
											<xs:annotation>
												<xs:documentation xml:lang="en-us"> This section is used
													to track the actual installation location, relative to
													the WORKSPACE. Every module that is part of this
													package must be listed here. During an installation,
													the user may be presented with an option to relocate
													module content from the ZIP portion of the archive
													into a different location, the installation tools must
													modify this value if the location is different from
													the default location. Any removal tools must check
													this value to locate correctly, the items that will be
													removed. </xs:documentation>
												<xs:documentation xml:lang="en-us"> The name of any INF
													files that were created during the installation of a
													distribution must also be listed in this section.
												</xs:documentation>
											</xs:annotation>
										</xs:element>
									</xs:sequence>
								</xs:complexType>
							</xs:element>
						</xs:sequence>
					</xs:complexType>
				</xs:element>
				<xs:element ref="ModuleList" minOccurs="0" maxOccurs="1">
					<xs:annotation>
						<xs:documentation xml:lang="en-us"> This section is used to record
							distribution packages that contain modules that are not part of a
							package. Modules that are part of packages are listed under the
							Package element of the PackageList section. </xs:documentation>
						<xs:documentation xml:lang="en-us"> Module only distribution will
							typically be for binary only modules, like the enhanced FAT
							driver. </xs:documentation>
					</xs:annotation>
				</xs:element>
			</xs:sequence>
		</xs:complexType>
	</xs:element>

	<xs:element name="GUID">
		<xs:complexType>
			<xs:simpleContent>
				<xs:extension base="RegistryFormatGuid">
					<xs:attribute name="Version" type="xs:decimal" use="required" />
				</xs:extension>
			</xs:simpleContent>
		</xs:complexType>
	</xs:element>

	<!-- Simple Types that further restrict allowed content. -->

	<xs:simpleType name="RegistryFormatGuid">
		<xs:annotation>
			<xs:documentation xml:lang="en-us"> A Registry format GUID must contain
				five different Hexadecimal character sets that are separated by a dash
				(-) character. </xs:documentation>
		</xs:annotation>
		<xs:restriction base="xs:normalizedString">
			<xs:pattern
				value="\s*[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}\s*"
			 />
		</xs:restriction>
	</xs:simpleType>

</xs:schema>