summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorjan Iversen <jani@documentfoundation.org>2017-01-01 18:26:37 +0100
committerjan Iversen <jani@documentfoundation.org>2017-01-01 18:26:37 +0100
commitae4f8ac9a16b7a0631124272d08c625e86c432d8 (patch)
tree33b5c80278eea204f18c1210c548c4302652a314 /bin
parentf33aa5bc3af5de14cc5286f2655470474f22465c (diff)
gbuild-to-ide performance optimize parser
Change-Id: I93c81e027269830af7d6b2c9df2f1b0f0194880e
Diffstat (limited to 'bin')
-rwxr-xr-xbin/gbuild-to-ide19
1 files changed, 9 insertions, 10 deletions
diff --git a/bin/gbuild-to-ide b/bin/gbuild-to-ide
index e12e0fa87dcc..978fd1756921 100755
--- a/bin/gbuild-to-ide
+++ b/bin/gbuild-to-ide
@@ -108,26 +108,26 @@ class GbuildParser:
with open(os.path.join(self.workdir, 'GbuildToJson', jsontype, jsonfilename), 'r') as f:
jsondata = json.load(f)
- (foundincludes, foundisystem) = self.__split_includes(jsondata['INCLUDE'])
- match = self.buildpattern[jsontype].match(os.path.basename(jsondata['MAKEFILE'])).group(1)
+ (foundincludes, foundisystem) = GbuildParser.__split_includes(jsondata['INCLUDE'])
+ match = GbuildParser.buildpattern[jsontype].match(os.path.basename(jsondata['MAKEFILE'])).group(1)
newObj = GbuildLinkTarget(match,
os.path.dirname(jsondata['MAKEFILE']),
foundincludes,
foundisystem,
- self.__split_defs(jsondata['DEFS']),
- self.__split_objs(jsondata['CXXOBJECTS']),
- self.__split_flags(jsondata['CXXFLAGS'], jsondata['CXXFLAGSAPPEND']),
+ GbuildParser.__split_defs(jsondata['DEFS']),
+ GbuildParser.__split_objs(jsondata['CXXOBJECTS']),
+ GbuildParser.__split_flags(jsondata['CXXFLAGS'], jsondata['CXXFLAGSAPPEND']),
jsondata['LINKED_LIBS'].strip().split(' '),
jsondata['ASMOBJECTS'],
- self.__split_flags(jsondata['CFLAGS'], jsondata['CFLAGSAPPEND']),
+ GbuildParser.__split_flags(jsondata['CFLAGS'], jsondata['CFLAGSAPPEND']),
jsondata['GENCOBJECTS'],
jsondata['GENCXXOBJECTS'],
jsondata['ILIBTARGET'],
jsondata['LINKED_STATIC_LIBS'],
jsondata['LINKTARGET'],
- self.__split_flags(jsondata['OBJCFLAGS'], jsondata['OBJCFLAGSAPPEND']),
+ GbuildParser.__split_flags(jsondata['OBJCFLAGS'], jsondata['OBJCFLAGSAPPEND']),
jsondata['OBJCOBJECTS'],
- self.__split_flags(jsondata['OBJCXXFLAGS'], jsondata['OBJCXXFLAGSAPPEND']),
+ GbuildParser.__split_flags(jsondata['OBJCXXFLAGS'], jsondata['OBJCXXFLAGSAPPEND']),
jsondata['OBJCXXOBJECTS'],
jsondata['YACCOBJECTS'],
jsontype)
@@ -154,8 +154,7 @@ class GbuildParser:
class IdeIntegrationGenerator:
def __init__(self, gbuildparser, ide):
- self.gbuildparser = gbuildparser
- self.ide = ide
+ (self.gbuildparser, self.ide) = (gbuildparser, ide)
def emit(self):
pass