Bug 730325 - Integrate Thunderbird build config with Firefox build config. r=bhearsum.
authorJohn Hopkins <jhopkins@mozilla.com>
Mon, 16 Apr 2012 11:25:29 -0400
changeset 5790 bb260b55320e0da5b7143c0e6cce39b9ef2082e8
parent 5771 e82b9b7336830615e9b11a1b1fbd51506241ba22
child 5791 03083899a9cdec9c0d79a8be4357ebacf948cd5b
push id1
push userroot
push dateWed, 17 Dec 2014 00:18:48 +0000
reviewersbhearsum
bugs730325
Bug 730325 - Integrate Thunderbird build config with Firefox build config. r=bhearsum. Nits will be addressed in separate patches.
mozilla-tests/scheduler_localconfig.py
mozilla-tests/scheduler_master.cfg
mozilla-tests/staging_tests_master_stm02_localconfig.py
mozilla-tests/tests_localconfig.py
mozilla-tests/tests_master.cfg
mozilla-tests/thunderbird_config.py
mozilla-tests/thunderbird_production_config.py
mozilla-tests/thunderbird_staging_config.py
mozilla-tests/universal_master_sqlite.cfg
mozilla/build_localconfig.py
mozilla/builder_master.cfg
mozilla/release-thunderbird-comm-beta.py
mozilla/release-thunderbird-comm-esr10.py
mozilla/release-thunderbird-comm-release.py
mozilla/scheduler_master.cfg
mozilla/staging_builder_master_sm02_localconfig.py
mozilla/staging_config.py
mozilla/thunderbird_config.py
mozilla/thunderbird_production_config.py
mozilla/thunderbird_staging_config.py
mozilla/try_localconfig.py
mozilla/universal_master_sqlite.cfg
setup-master.py
--- a/mozilla-tests/scheduler_localconfig.py
+++ b/mozilla-tests/scheduler_localconfig.py
@@ -7,14 +7,17 @@ c = BuildmasterConfig = {}
 c['slavePortnum'] = master_config.get('pb_port', None)
 
 if 'ssh_port' in master_config:
     c['manhole'] = manhole.PasswordManhole(
             "tcp:%(ssh_port)i:interface=127.0.0.1" % master_config,
             "cltbld", "password")
 
 from config import BRANCHES, PLATFORMS, PROJECTS
+import thunderbird_config
 # Do everything!
 ACTIVE_BRANCHES = BRANCHES.keys()
+ACTIVE_THUNDERBIRD_BRANCHES = thunderbird_config.BRANCHES.keys()
 ACTIVE_PLATFORMS = dict((platform, None) for platform in PLATFORMS.keys())
+ACTIVE_THUNDERBIRD_PLATFORMS = dict((platform, None) for platform in thunderbird_config.PLATFORMS.keys())
 ACTIVE_PROJECTS = PROJECTS.keys()
 
 QUEUEDIR = "/dev/shm/queue"
--- a/mozilla-tests/scheduler_master.cfg
+++ b/mozilla-tests/scheduler_master.cfg
@@ -20,31 +20,44 @@ for key, value in master_localconfig.Bui
         c[key] = value
 
 # Create our QueueDir objects
 # This is reloaded in buildbotcustom.misc
 from mozilla_buildtools.queuedir import QueueDir
 commandsQueue = QueueDir('commands', '%s/commands' % master_localconfig.QUEUEDIR)
 
 from config import BRANCHES, PLATFORMS, SUITES, BRANCH_UNITTEST_VARS, PROJECTS, SLAVES
-from master_localconfig import ACTIVE_BRANCHES, ACTIVE_PLATFORMS, ACTIVE_PROJECTS
+from thunderbird_config import BRANCHES as THUNDERBIRD_BRANCHES
+from thunderbird_config import PLATFORMS as THUNDERBIRD_PLATFORMS
+from thunderbird_config import BRANCH_UNITTEST_VARS as THUNDERBIRD_BRANCH_UNITTEST_VARS
+from master_localconfig import ACTIVE_BRANCHES, ACTIVE_PLATFORMS, ACTIVE_PROJECTS, \
+    ACTIVE_THUNDERBIRD_BRANCHES, ACTIVE_THUNDERBIRD_PLATFORMS
 
 from buildbotcustom.misc import generateTalosBranchObjects, generateProjectObjects, mergeBuildObjects
 
 for p in ACTIVE_PLATFORMS.keys():
     ACTIVE_PLATFORMS[p] = deepcopy(PLATFORMS[p])
 
+for p in ACTIVE_THUNDERBIRD_PLATFORMS.keys():
+    ACTIVE_THUNDERBIRD_PLATFORMS[p] = deepcopy(THUNDERBIRD_PLATFORMS[p])
+
 buildObjects = {}
 
 for branch in ACTIVE_BRANCHES:
     talosObjects = generateTalosBranchObjects(branch, BRANCHES[branch],
                                                ACTIVE_PLATFORMS, SUITES,
                                                BRANCH_UNITTEST_VARS['platforms'])
     buildObjects = mergeBuildObjects(buildObjects, talosObjects)
 
+for branch in ACTIVE_THUNDERBIRD_BRANCHES:
+    talosObjects = generateTalosBranchObjects(branch, THUNDERBIRD_BRANCHES[branch],
+                                               ACTIVE_THUNDERBIRD_PLATFORMS, SUITES,
+                                               THUNDERBIRD_BRANCH_UNITTEST_VARS['platforms'])
+    buildObjects = mergeBuildObjects(buildObjects, talosObjects)
+
 for project in ACTIVE_PROJECTS:
     projectObjects = generateProjectObjects(project, PROJECTS[project], SLAVES)
     buildObjects = mergeBuildObjects(buildObjects, projectObjects)
 
 # We only want the schedulers and change sources
 c['schedulers'].extend(buildObjects['schedulers'])
 c['change_source'].extend(buildObjects['change_source'])
 
--- a/mozilla-tests/staging_tests_master_stm02_localconfig.py
+++ b/mozilla-tests/staging_tests_master_stm02_localconfig.py
@@ -7,16 +7,21 @@ c['status'] = [
 ]
 
 c['buildbotURL'] = 'http://talos-staging-master02.build.mozilla.org:8012/'
 
 from buildbot import manhole
 c['manhole'] = manhole.PasswordManhole("tcp:1236:interface=127.0.0.1", "cltbld", "password")
 
 from config import BRANCHES, PLATFORMS, PROJECTS
+from thunderbird_config import BRANCHES as THUNDERBIRD_BRANCHES, \
+    PLATFORMS as THUNDERBIRD_PLATFORMS
+
 # Do everything!
 #ACTIVE_BRANCHES = BRANCHES.keys()
 # I changed my mind; do only trunk
 ACTIVE_BRANCHES = ['mozilla-central']
 ACTIVE_PLATFORMS = dict((k,None) for k in PLATFORMS.keys())
 ACTIVE_PROJECTS = PROJECTS.keys()
+ACTIVE_THUNDERBIRD_BRANCHES = THUNDERBIRD_BRANCHES.keys()
+ACTIVE_THUNDERBIRD_PLATFORMS = dict((k,None) for k in THUNDERBIRD_PLATFORMS.keys())
 
 QUEUEDIR = "/dev/shm/queue"
--- a/mozilla-tests/tests_localconfig.py
+++ b/mozilla-tests/tests_localconfig.py
@@ -14,17 +14,21 @@ if 'http_port' in master_config:
     c['buildbotURL'] = 'http://%(hostname)s:%(http_port)i/' % master_config
 
 if 'ssh_port' in master_config:
     c['manhole'] = manhole.PasswordManhole(
             "tcp:%(ssh_port)i:interface=127.0.0.1" % master_config,
             "cltbld", "password")
 
 from config import BRANCHES, PLATFORMS, PROJECTS
+import thunderbird_config
 # Do everything!
 ACTIVE_BRANCHES = BRANCHES.keys()
+ACTIVE_THUNDERBIRD_BRANCHES = thunderbird_config.BRANCHES.keys()
 if 'limit_platforms' in master_config:
     ACTIVE_PLATFORMS = dict((p,None) for p in master_config['limit_platforms'])
+    ACTIVE_THUNDERBIRD_PLATFORMS = dict((p,None) for p in master_config['limit_platforms'])
 else:
     ACTIVE_PLATFORMS = dict((k,None) for k in PLATFORMS.keys())
+    ACTIVE_THUNDERBIRD_PLATFORMS = dict((k,None) for k in THUNDERBIRD_PLATFORMS.keys())
 ACTIVE_PROJECTS = PROJECTS.keys()
 
 QUEUEDIR = master_config.get("queuedir", "/dev/shm/queue")
--- a/mozilla-tests/tests_master.cfg
+++ b/mozilla-tests/tests_master.cfg
@@ -2,21 +2,23 @@
 import os, sys
 from copy import deepcopy
 
 # import/reload dance so that reconfigs work
 import buildbotcustom.misc
 import buildbotcustom.status.queued_command
 import master_common
 import config
+import thunderbird_config
 import master_localconfig
 reload(buildbotcustom.misc)
 reload(buildbotcustom.status.queued_command)
 reload(master_common)
 reload(config)
+reload(thunderbird_config)
 reload(master_localconfig)
 
 from master_common import BuildmasterConfig
 c = BuildmasterConfig
 for key, value in master_localconfig.BuildmasterConfig.items():
     if key in c:
         c[key].extend(value)
     else:
@@ -28,48 +30,62 @@ from mozilla_buildtools.queuedir import 
 commandsQueue = QueueDir('commands', '%s/commands' % master_localconfig.QUEUEDIR)
 from buildbotcustom.status.queued_command import QueuedCommandHandler
 c['status'].append(QueuedCommandHandler(
     command=[sys.executable, os.path.join(os.path.dirname(buildbotcustom.__file__), 'bin', 'postrun.py'), '-c', os.path.abspath(os.path.join(os.curdir, 'postrun.cfg'))],
     queuedir=commandsQueue,
 ))
 
 from config import BRANCHES, PLATFORMS, SUITES, BRANCH_UNITTEST_VARS, SLAVES, TRY_SLAVES, PROJECTS
-from master_localconfig import ACTIVE_BRANCHES, ACTIVE_PLATFORMS, ACTIVE_PROJECTS
+from thunderbird_config import BRANCHES as THUNDERBIRD_BRANCHES
+from thunderbird_config import PLATFORMS as THUNDERBIRD_PLATFORMS
+from thunderbird_config import SUITES as THUNDERBIRD_SUITES
+from thunderbird_config import BRANCH_UNITTEST_VARS as THUNDERBIRD_BRANCH_UNITTEST_VARS
+from master_localconfig import ACTIVE_BRANCHES, ACTIVE_PLATFORMS, ACTIVE_PROJECTS, \
+    ACTIVE_THUNDERBIRD_BRANCHES, ACTIVE_THUNDERBIRD_PLATFORMS
 
 import BuildSlaves
 reload(BuildSlaves)
 from BuildSlaves import SlavePasswords
 from buildbot.buildslave import BuildSlave
 
-# Handle active platforms
+# Handle active platforms - Firefox
 all_slave_platforms = []
 for p in ACTIVE_PLATFORMS.keys():
      ACTIVE_PLATFORMS[p] = deepcopy(PLATFORMS[p])
      all_slave_platforms.extend(PLATFORMS[p]['slave_platforms'])
 
-# Remove non-active platform entries for projects
+# Handle active platforms - Thunderbird
+tb_all_slave_platforms = []
+for p in ACTIVE_THUNDERBIRD_PLATFORMS.keys():
+    #XXX we shouldn't have to filter these platforms
+    if p in THUNDERBIRD_PLATFORMS:
+        ACTIVE_THUNDERBIRD_PLATFORMS[p] = deepcopy(THUNDERBIRD_PLATFORMS[p])
+        tb_all_slave_platforms.extend(THUNDERBIRD_PLATFORMS[p]['slave_platforms'])
+
+# Remove non-active platform entries for projects - Firefox only
 for p in PROJECTS:
     if 'platforms' in PROJECTS[p]:
         for project_slave_platform in PROJECTS[p]['platforms'].keys():
             if project_slave_platform not in all_slave_platforms:
                 del PROJECTS[p]['platforms'][project_slave_platform]
 
 for slave_platform, slaves in SLAVES.items():
     # If this platform isn't active, skip it!
-    if slave_platform not in all_slave_platforms:
+    if slave_platform not in all_slave_platforms and slave_platform not in tb_all_slave_platforms:
         continue
     for name in sorted(slaves.keys()):
         c['slaves'].append(BuildSlave(name, SlavePasswords[slave_platform], max_builds=1,
                                       properties=slaves[name]))
 
+# I have no idea why this block exists - bhearsum
 if 'try' in ACTIVE_BRANCHES:
     for slave_platform, slaves in TRY_SLAVES.items():
         # If this platform isn't active, skip it!
-        if slave_platform not in all_slave_platforms:
+        if slave_platform not in all_slave_platforms and slave_platform not in tb_all_slave_platforms:
             continue
         for name in sorted(slaves.keys()):
             c['slaves'].append(BuildSlave(name, SlavePasswords[slave_platform], max_builds=1,
                                           properties=slaves[name]))
 
 from buildbotcustom.misc import generateTalosBranchObjects, generateProjectObjects, \
          mergeBuildObjects
 
@@ -78,16 +94,27 @@ from buildbot.schedulers.triggerable imp
 buildObjects = {}
 
 for branch in ACTIVE_BRANCHES:
     talosObjects = generateTalosBranchObjects(branch, BRANCHES[branch],
                                                 ACTIVE_PLATFORMS, BRANCHES[branch].get('suites', SUITES),
                                                 BRANCH_UNITTEST_VARS['platforms'])
     buildObjects = mergeBuildObjects(buildObjects, talosObjects)
 
+#XXX we should not have these mobile platforms in Thunderbird to begin with
+for b in ['android', 'android-xul', 'linux-android']:
+    if b in ACTIVE_THUNDERBIRD_PLATFORMS:
+        del ACTIVE_THUNDERBIRD_PLATFORMS[b]
+for branch in ACTIVE_THUNDERBIRD_BRANCHES:
+    talosObjects = generateTalosBranchObjects(branch, THUNDERBIRD_BRANCHES[branch],
+                                                ACTIVE_THUNDERBIRD_PLATFORMS,
+                                                THUNDERBIRD_BRANCHES[branch].get('suites', THUNDERBIRD_SUITES),
+                                                THUNDERBIRD_BRANCH_UNITTEST_VARS['platforms'])
+    buildObjects = mergeBuildObjects(buildObjects, talosObjects)
+
 for project in ACTIVE_PROJECTS:
     projectObjects = generateProjectObjects(project, PROJECTS[project], SLAVES)
     buildObjects = mergeBuildObjects(buildObjects, projectObjects)
 
 # We only want builders, status objects
 c['builders'].extend(buildObjects['builders'])
 c['status'].extend(buildObjects['status'])
 # We need just the triggerable schedulers here
new file mode 100644
--- /dev/null
+++ b/mozilla-tests/thunderbird_config.py
@@ -0,0 +1,468 @@
+from copy import deepcopy
+
+from config import BRANCH_UNITTEST_VARS, MOZHARNESS_REPO
+from localconfig import SLAVES, TRY_SLAVES, GLOBAL_VARS, GRAPH_CONFIG, \
+                        PLATFORM_VARS
+
+import thunderbird_localconfig
+reload(thunderbird_localconfig)
+
+GLOBAL_VARS = deepcopy(GLOBAL_VARS)
+BRANCH_UNITTEST_VARS = deepcopy(BRANCH_UNITTEST_VARS)
+
+GLOBAL_VARS['stage_username'] = 'tbirdbld'
+GLOBAL_VARS.update(thunderbird_localconfig.GLOBAL_VARS.copy())
+
+BRANCH_UNITTEST_VARS
+
+BRANCHES = {
+    'comm-central': {
+    },
+    'comm-release': {
+    },
+    'comm-beta': {
+    },
+    'comm-aurora': {
+    },
+    'comm-esr10': {
+    },
+}
+
+PLATFORMS = {                                                                                      
+    'macosx': {},                                                                                  
+    'macosx64': {},                                                                                
+    'win32': {},                                                                                   
+    'win64': {},                                                                                   
+    'linux': {},                                                                                   
+    'linux64' : {},                                                                                
+}
+
+# work around path length problem bug 599795
+# leopard-o == leopard-old
+PLATFORMS['macosx']['slave_platforms'] = ['leopard-o']
+PLATFORMS['macosx']['env_name'] = 'mac-perf'
+PLATFORMS['macosx']['leopard-o'] = {'name': "Rev3 MacOSX Leopard 10.5.8"}
+PLATFORMS['macosx']['stage_product'] = 'thunderbird'
+PLATFORMS['macosx']['mozharness_python'] = '/tools/buildbot/bin/python'
+
+PLATFORMS['macosx64']['slave_platforms'] = ['leopard', 'snowleopard',
+                                            'lion']
+PLATFORMS['macosx64']['env_name'] = 'mac-perf'
+PLATFORMS['macosx64']['leopard'] = {'name': "Rev3 MacOSX Leopard 10.5.8"}
+PLATFORMS['macosx64']['snowleopard'] = {'name': "Rev4 MacOSX Snow Leopard 10.6"}
+PLATFORMS['macosx64']['lion'] = {'name': "Rev4 MacOSX Lion 10.7"}
+PLATFORMS['macosx64']['stage_product'] = 'thunderbird'
+PLATFORMS['macosx64']['mozharness_python'] = '/tools/buildbot/bin/python'
+
+PLATFORMS['win32']['slave_platforms'] = ['xp', 'win7']
+PLATFORMS['win32']['env_name'] = 'win32-perf'
+PLATFORMS['win32']['xp'] = {'name': "Rev3 WINNT 5.1"}
+PLATFORMS['win32']['win7'] = {'name': "Rev3 WINNT 6.1"}
+PLATFORMS['win32']['stage_product'] = 'thunderbird'
+PLATFORMS['win32']['mozharness_python'] = ['c:/mozilla-build/python25/python', '-u']
+
+PLATFORMS['win64']['slave_platforms'] = ['w764']
+PLATFORMS['win64']['env_name'] = 'win64-perf'
+PLATFORMS['win64']['w764'] = {'name': "Rev3 WINNT 6.1 x64",
+                              'download_symbols': False,
+                             }
+PLATFORMS['win64']['stage_product'] = 'thunderbird'
+PLATFORMS['win64']['mozharness_python'] = ['c:/mozilla-build/python25/python', '-u']
+
+PLATFORMS['linux']['slave_platforms'] = ['fedora']
+PLATFORMS['linux']['env_name'] = 'linux-perf'
+PLATFORMS['linux']['fedora'] = {'name': "Rev3 Fedora 12"}
+PLATFORMS['linux']['stage_product'] = 'thunderbird'
+PLATFORMS['linux']['mozharness_python'] = '/tools/buildbot/bin/python'
+
+PLATFORMS['linux64']['slave_platforms'] = ['fedora64']
+PLATFORMS['linux64']['env_name'] = 'linux-perf'
+PLATFORMS['linux64']['fedora64'] = {'name': "Rev3 Fedora 12x64"}
+PLATFORMS['linux64']['stage_product'] = 'thunderbird'
+PLATFORMS['linux64']['mozharness_python'] = '/tools/buildbot/bin/python'
+
+# Lets be explicit instead of magical.  leopard-o should be a second
+# entry in the SLAVE dict
+for platform, platform_config in PLATFORMS.items():
+    for slave_platform in platform_config['slave_platforms']:
+        platform_config[slave_platform]['slaves'] = sorted(SLAVES[slave_platform])
+        if slave_platform in TRY_SLAVES:
+            platform_config[slave_platform]['try_slaves'] = sorted(TRY_SLAVES[slave_platform])
+        else:
+            platform_config[slave_platform]['try_slaves'] = platform_config[slave_platform]['slaves']
+
+MOBILE_PLATFORMS = []
+
+ALL_PLATFORMS = PLATFORMS['linux']['slave_platforms'] + \
+                PLATFORMS['linux64']['slave_platforms'] + \
+                PLATFORMS['win32']['slave_platforms'] + \
+                PLATFORMS['macosx64']['slave_platforms']
+
+WIN7_ONLY = ['win7']
+
+NO_WIN = PLATFORMS['macosx64']['slave_platforms'] + PLATFORMS['linux']['slave_platforms'] + PLATFORMS['linux64']['slave_platforms']
+
+NO_MAC = PLATFORMS['linux']['slave_platforms'] + \
+         PLATFORMS['linux64']['slave_platforms'] + \
+         PLATFORMS['win32']['slave_platforms']
+
+MAC_ONLY = PLATFORMS['macosx64']['slave_platforms']
+
+ANDROID = []
+
+ANDROID_NATIVE = []
+
+ANDROID_XUL = []
+
+ADDON_TESTER_PLATFORMS = ['win7', 'fedora', 'snowleopard']
+
+SUITES = {}
+
+# these three are for mozilla-1.9.2
+OLD_BRANCH_ALL_PLATFORMS = PLATFORMS['linux']['slave_platforms'] + \
+                PLATFORMS['win32']['slave_platforms'] + \
+                PLATFORMS['macosx']['slave_platforms']
+
+OLD_BRANCH_NO_WIN = PLATFORMS['macosx']['slave_platforms'] + PLATFORMS['linux']['slave_platforms']
+
+OLD_BRANCH_NO_MAC = PLATFORMS['linux']['slave_platforms'] + PLATFORMS['win32']['slave_platforms']
+
+OLD_BRANCH_MAC_ONLY = PLATFORMS['macosx']['slave_platforms'] 
+
+OLD_BRANCH_ADDON_TESTER_PLATFORMS = ['win7'] + ['fedora'] + ['snowleopard']
+
+BRANCH_UNITTEST_VARS = {
+    'hghost': 'hg.mozilla.org',
+    # turn on platforms as we get them running
+    'platforms': {
+        'linux': {},
+        'linux64': {},
+        'macosx': {},
+        'macosx64': {},
+        'win32': {},
+        'win64': {},
+    },
+}
+
+# Default set of unit tests
+UNITTEST_SUITES = {
+    'opt_unittest_suites': [
+        ('xpcshell', ['xpcshell']),
+        ('mozmill', ['mozmill']),
+    ],
+    'debug_unittest_suites': [
+        ('xpcshell', ['xpcshell']),
+        ('mozmill', ['mozmill']),
+    ],
+}
+
+def removeSuite(suiteName, suiteList):
+    '''It removes 'suite' from 'suiteList' and returns it.
+
+    Keyword arguments:
+    suiteName -- it is the name of the suite that we want to remove
+    suiteList -- it is the list of suites from where we want to remove
+                 suiteList is a list of tuples. The tuples is formed
+                 of a string and a list of suites.
+    '''
+    # Let's iterate over each tuple
+    for i, info in enumerate(suiteList):
+        name, suites = info
+        # Let's see if suiteName is on this list of suites
+        if suiteName in suites:
+            suites = suites[:]
+            suites.remove(suiteName)
+            suiteList[i] = (name, suites)
+    return suiteList
+
+def addSuite(suiteGroupName, newSuiteName, suiteList):
+    # In UNITTEST_SUITES we have opt, debug and mobile unit tests keys.
+    # Each one of these have a list of tuples of test suites.
+    #     e.g. suiteGroup = ('reftest', ['reftest])
+    newSuiteList = []
+    added = False
+    for tuple in suiteList:
+        name, suites = tuple
+        if suiteGroupName == name:
+            suites.append(newSuiteName)
+            added = True
+        newSuiteList.append((name, suites))
+
+    if not added:
+        newSuiteList.append((name, suites))
+
+    return newSuiteList
+
+def loadDefaultValues(BRANCHES, branch, branchConfig):
+    BRANCHES[branch]['repo_path'] = branchConfig.get('repo_path', 'projects/' + branch) 
+    BRANCHES[branch]['branch_name'] = branchConfig.get('branch_name', branch.title())
+    BRANCHES[branch]['build_branch'] = branchConfig.get('build_branch', branch.title())
+    BRANCHES[branch]['fetch_symbols'] = branchConfig.get('fetch_symbols', True)
+    BRANCHES[branch]['enable_unittests'] = branchConfig.get('enable_unittests', True)
+    BRANCHES[branch]['pgo_strategy'] = branchConfig.get('pgo_strategy', None)
+
+def loadCustomUnittestSuites(BRANCHES, branch, branchConfig):
+    # If you want a project branch to have a different set of unit tests you can
+    # do the following:
+    #  - add a key called "add_test_suites"
+    #  - add a tuple for each test suite with the following format:
+    #      ('OS_nick', 'platform', 'opt|debug', 'new or existing group', 'suite name')
+    #      e.g. ('macosx64', 'snowleopard', 'debug', 'mochitest-other', 'a11y')
+    #
+    # Old way of adding suites but still the same format
+    #    BRANCHES['mozilla-central']['platforms']['win32']['win7']['debug_unittest_suites'] \
+    #        += [('jetpack', ['jetpack'])]
+    #
+    for suiteToAdd in branchConfig.get('add_test_suites', []):
+        type = 'opt_unittest_suites' if suiteToAdd[2] == 'opt' else 'debug_unittest_suites'
+        # 'debug_unittest_suites' or 'opt_unittest_suites' is a list of tuple
+        # addSuite() modifies that list and returns a new one with the added suite
+        BRANCHES[branch]['platforms'][suiteToAdd[0]][suiteToAdd[1]][type] = \
+            addSuite( suiteGroupName=suiteToAdd[3], newSuiteName=suiteToAdd[4],
+                      suiteList=BRANCHES[branch]['platforms'][suiteToAdd[0]][suiteToAdd[1]][type])
+
+ANDROID_XUL_UNITTEST_DICT = {}
+ANDROID_UNITTEST_DICT = {}
+
+# You must define opt_unittest_suites when enable_opt_unittests is True for a 
+# platform. Likewise debug_unittest_suites for enable_debug_unittests
+PLATFORM_UNITTEST_VARS = {
+        'linux': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'brand_name': 'Daily',
+            'builds_before_reboot': 1,
+            'unittest-env' : {'DISPLAY': ':0'},
+            'enable_opt_unittests': True,
+            'enable_debug_unittests': True,
+            'fedora': {
+                'opt_unittest_suites' : \
+                    UNITTEST_SUITES['opt_unittest_suites'][:],
+                'debug_unittest_suites' : UNITTEST_SUITES['debug_unittest_suites'][:],
+            },
+        },
+        'linux64': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'brand_name': 'Daily',
+            'builds_before_reboot': 1,
+            'unittest-env' : {'DISPLAY': ':0'},
+            'enable_opt_unittests': True,
+            'enable_debug_unittests': True,
+            'fedora64': {
+                'opt_unittest_suites' : UNITTEST_SUITES['opt_unittest_suites'][:],
+                'debug_unittest_suites' : UNITTEST_SUITES['debug_unittest_suites'][:],
+            },
+        },
+        'win32': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'brand_name': 'Daily',
+            'builds_before_reboot': 1,
+            'mochitest_leak_threshold': 484,
+            'crashtest_leak_threshold': 484,
+            'env_name' : 'win32-perf-unittest',
+            'enable_opt_unittests': True,
+            'enable_debug_unittests': True,
+            'xp': {
+                'opt_unittest_suites' : UNITTEST_SUITES['opt_unittest_suites'][:],
+                'debug_unittest_suites' : UNITTEST_SUITES['debug_unittest_suites'][:],
+            },
+            'win7': {
+                'opt_unittest_suites' : \
+                    UNITTEST_SUITES['opt_unittest_suites'][:] + \
+                    [('reftest-no-accel', ['reftest-no-d2d-d3d'])],
+                'debug_unittest_suites' : UNITTEST_SUITES['debug_unittest_suites'][:],
+            }
+        },
+        'win64': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'brand_name': 'Daily',
+            'builds_before_reboot': 1,
+            'download_symbols': False,
+            'enable_opt_unittests': False,
+            # We can't yet run unit tests on debug builds - see bug 562459
+            'enable_debug_unittests': False,
+            'w764': {
+                'opt_unittest_suites' : UNITTEST_SUITES['opt_unittest_suites'][:],
+                'debug_unittest_suites' : UNITTEST_SUITES['debug_unittest_suites'][:],
+            },
+        },
+        'macosx': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'brand_name': 'Daily',
+            'builds_before_reboot': 1,
+            'enable_opt_unittests': True,
+            'enable_debug_unittests': True,
+            'leopard-o': {
+                'opt_unittest_suites' : [],
+                'debug_unittest_suites' : removeSuite('mochitest-a11y', UNITTEST_SUITES['debug_unittest_suites'][:]),
+            },
+        },
+        'macosx64': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'brand_name': 'Daily',
+            'builds_before_reboot': 1,
+            'enable_opt_unittests': True,
+            'enable_debug_unittests': True,
+            'leopard': {
+                'opt_unittest_suites' : removeSuite('mochitest-a11y', UNITTEST_SUITES['opt_unittest_suites'][:]),
+                'debug_unittest_suites' : [],
+            },
+            'snowleopard': {
+                'opt_unittest_suites' : removeSuite('mochitest-a11y', UNITTEST_SUITES['opt_unittest_suites'][:]),
+                'debug_unittest_suites' : removeSuite('mochitest-a11y', UNITTEST_SUITES['debug_unittest_suites'][:]),
+            },
+            'lion': {
+                'opt_unittest_suites' : removeSuite('mochitest-a11y', UNITTEST_SUITES['opt_unittest_suites'][:]),
+                'debug_unittest_suites' : removeSuite('mochitest-a11y', UNITTEST_SUITES['debug_unittest_suites'][:]),
+            },
+        },
+}
+
+# Copy project branches into BRANCHES keys
+#for branch in ACTIVE_PROJECT_BRANCHES:
+#    BRANCHES[branch] = deepcopy(PROJECT_BRANCHES[branch])
+
+# Copy unittest vars in first, then platform vars
+for branch in BRANCHES.keys():
+    for key, value in GLOBAL_VARS.items():
+        # Don't override platforms if it's set
+        if key == 'platforms' and 'platforms' in BRANCHES[branch]:
+            continue
+        BRANCHES[branch][key] = deepcopy(value)
+
+    for key, value in BRANCH_UNITTEST_VARS.items():
+        # Don't override platforms if it's set and locked
+        if key == 'platforms' and 'platforms' in BRANCHES[branch] and BRANCHES[branch].get('lock_platforms'):
+            continue
+        BRANCHES[branch][key] = deepcopy(value)
+
+    for platform, platform_config in PLATFORM_UNITTEST_VARS.items():
+        if platform in BRANCHES[branch]['platforms']:
+            for key, value in platform_config.items():
+                value = deepcopy(value)
+                if isinstance(value, str):
+                    value = value % locals()
+                BRANCHES[branch]['platforms'][platform][key] = value
+
+    # Copy in local config
+    if branch in thunderbird_localconfig.BRANCHES:
+        for key, value in thunderbird_localconfig.BRANCHES[branch].items():
+            if key == 'platforms':
+                # Merge in these values
+                if 'platforms' not in BRANCHES[branch]:
+                    BRANCHES[branch]['platforms'] = {}
+
+                for platform, platform_config in value.items():
+                    for key, value in platform_config.items():
+                        value = deepcopy(value)
+                        if isinstance(value, str):
+                            value = value % locals()
+                        BRANCHES[branch]['platforms'][platform][key] = value
+            else:
+                BRANCHES[branch][key] = deepcopy(value)
+ 
+    # Merge in any project branch config for platforms
+#    if branch in ACTIVE_PROJECT_BRANCHES and PROJECT_BRANCHES[branch].has_key('platforms'):
+#        for platform, platform_config in PROJECT_BRANCHES[branch]['platforms'].items():
+#            if platform in PLATFORMS:
+#                for key, value in platform_config.items():
+#                    value = deepcopy(value)
+#                    if isinstance(value, str):
+#                        value = value % locals()
+#                    BRANCHES[branch]['platforms'][platform][key] = value
+
+    for platform, platform_config in thunderbird_localconfig.PLATFORM_VARS.items():
+        if platform in BRANCHES[branch]['platforms']:
+            for key, value in platform_config.items():
+                value = deepcopy(value)
+                if isinstance(value, str):
+                    value = value % locals()
+                BRANCHES[branch]['platforms'][platform][key] = value
+
+########
+# Entries in BRANCHES for tests should be a tuple of:
+# - Number of tests to run per build
+# - Whether queue merging is on
+# - TalosFactory options
+# - Which platforms to run on
+
+# Let's load the defaults
+for branch in BRANCHES.keys():
+    BRANCHES[branch]['repo_path'] = branch
+    BRANCHES[branch]['branch_name'] = branch.title()
+    BRANCHES[branch]['build_branch'] = branch.title()
+    BRANCHES[branch]['enable_unittests'] = True
+    BRANCHES[branch]['fetch_symbols'] = True
+    BRANCHES[branch]['fetch_release_symbols'] = False
+    if BRANCHES[branch].has_key('release_branch'):
+        BRANCHES[branch]['release_tests'] = 5
+        BRANCHES[branch]['repo_path'] = "releases/%s" % branch
+    BRANCHES[branch]['pgo_strategy'] = None
+    BRANCHES[branch]['pgo_platforms'] = ['linux', 'linux64', 'win32']
+
+# The following are exceptions to the defaults
+
+######## comm-central
+BRANCHES['comm-central']['branch_name'] = "Thunderbird"
+BRANCHES['comm-central']['repo_path'] = "comm-central"
+#BRANCHES['comm-central']['build_branch'] = "1.9.2"
+BRANCHES['comm-central']['pgo_strategy'] = 'periodic'
+# Let's add win64 tests only for comm-central until we have enough capacity - see bug 667024
+# XXX hacking warning - this code could get out of date easily
+BRANCHES['comm-central']['platforms']['win64']['enable_opt_unittests'] = True
+for suite in SUITES.keys():
+    options = SUITES[suite]['options']
+    if options[1] == ALL_PLATFORMS:
+        options = (options[0], ALL_PLATFORMS + PLATFORMS['win64']['slave_platforms'])
+    if options[1] == NO_MAC:
+        options = (options[0], NO_MAC + PLATFORMS['win64']['slave_platforms'])
+    if not SUITES[suite]['enable_by_default']:
+        # Suites that are turned off by default
+        BRANCHES['comm-central'][suite + '_tests'] = (0, True) + options
+    else:
+        # Suites that are turned on by default
+        BRANCHES['comm-central'][suite + '_tests'] = (1, True) + options
+BRANCHES['comm-central']['xperf_tests'] = (1, True, {}, WIN7_ONLY)
+
+######## comm-release
+BRANCHES['comm-release']['pgo_strategy'] = 'per-checkin'
+
+######## comm-beta
+BRANCHES['comm-beta']['pgo_strategy'] = 'per-checkin'
+
+######## comm-aurora
+BRANCHES['comm-aurora']['pgo_strategy'] = 'per-checkin'
+
+######## comm-esr10
+BRANCHES['comm-esr10']['pgo_strategy'] = 'per-checkin'
+
+if __name__ == "__main__":
+    import sys, pprint, re
+
+    class BBPrettyPrinter(pprint.PrettyPrinter):
+        def format(self, object, context, maxlevels, level):
+            if isinstance(object, WithProperties):
+                return pprint.PrettyPrinter.format(self, object.fmtstring, context, maxlevels, level)
+            return pprint.PrettyPrinter.format(self, object, context, maxlevels, level)
+
+    args = sys.argv[1:]
+
+    if len(args) > 0:
+        branches = args
+    else:
+        branches = BRANCHES.keys()
+
+    pp = BBPrettyPrinter()
+    for branch in branches:
+        print branch
+        pp.pprint(BRANCHES[branch])
+
+    for suite in SUITES:
+        print suite
+        pp.pprint(SUITES[suite])
+
new file mode 100644
--- /dev/null
+++ b/mozilla-tests/thunderbird_production_config.py
@@ -0,0 +1,46 @@
+from copy import deepcopy
+
+from production_config import \
+    GLOBAL_VARS, SLAVES, TRY_SLAVES, GRAPH_CONFIG
+
+
+GLOBAL_VARS = deepcopy(GLOBAL_VARS)
+
+GLOBAL_VARS['disable_tinderbox_mail'] = True
+GLOBAL_VARS['stage_username'] = 'tbirdbld'
+GLOBAL_VARS['stage_ssh_key'] = 'tbirdbld_dsa'
+
+# Local branch overrides
+BRANCHES = {
+    'comm-central': {
+        'tinderbox_tree': 'ThunderbirdTrunk',
+    },
+    'comm-release': {
+        'tinderbox_tree': 'Thunderbird-Release',
+    },
+    'comm-esr10': {
+        'tinderbox_tree': 'Thunderbird-Esr10',
+    },
+    'comm-beta': {
+        'tinderbox_tree': 'Thunderbird-Beta',
+    },
+    'comm-aurora': {
+        'tinderbox_tree': 'Thunderbird-Aurora',
+    },
+    'try-comm-central': {
+        'tinderbox_tree': 'ThunderbirdTry',
+        'enable_mail_notifier': True,
+        'notify_real_author': True,
+        'enable_merging': False,
+        'slave_key': 'try_slaves',
+        'package_url': 'http://ftp.mozilla.org/pub/mozilla.org/thunderbird/try-builds',
+        'package_dir': '%(who)s-%(got_revision)s',
+        'stage_username': 'tbirdbld',
+        'stage_ssh_key': 'tbirdbld_dsa',
+    },
+}
+
+PLATFORM_VARS = {}
+
+PROJECTS = {}
+
new file mode 100644
--- /dev/null
+++ b/mozilla-tests/thunderbird_staging_config.py
@@ -0,0 +1,26 @@
+from copy import deepcopy
+
+from staging_config import GLOBAL_VARS, SLAVES, TRY_SLAVES
+
+GLOBAL_VARS = deepcopy(GLOBAL_VARS)
+
+GLOBAL_VARS['disable_tinderbox_mail'] = True
+GLOBAL_VARS['tinderbox_tree'] = 'ThunderbirdTest'
+GLOBAL_VARS['stage_username'] = 'tbirdbld'
+GLOBAL_VARS['stage_ssh_key'] = 'tbirdbld_dsa'
+
+BRANCHES = {
+    'try-comm-central': {
+            'enable_mail_notifier': False, # Set to True when testing
+            'email_override': [], # Set to your address when testing
+            'package_url': 'http://dev-stage01.build.sjc1.mozilla.com/pub/mozilla.org/thunderbird/try-builds',
+            'package_dir': '%(who)s-%(got_revision)s',
+            'stage_username': 'tbirdbld',
+            'stage_ssh_key': 'tbirdbld_dsa',
+    },
+}
+
+PLATFORM_VARS = {}
+
+PROJECTS = {}
+
--- a/mozilla-tests/universal_master_sqlite.cfg
+++ b/mozilla-tests/universal_master_sqlite.cfg
@@ -2,21 +2,23 @@
 import os, sys
 from copy import deepcopy
 
 # import/reload dance so that reconfigs work
 import buildbotcustom.misc
 import buildbotcustom.status.queued_command
 import master_common
 import config
+import thunderbird_config
 import master_localconfig
 reload(buildbotcustom.misc)
 reload(buildbotcustom.status.queued_command)
 reload(master_common)
 reload(config)
+reload(thunderbird_config)
 reload(master_localconfig)
 
 from master_common import BuildmasterConfig
 c = BuildmasterConfig
 for key, value in master_localconfig.BuildmasterConfig.items():
     if key in c:
         c[key].extend(value)
     else:
@@ -28,64 +30,89 @@ from mozilla_buildtools.queuedir import 
 commandsQueue = QueueDir('commands', '%s/commands' % master_localconfig.QUEUEDIR)
 from buildbotcustom.status.queued_command import QueuedCommandHandler
 c['status'].append(QueuedCommandHandler(
     command=[sys.executable, os.path.join(os.path.dirname(buildbotcustom.__file__), 'bin', 'postrun.py'), '-c', os.path.abspath(os.path.join(os.curdir, 'postrun.cfg'))],
     queuedir=commandsQueue,
 ))
 
 from config import BRANCHES, PLATFORMS, SUITES, BRANCH_UNITTEST_VARS, SLAVES, TRY_SLAVES, PROJECTS
-from master_localconfig import ACTIVE_BRANCHES, ACTIVE_PLATFORMS, ACTIVE_PROJECTS
+from thunderbird_config import BRANCHES as THUNDERBIRD_BRANCHES
+from thunderbird_config import PLATFORMS as THUNDERBIRD_PLATFORMS
+from thunderbird_config import BRANCH_UNITTEST_VARS as THUNDERBIRD_BRANCH_UNITTEST_VARS
+from thunderbird_config import SUITES as THUNDERBIRD_SUITES
+from master_localconfig import ACTIVE_BRANCHES, ACTIVE_PLATFORMS, ACTIVE_PROJECTS, \
+    ACTIVE_THUNDERBIRD_BRANCHES, ACTIVE_THUNDERBIRD_PLATFORMS
 
 import BuildSlaves
 reload(BuildSlaves)
 from BuildSlaves import SlavePasswords
 from buildbot.buildslave import BuildSlave
 
-# Handle active platforms
+# Handle active platforms - Firefox
 all_slave_platforms = []
 for p in ACTIVE_PLATFORMS.keys():
      ACTIVE_PLATFORMS[p] = deepcopy(PLATFORMS[p])
      all_slave_platforms.extend(PLATFORMS[p]['slave_platforms'])
 
+# Handle active platforms - Thunderbird
+tb_all_slave_platforms = []
+for p in ACTIVE_THUNDERBIRD_PLATFORMS.keys():
+     #XXX we shouldn't have to filter these platforms
+     if p in THUNDERBIRD_PLATFORMS:
+         ACTIVE_THUNDERBIRD_PLATFORMS[p] = deepcopy(THUNDERBIRD_PLATFORMS[p])
+         tb_all_slave_platforms.extend(THUNDERBIRD_PLATFORMS[p]['slave_platforms'])
+
 # Remove non-active platform entries for projects
 for p in PROJECTS:
     if 'platforms' in PROJECTS[p]:
         for project_slave_platform in PROJECTS[p]['platforms'].keys():
             if project_slave_platform not in all_slave_platforms:
                 del PROJECTS[p]['platforms'][project_slave_platform]
 
 for slave_platform, slaves in SLAVES.items():
     # If this platform isn't active, skip it!
-    if slave_platform not in all_slave_platforms:
+    if slave_platform not in all_slave_platforms and slave_platform not in tb_all_slave_platforms:
         continue
     for name in sorted(slaves.keys()):
         c['slaves'].append(BuildSlave(name, SlavePasswords[slave_platform], max_builds=1,
                                       properties=slaves[name]))
 
 if 'try' in ACTIVE_BRANCHES:
     for slave_platform, slaves in TRY_SLAVES.items():
         # If this platform isn't active, skip it!
-        if slave_platform not in all_slave_platforms:
+        if slave_platform not in all_slave_platforms and slave_platform not in tb_all_slave_platforms:
             continue
         for name in sorted(slaves.keys()):
             c['slaves'].append(BuildSlave(name, SlavePasswords[slave_platform], max_builds=1,
                                           properties=slaves[name]))
 
 from buildbotcustom.misc import generateTalosBranchObjects, generateProjectObjects, \
          mergeBuildObjects
 
 buildObjects = {}
 
 for branch in ACTIVE_BRANCHES:
     talosObjects = generateTalosBranchObjects(branch, BRANCHES[branch],
                                                 ACTIVE_PLATFORMS, BRANCHES[branch].get('suites', SUITES),
                                                 BRANCH_UNITTEST_VARS['platforms'])
     buildObjects = mergeBuildObjects(buildObjects, talosObjects)
 
+#XXX we should not have these mobile platforms in Thunderbird to begin with
+for b in ['android', 'android-xul', 'linux-android']:
+    if b in ACTIVE_THUNDERBIRD_PLATFORMS:
+        del ACTIVE_THUNDERBIRD_PLATFORMS[b]
+
+for branch in ACTIVE_THUNDERBIRD_BRANCHES:
+    talosObjects = generateTalosBranchObjects(branch, THUNDERBIRD_BRANCHES[branch],
+                                                ACTIVE_THUNDERBIRD_PLATFORMS,
+                                                THUNDERBIRD_BRANCHES[branch].get('suites', THUNDERBIRD_SUITES),
+                                                THUNDERBIRD_BRANCH_UNITTEST_VARS['platforms'])
+    buildObjects = mergeBuildObjects(buildObjects, talosObjects)
+
 for project in ACTIVE_PROJECTS:
     projectObjects = generateProjectObjects(project, PROJECTS[project], SLAVES)
     buildObjects = mergeBuildObjects(buildObjects, projectObjects)
 
 c['builders'].extend(buildObjects['builders'])
 c['status'].extend(buildObjects['status'])
 c['schedulers'].extend(buildObjects['schedulers'])
 c['change_source'].extend(buildObjects['change_source'])
--- a/mozilla/build_localconfig.py
+++ b/mozilla/build_localconfig.py
@@ -23,16 +23,23 @@ ACTIVE_BRANCHES = ACTIVE_PROJECT_BRANCHE
 ACTIVE_BRANCHES.extend([
     'mozilla-1.9.2',
     'mozilla-central',
     'mozilla-beta',
     'mozilla-aurora',
     'mozilla-release',
     'mozilla-esr10',
     ])
+ACTIVE_THUNDERBIRD_BRANCHES = [
+    'comm-central',
+    'comm-beta',
+    'comm-aurora',
+    'comm-release',
+    'comm-esr10',
+]
 ACTIVE_PROJECTS = PROJECTS.keys()
 
 ACTIVE_RELEASE_BRANCHES = []
 ACTIVE_MOBILE_RELEASE_BRANCHES = []
 ENABLE_RELEASES = False
 if 'release_branches' in master_config:
     ACTIVE_RELEASE_BRANCHES.extend(master_config['release_branches'])
     ENABLE_RELEASES = True
--- a/mozilla/builder_master.cfg
+++ b/mozilla/builder_master.cfg
@@ -3,22 +3,24 @@
 # so that the fastRegexes don't get reset
 # vim: ft=python
 import os, sys
 
 import buildbotcustom.misc
 import buildbotcustom.status.queued_command
 import master_common
 import config
+import thunderbird_config
 import master_localconfig
 import build.paths
 reload(buildbotcustom.misc)
 reload(buildbotcustom.status.queued_command)
 reload(master_common)
 reload(config)
+reload(thunderbird_config)
 reload(master_localconfig)
 reload(build.paths)
 
 from master_common import BuildmasterConfig
 from build.paths import getRealpath
 
 c = BuildmasterConfig
 for key, value in master_localconfig.BuildmasterConfig.items():
@@ -33,19 +35,20 @@ from mozilla_buildtools.queuedir import 
 commandsQueue = QueueDir('commands', '%s/commands' % master_localconfig.QUEUEDIR)
 from buildbotcustom.status.queued_command import QueuedCommandHandler
 c['status'].append(QueuedCommandHandler(
     command=[sys.executable, os.path.join(os.path.dirname(buildbotcustom.__file__), 'bin', 'postrun.py'), '-c', os.path.abspath(os.path.join(os.curdir, 'postrun.cfg'))],
     queuedir=commandsQueue,
 ))
 
 from config import BRANCHES, PROJECTS
+from thunderbird_config import BRANCHES as THUNDERBIRD_BRANCHES
 from master_localconfig import ACTIVE_BRANCHES, ACTIVE_PROJECTS, SLAVES, \
          ENABLE_RELEASES, RESERVED_SLAVES, ACTIVE_RELEASE_BRANCHES, \
-         ACTIVE_MOBILE_RELEASE_BRANCHES
+         ACTIVE_MOBILE_RELEASE_BRANCHES, ACTIVE_THUNDERBIRD_BRANCHES
 
 import BuildSlaves
 reload(BuildSlaves)
 from BuildSlaves import SlavePasswords
 from buildbot.buildslave import BuildSlave
 
 for platform, names in SLAVES.items():
     for name in names:
@@ -64,16 +67,21 @@ buildObjects = {'builders': [], 'status'
 import passwords
 reload(passwords)
 
 for branch in ACTIVE_BRANCHES:
     branchObjects = generateBranchObjects(BRANCHES[branch], branch,
             getattr(passwords, 'secrets', None))
     buildObjects = mergeBuildObjects(buildObjects, branchObjects)
 
+for branch in ACTIVE_THUNDERBIRD_BRANCHES:
+    branchObjects = generateBranchObjects(THUNDERBIRD_BRANCHES[branch], branch,
+            getattr(passwords, 'secrets', None))
+    buildObjects = mergeBuildObjects(buildObjects, branchObjects)
+
 for project in ACTIVE_PROJECTS:
     projectObjects = generateProjectObjects(project, PROJECTS[project], SLAVES)
     buildObjects = mergeBuildObjects(buildObjects, projectObjects)
 
 # We only want builders, status objects, and triggerable schedulers
 c['builders'].extend(buildObjects['builders'])
 c['status'].extend(buildObjects['status'])
 for s in buildObjects['schedulers']:
new file mode 100644
--- /dev/null
+++ b/mozilla/release-thunderbird-comm-beta.py
@@ -0,0 +1,123 @@
+releaseConfig = {}
+releaseConfig['disable_tinderbox_mail'] = True
+
+# Release Notification
+releaseConfig['AllRecipients']       = ['release@mozilla.com','akeybl@mozilla.com','Callek@gmail.com']
+releaseConfig['ImportantRecipients'] = ['release-drivers@mozilla.org',]
+releaseConfig['AVVendorsRecipients'] = ['av-vendor-release-announce@mozilla.org',]
+releaseConfig['releaseTemplates']    = 'release_templates'
+releaseConfig['messagePrefix']       = '[release] '
+
+# Basic product configuration
+#  Names for the product/files
+releaseConfig['productName']         = 'thunderbird'
+releaseConfig['appName']             = 'mail'
+releaseConfig['binaryName']          = releaseConfig['productName'].capitalize()
+releaseConfig['oldBinaryName']       = releaseConfig['binaryName']
+#  Current version info
+releaseConfig['version']             = '12.0b4'
+releaseConfig['appVersion']          = '12.0'
+releaseConfig['milestone']           = '12.0'
+releaseConfig['buildNumber']         = 1
+releaseConfig['baseTag']             = 'THUNDERBIRD_12_0b4'
+#  Old version info
+releaseConfig['oldVersion']          = '12.0b3'
+releaseConfig['oldAppVersion']       = '12.0'
+releaseConfig['oldBuildNumber']      = 1
+releaseConfig['oldBaseTag']          = 'THUNDERBIRD_12_0b3'
+#  Next (nightly) version info
+releaseConfig['nextAppVersion']      = releaseConfig['appVersion']
+releaseConfig['nextMilestone']       = releaseConfig['milestone']
+#  Repository configuration, for tagging
+releaseConfig['sourceRepositories']  = {
+    'mozilla': {
+        'name': 'comm-beta',
+        'path': 'releases/comm-beta',
+        'revision': 'fa4685b8588e',
+        'relbranch': None,
+        'bumpFiles': {
+            'mail/config/version.txt': {
+                'version': releaseConfig['appVersion'],
+                'nextVersion': releaseConfig['nextAppVersion']
+            },
+        }
+    }
+}
+#  L10n repositories
+releaseConfig['l10nRelbranch']       = None
+releaseConfig['l10nRepoPath']        = 'releases/l10n/mozilla-beta'
+releaseConfig['l10nRevisionFile']    = 'l10n-thunderbird-changesets-beta'
+#  Support repositories
+releaseConfig['otherReposToTag']     = {
+    'build/compare-locales': 'RELEASE_AUTOMATION',
+    'build/buildbot': 'production-0.8',
+    'build/mozharness': 'default',
+}
+
+# Platform configuration
+releaseConfig['enUSPlatforms']       = ('linux', 'linux64', 'win32', 'macosx64')
+releaseConfig['notifyPlatforms']     = releaseConfig['enUSPlatforms']
+releaseConfig['talosTestPlatforms']  = ()
+releaseConfig['xulrunnerPlatforms']  = ()
+
+# Unittests
+releaseConfig['unittestPlatforms']   = ()
+releaseConfig['enableUnittests']     = True
+
+# L10n configuration
+releaseConfig['l10nPlatforms']       = releaseConfig['enUSPlatforms']
+releaseConfig['shippedLocalesPath']  = 'mail/locales/shipped-locales'
+releaseConfig['l10nChunks']          = 6
+releaseConfig['mergeLocales']        = True
+
+# Mercurial account
+releaseConfig['hgUsername']          = 'tbirdbld'
+releaseConfig['hgSshKey']            = '~cltbld/.ssh/tbirdbld_dsa'
+
+# Update-specific configuration
+releaseConfig['cvsroot']             = ':ext:cltbld@cvs.mozilla.org:/cvsroot'
+releaseConfig['patcherConfig']       = 'mozBeta-thunderbird-branch-patcher2.cfg'
+releaseConfig['commitPatcherConfig'] = True
+releaseConfig['patcherToolsTag']     = 'UPDATE_PACKAGING_R16'
+releaseConfig['ftpServer']           = 'ftp.mozilla.org'
+releaseConfig['stagingServer']       = 'stage.mozilla.org'
+releaseConfig['bouncerServer']       = 'download.mozilla.org'
+releaseConfig['ausServerUrl']        = 'https://aus3.mozilla.org'
+releaseConfig['ausHost']             = 'aus2-staging.mozilla.org'
+releaseConfig['ausUser']             = 'tbirdbld'
+releaseConfig['ausSshKey']           = 'tbirdbld_dsa'
+releaseConfig['releaseNotesUrl']     = 'http://live.mozillamessaging.com/thunderbird/releasenotes?locale=%locale%&platform=%platform%&version=%version%'
+releaseConfig['testOlderPartials']   = False
+releaseConfig['verifyConfigs']       = {
+    'linux':  'mozBeta-thunderbird-linux.cfg',
+    'linux64':  'mozBeta-thunderbird-linux64.cfg',
+    'macosx64': 'mozBeta-thunderbird-mac64.cfg',
+    'win32':  'mozBeta-thunderbird-win32.cfg'
+}
+releaseConfig['mozconfigs']          = {
+    'linux': 'mail/config/mozconfigs/linux32/release',
+    'linux64': 'mail/config/mozconfigs/linux64/release',
+    'macosx64': 'mail/config/mozconfigs/macosx-universal/release',
+    'win32': 'mail/config/mozconfigs/win32/release',
+}
+releaseConfig['xulrunner_mozconfigs']          = {}
+releaseConfig['releaseChannel']      = 'beta'
+
+# Partner repack configuration
+releaseConfig['doPartnerRepacks']    = False
+releaseConfig['partnersRepoPath']    = 'build/partner-repacks'
+
+# Major update configuration
+releaseConfig['majorUpdateRepoPath'] = None
+# Tuxedo/Bouncer configuration
+releaseConfig['tuxedoConfig']        = 'thunderbird-tuxedo.ini'
+releaseConfig['tuxedoServerUrl']     = 'https://bounceradmin.mozilla.com/api/'
+releaseConfig['extraBouncerPlatforms'] = ('solaris-sparc', 'solaris-i386',
+                                          'opensolaris-sparc',
+                                          'opensolaris-i386')
+releaseConfig['releaseUptake']       = 3
+releaseConfig['releasetestUptake']   = 1
+
+# Misc configuration
+releaseConfig['enable_repo_setup'] = False
+releaseConfig['enableAutomaticPushToMirrors'] = True
new file mode 100644
--- /dev/null
+++ b/mozilla/release-thunderbird-comm-esr10.py
@@ -0,0 +1,124 @@
+releaseConfig = {}
+releaseConfig['disable_tinderbox_mail'] = True
+
+# Release Notification
+releaseConfig['AllRecipients']       = ['release@mozilla.com','akeybl@mozilla.com',]
+releaseConfig['ImportantRecipients'] = ['release-drivers@mozilla.org',]
+releaseConfig['AVVendorsRecipients'] = ['av-vendor-release-announce@mozilla.org',]
+releaseConfig['releaseTemplates']    = 'release_templates'
+releaseConfig['messagePrefix']       = '[release] '
+
+# Basic product configuration
+#  Names for the product/files
+releaseConfig['productName']         = 'thunderbird'
+releaseConfig['appName']             = 'mail'
+releaseConfig['binaryName']          = releaseConfig['productName'].capitalize()
+releaseConfig['oldBinaryName']       = releaseConfig['binaryName']
+#  Current version info
+releaseConfig['version']             = '10.0.3esr'
+releaseConfig['appVersion']          = '10.0.3'
+releaseConfig['milestone']           = '10.0.3'
+releaseConfig['buildNumber']         = 2
+releaseConfig['baseTag']             = 'THUNDERBIRD_10_0_3esr'
+#  Old version info
+releaseConfig['oldVersion']          = '10.0.2esr'
+releaseConfig['oldAppVersion']       = '10.0.2'
+releaseConfig['oldBuildNumber']      = 1
+releaseConfig['oldBaseTag']          = 'THUNDERBIRD_10_0_2esr'
+#  Next (nightly) version info
+releaseConfig['nextAppVersion']      = '10.0.4esrpre'
+releaseConfig['nextMilestone']       = '10.0.4esrpre'
+#  Repository configuration, for tagging
+releaseConfig['sourceRepositories']  = {
+    'mozilla': {
+        'name': 'comm-esr10',
+        'path': 'releases/comm-esr10',
+        'revision': 'f0e5d995d302',
+        'relbranch': None,
+        'bumpFiles': {
+            'mail/config/version.txt': {
+                'version': releaseConfig['appVersion'],
+                'nextVersion': releaseConfig['nextAppVersion']
+            },
+        }
+    }
+}
+#  L10n repositories
+releaseConfig['l10nRelbranch']       = None
+releaseConfig['l10nRepoPath']        = 'releases/l10n/mozilla-release'
+releaseConfig['l10nRevisionFile']    = 'l10n-thunderbird-changesets-esr10'
+#  Support repositories
+releaseConfig['otherReposToTag']     = {
+    'build/compare-locales': 'RELEASE_0_8_2',
+    'build/buildbot': 'production-0.8',
+    'build/partner-repacks': 'default',
+    'build/mozharness': 'default',
+}
+
+# Platform configuration
+releaseConfig['enUSPlatforms']       = ('linux', 'linux64', 'win32', 'macosx64')
+releaseConfig['notifyPlatforms']     = ('linux', 'linux64', 'win32', 'macosx64')
+releaseConfig['talosTestPlatforms']  = ()
+releaseConfig['xulrunnerPlatforms']  = ()
+
+# Unittests
+releaseConfig['unittestPlatforms']   = ()
+releaseConfig['enableUnittests'] = True
+
+# L10n configuration
+releaseConfig['l10nPlatforms']       = releaseConfig['enUSPlatforms']
+releaseConfig['shippedLocalesPath']  = 'mail/locales/shipped-locales'
+releaseConfig['l10nChunks']          = 6
+releaseConfig['mergeLocales']        = True
+
+# Mercurial account
+releaseConfig['hgUsername']          = 'tbirdbld'
+releaseConfig['hgSshKey']            = '~cltbld/.ssh/tbirdbld_dsa'
+
+# Update-specific configuration
+releaseConfig['cvsroot']             = ':ext:cltbld@cvs.mozilla.org:/cvsroot'
+releaseConfig['patcherConfig']       = 'mozEsr10-thunderbird-branch-patcher2.cfg'
+releaseConfig['commitPatcherConfig'] = True
+releaseConfig['patcherToolsTag']     = 'UPDATE_PACKAGING_R16'
+releaseConfig['ftpServer']           = 'ftp.mozilla.org'
+releaseConfig['stagingServer']       = 'stage-old.mozilla.org'
+releaseConfig['bouncerServer']       = 'download.mozilla.org'
+releaseConfig['ausServerUrl']        = 'https://aus3.mozilla.org'
+releaseConfig['ausHost']             = 'aus2-staging.mozilla.org'
+releaseConfig['ausUser']             = 'tbirdbld'
+releaseConfig['ausSshKey']           = 'tbirdbld_dsa'
+releaseConfig['releaseNotesUrl']     = 'http://live.mozillamessaging.com/thunderbird/releasenotes?locale=%locale%&platform=%platform%&version=%version%'
+releaseConfig['testOlderPartials']   = False
+releaseConfig['useBetaChannel']      = 1
+releaseConfig['verifyConfigs']       = {
+    'linux':  'mozEsr10-thunderbird-linux.cfg',
+    'linux64':  'mozEsr10-thunderbird-linux64.cfg',
+    'macosx64': 'mozEsr10-thunderbird-mac64.cfg',
+    'win32':  'mozEsr10-thunderbird-win32.cfg'
+}
+releaseConfig['mozconfigs']          = {
+    'linux': 'mail/config/mozconfigs/linux32/release',
+    'linux64': 'mail/config/mozconfigs/linux64/release',
+    'macosx64': 'mail/config/mozconfigs/macosx-universal/release',
+    'win32': 'mail/config/mozconfigs/win32/release',
+}
+releaseConfig['releaseChannel']      = 'esr'
+
+# Partner repack configuration
+releaseConfig['doPartnerRepacks']    = False
+releaseConfig['partnersRepoPath']    = 'build/partner-repacks'
+
+# Major update configuration
+releaseConfig['majorUpdateRepoPath'] = None
+# Tuxedo/Bouncer configuration
+releaseConfig['tuxedoConfig']        = 'thunderbird-tuxedo.ini'
+releaseConfig['tuxedoServerUrl']     = 'https://bounceradmin.mozilla.com/api/'
+releaseConfig['extraBouncerPlatforms'] = ('solaris-sparc', 'solaris-i386',
+                                          'opensolaris-sparc',
+                                          'opensolaris-i386')
+releaseConfig['releaseUptake']       = 3
+releaseConfig['releasetestUptake']   = 1
+
+# Misc configuration
+releaseConfig['enable_repo_setup'] = False
+releaseConfig['enableAutomaticPushToMirrors'] = True
new file mode 100644
--- /dev/null
+++ b/mozilla/release-thunderbird-comm-release.py
@@ -0,0 +1,120 @@
+releaseConfig = {}
+releaseConfig['disable_tinderbox_mail'] = True
+
+# Release Notification
+releaseConfig['AllRecipients']       = ['release@mozilla.com','akeybl@mozilla.com','Callek@gmail.com']
+releaseConfig['ImportantRecipients'] = ['release-drivers@mozilla.org',]
+releaseConfig['AVVendorsRecipients'] = ['av-vendor-release-announce@mozilla.org',]
+releaseConfig['releaseTemplates']    = 'release_templates'
+releaseConfig['messagePrefix']       = '[release] '
+
+# Basic product configuration
+#  Names for the product/files
+releaseConfig['productName']         = 'thunderbird'
+releaseConfig['appName']             = 'mail'
+releaseConfig['binaryName']          = releaseConfig['productName'].capitalize()
+releaseConfig['oldBinaryName']       = releaseConfig['binaryName']
+#  Current version info
+releaseConfig['version']             = '11.0'
+releaseConfig['appVersion']          = releaseConfig['version']
+releaseConfig['milestone']           = releaseConfig['version']
+releaseConfig['buildNumber']         = 2
+releaseConfig['baseTag']             = 'THUNDERBIRD_11_0'
+#  Old version info
+releaseConfig['oldVersion']          = '10.0.2'
+releaseConfig['oldAppVersion']       = releaseConfig['oldVersion']
+releaseConfig['oldBuildNumber']      = 1
+releaseConfig['oldBaseTag']          = 'THUNDERBIRD_10_0_2'
+#  Next (nightly) version info
+releaseConfig['nextAppVersion']      = releaseConfig['appVersion']
+releaseConfig['nextMilestone']       = releaseConfig['milestone']
+#  Repository configuration, for tagging
+releaseConfig['sourceRepositories']  = {
+    'mozilla': {
+        'name': 'comm-release',
+        'path': 'releases/comm-release',
+        'revision': '832c448e5d0a',
+        'relbranch': None,
+        'bumpFiles': {
+            'browser/config/version.txt': {
+                'version': releaseConfig['appVersion'],
+                'nextVersion': releaseConfig['nextAppVersion']
+            },
+        }
+    }
+}
+#  L10n repositories
+releaseConfig['l10nRelbranch']       = None
+releaseConfig['l10nRepoPath']        = 'releases/l10n/mozilla-release'
+releaseConfig['l10nRevisionFile']    = 'l10n-thunderbird-changesets-release'
+#  Support repositories
+releaseConfig['otherReposToTag']     = {
+    'build/compare-locales': 'RELEASE_AUTOMATION',
+    'build/buildbot': 'production-0.8',
+    'build/partner-repacks': 'default',
+    'build/mozharness': 'default',
+}
+
+# Platform configuration
+releaseConfig['enUSPlatforms']       = ('linux', 'linux64', 'win32', 'macosx64')
+releaseConfig['notifyPlatforms']     = releaseConfig['enUSPlatforms']
+releaseConfig['talosTestPlatforms']  = ()
+releaseConfig['xulrunnerPlatforms']  = ()
+
+# Unittests
+releaseConfig['unittestPlatforms']   = ()
+releaseConfig['enableUnittests'] = True
+
+# L10n configuration
+releaseConfig['l10nPlatforms']       = releaseConfig['enUSPlatforms']
+releaseConfig['shippedLocalesPath']  = 'mail/locales/shipped-locales'
+releaseConfig['l10nChunks']          = 6
+releaseConfig['mergeLocales']        = True
+
+# Mercurial account
+releaseConfig['hgUsername']          = 'tbirdbld'
+releaseConfig['hgSshKey']            = '~cltbld/.ssh/tbirdbld_dsa'
+
+# Update-specific configuration
+releaseConfig['cvsroot']             = ':ext:cltbld@cvs.mozilla.org:/cvsroot'
+releaseConfig['patcherConfig']       = 'mozRelease-thunderbird-branch-patcher2.cfg'
+releaseConfig['commitPatcherConfig'] = True
+releaseConfig['patcherToolsTag']     = 'UPDATE_PACKAGING_R16'
+releaseConfig['ftpServer']           = 'ftp.mozilla.org'
+releaseConfig['stagingServer']       = 'stage.mozilla.org'
+releaseConfig['bouncerServer']       = 'download.mozilla.org'
+releaseConfig['ausServerUrl']        = 'https://aus3.mozilla.org'
+releaseConfig['ausHost']             = 'aus2-staging.mozilla.org'
+releaseConfig['ausUser']             = 'tbirdbld'
+releaseConfig['ausSshKey']           = 'tbirdbld_dsa'
+releaseConfig['releaseNotesUrl']     = 'http://live.mozillamessaging.com/thunderbird/releasenotes?locale=%locale%&platform=%platform%&version=%version%'
+releaseConfig['testOlderPartials']   = False
+releaseConfig['verifyConfigs']       = {
+    'linux':  'mozRelease-thunderbird-linux.cfg',
+    'linux64':  'mozRelease-thunderbird-linux64.cfg',
+    'macosx64': 'mozRelease-thunderbird-mac64.cfg',
+    'win32':  'mozRelease-thunderbird-win32.cfg'
+}
+releaseConfig['mozconfigs']          = {
+    'linux': 'mail/config/mozconfigs/linux32/release',
+    'linux64': 'mail/config/mozconfigs/linux64/release',
+    'macosx64': 'mail/config/mozconfigs/macosx-universal/release',
+    'win32': 'mail/config/mozconfigs/win32/release',
+}
+releaseConfig['xulrunner_mozconfigs']          = {}
+
+# Partner repack configuration
+releaseConfig['doPartnerRepacks']    = True
+releaseConfig['partnersRepoPath']    = 'build/partner-repacks'
+
+# Major update configuration
+releaseConfig['majorUpdateRepoPath'] = None
+# Tuxedo/Bouncer configuration
+releaseConfig['tuxedoConfig']        = 'thunderbird-tuxedo.ini'
+releaseConfig['tuxedoServerUrl']     = 'https://bounceradmin.mozilla.com/api/'
+releaseConfig['extraBouncerPlatforms'] = ('solaris-sparc', 'solaris-i386',
+                                          'opensolaris-sparc',
+                                          'opensolaris-i386')
+
+# Misc configuration
+releaseConfig['enable_repo_setup'] = False
--- a/mozilla/scheduler_master.cfg
+++ b/mozilla/scheduler_master.cfg
@@ -1,35 +1,39 @@
 # import/reload dance so that reconfigs work
 # vim: ft=python
 import buildbotcustom.misc
 import master_common
 import config
+import thunderbird_config
 import master_localconfig
 reload(buildbotcustom.misc)
 reload(master_common)
 reload(config)
+reload(thunderbird_config)
 reload(master_localconfig)
 
 from master_common import BuildmasterConfig
 c = BuildmasterConfig
 for key, value in master_localconfig.BuildmasterConfig.items():
     if key in c:
         c[key].extend(value)
     else:
         c[key] = value
 
 # Create our QueueDir objects
 # This is reloaded in buildbotcustom.misc
 from mozilla_buildtools.queuedir import QueueDir
 commandsQueue = QueueDir('commands', '%s/commands' % master_localconfig.QUEUEDIR)
 
 from config import BRANCHES, PROJECTS, SLAVES
+from thunderbird_config import BRANCHES as THUNDERBIRD_BRANCHES
 
 ACTIVE_BRANCHES = BRANCHES.keys()
+ACTIVE_THUNDERBIRD_BRANCHES = THUNDERBIRD_BRANCHES.keys()
 
 ACTIVE_PROJECTS = PROJECTS.keys()
 
 # generateBranchObjects breaks if there are no l10n_slaves, so we make it so
 # there's an empty list for everything
 from collections import defaultdict
 for branch in BRANCHES:
     BRANCHES[branch]['l10n_slaves'] = defaultdict(list)
@@ -45,16 +49,26 @@ from buildbot.changes.pb import PBChange
 c['change_source'].append(PBChangeSource())
 
 buildObjects = {'status': [], 'change_source': [], 'schedulers': []}
 
 for branch in ACTIVE_BRANCHES:
     branchObjects = generateBranchObjects(BRANCHES[branch], branch)
     buildObjects = mergeBuildObjects(buildObjects, branchObjects)
 
+for branch in ACTIVE_THUNDERBIRD_BRANCHES:
+    branchObjects = generateBranchObjects(THUNDERBIRD_BRANCHES[branch], branch)
+    # Strip away any duplicate change sources
+    usefulChangeSources = []
+    for cs in branchObjects['change_source']:
+        if cs.branch not in [cs.branch for cs in buildObjects['change_source']]:
+            usefulChangeSources.append(cs)
+    branchObjects['change_source'] = usefulChangeSources
+    buildObjects = mergeBuildObjects(buildObjects, branchObjects)
+
 for project in ACTIVE_PROJECTS:
     projectObjects = generateProjectObjects(project, PROJECTS[project], SLAVES)
     buildObjects = mergeBuildObjects(buildObjects, projectObjects)
 
 # We only want the schedulers and change sources
 c['schedulers'].extend(buildObjects['schedulers'])
 
 # Remove duplicate change sources
--- a/mozilla/staging_builder_master_sm02_localconfig.py
+++ b/mozilla/staging_builder_master_sm02_localconfig.py
@@ -7,20 +7,22 @@ c['status'] = [
 ]
 
 c['buildbotURL'] = 'http://dev-master01.build.scl1.mozilla.com:8011/'
 
 from buildbot import manhole
 c['manhole'] = manhole.PasswordManhole("tcp:1236:interface=127.0.0.1", "cltbld", "password")
 
 from config import BRANCHES, SLAVES, PROJECTS
+from thunderbird_config import BRANCHES as THUNDERBIRD_BRANCHES
 ACTIVE_BRANCHES = BRANCHES.keys()
 ACTIVE_PROJECTS = PROJECTS.keys()
 ACTIVE_RELEASE_BRANCHES = ['mozilla-beta', 'mozilla-release']
 ACTIVE_MOBILE_RELEASE_BRANCHES = ['mozilla-beta', 'mozilla-release']
+ACTIVE_THUNDERBIRD_BRANCHES = THUNDERBIRD_BRANCHES.keys()
 
 
 # Set up our fast slaves
 # No need to reload, this is reloaded by builder_master.cfg
 import buildbotcustom.misc
 buildbotcustom.misc.fastRegexes.extend([
     'linux-ix-',
     'linux64-ix-',
--- a/mozilla/staging_config.py
+++ b/mozilla/staging_config.py
@@ -56,23 +56,23 @@ GLOBAL_VARS = {
     'balrog_api_root': 'https://aus4-admin-dev.allizom.org',
     'build_tools_repo_path': 'build/tools',
     'base_clobber_url': 'http://build.mozilla.org/stage-clobberer/index.php',
     'disable_tinderbox_mail': True,
     # List of talos masters to notify of new builds,
     # and if a failure to notify the talos master should result in a warning,
     # and sendchange retry count before give up
     'talos_masters': [
-        ('dev-master01.build.scl1.mozilla.com:9060', True, 1),
+        ('dev-master01.build.scl1.mozilla.com:9901', True, 1),
     ],
     # List of unittest masters to notify of new builds to test,
     # if a failure to notify the master should result in a warning,
     # and sendchange retry count before give up
     'unittest_masters': [
-        ('dev-master01.build.scl1.mozilla.com:9060', True, 1),
+        ('dev-master01.build.scl1.mozilla.com:9901', True, 1),
         ],
     'xulrunner_tinderbox_tree': 'MozillaTest',
     'weekly_tinderbox_tree': 'MozillaTest',
     'l10n_tinderbox_tree': 'MozillaStaging',
     'packaged_unittest_tinderbox_tree': 'MozillaTest',
     'tinderbox_tree': 'MozillaTest',
     'mobile_tinderbox_tree': 'MobileTest',
     'hg_username': 'stage-ffxbld',
new file mode 100644
--- /dev/null
+++ b/mozilla/thunderbird_config.py
@@ -0,0 +1,1108 @@
+from copy import deepcopy
+
+from config import GLOBAL_VARS, PLATFORM_VARS
+
+# Note that thunderbird_localconfig.py is symlinked to one of: {production,staging,preproduction}_thunderbird_config.py
+import thunderbird_localconfig
+reload(thunderbird_localconfig)
+
+# Can't reload this one because it gets reloaded in another file
+from localconfig import MAC_SNOW_MINIS, MAC_MINIS, XSERVES, LINUX_VMS, \
+                        LINUX_IXS, WIN32_IXS, SLAVES, \
+                        TRY_SLAVES
+
+GLOBAL_VARS = deepcopy(GLOBAL_VARS)
+PLATFORM_VARS = deepcopy(PLATFORM_VARS)
+
+GLOBAL_VARS['objdir'] = 'obj-tb'
+GLOBAL_VARS['stage_username'] = 'tbirdbld'
+GLOBAL_VARS['stage_ssh_key'] = 'tbirdbld_dsa'
+# etc.
+GLOBAL_VARS.update(thunderbird_localconfig.GLOBAL_VARS.copy())
+
+PLATFORM_VARS['linux']['product_name'] = 'thunderbird'
+PLATFORM_VARS['linux']['app_name'] = 'mailnews'
+# etc.
+# You can probably do something like this if you really wanted to:
+# for p in PLATFORM_VARS:
+#     PLATFORM_VARS[p]['product_name'] = 'thunderbird'
+#     # etc.
+
+
+GLOBAL_VARS.update({
+    # It's a little unfortunate to have both of these but some things (HgPoller)
+    # require an URL while other things (BuildSteps) require only the host.
+    # Since they're both right here it shouldn't be
+    # a problem to keep them in sync.
+    'objdir': 'objdir-tb',
+    'objdir_unittests': 'objdir',
+    'stage_username': 'tbirdbld',
+    'stage_group': None,
+    'stage_ssh_key': 'tbirdbld_dsa',
+    'symbol_server_path': '/mnt/netapp/breakpad/symbols_tbrd/',
+    'aus2_user': 'cltbld',
+    'aus2_ssh_key': 'cltbld_dsa',
+    'hg_username': 'tbirdbld',
+    'hg_ssh_key': '~cltbld/.ssh/tbirdbld_dsa',
+    'unittest_suites': [
+        ('xpcshell', ['xpcshell']),
+        ('mozmill', ['mozmill']),
+    ],
+    'geriatric_masters': [],
+    'platforms': {
+        'linux': {},
+        'linux64': {},
+        'win32': {},
+        'win64': {},
+        'macosx64': {},
+        'linux-debug': {},
+        'linux64-debug': {},
+        'macosx-debug': {},
+        'macosx64-debug': {},
+        'win32-debug': {},
+    },
+    'enable_pgo': False,
+    'pgo_platforms': ('linux', 'linux64', 'win32'),
+    'pgo_strategy': None,
+    'periodic_pgo_interval': 6, # in hours
+    'product_name': 'thunderbird', # Not valid for mobile builds
+    'app_name': 'mail',     # Not valid for mobile builds
+    'brand_name': 'Daily', # Not valid for mobile builds
+    'enable_codecoverage': False,
+    'enable_blocklist_update': False,
+    'blocklist_update_on_closed_tree': False,
+    'enable_nightly': True,
+    'enabled_products': ['thunderbird'],
+    'enable_valgrind': True,
+    'valgrind_platforms': ('linux', 'linux64'),
+
+    # if true, this branch will get bundled and uploaded to ftp.m.o for users
+    # to download and thereby accelerate their cloning
+    'enable_weekly_bundle': False,
+
+    'hash_type': 'sha512',
+    'create_snippet': False,
+    'create_partial': False,
+    'create_partial_l10n': False,
+    'l10n_modules': [
+            'mail',
+            'editor',
+            'other-licenses/branding/thunderbird',
+            'netwerk',
+            'dom',
+            'toolkit',
+            'security/manager',
+        ],
+    'scratchbox_path': '/builds/scratchbox/moz_scratchbox',
+    'scratchbox_home': '/scratchbox/users/cltbld/home/cltbld',
+    'use_old_updater': False,
+    'mozilla_dir': '/mozilla',
+    'leak_target': 'mailbloat',
+})
+
+# shorthand, because these are used often
+OBJDIR = GLOBAL_VARS['objdir']
+SYMBOL_SERVER_PATH = GLOBAL_VARS['symbol_server_path']
+SYMBOL_SERVER_POST_UPLOAD_CMD = GLOBAL_VARS['symbol_server_post_upload_cmd']
+SYMBOL_SERVER_MOBILE_PATH = GLOBAL_VARS['symbol_server_mobile_path']
+builder_prefix = "TB "
+
+PLATFORM_VARS = {
+        'linux': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'Linux %(branch)s',
+            'mozconfig': 'linux/%(branch)s/nightly',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/linux32/nightly',
+            'src_xulrunner_mozconfig': 'xulrunner/config/mozconfigs/linux32/xulrunner',
+            'profiled_build': False,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'build_space': 6,
+            'leak_target': 'mailbloat',
+            'upload_symbols': True,
+            'download_symbols': True,
+            'packageTests': True,
+            'slaves': SLAVES['linux'],
+            'platform_objdir': OBJDIR,
+            'stage_product': 'thunderbird',
+            'stage_platform': 'linux',
+            'update_platform': 'Linux_x86-gcc3',
+            'enable_ccache': True,
+            'enable_shared_checkouts': True,
+            'env': {
+                'DISPLAY': ':2',
+                'HG_SHARE_BASE_DIR': '/builds/hg-shared',
+                'MOZ_OBJDIR': OBJDIR,
+                'SYMBOL_SERVER_HOST': thunderbird_localconfig.SYMBOL_SERVER_HOST,
+                'SYMBOL_SERVER_USER': 'tbirdbld',
+                'SYMBOL_SERVER_PATH': SYMBOL_SERVER_PATH,
+                'POST_SYMBOL_UPLOAD_CMD': SYMBOL_SERVER_POST_UPLOAD_CMD,
+                'SYMBOL_SERVER_SSH_KEY': "/home/cltbld/.ssh/tbirdbld_dsa",
+                'TINDERBOX_OUTPUT': '1',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'CCACHE_DIR': '/builds/ccache',
+                'CCACHE_COMPRESS': '1',
+                'CCACHE_UMASK': '002',
+                'LC_ALL': 'C',
+            },
+            'enable_opt_unittests': False,
+            'enable_checktests': True,
+            'enable_build_analysis': True,
+            'talos_masters': None,
+            'test_pretty_names': True,
+            'l10n_check_test': False,
+        },
+        'linuxqt': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'Linux QT %(branch)s',
+            'mozconfig': 'linux/%(branch)s/qt',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/linux32/qt',
+            'xr_mozconfig': 'linux/%(branch)s/xulrunner-qt',
+            'src_xulrunner_mozconfig': 'xulrunner/config/mozconfigs/linux32/xulrunner-qt',
+            'profiled_build': False,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'leak_target': 'mailbloat',
+            'build_space': 6,
+            'upload_symbols': True,
+            'download_symbols': True,
+            'packageTests': True,
+            'slaves': SLAVES['linux'],
+            'platform_objdir': OBJDIR,
+            'stage_product': 'thunderbird',
+            'stage_platform': 'linuxqt',
+            'update_platform': 'Linux_x86-gcc3',
+            'enable_ccache': True,
+            'enable_shared_checkouts': True,
+            'enable_nightly': False,
+            'env': {
+                'DISPLAY': ':2',
+                'HG_SHARE_BASE_DIR': '/builds/hg-shared',
+                'MOZ_OBJDIR': OBJDIR,
+                'SYMBOL_SERVER_HOST': thunderbird_localconfig.SYMBOL_SERVER_HOST,
+                'SYMBOL_SERVER_USER': 'tbirdbld',
+                'SYMBOL_SERVER_PATH': SYMBOL_SERVER_PATH,
+                'SYMBOL_SERVER_SSH_KEY': "/home/cltbld/.ssh/tbirdbld_dsa",
+                'TINDERBOX_OUTPUT': '1',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'CCACHE_DIR': '/builds/ccache',
+                'CCACHE_COMPRESS': '1',
+                'CCACHE_UMASK': '002',
+                'LC_ALL': 'C',
+            },
+            'enable_opt_unittests': False,
+            'enable_checktests': True,
+            'talos_masters': None,
+        },
+        'linux-rpm': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'Linux RPM %(branch)s',
+            'mozconfig': 'linux/%(branch)s/nightly-rpm',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/linux32/rpm',
+            'enable_nightly': False, # We will explicitly enable for m-c
+            'enable_dep': False,
+            'enable_xulrunner': False,
+            'stage_platform': 'linux-rpm',
+            'leak_target': 'mailbloat',
+            'mc_patches': [],
+            'create_snippet': False,
+            'create_partial': False,
+            'profiled_build': False,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'build_space': 6,
+            'upload_symbols': False,
+            'download_symbols': False,
+            'packageTests': False, #Done in rpm spec file
+            'slaves': SLAVES['linux'],
+            'platform_objdir': OBJDIR,
+            'stage_product': 'thunderbird',
+            'update_platform': 'Linux_x86-gcc3',
+            'enable_ccache': True,
+            'enable_shared_checkouts': True,
+            'env': {
+                'DISPLAY': ':2',
+                'HG_SHARE_BASE_DIR': '/builds/hg-shared',
+                'MOZ_OBJDIR': OBJDIR,
+                'SYMBOL_SERVER_HOST': thunderbird_localconfig.SYMBOL_SERVER_HOST,
+                'SYMBOL_SERVER_USER': 'tbirdbld',
+                'SYMBOL_SERVER_PATH': SYMBOL_SERVER_PATH,
+                'POST_SYMBOL_UPLOAD_CMD': SYMBOL_SERVER_POST_UPLOAD_CMD,
+                'SYMBOL_SERVER_SSH_KEY': "/home/cltbld/.ssh/tbirdbld_dsa",
+                'MOZ_SYMBOLS_EXTRA_BUILDID': 'linux-rpm',
+                'TINDERBOX_OUTPUT': '1',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'CCACHE_DIR': '/builds/ccache',
+                'CCACHE_COMPRESS': '1',
+                'CCACHE_UMASK': '002',
+                'LC_ALL': 'C',
+                'LD_LIBRARY_PATH': '/tools/gcc-4.3.3/installed/lib',
+            },
+            'enable_opt_unittests': False,
+            'enable_checktests': True,
+            'talos_masters': None,
+            'unittest_masters': [],
+            'test_pretty_names': False,
+        },
+        'linux64': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'Linux x86-64 %(branch)s',
+            'mozconfig': 'linux64/%(branch)s/nightly',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/linux64/nightly',
+            'src_xulrunner_mozconfig': 'xulrunner/config/mozconfigs/linux64/xulrunner',
+            'profiled_build': False,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'build_space': 6,
+            'leak_target': 'mailbloat',
+            'upload_symbols': True,
+            'download_symbols': False,
+            'packageTests': True,
+            'slaves': SLAVES['linux64'],
+            'platform_objdir': OBJDIR,
+            'stage_product': 'thunderbird',
+            'stage_platform': 'linux64',
+            'update_platform': 'Linux_x86_64-gcc3',
+            'enable_ccache': True,
+            'enable_shared_checkouts': True,
+            'env': {
+                'DISPLAY': ':2',
+                'HG_SHARE_BASE_DIR': '/builds/hg-shared',
+                'MOZ_OBJDIR': OBJDIR,
+                'SYMBOL_SERVER_HOST': thunderbird_localconfig.SYMBOL_SERVER_HOST,
+                'SYMBOL_SERVER_USER': 'tbirdbld',
+                'SYMBOL_SERVER_PATH': SYMBOL_SERVER_PATH,
+                'POST_SYMBOL_UPLOAD_CMD': SYMBOL_SERVER_POST_UPLOAD_CMD,
+                'SYMBOL_SERVER_SSH_KEY': "/home/cltbld/.ssh/tbirdbld_dsa",
+                'MOZ_SYMBOLS_EXTRA_BUILDID': 'linux64',
+                'TINDERBOX_OUTPUT': '1',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'CCACHE_DIR': '/builds/ccache',
+                'CCACHE_COMPRESS': '1',
+                'CCACHE_UMASK': '002',
+                'LC_ALL': 'C',
+            },
+            'enable_opt_unittests': False,
+            'enable_checktests': True,
+            'enable_build_analysis': True,
+            'talos_masters': None,
+            'test_pretty_names': True,
+            'l10n_check_test': False,
+        },
+        'linux64-rpm': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'Linux RPM x86-64 %(branch)s',
+            'mozconfig': 'linux64/%(branch)s/nightly-rpm',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/linux64/rpm',
+            'enable_nightly': False, # We will explicitly enable for m-c
+            'enable_dep': False,
+            'enable_xulrunner': False,
+            'stage_platform': 'linux64-rpm',
+            'leak_target': 'mailbloat',
+            'mc_patches': [],
+            'create_snippet': False,
+            'create_partial': False,
+            'profiled_build': False,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'build_space': 6,
+            'upload_symbols': False,
+            'download_symbols': False,
+            'packageTests': False, #Done in rpm spec file
+            'slaves': SLAVES['linux64'],
+            'platform_objdir': OBJDIR,
+            'stage_product': 'thunderbird',
+            'update_platform': 'Linux_x86_64-gcc3',
+            'enable_shared_checkouts': True,
+            'env': {
+                'DISPLAY': ':2',
+                'HG_SHARE_BASE_DIR': '/builds/hg-shared',
+                'MOZ_OBJDIR': OBJDIR,
+                'SYMBOL_SERVER_HOST': thunderbird_localconfig.SYMBOL_SERVER_HOST,
+                'SYMBOL_SERVER_USER': 'tbirdbld',
+                'SYMBOL_SERVER_PATH': SYMBOL_SERVER_PATH,
+                'POST_SYMBOL_UPLOAD_CMD': SYMBOL_SERVER_POST_UPLOAD_CMD,
+                'SYMBOL_SERVER_SSH_KEY': "/home/cltbld/.ssh/tbirdbld_dsa",
+                'MOZ_SYMBOLS_EXTRA_BUILDID': 'linux64-rpm',
+                'TINDERBOX_OUTPUT': '1',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'CCACHE_DIR': '/builds/ccache',
+                'CCACHE_COMPRESS': '1',
+                'CCACHE_UMASK': '002',
+                'LC_ALL': 'C',
+                'LD_LIBRARY_PATH': '/tools/gcc-4.3.3/installed/lib64',
+            },
+            'enable_opt_unittests': False,
+            'enable_checktests': True,
+            'talos_masters': None,
+            'unittest_masters': [],
+            'test_pretty_names': False,
+        },
+        'macosx': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'OS X 10.5.2 %(branch)s',
+            'mozconfig': 'macosx/%(branch)s/nightly',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/macosx-universal/nightly',
+            'src_xulrunner_mozconfig': 'xulrunner/config/mozconfigs/macosx-universal/xulrunner',
+            'src_shark_mozconfig': 'mail/config/mozconfigs/macosx-universal/shark',
+            'profiled_build': False,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'leak_target': 'mailbloat',
+            'build_space': 10,
+            'upload_symbols': True,
+            'download_symbols': True,
+            'packageTests': True,
+            'slaves': SLAVES['macosx'],
+            'platform_objdir': "%s/ppc" % OBJDIR,
+            'stage_product': 'thunderbird',
+            'stage_platform': 'macosx',
+            'update_platform': 'Darwin_Universal-gcc3',
+            'enable_shared_checkouts': True,
+            'enable_shark': True,
+            'env': {
+                'MOZ_OBJDIR': OBJDIR,
+                'HG_SHARE_BASE_DIR': '/builds/hg-shared',
+                'SYMBOL_SERVER_HOST': thunderbird_localconfig.SYMBOL_SERVER_HOST,
+                'SYMBOL_SERVER_USER': 'tbirdbld',
+                'SYMBOL_SERVER_PATH': SYMBOL_SERVER_PATH,
+                'POST_SYMBOL_UPLOAD_CMD': SYMBOL_SERVER_POST_UPLOAD_CMD,
+                'SYMBOL_SERVER_SSH_KEY': "/Users/cltbld/.ssh/tbirdbld_dsa",
+                'TINDERBOX_OUTPUT': '1',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'CHOWN_ROOT': '~/bin/chown_root',
+                'CHOWN_REVERT': '~/bin/chown_revert',
+                'LC_ALL': 'C',
+            },
+            'enable_opt_unittests': False,
+            'enable_checktests': True,
+            'talos_masters': None,
+        },
+        'macosx64': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'OS X 10.6.2 %(branch)s',
+            'mozconfig': 'macosx64/%(branch)s/nightly',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/macosx-universal/nightly',
+            'src_xulrunner_mozconfig': 'xulrunner/config/mozconfigs/macosx-universal/xulrunner',
+            'src_shark_mozconfig': 'mail/config/mozconfigs/macosx-universal/shark',
+            'packageTests': True,
+            'profiled_build': False,
+            'leak_target': 'mailbloat',
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'build_space': 12,
+            'upload_symbols': True,
+            'download_symbols': True,
+            'slaves': SLAVES['macosx64'],
+            'platform_objdir': "%s/i386" % OBJDIR,
+            'stage_product': 'thunderbird',
+            'stage_platform': 'macosx64',
+            'update_platform': 'Darwin_x86_64-gcc3',
+            'enable_shared_checkouts': True,
+            'enable_shark': True,
+            'env': {
+                'MOZ_OBJDIR': OBJDIR,
+                'HG_SHARE_BASE_DIR': '/builds/hg-shared',
+                'SYMBOL_SERVER_HOST': thunderbird_localconfig.SYMBOL_SERVER_HOST,
+                'SYMBOL_SERVER_USER': 'tbirdbld',
+                'SYMBOL_SERVER_PATH': SYMBOL_SERVER_PATH,
+                'POST_SYMBOL_UPLOAD_CMD': SYMBOL_SERVER_POST_UPLOAD_CMD,
+                'SYMBOL_SERVER_SSH_KEY': "/Users/cltbld/.ssh/tbirdbld_dsa",
+                'MOZ_SYMBOLS_EXTRA_BUILDID': 'macosx64',
+                'TINDERBOX_OUTPUT': '1',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'CHOWN_ROOT': '~/bin/chown_root',
+                'CHOWN_REVERT': '~/bin/chown_revert',
+                'LC_ALL': 'C',
+                'PATH': '/tools/python/bin:/tools/buildbot/bin:/opt/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin',
+            },
+            'enable_opt_unittests': False,
+            'enable_checktests': True,
+            'talos_masters': None,
+            'test_pretty_names': True,
+        },
+        'win32': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'WINNT 5.2 %(branch)s',
+            'mozconfig': 'win32/%(branch)s/nightly',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/win32/nightly',
+            'src_xulrunner_mozconfig': 'xulrunner/config/mozconfigs/win32/xulrunner',
+            'profiled_build': False,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'build_space': 12,
+            'leak_target': 'mailbloat',
+            'upload_symbols': True,
+            'download_symbols': True,
+            'packageTests': True,
+            'slaves': SLAVES['win32'],
+            'platform_objdir': OBJDIR,
+            'stage_product': 'thunderbird',
+            'stage_platform': 'win32',
+            'mochitest_leak_threshold': 484,
+            'crashtest_leak_threshold': 484,
+            'update_platform': 'WINNT_x86-msvc',
+            'enable_shared_checkouts': True,
+            'env': {
+                'CVS_RSH': 'ssh',
+                'MOZ_OBJDIR': OBJDIR,
+                'SYMBOL_SERVER_HOST': thunderbird_localconfig.SYMBOL_SERVER_HOST,
+                'SYMBOL_SERVER_USER': 'tbirdbld',
+                'SYMBOL_SERVER_PATH': SYMBOL_SERVER_PATH,
+                'POST_SYMBOL_UPLOAD_CMD': SYMBOL_SERVER_POST_UPLOAD_CMD,
+                'SYMBOL_SERVER_SSH_KEY': "/c/Documents and Settings/cltbld/.ssh/tbirdbld_dsa",
+                'TINDERBOX_OUTPUT': '1',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                # Source server support, bug 506702
+                'PDBSTR_PATH': '/c/Program Files/Debugging Tools for Windows/srcsrv/pdbstr.exe',
+                'HG_SHARE_BASE_DIR': 'e:/builds/hg-shared',
+            },
+            'enable_opt_unittests': False,
+            'enable_checktests': True,
+            'talos_masters': None,
+            'test_pretty_names': True,
+            'l10n_check_test': False,
+        },
+        'win64': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'WINNT 6.1 x86-64 %(branch)s',
+            'src_mozconfig': 'mail/config/mozconfigs/win64/nightly',
+            'mozconfig': 'win64/%(branch)s/nightly',
+            'run_alive_tests': False,
+            # XXX we cannot build xulrunner on Win64 -- see bug 575912
+            'enable_xulrunner': False,
+            'profiled_build': True,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'build_space': 12,
+            'leak_target': 'mailbloat',
+            'upload_symbols': True,
+            'packageTests': True,
+            'slaves': SLAVES['win64'],
+            'platform_objdir': OBJDIR,
+            'stage_product': 'thunderbird',
+            'stage_platform': 'win64',
+            'mochitest_leak_threshold': 484,
+            'crashtest_leak_threshold': 484,
+            'update_platform': 'WINNT_x86_64-msvc',
+            'enable_shared_checkouts': True,
+            'env': {
+                'CVS_RSH': 'ssh',
+                'MOZ_OBJDIR': OBJDIR,
+                'SYMBOL_SERVER_HOST': thunderbird_localconfig.SYMBOL_SERVER_HOST,
+                'SYMBOL_SERVER_USER': 'tbirdbld',
+                'SYMBOL_SERVER_PATH': SYMBOL_SERVER_PATH,
+                'POST_SYMBOL_UPLOAD_CMD': SYMBOL_SERVER_POST_UPLOAD_CMD,
+                'SYMBOL_SERVER_SSH_KEY': "/c/Users/cltbld/.ssh/tbirdbld_dsa",
+                'MOZ_SYMBOLS_EXTRA_BUILDID': 'win64',
+                'TINDERBOX_OUTPUT': '1',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'PDBSTR_PATH': '/c/Program Files/Debugging Tools for Windows (x64)/srcsrv/pdbstr.exe',
+                'HG_SHARE_BASE_DIR': 'e:/builds/hg-shared',
+            },
+            'enable_opt_unittests': False,
+            'enable_checktests': True,
+            'talos_masters': None,
+            'test_pretty_names': True,
+            'l10n_check_test': False,
+        },
+        'linux-debug': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'Linux %(branch)s leak test',
+            'mozconfig': 'linux/%(branch)s/debug',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/linux32/debug',
+            'profiled_build': False,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'download_symbols': True,
+            'packageTests': True,
+            'leak_target': 'mailbloat',
+            'build_space': 7,
+            'slaves': SLAVES['linux'],
+            'platform_objdir': OBJDIR,
+            'stage_product': 'thunderbird',
+            'stage_platform': 'linux-debug',
+            'enable_ccache': True,
+            'enable_shared_checkouts': True,
+            'env': {
+                'MOZ_OBJDIR': OBJDIR,
+                'HG_SHARE_BASE_DIR': '/builds/hg-shared',
+                'DISPLAY': ':2',
+                'LD_LIBRARY_PATH': '%s/mozilla/dist/bin' % OBJDIR,
+                'XPCOM_DEBUG_BREAK': 'stack-and-abort',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'CCACHE_DIR': '/builds/ccache',
+                'CCACHE_COMPRESS': '1',
+                'CCACHE_UMASK': '002',
+                'LC_ALL': 'C',
+            },
+            'enable_unittests': False,
+            'enable_checktests': True,
+            'talos_masters': None,
+        },
+        'linux64-debug': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'Linux x86-64 %(branch)s leak test',
+            'mozconfig': 'linux64/%(branch)s/debug',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/linux64/debug',
+            'profiled_build': False,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'download_symbols': False,
+            'packageTests': True,
+            'leak_target': 'mailbloat',
+            'build_space': 7,
+            'slaves': SLAVES['linux64'],
+            'platform_objdir': OBJDIR,
+            'stage_product': 'thunderbird',
+            'stage_platform': 'linux64-debug',
+            'enable_ccache': True,
+            'enable_shared_checkouts': True,
+            'env': {
+                'MOZ_OBJDIR': OBJDIR,
+                'HG_SHARE_BASE_DIR': '/builds/hg-shared',
+                'DISPLAY': ':2',
+                'LD_LIBRARY_PATH': '%s/mozilla/dist/bin' % OBJDIR,
+                'XPCOM_DEBUG_BREAK': 'stack-and-abort',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'CCACHE_DIR': '/builds/ccache',
+                'CCACHE_COMPRESS': '1',
+                'CCACHE_UMASK': '002',
+                'LC_ALL': 'C',
+            },
+            'enable_unittests': False,
+            'enable_checktests': True,
+            'talos_masters': None,
+        },
+        'macosx-debug': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'OS X 10.5.2 %(branch)s leak test',
+            'mozconfig': 'macosx/%(branch)s/debug',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/macosx32/debug',
+            'profiled_build': False,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'download_symbols': True,
+            'packageTests': True,
+            'leak_target': 'mailbloat',
+            'build_space': 10,
+            'slaves': SLAVES['macosx'],
+            'platform_objdir': OBJDIR,
+            'stage_product': 'thunderbird',
+            'stage_platform': 'macosx-debug',
+            'enable_shared_checkouts': True,
+            'enable_shark': True,
+            'env': {
+                'MOZ_OBJDIR': OBJDIR,
+                'HG_SHARE_BASE_DIR': '/builds/hg-shared',
+                'XPCOM_DEBUG_BREAK': 'stack-and-abort',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'LC_ALL': 'C',
+            },
+            'enable_unittests': False,
+            'enable_checktests': True,
+            'talos_masters': None,
+        },
+        'macosx64-debug': {
+            'product_name': 'thunderbird',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'OS X 10.6.2 %(branch)s leak test',
+            'mozconfig': 'macosx64/%(branch)s/debug',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/macosx-universal/debug',
+            'packageTests': True,
+            'profiled_build': False,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'download_symbols': True,
+            'leak_target': 'mailbloat',
+            'build_space': 10,
+            'slaves': SLAVES['macosx64'],
+            'platform_objdir': OBJDIR,
+            'stage_product': 'thunderbird',
+            'stage_platform': 'macosx64-debug',
+            'enable_shared_checkouts': True,
+            'enable_shark': True,
+            'env': {
+                'MOZ_OBJDIR': OBJDIR,
+                'HG_SHARE_BASE_DIR': '/builds/hg-shared',
+                'XPCOM_DEBUG_BREAK': 'stack-and-abort',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'LC_ALL': 'C',
+                'PATH': '/tools/python/bin:/tools/buildbot/bin:/opt/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin',
+            },
+            'enable_unittests': False,
+            'enable_checktests': True,
+            'talos_masters': None,
+        },
+        'win32-debug': {
+            'product_name': 'firefox',
+            'app_name': 'mail',
+            'base_name': builder_prefix + 'WINNT 5.2 %(branch)s leak test',
+            'mozconfig': 'win32/%(branch)s/debug',
+            'run_alive_tests': False,
+            'src_mozconfig': 'mail/config/mozconfigs/win32/debug',
+            'profiled_build': False,
+            'builds_before_reboot': thunderbird_localconfig.BUILDS_BEFORE_REBOOT,
+            'download_symbols': True,
+            'packageTests': True,
+            'leak_target': 'mailbloat',
+            'build_space': 9,
+            'slaves': SLAVES['win32'],
+            'platform_objdir': OBJDIR,
+            'stage_product': 'thunderbird',
+            'stage_platform': 'win32-debug',
+            'enable_shared_checkouts': True,
+            'env': {
+                'MOZ_OBJDIR': OBJDIR,
+                'XPCOM_DEBUG_BREAK': 'stack-and-abort',
+                'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                'HG_SHARE_BASE_DIR': 'e:/builds/hg-shared',
+            },
+            'enable_unittests': False,
+            'enable_checktests': True,
+            'talos_masters': None,
+        },
+}
+
+
+# All branches (not in project_branches) that are to be built MUST be listed here, along with their
+# platforms (if different from the default set).
+BRANCHES = {
+    'comm-central': {
+    },
+    'comm-aurora': {
+    },
+    'comm-beta': {
+    },
+    'comm-release': {
+    },
+    'comm-esr10': {
+        'lock_platforms': True,
+        'platforms': {
+            'linux': {},
+            'linux64': {},
+            'win32': {},
+            'macosx64': {},
+            'linux-debug': {},
+            'linux64-debug': {},
+            'macosx-debug': {},
+            'macosx64-debug': {},
+            'win32-debug': {},
+        },
+    },
+    'try-comm-central': {
+    },
+}
+
+for branch in BRANCHES:
+    BRANCHES[branch]['l10n_slaves'] = SLAVES
+
+# Copy global vars in first, then platform vars
+for branch in BRANCHES.keys():
+    for key, value in GLOBAL_VARS.items():
+        # Don't override platforms if it's set and locked
+        if key == 'platforms' and 'platforms' in BRANCHES[branch] and BRANCHES[branch].get('lock_platforms'):
+            continue
+        elif key == 'mobile_platforms' and 'mobile_platforms' in BRANCHES[branch]:
+            continue
+        # Don't override something that's set
+        elif key in ('enable_weekly_bundle',) and key in BRANCHES[branch]:
+            continue
+        else:
+            BRANCHES[branch][key] = deepcopy(value)
+
+    for platform, platform_config in PLATFORM_VARS.items():
+        if platform in BRANCHES[branch]['platforms']:
+            for key, value in platform_config.items():
+                # put default platform set in all branches
+                value = deepcopy(value)
+                if isinstance(value, str):
+                    value = value % locals()
+                else:
+                    value = deepcopy(value)
+                BRANCHES[branch]['platforms'][platform][key] = value
+
+    # Copy in local config
+    if branch in thunderbird_localconfig.BRANCHES:
+        for key, value in thunderbird_localconfig.BRANCHES[branch].items():
+            if key == 'platforms':
+                # Merge in these values
+                if 'platforms' not in BRANCHES[branch]:
+                    BRANCHES[branch]['platforms'] = {}
+
+                for platform, platform_config in value.items():
+                    for key, value in platform_config.items():
+                        value = deepcopy(value)
+                        if isinstance(value, str):
+                            value = value % locals()
+                        BRANCHES[branch]['platforms'][platform][key] = value
+            else:
+                BRANCHES[branch][key] = deepcopy(value)
+
+    for platform, platform_config in thunderbird_localconfig.PLATFORM_VARS.items():
+        if platform in BRANCHES[branch]['platforms']:
+            for key, value in platform_config.items():
+                value = deepcopy(value)
+                if isinstance(value, str):
+                    value = value % locals()
+                BRANCHES[branch]['platforms'][platform][key] = value
+
+
+######## comm-central
+# This is a path, relative to HGURL, where the repository is located
+# HGURL + repo_path should be a valid repository
+BRANCHES['comm-central']['moz_repo_path'] = 'mozilla-central'
+BRANCHES['comm-central']['mozilla_dir'] = 'mozilla'
+BRANCHES['comm-central']['skip_blank_repos'] = True
+BRANCHES['comm-central']['call_client_py'] = True
+BRANCHES['comm-central']['repo_path'] = 'comm-central'
+BRANCHES['comm-central']['l10n_repo_path'] = 'l10n-central'
+BRANCHES['comm-central']['enable_weekly_bundle'] = True
+BRANCHES['comm-central']['start_hour'] = [3]
+BRANCHES['comm-central']['start_minute'] = [2]
+# Enable XULRunner / SDK builds
+BRANCHES['comm-central']['enable_xulrunner'] = False
+# Enable PGO Builds on this branch
+BRANCHES['comm-central']['enable_pgo'] = True
+# Enable unit tests
+BRANCHES['comm-central']['geriatric_masters'] = [
+    ('10.250.48.137:9989', False),
+]
+BRANCHES['comm-central']['enable_mac_a11y'] = True
+BRANCHES['comm-central']['unittest_build_space'] = 6
+# And code coverage
+BRANCHES['comm-central']['enable_codecoverage'] = False
+# L10n configuration
+BRANCHES['comm-central']['enable_l10n'] = True
+BRANCHES['comm-central']['enable_l10n_onchange'] = True
+BRANCHES['comm-central']['l10nNightlyUpdate'] = True
+BRANCHES['comm-central']['l10n_platforms'] = ['linux', 'linux64', 'win32',
+                                                 'macosx64']
+BRANCHES['comm-central']['l10nDatedDirs'] = True
+BRANCHES['comm-central']['l10n_tree'] = 'fx37x'
+#make sure it has an ending slash
+BRANCHES['comm-central']['l10nUploadPath'] = \
+    '/home/ftp/pub/mozilla.org/thunderbird/nightly/latest-comm-central-l10n/'
+BRANCHES['comm-central']['enUS_binaryURL'] = \
+    GLOBAL_VARS['download_base_url'] + '/nightly/latest-comm-central'
+BRANCHES['comm-central']['allLocalesFile'] = 'mail/locales/all-locales'
+BRANCHES['comm-central']['localesURL'] = \
+    '%s/build/buildbot-configs/raw-file/production/thunderbird/l10n/all-locales.comm-central' % (GLOBAL_VARS['hgurl'])
+BRANCHES['comm-central']['enable_multi_locale'] = True
+BRANCHES['comm-central']['upload_mobile_symbols'] = True
+# If True, a complete update snippet for this branch will be generated and
+# uploaded to. Any platforms with 'debug' in them will not have snippets
+# generated.
+BRANCHES['comm-central']['create_snippet'] = True
+BRANCHES['comm-central']['update_channel'] = 'nightly'
+BRANCHES['comm-central']['create_mobile_snippet'] = True
+BRANCHES['comm-central']['create_partial'] = True
+BRANCHES['comm-central']['create_partial_l10n'] = True
+BRANCHES['comm-central']['aus2_user'] = 'tbirdbld'
+BRANCHES['comm-central']['aus2_ssh_key'] = 'tbirdbld_dsa'
+BRANCHES['comm-central']['aus2_base_upload_dir'] = '/opt/aus2/build/0/Thunderbird/comm-central'
+BRANCHES['comm-central']['aus2_base_upload_dir_l10n'] = '/opt/aus2/build/0/Thunderbird/comm-central'
+BRANCHES['comm-central']['aus2_mobile_base_upload_dir'] = None
+BRANCHES['comm-central']['aus2_mobile_base_upload_dir_l10n'] = None
+BRANCHES['comm-central']['enable_blocklist_update'] = True
+BRANCHES['comm-central']['blocklist_update_on_closed_tree'] = False
+
+######## comm-release
+BRANCHES['comm-release']['repo_path'] = 'releases/comm-release'
+BRANCHES['comm-release']['update_channel'] = 'release'
+BRANCHES['comm-release']['l10n_repo_path'] = 'releases/l10n/mozilla-release'
+BRANCHES['comm-release']['enable_weekly_bundle'] = True
+BRANCHES['comm-release']['start_hour'] = [3]
+BRANCHES['comm-release']['start_minute'] = [2]
+BRANCHES['comm-release']['enable_xulrunner'] = False
+# Enable unit tests
+BRANCHES['comm-release']['geriatric_masters'] = [
+    ('10.250.48.137:9989', False),
+]
+BRANCHES['comm-release']['enable_mac_a11y'] = True
+# And code coverage
+BRANCHES['comm-release']['enable_codecoverage'] = False
+# L10n configuration
+BRANCHES['comm-release']['enable_l10n'] = False
+BRANCHES['comm-release']['enable_l10n_onchange'] = True
+BRANCHES['comm-release']['l10nNightlyUpdate'] = False
+BRANCHES['comm-release']['l10n_platforms'] = ['linux', 'linux64', 'win32',
+                                                 'macosx64']
+BRANCHES['comm-release']['l10nDatedDirs'] = True
+BRANCHES['comm-release']['l10n_tree'] = 'fxrel'
+BRANCHES['comm-release']['enUS_binaryURL'] = \
+    GLOBAL_VARS['download_base_url'] + '/nightly/latest-comm-release'
+BRANCHES['comm-release']['allLocalesFile'] = 'mail/locales/all-locales'
+BRANCHES['comm-release']['localesURL'] = \
+    '%s/build/buildbot-configs/raw-file/production/thunderbird/l10n/all-locales.comm-release' % (GLOBAL_VARS['hgurl'])
+BRANCHES['comm-release']['enable_multi_locale'] = True
+BRANCHES['comm-release']['upload_mobile_symbols'] = True
+# temp disable nightlies (which includes turning off enable_l10n and l10nNightlyUpdate)
+BRANCHES['comm-release']['enable_nightly'] = False
+BRANCHES['comm-release']['enable_blocklist_update'] = False
+BRANCHES['comm-release']['blocklist_update_on_closed_tree'] = False
+del BRANCHES['comm-release']['platforms']['win64']
+BRANCHES['comm-release']['enable_valgrind'] = False
+
+######## comm-esr10
+BRANCHES['comm-esr10']['repo_path'] = 'releases/comm-esr10'
+BRANCHES['comm-esr10']['update_channel'] = 'nightly-esr10'
+BRANCHES['comm-esr10']['l10n_repo_path'] = 'releases/l10n/mozilla-release'
+BRANCHES['comm-esr10']['enable_weekly_bundle'] = True
+BRANCHES['comm-esr10']['start_hour'] = [3]
+BRANCHES['comm-esr10']['start_minute'] = [45]
+BRANCHES['comm-esr10']['enable_xulrunner'] = False
+BRANCHES['comm-esr10']['enable_mac_a11y'] = True
+BRANCHES['comm-esr10']['pgo_strategy'] = 'per-checkin'
+# L10n configuration
+BRANCHES['comm-esr10']['enable_l10n'] = False
+BRANCHES['comm-esr10']['enable_l10n_onchange'] = False
+BRANCHES['comm-esr10']['l10nNightlyUpdate'] = False
+BRANCHES['comm-esr10']['l10n_platforms'] = ['linux', 'linux64', 'win32',
+                                                 'macosx64']
+BRANCHES['comm-esr10']['l10nDatedDirs'] = True
+BRANCHES['comm-esr10']['l10n_tree'] = 'fxesr10'
+BRANCHES['comm-esr10']['enable_multi_locale'] = True
+BRANCHES['comm-esr10']['enUS_binaryURL'] = \
+    GLOBAL_VARS['download_base_url'] + '/nightly/latest-comm-esr10'
+BRANCHES['comm-esr10']['allLocalesFile'] = 'browser/locales/all-locales'
+BRANCHES['comm-esr10']['localesURL'] = \
+    '%s/build/buildbot-configs/raw-file/production/mozilla/l10n/all-locales.comm-esr10' % (GLOBAL_VARS['hgurl'])
+# temp disable nightlies (which includes turning off enable_l10n and l10nNightlyUpdate)
+BRANCHES['comm-esr10']['enable_nightly'] = True
+BRANCHES['comm-esr10']['create_snippet'] = True
+BRANCHES['comm-esr10']['create_partial'] = True
+BRANCHES['comm-esr10']['aus2_user'] = 'tbirdbld'
+BRANCHES['comm-esr10']['aus2_ssh_key'] = 'tbirdbld_dsa'
+# use comm-esr10-test when disabling updates for merges
+BRANCHES['comm-esr10']['aus2_base_upload_dir'] = '/opt/aus2/incoming/2/Thunderbird/comm-esr10'
+BRANCHES['comm-esr10']['aus2_base_upload_dir_l10n'] = '/opt/aus2/incoming/2/Thunderbird/comm-esr10'
+BRANCHES['comm-esr10']['enable_blocklist_update'] = False
+BRANCHES['comm-esr10']['blocklist_update_on_closed_tree'] = False
+BRANCHES['comm-esr10']['enable_valgrind'] = False
+BRANCHES['comm-esr10']['upload_mobile_symbols'] = True
+
+######## comm-beta
+BRANCHES['comm-beta']['moz_repo_path'] = 'releases/mozilla-beta'
+BRANCHES['comm-beta']['mozilla_dir'] = 'mozilla'
+BRANCHES['comm-beta']['skip_blank_repos'] = True
+BRANCHES['comm-beta']['call_client_py'] = True
+BRANCHES['comm-beta']['repo_path'] = 'releases/comm-beta'
+BRANCHES['comm-beta']['l10n_repo_path'] = 'releases/l10n/mozilla-beta'
+BRANCHES['comm-beta']['enable_weekly_bundle'] = True
+BRANCHES['comm-beta']['update_channel'] = 'beta'
+BRANCHES['comm-beta']['start_hour'] = [3]
+BRANCHES['comm-beta']['start_minute'] = [2]
+# Enable XULRunner / SDK builds
+BRANCHES['comm-beta']['enable_xulrunner'] = False
+# Enable PGO Builds on this branch
+BRANCHES['comm-beta']['enable_pgo'] = True
+# Enable unit tests
+BRANCHES['comm-beta']['geriatric_masters'] = [
+    ('10.250.48.137:9989', False),
+]
+BRANCHES['comm-beta']['enable_mac_a11y'] = True
+BRANCHES['comm-beta']['unittest_build_space'] = 6
+# And code coverage
+BRANCHES['comm-beta']['enable_codecoverage'] = False
+# L10n configuration
+BRANCHES['comm-beta']['enable_l10n'] = False
+BRANCHES['comm-beta']['enable_l10n_onchange'] = True
+BRANCHES['comm-beta']['l10nNightlyUpdate'] = False
+BRANCHES['comm-beta']['l10n_platforms'] = ['linux', 'linux64', 'win32',
+                                                 'macosx64']
+BRANCHES['comm-beta']['l10nDatedDirs'] = True
+BRANCHES['comm-beta']['l10n_tree'] = 'fxbeta'
+#make sure it has an ending slash
+BRANCHES['comm-beta']['l10nUploadPath'] = \
+    '/home/ftp/pub/mozilla.org/thunderbird/nightly/latest-comm-beta-l10n/'
+BRANCHES['comm-beta']['enUS_binaryURL'] = \
+    GLOBAL_VARS['download_base_url'] + '/nightly/latest-comm-beta'
+BRANCHES['comm-beta']['allLocalesFile'] = 'mail/locales/all-locales'
+BRANCHES['comm-beta']['localesURL'] = \
+    '%s/build/buildbot-configs/raw-file/production/thunderbird/l10n/all-locales.comm-beta' % (GLOBAL_VARS['hgurl'])
+BRANCHES['comm-beta']['enable_multi_locale'] = True
+BRANCHES['comm-beta']['upload_mobile_symbols'] = True
+# temp disable nightlies (which includes turning off enable_l10n and l10nNightlyUpdate)
+BRANCHES['comm-beta']['enable_nightly'] = False
+# If True, a complete update snippet for this branch will be generated and
+# uploaded to. Any platforms with 'debug' in them will not have snippets
+# generated.
+BRANCHES['comm-beta']['enable_blocklist_update'] = True
+BRANCHES['comm-beta']['blocklist_update_on_closed_tree'] = False
+del BRANCHES['comm-beta']['platforms']['win64']
+BRANCHES['comm-beta']['enable_valgrind'] = False
+
+######## comm-aurora
+BRANCHES['comm-aurora']['moz_repo_path'] = 'releases/mozilla-aurora'
+BRANCHES['comm-aurora']['mozilla_dir'] = 'mozilla'
+BRANCHES['comm-aurora']['skip_blank_repos'] = True
+BRANCHES['comm-aurora']['call_client_py'] = True
+BRANCHES['comm-aurora']['repo_path'] = 'releases/comm-aurora'
+BRANCHES['comm-aurora']['l10n_repo_path'] = 'releases/l10n/mozilla-aurora'
+BRANCHES['comm-aurora']['enable_weekly_bundle'] = True
+BRANCHES['comm-aurora']['start_hour'] = [4]
+BRANCHES['comm-aurora']['start_minute'] = [20]
+# Enable XULRunner / SDK builds
+BRANCHES['comm-aurora']['enable_xulrunner'] = False
+# Enable PGO Builds on this branch
+BRANCHES['comm-aurora']['enable_pgo'] = True
+# Enable unit tests
+BRANCHES['comm-aurora']['geriatric_masters'] = [
+    ('10.250.48.137:9989', False),
+]
+BRANCHES['comm-aurora']['enable_mac_a11y'] = True
+BRANCHES['comm-aurora']['unittest_build_space'] = 6
+# And code coverage
+BRANCHES['comm-aurora']['enable_codecoverage'] = False
+# L10n configuration
+BRANCHES['comm-aurora']['enable_l10n'] = True
+BRANCHES['comm-aurora']['enable_l10n_onchange'] = True
+BRANCHES['comm-aurora']['l10nNightlyUpdate'] = True
+BRANCHES['comm-aurora']['l10n_platforms'] = ['linux', 'linux64', 'win32',
+                                                 'macosx64']
+BRANCHES['comm-aurora']['l10nDatedDirs'] = True
+BRANCHES['comm-aurora']['l10n_tree'] = 'fxaurora'
+#make sure it has an ending slash
+BRANCHES['comm-aurora']['l10nUploadPath'] = \
+    '/home/ftp/pub/mozilla.org/thunderbird/nightly/latest-comm-aurora-l10n/'
+BRANCHES['comm-aurora']['enUS_binaryURL'] = \
+    GLOBAL_VARS['download_base_url'] + '/nightly/latest-comm-aurora'
+BRANCHES['comm-aurora']['allLocalesFile'] = 'mail/locales/all-locales'
+BRANCHES['comm-aurora']['localesURL'] = \
+    '%s/build/buildbot-configs/raw-file/production/thunderbird/l10n/all-locales.comm-aurora' % (GLOBAL_VARS['hgurl'])
+BRANCHES['comm-aurora']['enable_multi_locale'] = True
+BRANCHES['comm-aurora']['upload_mobile_symbols'] = True
+# If True, a complete update snippet for this branch will be generated and
+# uploaded to. Any platforms with 'debug' in them will not have snippets
+# generated.
+BRANCHES['comm-aurora']['create_snippet'] = True
+BRANCHES['comm-aurora']['update_channel'] = 'aurora'
+BRANCHES['comm-aurora']['create_mobile_snippet'] = True
+BRANCHES['comm-aurora']['create_partial'] = True
+BRANCHES['comm-aurora']['create_partial_l10n'] = True
+BRANCHES['comm-aurora']['aus2_user'] = 'tbirdbld'
+BRANCHES['comm-aurora']['aus2_ssh_key'] = 'tbirdbld_dsa'
+# use comm-aurora-test when disabling updates for merges
+BRANCHES['comm-aurora']['aus2_base_upload_dir'] = '/opt/aus2/build/0/Thunderbird/comm-aurora'
+BRANCHES['comm-aurora']['aus2_base_upload_dir_l10n'] = '/opt/aus2/build/0/Thunderbird/comm-aurora'
+BRANCHES['comm-aurora']['aus2_mobile_base_upload_dir'] = None
+BRANCHES['comm-aurora']['aus2_mobile_base_upload_dir_l10n'] = None
+BRANCHES['comm-aurora']['enable_blocklist_update'] = True
+BRANCHES['comm-aurora']['blocklist_update_on_closed_tree'] = False
+del BRANCHES['comm-aurora']['platforms']['win64']
+BRANCHES['comm-aurora']['enable_valgrind'] = False
+
+######## try
+# Try-specific configs
+BRANCHES['try-comm-central']['stage_username'] = 'trybld'
+BRANCHES['try-comm-central']['stage_username_mobile'] = 'trybld'
+BRANCHES['try-comm-central']['stage_ssh_key'] = 'trybld_dsa'
+BRANCHES['try-comm-central']['stage_ssh_mobile_key'] = 'trybld_dsa'
+BRANCHES['try-comm-central']['stage_base_path'] = '/home/ftp/pub/thunderbird/try-builds'
+BRANCHES['try-comm-central']['stage_base_path_mobile'] = '/home/ftp/pub/thunderbird/try-builds'
+BRANCHES['try-comm-central']['enable_merging'] = False
+BRANCHES['try-comm-central']['enable_try'] = True
+BRANCHES['try-comm-central']['package_dir'] ='%(who)s-%(got_revision)s'
+# This is a path, relative to HGURL, where the repository is located
+# HGURL  repo_path should be a valid repository
+BRANCHES['try-comm-central']['repo_path'] = 'try-comm-central'
+BRANCHES['try-comm-central']['start_hour'] = [3]
+BRANCHES['try-comm-central']['start_minute'] = [2]
+# Disable Nightly builds
+BRANCHES['try-comm-central']['enable_nightly'] = False
+# Disable XULRunner / SDK builds
+BRANCHES['try-comm-central']['enable_xulrunner'] = False
+BRANCHES['try-comm-central']['enable_mac_a11y'] = True
+# only do unittests locally until they are switched over to talos-r3
+BRANCHES['try-comm-central']['enable_l10n'] = False
+BRANCHES['try-comm-central']['enable_l10n_onchange'] = False
+BRANCHES['try-comm-central']['l10nNightlyUpdate'] = False
+BRANCHES['try-comm-central']['l10nDatedDirs'] = False
+BRANCHES['try-comm-central']['enable_codecoverage'] = False
+BRANCHES['try-comm-central']['enable_shark'] = False
+BRANCHES['try-comm-central']['create_snippet'] = False
+# need this or the master.cfg will bail
+BRANCHES['try-comm-central']['aus2_base_upload_dir'] = 'fake'
+BRANCHES['try-comm-central']['platforms']['linux']['slaves'] = TRY_SLAVES['linux']
+BRANCHES['try-comm-central']['platforms']['linux64']['slaves'] = TRY_SLAVES['linux64']
+BRANCHES['try-comm-central']['platforms']['win32']['slaves'] = TRY_SLAVES['win32']
+BRANCHES['try-comm-central']['platforms']['win64']['slaves'] = TRY_SLAVES['win64']
+BRANCHES['try-comm-central']['platforms']['macosx64']['slaves'] = TRY_SLAVES['macosx64']
+BRANCHES['try-comm-central']['platforms']['linux-debug']['slaves'] = TRY_SLAVES['linux']
+BRANCHES['try-comm-central']['platforms']['linux64-debug']['slaves'] = TRY_SLAVES['linux64']
+BRANCHES['try-comm-central']['platforms']['win32-debug']['slaves'] = TRY_SLAVES['win32']
+BRANCHES['try-comm-central']['platforms']['macosx-debug']['slaves'] = TRY_SLAVES['macosx']
+BRANCHES['try-comm-central']['platforms']['macosx64-debug']['slaves'] = TRY_SLAVES['macosx64']
+BRANCHES['try-comm-central']['platforms']['linux']['upload_symbols'] = False
+BRANCHES['try-comm-central']['platforms']['linux64']['upload_symbols'] = False
+BRANCHES['try-comm-central']['platforms']['macosx64']['upload_symbols'] = False
+BRANCHES['try-comm-central']['platforms']['win32']['upload_symbols'] = True
+BRANCHES['try-comm-central']['platforms']['win32']['env']['SYMBOL_SERVER_USER'] = 'trybld'
+BRANCHES['try-comm-central']['platforms']['win32']['env']['SYMBOL_SERVER_PATH'] = '/symbols/windows'
+BRANCHES['try-comm-central']['platforms']['win32']['env']['SYMBOL_SERVER_SSH_KEY'] = '/c/Documents and Settings/cltbld/.ssh/trybld_dsa'
+BRANCHES['try-comm-central']['platforms']['win64']['upload_symbols'] = False
+for platform in BRANCHES['try-comm-central']['platforms'].keys():
+    BRANCHES['try-comm-central']['platforms'][platform]['stage_product'] = 'thunderbird'
+
+# Bug 578880, remove the following block after gcc-4.5 switch
+branches = BRANCHES.keys()
+for branch in branches:
+    if BRANCHES[branch]['platforms'].has_key('linux'):
+        BRANCHES[branch]['platforms']['linux']['env']['LD_LIBRARY_PATH'] = '/tools/gcc-4.3.3/installed/lib'
+        BRANCHES[branch]['platforms']['linux']['unittest-env'] = {
+            'LD_LIBRARY_PATH': '/tools/gcc-4.3.3/installed/lib',
+        }
+    if BRANCHES[branch]['platforms'].has_key('linux-mobile'):
+        BRANCHES[branch]['platforms']['linux-mobile']['env']['LD_LIBRARY_PATH'] = '/tools/gcc-4.3.3/installed/lib'
+        BRANCHES[branch]['platforms']['linux-mobile']['unittest-env'] = {
+            'LD_LIBRARY_PATH': '/tools/gcc-4.3.3/installed/lib',
+        }
+    if BRANCHES[branch]['platforms'].has_key('linuxqt'):
+        BRANCHES[branch]['platforms']['linuxqt']['env']['LD_LIBRARY_PATH'] = '/tools/gcc-4.3.3/installed/lib'
+        BRANCHES[branch]['platforms']['linuxqt']['unittest-env'] = {
+            'LD_LIBRARY_PATH': '/tools/gcc-4.3.3/installed/lib',
+        }
+    if BRANCHES[branch]['platforms'].has_key('linux64'):
+        BRANCHES[branch]['platforms']['linux64']['env']['LD_LIBRARY_PATH'] = '/tools/gcc-4.3.3/installed/lib64'
+        BRANCHES[branch]['platforms']['linux64']['unittest-env'] = {
+            'LD_LIBRARY_PATH': '/tools/gcc-4.3.3/installed/lib64',
+        }
+    if BRANCHES[branch]['platforms'].has_key('linux-debug'):
+        BRANCHES[branch]['platforms']['linux-debug']['env']['LD_LIBRARY_PATH'] ='/tools/gcc-4.3.3/installed/lib:%s/mozilla/dist/bin' % OBJDIR
+        BRANCHES[branch]['platforms']['linux-debug']['unittest-env'] = {
+            'LD_LIBRARY_PATH': '/tools/gcc-4.3.3/installed/lib',
+        }
+    if BRANCHES[branch]['platforms'].has_key('linux64-debug'):
+        BRANCHES[branch]['platforms']['linux64-debug']['env']['LD_LIBRARY_PATH'] ='/tools/gcc-4.3.3/installed/lib64:%s/mozilla/dist/bin' % OBJDIR
+        BRANCHES[branch]['platforms']['linux64-debug']['unittest-env'] = {
+            'LD_LIBRARY_PATH': '/tools/gcc-4.3.3/installed/lib64',
+        }
+
+if __name__ == "__main__":
+    import sys, pprint
+    args = sys.argv[1:]
+
+    if len(args) > 0:
+        branches = args
+    else:
+        branches = BRANCHES.keys()
+
+    for branch in branches:
+        print branch
+        pprint.pprint(BRANCHES[branch])
+
+    pprint.pprint(PROJECTS)
+
+# need to do things to copy platform/global stuff into BRANCHES here, like config.py does
new file mode 100644
--- /dev/null
+++ b/mozilla/thunderbird_production_config.py
@@ -0,0 +1,105 @@
+from copy import deepcopy
+
+from production_config import \
+    GLOBAL_VARS, MAC_LION_MINIS, MAC_SNOW_MINIS, MAC_MINIS, XSERVES, \
+    LINUX_VMS, LINUX_IXS, LINUX64_VMS, LINUX64_IXS, WIN32_IXS, WIN64_IXS, \
+    WIN64_IXS, MOCK_DL120G7, \
+    TRY_LINUX, TRY_LINUX_IXS, TRY_LINUX64, TRY_LINUX64_IXS, TRY_MAC, \
+    TRY_XSERVES, TRY_MAC64, TRY_WIN32_IXS, TRY_WIN64_IXS, TRY_MOCK_DL120G7, \
+    TRY_LION, \
+    BUILDS_BEFORE_REBOOT, SYMBOL_SERVER_HOST
+
+GLOBAL_VARS = deepcopy(GLOBAL_VARS)
+GLOBAL_VARS['download_base_url'] = 'http://ftp.mozilla.org/pub/mozilla.org/thunderbird'
+
+SLAVES = {
+    'linux':            LINUX_VMS + LINUX_IXS,
+    'linux64':          LINUX64_VMS + LINUX64_IXS,
+    'win32':            WIN32_IXS,
+    'win64':            WIN64_IXS,
+    'macosx':           MAC_MINIS + XSERVES,
+    'macosx64':         MAC_SNOW_MINIS,
+    'macosx64-lion':    MAC_LION_MINIS,
+    'mock':             MOCK_DL120G7
+}
+
+TRY_SLAVES = {
+    'linux':       TRY_LINUX + TRY_LINUX_IXS,
+    'linux64':     TRY_LINUX64 + TRY_LINUX64_IXS,
+    'win32':       TRY_WIN32_IXS,
+    'win64':       TRY_WIN64_IXS,
+    'macosx':      TRY_MAC + TRY_XSERVES,
+    'macosx64':    TRY_MAC64,
+    'macosx64-lion': TRY_LION,
+    'mock':        TRY_MOCK_DL120G7,
+}
+
+# Local overrides for default values
+GLOBAL_VARS['download_base_url'] = 'http://ftp.mozilla.org/pub/mozilla.org/thunderbird'
+GLOBAL_VARS['talos_masters'] = []
+# List of unittest masters to notify of new builds to test,
+# if a failure to notify the master should result in a warning,
+# and sendchange retry count before give up
+GLOBAL_VARS['unittest_masters'] = [
+    ('buildbot-master10.build.mozilla.org:9301', True, 5),
+    ('geriatric-master.build.mozilla.org:9989', False, 1),
+]
+GLOBAL_VARS['xulrunner_tinderbox_tree'] = None
+GLOBAL_VARS['weekly_tinderbox_tree'] = 'ThunderbirdTest'
+GLOBAL_VARS['l10n_tinderbox_tree'] = 'Thunderbird-l10n'
+GLOBAL_VARS['base_mirror_urls'] = ['http://hg.build.scl1.mozilla.com']
+GLOBAL_VARS['base_bundle_urls'] = ['http://ftp.mozilla.org/pub/mozilla.org/thunderbird/bundles']
+
+# Local branch overrides
+BRANCHES = {
+    'comm-central': {
+        'packaged_unittest_tinderbox_tree': 'ThunderbirdTrunk',
+        'tinderbox_tree': 'ThunderbirdTrunk',
+    },
+    'comm-release': {
+        'packaged_unittest_tinderbox_tree': 'Thunderbird-Release',
+        'tinderbox_tree': 'Thunderbird-Release',
+    },
+    'comm-esr10': {
+        'packaged_unittest_tinderbox_tree': 'Thunderbird-Esr10',
+        'tinderbox_tree': 'Thunderbird-Esr10',
+    },
+    'comm-beta': {
+        'packaged_unittest_tinderbox_tree': 'Thunderbird-Beta',
+        'tinderbox_tree': 'Thunderbird-Beta',
+    },
+    'comm-aurora': {
+        'packaged_unittest_tinderbox_tree': 'Thunderbird-Aurora',
+        'tinderbox_tree': 'Thunderbird-Aurora',
+    },
+    'try-comm-central': {
+        'tinderbox_tree': 'ThunderbirdTry',
+        'packaged_unittest_tinderbox_tree': 'ThunderbirdTry',
+        'download_base_url': 'http://ftp.mozilla.org/pub/mozilla.org/thunderbird/try-builds',
+        'mobile_download_base_url': 'http://ftp.mozilla.org/pub/mozilla.org/thunderbird/try-builds',
+        'enable_mail_notifier': True,
+        'notify_real_author': True,
+        'package_url': 'http://ftp.mozilla.org/pub/mozilla.org/thunderbird/try-builds',
+        'talos_masters': [],
+        'platforms': {
+            'win32': {
+                'env': {
+                    'SYMBOL_SERVER_HOST': 'build.mozilla.org',
+                    'CVS_RSH': 'ssh',
+                    'MOZ_OBJDIR': 'objdir-tb',
+                    'TINDERBOX_OUTPUT': '1',
+                    'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                    # Source server support, bug 506702
+                    'PDBSTR_PATH': '/c/Program Files/Debugging Tools for Windows/srcsrv/pdbstr.exe',
+                    'HG_SHARE_BASE_DIR': 'e:/builds/hg-shared',
+                    'BINSCOPE': 'C:\Program Files\Microsoft\SDL BinScope\Binscope.exe',
+                    'PATH': "${MOZILLABUILD}buildbotve\\scripts;${PATH}",
+                }
+            }
+        }
+    },
+}
+
+PLATFORM_VARS = {}
+
+PROJECTS = {}
new file mode 100644
--- /dev/null
+++ b/mozilla/thunderbird_staging_config.py
@@ -0,0 +1,115 @@
+from staging_config import \
+    MAC_SNOW_MINIS, MAC_MINIS, XSERVES, WIN32_IXS, WIN64_IXS, LINUX_VMS, \
+    LINUX_IXS, LINUX64_VMS, LINUX64_IXS
+    
+SLAVES = {
+    'linux':            LINUX_VMS + LINUX_IXS,
+    'linux64':          LINUX64_VMS + LINUX64_IXS,
+    'win32':            WIN32_IXS,
+    'win64':            WIN64_IXS,
+    'macosx':           MAC_MINIS + XSERVES,
+    'macosx64':         MAC_SNOW_MINIS,
+}
+
+TRY_LINUX      = ['try-linux-slave%02i' % x for x in range (1,31)]
+TRY_LINUX_IXS  = []
+TRY_LINUX64    = ['try-linux64-slave%02i' % x for x in range (1,11)]
+TRY_LINUX64_IXS= ['linux64-ix-slave%02i' % x for x in range(22,41)]
+TRY_MAC        = ['try-mac-slave%02i' % x for x in range (1,48)]
+TRY_MAC64      = ['try-mac64-slave%02i' % x for x in range (1,32)]
+TRY_WIN32_IXS  = []
+
+TRY_SLAVES = SLAVES
+TRY_SLAVES['linux'] += TRY_LINUX + TRY_LINUX_IXS
+TRY_SLAVES['linux64'] += TRY_LINUX64 + TRY_LINUX64_IXS
+TRY_SLAVES['macosx'] += TRY_MAC
+TRY_SLAVES['macosx64'] += TRY_MAC64
+TRY_SLAVES['win32'] += TRY_WIN32_IXS
+
+
+GLOBAL_VARS = {
+    'staging': True,
+    #XXX 'config_repo_path': 'build/buildbot-configs',
+    'config_repo_path': 'users/john.hopkins_mozillamessaging.com/buildbot-configs-stage',
+    'buildbotcustom_repo_path': 'build/buildbotcustom',
+    'stage_server': 'dev-stage01.build.sjc1.mozilla.com',
+    'aus2_host': 'dev-stage01.build.sjc1.mozilla.com',
+    'download_base_url': 'http://dev-stage01.build.sjc1.mozilla.com/pub/mozilla.org/thunderbird',
+    'mobile_download_base_url': 'http://dev-stage01.build.sjc1.mozilla.com/pub/mozilla.org/mobile',
+    'graph_server': None, #XXX reenable once graph server has Thunderbird entries
+    'build_tools_repo_path': 'build/tools',
+    'base_clobber_url': 'http://build.mozilla.org/stage-clobberer/index.php',
+    'disable_tinderbox_mail': True,
+    'talos_masters': [],
+    # List of unittest masters to notify of new builds to test,
+    # if a failure to notify the master should result in a warning,
+    # and sendchange retry count before give up
+    'unittest_masters': [
+        ('dev-master01.build.scl1.mozilla.com:9901', True, 1),
+        ],
+    'xulrunner_tinderbox_tree': 'MozillaTest',
+    'weekly_tinderbox_tree': 'MozillaTest',
+    'l10n_tinderbox_tree': 'MozillaStaging',
+    'packaged_unittest_tinderbox_tree': 'MozillaTest',
+    'tinderbox_tree': 'MozillaTest',
+    'mobile_tinderbox_tree': 'MobileTest',
+    'hg_username': 'stage-tbirdbld',
+    'base_mirror_urls': ['http://hg.build.scl1.mozilla.com'],
+    'base_bundle_urls': ['http://dev-stage01.build.mozilla.org/pub/mozilla.org/thunderbird/bundles'],
+}
+
+BUILDS_BEFORE_REBOOT = 5
+SYMBOL_SERVER_HOST = 'dev-stage01.build.sjc1.mozilla.com'
+
+# Local branch overrides
+BRANCHES = {
+    'comm-central': {
+        'enable_blocklist_update': False,
+        'blocklist_update_on_closed_tree': False,
+    },
+    'comm-release': {
+        'enable_blocklist_update': False,
+        'blocklist_update_on_closed_tree': False,
+    },
+    'comm-beta': {
+        'enable_blocklist_update': False,
+        'blocklist_update_on_closed_tree': False,
+    },
+    'comm-aurora': {
+        'enable_blocklist_update': False,
+        'blocklist_update_on_closed_tree': False,
+    },
+    'comm-esr10': {
+        'enable_blocklist_update': False,
+        'blocklist_update_on_closed_tree': False,
+    },
+    'try-comm-central': {
+        'download_base_url': 'http://dev-stage01.build.sjc1.mozilla.com/pub/mozilla.org/thunderbird',
+        'mobile_download_base_url': 'http://dev-stage01.build.sjc1.mozilla.com/pub/mozilla.org/mobile',
+        'enable_mail_notifier': False, # Set to True when testing
+        'email_override': [], # Set to your address when testing
+        'package_url': 'http://dev-stage01.build.sjc1.mozilla.com/pub/mozilla.org/thunderbird/try-builds',
+        'talos_masters': [],
+        'platforms': {
+            'win32': {
+                'env': {
+                    'SYMBOL_SERVER_HOST': 'dev-stage01.build.sjc1.mozilla.com',
+                    'CVS_RSH': 'ssh',
+                    'MOZ_OBJDIR': 'objdir-tb',
+                    'TINDERBOX_OUTPUT': '1',
+                    'MOZ_CRASHREPORTER_NO_REPORT': '1',
+                    # Source server support, bug 506702
+                    'PDBSTR_PATH': '/c/Program Files/Debugging Tools for Windows/srcsrv/pdbstr.exe',
+                    'HG_SHARE_BASE_DIR': 'e:/builds/hg-shared',
+                    'PATH': "${MOZILLABUILD}buildbotve\\scripts;${PATH}",
+                }
+            }
+        }
+    },
+}
+
+PLATFORM_VARS = {
+}
+
+PROJECTS = {
+}
--- a/mozilla/try_localconfig.py
+++ b/mozilla/try_localconfig.py
@@ -15,16 +15,17 @@ if 'http_port' in master_config:
 
 if 'ssh_port' in master_config:
     c['manhole'] = manhole.PasswordManhole(
             "tcp:%(ssh_port)i:interface=127.0.0.1" % master_config,
             "cltbld", "password")
 
 from config import BRANCHES, TRY_SLAVES
 ACTIVE_BRANCHES = ['try']
+ACTIVE_THUNDERBIRD_BRANCHES = ['try-comm-central']
 ACTIVE_RELEASE_BRANCHES = []
 ACTIVE_MOBILE_RELEASE_BRANCHES = []
 ACTIVE_PROJECTS = []
 
 # Override with TRY_SLAVES
 SLAVES = TRY_SLAVES
 
 # Set up our fast slaves
--- a/mozilla/universal_master_sqlite.cfg
+++ b/mozilla/universal_master_sqlite.cfg
@@ -3,22 +3,24 @@
 # so that the fastRegexes don't get reset
 # vim: ft=python
 import os, sys
 
 import buildbotcustom.misc
 import buildbotcustom.status.queued_command
 import master_common
 import config
+import thunderbird_config
 import master_localconfig
 import build.paths
 reload(buildbotcustom.misc)
 reload(buildbotcustom.status.queued_command)
 reload(master_common)
 reload(config)
+reload(thunderbird_config)
 reload(master_localconfig)
 reload(build.paths)
 
 from master_common import BuildmasterConfig
 from build.paths import getRealpath
 
 c = BuildmasterConfig
 for key, value in master_localconfig.BuildmasterConfig.items():
@@ -33,19 +35,20 @@ from mozilla_buildtools.queuedir import 
 commandsQueue = QueueDir('commands', '%s/commands' % master_localconfig.QUEUEDIR)
 from buildbotcustom.status.queued_command import QueuedCommandHandler
 c['status'].append(QueuedCommandHandler(
     command=[sys.executable, os.path.join(os.path.dirname(buildbotcustom.__file__), 'bin', 'postrun.py'), '-c', os.path.abspath(os.path.join(os.curdir, 'postrun.cfg'))],
     queuedir=commandsQueue,
 ))
 
 from config import BRANCHES, PROJECTS
+from thunderbird_config import BRANCHES as THUNDERBIRD_BRANCHES
 from master_localconfig import ACTIVE_BRANCHES, ACTIVE_PROJECTS, SLAVES, \
          ENABLE_RELEASES, RESERVED_SLAVES, ACTIVE_RELEASE_BRANCHES, \
-         ACTIVE_MOBILE_RELEASE_BRANCHES
+         ACTIVE_MOBILE_RELEASE_BRANCHES, ACTIVE_THUNDERBIRD_BRANCHES
 
 import BuildSlaves
 reload(BuildSlaves)
 from BuildSlaves import SlavePasswords
 from buildbot.buildslave import BuildSlave
 for platform, names in SLAVES.items():
     for name in names:
         c['slaves'].append(BuildSlave(name, SlavePasswords[platform], max_builds=1))
@@ -65,26 +68,39 @@ buildObjects = {'builders': [], 'status'
 import passwords
 reload(passwords)
 
 for branch in ACTIVE_BRANCHES:
     branchObjects = generateBranchObjects(BRANCHES[branch], branch,
             getattr(passwords, 'secrets', None))
     buildObjects = mergeBuildObjects(buildObjects, branchObjects)
 
+for branch in ACTIVE_THUNDERBIRD_BRANCHES:
+    branchObjects = generateBranchObjects(THUNDERBIRD_BRANCHES[branch], branch)
+    # Strip away any duplicate change sources
+    usefulChangeSources = []
+    for cs in branchObjects['change_source']:
+        if cs.branch not in [x for x in buildObjects['change_source']]:
+            usefulChangeSources.append(cs)
+    branchObjects['change_source'] = usefulChangeSources
+    buildObjects = mergeBuildObjects(buildObjects, branchObjects)
+
 for project in ACTIVE_PROJECTS:
     projectObjects = generateProjectObjects(project, PROJECTS[project], SLAVES)
     buildObjects = mergeBuildObjects(buildObjects, projectObjects)
 
 # Remove duplicate change sources
 for cs in buildObjects['change_source'][:]:
-    while buildObjects['change_source'].count(cs) > 1:
+    cnt = 0
+    for x in buildObjects['change_source']:
+        if x.branch == cs.branch:
+            cnt = cnt + 1
+    if cnt > 1:
         buildObjects['change_source'].remove(cs)
 
-    assert buildObjects['change_source'].count(cs) == 1
 
 c['builders'].extend(buildObjects['builders'])
 c['status'].extend(buildObjects['status'])
 c['change_source'].extend(buildObjects['change_source'])
 c['schedulers'].extend(buildObjects['schedulers'])
 
 if ENABLE_RELEASES:
     import buildbotcustom.process.release
@@ -134,17 +150,18 @@ if hasattr(passwords, 'PULSE_PASSWORD'):
 # same thing
 assert c is BuildmasterConfig
 
 # Check that all our builders have branch, platform and product set
 for b in c['builders']:
     assert 'properties' in b, b
     assert 'branch' in b['properties'], b
     assert 'platform' in b['properties'], b
-    assert 'product' in b['properties'], b
+    if not 'coverage' in b['name']:
+        assert 'product' in b['properties'], b
 
 # Check that we don't have more too many  builders for any one slave
 _buildersBySlave = {}
 for b in c['builders']:
     for s in b['slavenames']:
         _buildersBySlave[s] = _buildersBySlave.get(s, 0) + 1
 
 for s, count in _buildersBySlave.items():
--- a/setup-master.py
+++ b/setup-master.py
@@ -163,26 +163,29 @@ def load_masters_json(masters_json, role
             environment_config = 'production_config.py'
         elif m['environment'] == 'staging':
             environment_config = 'staging_config.py'
         elif m['environment'] == 'preproduction':
             environment_config = 'preproduction_config.py'
         c = MasterConfig(name=m['name'],
                 globs=[
                     'config.py',
+                    'thunderbird_config.py',
                     environment_config,
+                    'thunderbird_' + environment_config,
                     'master_common.py',
                     'project_branches.py',
                     ],
                 renames=[
                     ('BuildSlaves.py.template', 'BuildSlaves.py'),
                     ('passwords.py.template', 'passwords.py'),
                     ],
                 local_links=[
                     (environment_config, 'localconfig.py'),
+                    ('thunderbird_' + environment_config, 'thunderbird_localconfig.py'),
                     ],
                 extras=[
                     ('master_config.json', json.dumps(m, indent=2, sort_keys=True)),
                     ],
                 log=log
                 )
 
         if universal:
@@ -272,178 +275,197 @@ mozilla_staging = mozilla_base + MasterC
                  for v in ['beta', 'release']]
     )
 
 mozilla_staging_scheduler_master_sm01 = mozilla_staging + MasterConfig(
         "staging-scheduler_master",
         local_links = [
             ('staging_scheduler_master_sm01_localconfig.py', 'master_localconfig.py'),
             ('staging_config.py', 'localconfig.py'),
+            ('thunderbird_staging_config.py', 'thunderbird_localconfig.py'),
             ('scheduler_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_staging_builder_master_sm01 = mozilla_staging + MasterConfig(
         "staging-builder_master1",
         local_links = [
             ('staging_builder_master_sm01_localconfig.py', 'master_localconfig.py'),
             ('staging_config.py', 'localconfig.py'),
+            ('thunderbird_staging_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_staging_univeral_master_sm02 = mozilla_staging + MasterConfig(
         "staging-builder_master2",
         local_links = [
             ('staging_builder_master_sm02_localconfig.py', 'master_localconfig.py'),
             ('staging_config.py', 'localconfig.py'),
+            ('thunderbird_staging_config.py', 'thunderbird_localconfig.py'),
             ('universal_master_sqlite.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_staging_univeral_master_sm03 = mozilla_staging + MasterConfig(
         "staging-builder_master3",
         local_links = [
             ('staging_builder_master_sm03_localconfig.py', 'master_localconfig.py'),
             ('staging_config.py', 'localconfig.py'),
+            ('thunderbird_staging_config.py', 'thunderbird_localconfig.py'),
             ('universal_master_sqlite.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_scheduler_master = mozilla_production + MasterConfig(
         "pm01-scheduler",
         local_links = [
             ('production_scheduler_master_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('scheduler_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_builder_master_pm01 = mozilla_production + MasterConfig(
         "pm01-builder",
         local_links = [
             ('production_builder_master_pm01_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_try_builder_master_pm02 = mozilla_production + MasterConfig(
         "pm02-trybuilder",
         local_links = [
             ('production_try_builder_master_pm02_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_try_builder_master_bm01 = mozilla_production + MasterConfig(
         "bm01-trybuilder",
         local_links = [
             ('production_try_builder_master_bm01_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_try_builder_master_bm02 = mozilla_production + MasterConfig(
         "bm02-trybuilder",
         local_links = [
             ('production_try_builder_master_bm02_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_try_builder_master_bm03 = mozilla_production + MasterConfig(
         "bm03-trybuilder",
         local_links = [
             ('production_try_builder_master_bm03_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_try_builder_master_bm04 = mozilla_base + MasterConfig(
         "bm04-try1",
         local_links = [
             ('production_try_builder_master_bm04_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_try_builder_master_bm05 = mozilla_base + MasterConfig(
         "bm05-trybuilder",
         local_links = [
             ('production_try_builder_master_bm05_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_try_builder_master_bm06 = mozilla_base + MasterConfig(
         "bm06-try1",
         local_links = [
             ('production_try_builder_master_bm06_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_builder_master_pm03 = mozilla_production + MasterConfig(
         "pm03-builder",
         local_links = [
             ('production_builder_master_pm03_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_builder_master_bm01 = mozilla_production + MasterConfig(
         "bm01-builder",
         local_links = [
             ('production_builder_master_bm01_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_builder_master_bm02 = mozilla_production + MasterConfig(
         "bm02-builder",
         local_links = [
             ('production_builder_master_bm02_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_builder_master_bm04 = mozilla_base + MasterConfig(
         "bm04-build1",
         local_links = [
             ('production_builder_master_bm04_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_builder_master_bm05 = mozilla_base + MasterConfig(
         "bm05-builder",
         local_links = [
             ('production_builder_master_bm05_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_production_builder_master_bm06 = mozilla_base + MasterConfig(
         "bm06-build1",
         local_links = [
             ('production_builder_master_bm06_localconfig.py', 'master_localconfig.py'),
             ('production_config.py', 'localconfig.py'),
+            ('production_thunderbird_config.py', 'thunderbird_localconfig.py'),
             ('builder_master.cfg', 'master.cfg'),
             ]
         )
 
 mozilla_tests = MasterConfig(
         config_dir="mozilla-tests",
         globs=['*.py', '*.cfg'],
         renames=[
@@ -453,34 +475,37 @@ mozilla_tests = MasterConfig(
         )
 
 mozilla_staging_tests_scheduler_master = mozilla_tests + MasterConfig(
         "staging-tests_scheduler",
         local_links = [
             ('staging_tests_scheduler_master.py', 'master_localconfig.py'),
             ('staging_config.py', 'localconfig.py'),
             ('tests_master.cfg', 'master.cfg'),
+            ('thunderbird_staging_config.py', 'thunderbird_localconfig.py'),
             ]
         )
 
 mozilla_staging_tests_master1 = mozilla_tests + MasterConfig(
         "staging-tests_master1",
         local_links = [
             ('staging_tests_master_stm01_localconfig.py', 'master_localconfig.py'),
             ('staging_config.py', 'localconfig.py'),
             ('tests_master.cfg', 'master.cfg'),
+            ('thunderbird_staging_config.py', 'thunderbird_localconfig.py'),
             ]
         )
 
 mozilla_staging_tests_master2 = mozilla_tests + MasterConfig(
         "staging-tests_master2",
         local_links = [
             ('staging_tests_master_stm02_localconfig.py', 'master_localconfig.py'),
             ('staging_config.py', 'localconfig.py'),
             ('universal_master_sqlite.cfg', 'master.cfg'),
+            ('thunderbird_staging_config.py', 'thunderbird_localconfig.py'),
             ]
         )
 
 mozilla_staging_ateam_master1 = mozilla_tests + MasterConfig(
         "staging-ateam_master1",
         local_links = [
             ('staging_ateam_master01_localconfig.py', 'master_localconfig.py'),
             ('staging_ateam_config.py', 'localconfig.py'),