Bug 1253076 - Handle the case defines are not present to avoid artifact build bustage when processing symbols files. r=glandium draft
authorChris Manchester <cmanchester@mozilla.com>
Wed, 02 Mar 2016 15:44:05 -0800
changeset 336248 37eae850e1375f7bb3fd25d40c21b940928ad5f0
parent 336247 f2990a314e2312d2f6bf4e5b4632083815f85f7d
child 515355 1287599e2230dfdd4786d776b55cc9068b535192
push id12023
push usercmanchester@mozilla.com
push dateWed, 02 Mar 2016 23:44:21 +0000
reviewersglandium
bugs1253076
milestone47.0a1
Bug 1253076 - Handle the case defines are not present to avoid artifact build bustage when processing symbols files. r=glandium MozReview-Commit-ID: 25oUlS12hec
python/mozbuild/mozbuild/frontend/emitter.py
--- a/python/mozbuild/mozbuild/frontend/emitter.py
+++ b/python/mozbuild/mozbuild/frontend/emitter.py
@@ -565,19 +565,22 @@ class TreeMetadataEmitter(LoggingMixin):
                 if is_component and not context['NO_COMPONENTS_MANIFEST']:
                     yield ChromeManifestEntry(context,
                         'components/components.manifest',
                         ManifestBinaryComponent('components', lib.lib_name))
                 if symbols_file:
                     script = mozpath.join(
                         mozpath.dirname(mozpath.dirname(__file__)),
                         'action', 'generate_symbols_file.py')
+                    defines = None
+                    if lib.defines:
+                        defines = lib.defines.get_defines()
                     yield GeneratedFile(context, script,
                         'generate_symbols_file', lib.symbols_file,
-                        [symbols_file.full_path], lib.defines.get_defines())
+                        [symbols_file.full_path], defines)
             if static_lib:
                 lib = StaticLibrary(context, libname, **static_args)
                 self._libs[libname].append(lib)
                 self._linkage.append((context, lib, 'USE_LIBS'))
                 has_linkables = True
 
             if lib_defines:
                 if not libname: