## @file\r
# Generate AutoGen.h, AutoGen.c and *.depex files\r
#\r
-# Copyright (c) 2007 - 2016, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) 2007 - 2017, Intel Corporation. All rights reserved.<BR>\r
# This program and the accompanying materials\r
# are licensed and made available under the terms and conditions of the BSD License\r
# which accompanies this distribution. The full text of the license may be found at\r
self._IncludePathLength = 0\r
self._AutoGenFileList = None\r
self._UnicodeFileList = None\r
+ self._VfrFileList = None\r
self._IdfFileList = None\r
self._SourceFileList = None\r
self._ObjectFileList = None\r
self._UnicodeFileList = []\r
return self._UnicodeFileList\r
\r
+ ## Return the list of vfr files\r
+ def _GetVfrFileList(self):\r
+ if self._VfrFileList == None:\r
+ if TAB_VFR_FILE in self.FileTypes:\r
+ self._VfrFileList = self.FileTypes[TAB_VFR_FILE]\r
+ else:\r
+ self._VfrFileList = []\r
+ return self._VfrFileList\r
+\r
## Return the list of Image Definition files\r
def _GetIdfFileList(self):\r
if self._IdfFileList == None:\r
IncludePathLength = property(_GetIncludePathLength)\r
AutoGenFileList = property(_GetAutoGenFileList)\r
UnicodeFileList = property(_GetUnicodeFileList)\r
+ VfrFileList = property(_GetVfrFileList)\r
SourceFileList = property(_GetSourceFileList)\r
BinaryFileList = property(_GetBinaryFiles) # FileType : [File List]\r
Targets = property(_GetTargets)\r
## @file\r
# Routines for generating AutoGen.h and AutoGen.c\r
#\r
-# Copyright (c) 2007 - 2016, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) 2007 - 2017, Intel Corporation. All rights reserved.<BR>\r
# This program and the accompanying materials\r
# are licensed and made available under the terms and conditions of the BSD License\r
# which accompanies this distribution. The full text of the license may be found at\r
GuidMacros.append('#define %s %s' % (Guid, Info.Module.Guids[Guid]))\r
for Guid, Value in Info.Module.Protocols.items() + Info.Module.Ppis.items():\r
GuidMacros.append('#define %s %s' % (Guid, Value))\r
+ # supports FixedAtBuild usage in VFR file\r
+ if Info.VfrFileList and Info.ModulePcdList:\r
+ GuidMacros.append('#define %s %s' % ('FixedPcdGetBool(TokenName)', '_PCD_VALUE_##TokenName'))\r
+ GuidMacros.append('#define %s %s' % ('FixedPcdGet8(TokenName)', '_PCD_VALUE_##TokenName'))\r
+ GuidMacros.append('#define %s %s' % ('FixedPcdGet16(TokenName)', '_PCD_VALUE_##TokenName'))\r
+ GuidMacros.append('#define %s %s' % ('FixedPcdGet32(TokenName)', '_PCD_VALUE_##TokenName'))\r
+ GuidMacros.append('#define %s %s' % ('FixedPcdGet64(TokenName)', '_PCD_VALUE_##TokenName'))\r
+ for Pcd in Info.ModulePcdList:\r
+ if Pcd.Type == TAB_PCDS_FIXED_AT_BUILD:\r
+ TokenCName = Pcd.TokenCName\r
+ Value = Pcd.DefaultValue\r
+ if Pcd.DatumType == 'BOOLEAN':\r
+ BoolValue = Value.upper()\r
+ if BoolValue == 'TRUE':\r
+ Value = '1'\r
+ elif BoolValue == 'FALSE':\r
+ Value = '0'\r
+ for PcdItem in GlobalData.MixedPcd:\r
+ if (Pcd.TokenCName, Pcd.TokenSpaceGuidCName) in GlobalData.MixedPcd[PcdItem]:\r
+ TokenCName = PcdItem[0]\r
+ break\r
+ GuidMacros.append('#define %s %s' % ('_PCD_VALUE_'+TokenCName, Value))\r
+\r
if GuidMacros:\r
StringH.Append('\n#ifdef VFRCOMPILE\n%s\n#endif\n' % '\n'.join(GuidMacros))\r
\r
## @file\r
# This file is used to define common static strings used by INF/DEC/DSC files\r
#\r
-# Copyright (c) 2007 - 2016, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) 2007 - 2017, Intel Corporation. All rights reserved.<BR>\r
# Portions copyright (c) 2011 - 2013, ARM Ltd. All rights reserved.<BR>\r
# This program and the accompanying materials\r
# are licensed and made available under the terms and conditions of the BSD License\r
TAB_UNKNOWN_FILE = "UNKNOWN-TYPE-FILE"\r
TAB_DEFAULT_BINARY_FILE = "_BINARY_FILE_"\r
TAB_OBJECT_FILE = "OBJECT-FILE"\r
+TAB_VFR_FILE = 'VISUAL-FORM-REPRESENTATION-FILE'\r
\r
# used by BRG\r
TAB_BRG_PCD = 'PCD'\r