bug 1191598 - Pass MOZ_CURRENT_PROJECT in environment when running post-build automation steps for universal mac builds. r=gps

--HG--
extra : commitid : IulYxRZ8FIa
extra : rebase_source : 6fd3f72081f6da9179d27fafad27bb3604c9db50
This commit is contained in:
Ted Mielczarek 2015-08-05 12:11:24 -04:00
parent 46566aee20
commit 9c8de9226b

View File

@ -394,15 +394,20 @@ class Build(MachCommandBase):
# For universal builds, we need to run the automation steps in
# the first architecture from MOZ_BUILD_PROJECTS
projects = make_extra.get('MOZ_BUILD_PROJECTS')
append_env = None
if projects:
subdir = os.path.join(self.topobjdir, projects.split()[0])
project = projects.split()[0]
append_env = {b'MOZ_CURRENT_PROJECT': project.encode('utf-8')}
subdir = os.path.join(self.topobjdir, project)
else:
subdir = self.topobjdir
moz_automation = os.getenv('MOZ_AUTOMATION') or make_extra.get('export MOZ_AUTOMATION', None)
if moz_automation and status == 0:
status = self._run_make(target='automation/build', directory=subdir,
line_handler=output.on_line, log=False, print_directory=False,
ensure_exit_code=False, num_jobs=jobs, silent=not verbose)
ensure_exit_code=False, num_jobs=jobs, silent=not verbose,
append_env=append_env
)
self.log(logging.WARNING, 'warning_summary',
{'count': len(monitor.warnings_database)},