diff options
author | Andoni Morales Alastruey <ylatuya@gmail.com> | 2013-05-02 16:57:50 +0200 |
---|---|---|
committer | Andoni Morales Alastruey <ylatuya@gmail.com> | 2013-05-02 16:57:50 +0200 |
commit | 85524815afd9d73b9481a8676379e313b0c0acad (patch) | |
tree | 2882059e16963a5bf9b2bb42eab91b5c357e2962 | |
parent | 824e31c9e45ad04ff3ad059f8675f51beb5d7a3a (diff) |
Fix for python 2.6
-rw-r--r-- | cerbero/ide/xcode/fwlib.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/cerbero/ide/xcode/fwlib.py b/cerbero/ide/xcode/fwlib.py index 33f7f0f..889b6b2 100644 --- a/cerbero/ide/xcode/fwlib.py +++ b/cerbero/ide/xcode/fwlib.py @@ -139,15 +139,18 @@ class StaticFrameworkLibrary(FrameworkLibrary): def _check_duplicated_symbols(self, files, tmpdir): for f in files: - dups = defaultdict(list) + syms = defaultdict(list) symbols = shell.check_call('nm -UA %s' % f, tmpdir).split('\n') # nm output is: test.o: 00000000 T _gzwrite # (filename, address, symbol type, symbols_name) for s in symbols: s = s.split(' ') if len(s) == 4 and s[2] == 'T': - dups[s[3]].append(s) - dups = {k:v for k,v in dups.iteritems() if len(v) > 1} + syms[s[3]].append(s) + dups = {} + for k,v in syms.iteritems(): + if len(v) > 1: + dups[k] = v m.warning ("The static library contains duplicated symbols") for k, v in dups.iteritems(): m.message (k) # symbol name |