summaryrefslogtreecommitdiff
path: root/BaseTools/Source/Python/build
diff options
context:
space:
mode:
authorlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2012-05-23 08:27:14 +0000
committerlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2012-05-23 08:27:14 +0000
commit25918452ed5e9d12ea56b3bb2193df9ab96666b1 (patch)
tree6565b567d47cbf90c95d1bba67982958d689a0f0 /BaseTools/Source/Python/build
parent74dee93181ad4914e9a708494e2056f1b3c4776f (diff)
downloadedk2-platforms-25918452ed5e9d12ea56b3bb2193df9ab96666b1.tar.xz
Sync BaseTools Trunk (version r2524) to EDKII main trunk.
Signed-off-by: Liming Gao <liming.gao@intel.com> Reviewed-by: Liu Yingke <yingke.d.liu@intel.com> Reviewed-by: Yurui Zeng <yurui.zeng@intel.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13353 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'BaseTools/Source/Python/build')
-rw-r--r--BaseTools/Source/Python/build/BuildReport.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/BaseTools/Source/Python/build/BuildReport.py b/BaseTools/Source/Python/build/BuildReport.py
index e20131a312..d5ea3bd3e5 100644
--- a/BaseTools/Source/Python/build/BuildReport.py
+++ b/BaseTools/Source/Python/build/BuildReport.py
@@ -39,6 +39,7 @@ from Common.DataType import TAB_SLASH
from Common.DataType import TAB_SPACE_SPLIT
from Common.DataType import TAB_BRG_PCD
from Common.DataType import TAB_BRG_LIBRARY
+from Common.DataType import TAB_BACK_SLASH
## Pattern to extract contents in EDK DXS files
gDxsDependencyPattern = re.compile(r"DEPENDENCY_START(.+)DEPENDENCY_END", re.DOTALL)
@@ -191,11 +192,11 @@ def FileLinesSplit(Content=None, MaxLength=None):
while len(Line.rstrip()) > MaxLength:
LineSpaceIndex = Line.rfind(TAB_SPACE_SPLIT, 0, MaxLength)
LineSlashIndex = Line.rfind(TAB_SLASH, 0, MaxLength)
- LineBreakIndex = MaxLength
- if LineSpaceIndex > LineSlashIndex:
- LineBreakIndex = LineSpaceIndex
- elif LineSlashIndex > LineSpaceIndex:
- LineBreakIndex = LineSlashIndex
+ LineBackSlashIndex = Line.rfind(TAB_BACK_SLASH, 0, MaxLength)
+ if max(LineSpaceIndex, LineSlashIndex, LineBackSlashIndex) > 0:
+ LineBreakIndex = max(LineSpaceIndex, LineSlashIndex, LineBackSlashIndex)
+ else:
+ LineBreakIndex = MaxLength
NewContentList.append(Line[:LineBreakIndex])
Line = Line[LineBreakIndex:]
if Line: