git-svn-id: https://buildtools.tianocore.org/svn/buildtools/trunk/BaseTools@412 7335b...
[people/mcb30/basetools.git] / Source / Python / CommonDataClass / PlatformClass.py
index 36125f1..5904dfe 100644 (file)
@@ -29,7 +29,7 @@ class PlatformHeaderClass(IdentificationClass, CommonHeaderClass, DefineClass):
         self.IntermediateDirectories = ''                            #MODULE | UNIFIED\r
         self.OutputDirectory = ''                                                    \r
         self.ForceDebugTarget = ''\r
-        self.SkuId = ''\r
+        self.SkuIdName = []\r
         self.BuildNumber = ''\r
         self.MakefileName = ''\r
         self.ClonedFrom = []                                         #[ ClonedRecordClass, ...]\r
@@ -100,53 +100,68 @@ class PlatformFfsClass(object):
     def __init__(self):\r
         self.Attribute = {}                                          #{ [(Name, PlatformFfsSectionsClass)] : Value}\r
         self.Sections = []                                           #[ PlatformFfsSectionsClass]\r
-\r
+            \r
 class PlatformBuildOptionClass(object):\r
     def __init__(self):\r
         self.UserDefinedAntTasks = {}                                #{ [Id] : PlatformAntTaskClass, ...}\r
         self.Options = []                                            #[ BuildOptionClass, ...]\r
         self.UserExtensions = {}                                     #{ [(UserID, Identifier)] : UserExtensionsClass, ...}\r
         self.FfsKeyList = {}                                         #{ [FfsKey]: PlatformFfsClass, ...} \r
-\r
-class PlatformLibraryInstanceClass(DefineClass):\r
+    \r
+class PlatformBuildOptionClasses(IncludeStatementClass):\r
     def __init__(self):\r
+        IncludeStatementClass.__init__(self)\r
+        self.FvBinding = ''\r
+        self.FfsFileNameGuid = ''\r
+        self.FfsFormatKey = ''\r
+        self.BuildOptionList = []                                    #[ BuildOptionClass, ...]\r
+\r
+class PlatformLibraryClass(CommonClass, DefineClass):\r
+    def __init__(self, Name = '', FilePath = ''):\r
+        CommonClass.__init__(self)\r
         DefineClass.__init__(self)\r
-        self.Name = ''\r
-        self.FilePath = ''\r
+        self.Name = Name\r
+        self.FilePath = FilePath\r
+        self.ModuleType = []\r
         self.ModuleGuid = ''\r
         self.ModuleVersion = ''\r
         self.PackageGuid = ''\r
         self.PackageVersion = ''\r
 \r
-class PlatformModuleSaBuildOptionClass(DefineClass):\r
+class PlatformLibraryClasses(IncludeStatementClass):\r
     def __init__(self):\r
-        self.FvBinding = ''\r
-        self.FfsFileNameGuid = ''\r
-        self.FfsFormatKey = ''\r
-        self.Options = []                                            #[ BuildOptionClass, ...]\r
-                \r
+        IncludeStatementClass.__init__(self)\r
+        self.LibraryList = []                                        #[ PlatformLibraryClass, ...]\r
+        \r
 class PlatformModuleClass(CommonClass, DefineClass, IncludeStatementClass):\r
     def __init__(self):\r
         CommonClass.__init__(self)\r
         DefineClass.__init__(self)\r
-        IncludeStatementClass.__init__(self)\r
         self.Name = ''                                               #Library name or libraryclass name or module name\r
         self.FilePath = ''\r
         self.Type = ''                                               #LIBRARY | LIBRARY_CLASS | MODULE, used by dsc\r
         self.ModuleType = ''\r
-        self.LibraryClasses = []                                     #[ PlatformLibraryInstanceClass, ...]\r
+        self.ExecFilePath = ''\r
+        self.LibraryClasses = PlatformLibraryClasses()\r
         self.PcdBuildDefinitions = []                                #[ PcdClass, ...]\r
-        self.ModuleSaBuildOption = PlatformModuleSaBuildOptionClass()\r
+        self.ModuleSaBuildOption = PlatformBuildOptionClasses()\r
         self.Specifications = []                                     #[ '', '', ...]\r
-    \r
+\r
+class PlatformModuleClasses(IncludeStatementClass):\r
+    def __init__(self):\r
+        IncludeStatementClass.__init__(self)\r
+        self.ModuleList = []                                         #[ PlatformModuleClass, ...]\r
+\r
 class PlatformClass(object):\r
     def __init__(self):\r
         self.Header = PlatformHeaderClass()\r
-        self.SkuInfoList = SkuInfoListClass()\r
-        self.Modules = []                                            #[ PlatformModuleClass, ...]\r
-        self.FlashDefinitionFile = None                              #PlatformFlashDefinitionFileClass()\r
+        self.SkuInfos = SkuInfoListClass()\r
+        self.Libraries = PlatformLibraryClasses()\r
+        self.LibraryClasses = PlatformLibraryClasses()\r
+        self.Modules = PlatformModuleClasses()\r
+        self.FlashDefinitionFile = PlatformFlashDefinitionFileClass()\r
         self.FvImages = []                                           #[ PlatformFvImagesClass, ...]\r
-        self.BuildOptions = []                                       #[ PlatformBuildOptionClass, ...]\r
+        self.BuildOptions = PlatformBuildOptionClasses()\r
         self.DynamicPcdBuildDefinitions = []                         #[ PcdClass, ...] \r
         self.Fdf = []                                                #[ FdfClass, ...]\r
         self.UserExtensions = []                                     #[ UserExtensionsClass, ...]\r