]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Scripts/PackageDocumentTools/packagedocapp.pyw
UefiCpuPkg: Move AsmRelocateApLoopStart from Mpfuncs.nasm to AmdSev.nasm
[mirror_edk2.git] / BaseTools / Scripts / PackageDocumentTools / packagedocapp.pyw
index 28f6f9bf5cceaf941ee0feb46a187349c48e7e9b..e96197a508aa9df5453f22b73685b67e42ff393d 100644 (file)
@@ -4,13 +4,7 @@
 #\r
 # Copyright (c) 2011 - 2018, Intel Corporation. All rights reserved.<BR>\r
 #\r
-# This program and the accompanying materials are licensed and made available\r
-# under the terms and conditions of the BSD License which accompanies this\r
-# distribution. The full text of the license may be found at\r
-# http://opensource.org/licenses/bsd-license.php\r
-#\r
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+# SPDX-License-Identifier: BSD-2-Clause-Patent\r
 #\r
 \r
 import os, sys, wx, logging\r
@@ -18,8 +12,8 @@ import os, sys, wx, logging
 import wx.stc\r
 import wx.lib.newevent\r
 import wx.lib.agw.genericmessagedialog as GMD\r
-import plugins.EdkPlugins.edk2.model.baseobject as baseobject\r
-import plugins.EdkPlugins.edk2.model.doxygengen as doxygengen\r
+from plugins.EdkPlugins.edk2.model import baseobject\r
+from plugins.EdkPlugins.edk2.model import doxygengen\r
 \r
 if hasattr(sys, "frozen"):\r
     appPath = os.path.abspath(os.path.dirname(sys.executable))\r
@@ -720,7 +714,7 @@ class ProgressDialog(wx.Dialog):
             lines = f.readlines()\r
             f.close()\r
             bfound = False\r
-            for index in xrange(len(lines)):\r
+            for index in range(len(lines)):\r
                 if lines[index].find('<a class="el" href="files.html" target="basefrm">File List</a>') != -1:\r
                     lines[index] = "<!-- %s" % lines[index]\r
                     bfound = True\r
@@ -969,7 +963,7 @@ class ProgressDialog(wx.Dialog):
             fd = open(path, 'r')\r
             text = fd.read()\r
             fd.close()\r
-        except Exception, e:\r
+        except Exception as e:\r
             self.LogMessage ("   <<<Fail to open file %s" % path)\r
             return\r
         text = text.replace ('.s.dox', '.s')\r
@@ -982,7 +976,7 @@ class ProgressDialog(wx.Dialog):
             fd = open(path, 'w')\r
             fd.write(text)\r
             fd.close()\r
-        except Exception, e:\r
+        except Exception as e:\r
             self.LogMessage ("    <<<Fail to fixup file %s" % path)\r
             return\r
         self.LogMessage('    >>> Finish to fixup .dox postfix for file %s \n' % path)\r
@@ -993,7 +987,7 @@ class ProgressDialog(wx.Dialog):
             fd = open(path, 'r')\r
             lines = fd.readlines()\r
             fd.close()\r
-        except Exception, e:\r
+        except Exception as e:\r
             self.LogMessage ("   <<<Fail to open file %s" % path)\r
             return\r
         for line in lines:\r
@@ -1004,7 +998,7 @@ class ProgressDialog(wx.Dialog):
             fd = open(path, 'w')\r
             fd.write("".join(lines))\r
             fd.close()\r
-        except Exception, e:\r
+        except Exception as e:\r
             self.LogMessage ("    <<<Fail to fixup file %s" % path)\r
             return\r
         self.LogMessage('    >>> Finish to fixup .decdoxygen postfix for file %s \n' % path)\r