## @file\r
# Common routines used by all tools\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
if m != None:\r
sections.append(m.groups(0))\r
for varname in varnames:\r
- m = re.match(".data.(%s)$" % varname, line)\r
+ Str = ''\r
+ m = re.match("^.data.(%s)" % varname, line)\r
if m != None:\r
- if lines[index + 1]:\r
- m = re.match('^([\da-fA-Fx]+) +([\da-fA-Fx]+)', lines[index + 1].strip())\r
+ m = re.match(".data.(%s)$" % varname, line)\r
+ if m != None:\r
+ Str = lines[index + 1]\r
+ else:\r
+ Str = line[len(".data.%s" % varname):]\r
+ if Str:\r
+ m = re.match('^([\da-fA-Fx]+) +([\da-fA-Fx]+)', Str.strip())\r
if m != None:\r
varoffset.append((varname, int(m.groups(0)[0], 16) , int(sections[-1][1], 16), sections[-1][0]))\r
\r