Bug 1547730 - Update a build moz.configure function, to support py3 r=#build
☠☠ backed out by ee4b88439111 ☠ ☠
authorJustin Wood <Callek@gmail.com>
Tue, 16 Apr 2019 14:24:43 -0400
changeset 474156 27ff9602d80a13414d81422eaa02d01d60475a4e
parent 474155 48f2c4980ad0f2cccf92d9a45c0885db3f1f7b45
child 474157 3df19a96f8ac74b2c4100d40dc91b18efcb59749
push id36023
push userncsoregi@mozilla.com
push dateThu, 16 May 2019 21:56:43 +0000
treeherdermozilla-central@786f094a30ae [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1547730
milestone68.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1547730 - Update a build moz.configure function, to support py3 r=#build Differential Revision: https://phabricator.services.mozilla.com/D28115
build/moz.configure/init.configure
--- a/build/moz.configure/init.configure
+++ b/build/moz.configure/init.configure
@@ -301,16 +301,17 @@ def early_options():
 
 early_options = early_options()
 
 
 @depends(mozconfig, 'MOZ_AUTOMATION', '--help')
 # This gives access to the sandbox. Don't copy this blindly.
 @imports('__sandbox__')
 @imports('os')
+@imports('six')
 def mozconfig_options(mozconfig, automation, help):
     if mozconfig['path']:
         if 'MOZ_AUTOMATION_MOZCONFIG' in mozconfig['env']['added']:
             if not automation:
                 log.error('%s directly or indirectly includes an in-tree '
                           'mozconfig.', mozconfig['path'])
                 log.error('In-tree mozconfigs make strong assumptions about '
                           'and are only meant to be used by Mozilla '
@@ -326,25 +327,25 @@ def mozconfig_options(mozconfig, automat
             helper.add(arg, origin='mozconfig', args=helper._args)
 
         def add(key, value):
             if key.isupper():
                 arg = '%s=%s' % (key, value)
                 log.info('  %s' % arg)
                 helper.add(arg, origin='mozconfig', args=helper._args)
 
-        for key, value in mozconfig['env']['added'].iteritems():
+        for key, value in six.iteritems(mozconfig['env']['added']):
             add(key, value)
             os.environ[key] = value
-        for key, (_, value) in mozconfig['env']['modified'].iteritems():
+        for key, (_, value) in six.iteritems(mozconfig['env']['modified']):
             add(key, value)
             os.environ[key] = value
-        for key, value in mozconfig['vars']['added'].iteritems():
+        for key, value in six.iteritems(mozconfig['vars']['added']):
             add(key, value)
-        for key, (_, value) in mozconfig['vars']['modified'].iteritems():
+        for key, (_, value) in six.iteritems(mozconfig['vars']['modified']):
             add(key, value)
 
 
 # Mozilla-Build
 # ==============================================================
 option(env='MOZILLABUILD', nargs=1,
        help='Path to Mozilla Build (Windows-only)')