Bug 1136456 - Remove leftovers from TIERS support in mozbuild.frontend.reader. r=gps

This commit is contained in:
Mike Hommey
2015-02-25 09:02:49 +09:00
parent a618220ed2
commit 1ea5cac299

View File

@@ -736,7 +736,7 @@ class BuildReader(object):
read, a new Context is created and emitted.
"""
path = mozpath.join(self.config.topsrcdir, 'moz.build')
return self.read_mozbuild(path, self.config, read_tiers=True)
return self.read_mozbuild(path, self.config)
def all_mozbuild_paths(self):
"""Iterator over all available moz.build files.
@@ -872,8 +872,7 @@ class BuildReader(object):
for name, key, value in assignments:
yield p, name, key, value
def read_mozbuild(self, path, config, read_tiers=False, descend=True,
metadata={}):
def read_mozbuild(self, path, config, descend=True, metadata={}):
"""Read and process a mozbuild file, descending into children.
This starts with a single mozbuild file, executes it, and descends into
@@ -884,10 +883,6 @@ class BuildReader(object):
directory, we will open the moz.build file located in that
directory in a new Sandbox and process it.
If read_tiers is True (it should only be True for the top-level
mozbuild file in a project), the TIERS variable will be used for
traversal as well.
If descend is True (the default), we will descend into child
directories and files per variable values.
@@ -900,8 +895,8 @@ class BuildReader(object):
"""
self._execution_stack.append(path)
try:
for s in self._read_mozbuild(path, config, read_tiers=read_tiers,
descend=descend, metadata=metadata):
for s in self._read_mozbuild(path, config, descend=descend,
metadata=metadata):
yield s
except BuildReaderError as bre:
@@ -927,7 +922,7 @@ class BuildReader(object):
raise BuildReaderError(list(self._execution_stack),
sys.exc_info()[2], other_error=e)
def _read_mozbuild(self, path, config, read_tiers, descend, metadata):
def _read_mozbuild(self, path, config, descend, metadata):
path = mozpath.normpath(path)
log(self._log, logging.DEBUG, 'read_mozbuild', {'path': path},
'Reading file: {path}')
@@ -1051,7 +1046,7 @@ class BuildReader(object):
continue
for res in self.read_mozbuild(child_path, context.config,
read_tiers=False, metadata=child_metadata):
metadata=child_metadata):
yield res
self._execution_stack.pop()