Skip to content
This repository has been archived by the owner on Jun 11, 2019. It is now read-only.

Commit

Permalink
changeset: 1967:41d33904e045
Browse files Browse the repository at this point in the history
parent:      1964:2c3f558e4d7b
user:        John Hopkins <jhopkins@mozilla.com>
date:        Wed Dec 21 16:34:45 2011 -0500
summary:     Bug 710350 - Don't hard-code 'firefox' and 'fennec' in misc.py. r=bhearsum

changeset:   1968:67081bb6526e
user:        Mike Taylor <bear@mozilla.com>
date:        Wed Dec 21 17:20:09 2011 -0500
summary:     bug 711367 r=aki adjust buildbot talos runner to add optional --nativeUI flag for android-xul

changeset:   1969:7a7847f7fc05
user:        Ben Hearsum <bhearsum@mozilla.com>
date:        Thu Dec 22 09:18:25 2011 -0500
summary:     bug 711275: Make sure appVersion changes with every Firefox 10 beta. r=rail

changeset:   1970:eee5d445b9b6
tag:         tip
user:        Armen Zambrano Gasparnian <armenzg@mozilla.com>
date:        Thu Dec 22 10:25:58 2011 -0500
summary:     Bug 673131. Use a Python that contains SimpleJson. r=coop

--HG--
branch : production-0.8
  • Loading branch information
Armen Zambrano Gasparnian committed Dec 22, 2011
2 parents 1ceb2db + 2dc42b3 commit 7ea9e82
Show file tree
Hide file tree
Showing 2 changed files with 63 additions and 40 deletions.
76 changes: 44 additions & 32 deletions misc.py
Expand Up @@ -9,6 +9,8 @@
import re
import sys, os, time

from copy import deepcopy

from twisted.python import log

from buildbot.scheduler import Nightly, Scheduler, Triggerable
Expand Down Expand Up @@ -372,9 +374,7 @@ def generateTestBuilder(config, branch_name, platform, name_prefix,
slavenames = slaves
if not category:
category = branch_name
productName = 'firefox'
if 'mobile' in name_prefix or 'Android' in name_prefix:
productName = 'fennec'
productName = pf['product_name']
branchProperty = branch_name
posixBinarySuffix = '' if 'mobile' in name_prefix else '-bin'
properties = {'branch': branchProperty, 'platform': platform,
Expand Down Expand Up @@ -483,7 +483,7 @@ def generateCCTestBuilder(config, branch_name, platform, name_prefix,
slavenames = slaves
if not category:
category = branch_name
productName = config['product_name']
productName = pf['product_name']
posixBinarySuffix = '-bin'
if isinstance(suites, dict) and "totalChunks" in suites:
totalChunks = suites['totalChunks']
Expand Down Expand Up @@ -637,7 +637,7 @@ def generateBranchObjects(config, name, secrets=None):
l10nBuilders[base_name] = {}
l10nBuilders[base_name]['tree'] = config['l10n_tree']
l10nBuilders[base_name]['l10n_builder'] = \
'%s %s %s l10n dep' % (config['product_name'].capitalize(),
'%s %s %s l10n dep' % (pf['product_name'].capitalize(),
name, platform)
l10nBuilders[base_name]['platform'] = platform
# Check if branch wants nightly builds
Expand All @@ -661,7 +661,7 @@ def generateBranchObjects(config, name, secrets=None):
l10nNightlyBuilders[builder] = {}
l10nNightlyBuilders[builder]['tree'] = config['l10n_tree']
l10nNightlyBuilders[builder]['l10n_builder'] = \
'%s %s %s l10n nightly' % (config['product_name'].capitalize(),
'%s %s %s l10n nightly' % (pf['product_name'].capitalize(),
name, platform)
l10nNightlyBuilders[builder]['platform'] = platform
if config['enable_shark'] and pf.get('enable_shark'):
Expand Down Expand Up @@ -1089,7 +1089,7 @@ def generateBranchObjects(config, name, secrets=None):
'configRepoPath': config['config_repo_path'],
'configSubDir': config['config_subdir'],
'profiledBuild': per_checkin_build_uses_pgo,
'productName': config['product_name'],
'productName': pf['product_name'],
'mozconfig': pf['mozconfig'],
'srcMozconfig': pf.get('src_mozconfig'),
'use_scratchbox': pf.get('use_scratchbox'),
Expand Down Expand Up @@ -1344,7 +1344,7 @@ def generateBranchObjects(config, name, secrets=None):
configRepoPath=config['config_repo_path'],
configSubDir=config['config_subdir'],
profiledBuild=nightly_pgo,
productName=config['product_name'],
productName=pf['product_name'],
mozconfig=pf['mozconfig'],
srcMozconfig=pf.get('src_mozconfig'),
use_scratchbox=pf.get('use_scratchbox'),
Expand Down Expand Up @@ -1422,8 +1422,8 @@ def generateBranchObjects(config, name, secrets=None):
platform=platform,
hgHost=config['hghost'],
tree=config['l10n_tree'],
project=config['product_name'],
appName=config['app_name'],
project=pf['product_name'],
appName=pf['app_name'],
enUSBinaryURL=config['enUS_binaryURL'],
nightly=True,
configRepoPath=config['config_repo_path'],
Expand Down Expand Up @@ -1485,7 +1485,7 @@ def generateBranchObjects(config, name, secrets=None):
configRepoPath=config['config_repo_path'],
configSubDir=config['config_subdir'],
profiledBuild=False,
productName=config['product_name'],
productName=pf['product_name'],
mozconfig='%s/%s/shark' % (platform, name),
srcMozconfig=pf.get('src_shark_mozconfig'),
stageServer=config['stage_server'],
Expand Down Expand Up @@ -1553,8 +1553,8 @@ def generateBranchObjects(config, name, secrets=None):
platform=platform,
hgHost=config['hghost'],
tree=config['l10n_tree'],
project=config['product_name'],
appName=config['app_name'],
project=pf['product_name'],
appName=pf['app_name'],
enUSBinaryURL=config['enUS_binaryURL'],
nightly=False,
l10nDatedDirs=config['l10nDatedDirs'],
Expand Down Expand Up @@ -1603,7 +1603,7 @@ def generateBranchObjects(config, name, secrets=None):
unittest_factory = factory_class(
env=pf.get('unittest-env', {}),
platform=platform,
productName=config['product_name'],
productName=pf['product_name'],
config_repo_path=config['config_repo_path'],
config_dir=config['config_subdir'],
objdir=config['objdir_unittests'],
Expand Down Expand Up @@ -1680,7 +1680,7 @@ def generateBranchObjects(config, name, secrets=None):
if platform == 'linux':
codecoverage_factory = CodeCoverageFactory(
platform=platform,
productName=config['product_name'],
productName=pf['product_name'],
config_repo_path=config['config_repo_path'],
config_dir=config['config_subdir'],
objdir=config['objdir_unittests'],
Expand Down Expand Up @@ -1870,7 +1870,7 @@ def generateCCBranchObjects(config, name):
l10nBuilders[base_name] = {}
l10nBuilders[base_name]['tree'] = config['l10n_tree']
l10nBuilders[base_name]['l10n_builder'] = \
'%s %s %s l10n dep' % (config['product_name'].capitalize(),
'%s %s %s l10n dep' % (pf['product_name'].capitalize(),
name, platform)
l10nBuilders[base_name]['platform'] = platform
# Check if branch wants nightly builds
Expand All @@ -1890,7 +1890,7 @@ def generateCCBranchObjects(config, name):
l10nNightlyBuilders[builder] = {}
l10nNightlyBuilders[builder]['tree'] = config['l10n_tree']
l10nNightlyBuilders[builder]['l10n_builder'] = \
'%s %s %s l10n nightly' % (config['product_name'].capitalize(),
'%s %s %s l10n nightly' % (pf['product_name'].capitalize(),
name, platform)
l10nNightlyBuilders[builder]['platform'] = platform
if config['enable_shark'] and platform.startswith('macosx'):
Expand Down Expand Up @@ -1918,7 +1918,7 @@ def generateCCBranchObjects(config, name):
weeklyBuilders.append('%s hg bundle' % name)

logUploadCmd = makeLogUploadCommand(name, config, is_try=config.get('enable_try'),
is_shadow=bool(name=='shadow-central'), product=config['product_name'])
is_shadow=bool(name=='shadow-central'), product=pf['product_name'])

branchObjects['status'].append(SubprocessLogHandler(
logUploadCmd,
Expand Down Expand Up @@ -2095,7 +2095,7 @@ def generateCCBranchObjects(config, name):
builderNames=l10n_builders,
fileIsImportant=lambda c: isImportantL10nFile(c, config['l10n_modules']),
properties={
'app': config['app_name'],
'app': pf['app_name'],
'en_revision': 'default',
'l10n_revision': 'default',
}
Expand Down Expand Up @@ -2245,7 +2245,7 @@ def generateCCBranchObjects(config, name):
configRepoPath=config['config_repo_path'],
configSubDir=config['config_subdir'],
profiledBuild=pf['profiled_build'],
productName=config['product_name'],
productName=pf['product_name'],
mozconfig=pf['mozconfig_dep'],
branchName=name,
stageServer=config['stage_server'],
Expand Down Expand Up @@ -2335,7 +2335,7 @@ def generateCCBranchObjects(config, name):
configRepoPath=config['config_repo_path'],
configSubDir=config['config_subdir'],
profiledBuild=pf['profiled_build'],
productName=config['product_name'],
productName=pf['product_name'],
mozconfig=pf['mozconfig'],
branchName=name,
stageServer=config['stage_server'],
Expand Down Expand Up @@ -2398,8 +2398,8 @@ def generateCCBranchObjects(config, name):
platform=platform,
hgHost=config['hghost'],
tree=config['l10n_tree'],
project=config['product_name'],
appName=config['app_name'],
project=pf['product_name'],
appName=pf['app_name'],
enUSBinaryURL=config['enUS_binaryURL'],
nightly=True,
configRepoPath=config['config_repo_path'],
Expand Down Expand Up @@ -2452,7 +2452,7 @@ def generateCCBranchObjects(config, name):
configRepoPath=config['config_repo_path'],
configSubDir=config['config_subdir'],
profiledBuild=False,
productName=config['product_name'],
productName=pf['product_name'],
mozconfig='%s/%s/shark' % (platform, name),
branchName=name,
stageServer=config['stage_server'],
Expand Down Expand Up @@ -2489,8 +2489,8 @@ def generateCCBranchObjects(config, name):
platform=platform,
hgHost=config['hghost'],
tree=config['l10n_tree'],
project=config['product_name'],
appName=config['app_name'],
project=pf['product_name'],
appName=pf['app_name'],
enUSBinaryURL=config['enUS_binaryURL'],
nightly=False,
branchName=name,
Expand Down Expand Up @@ -2534,9 +2534,9 @@ def generateCCBranchObjects(config, name):
unittest_factory = factory_class(
env=pf.get('unittest-env', {}),
platform=platform,
productName=config['product_name'],
productName=pf['product_name'],
branchName=name,
brandName=config['brand_name'],
brandName=pf['brand_name'],
config_repo_path=config['config_repo_path'],
config_dir=config['config_subdir'],
objdir=config['objdir_unittests'],
Expand Down Expand Up @@ -2613,7 +2613,7 @@ def generateCCBranchObjects(config, name):
if platform == 'linux':
codecoverage_factory = CodeCoverageFactory(
platform=platform,
productName=config['product_name'],
productName=pf['product_name'],
config_repo_path=config['config_repo_path'],
config_dir=config['config_subdir'],
objdir=config['objdir_unittests'],
Expand Down Expand Up @@ -2768,7 +2768,18 @@ def generateTalosBranchObjects(branch, branch_config, PLATFORMS, SUITES,
platform_config[slave_platform].get('download_symbols',True),
"talos_from_source_code": branch_config.get('talos_from_source_code', False)
}
factory_kwargs.update(extra)

if extra and extra.get('remoteTests', False) and 'xul' in platform:
myextra = deepcopy(extra)
remoteExtras = myextra.get('remoteExtras', {})
reOptions = remoteExtras.get('options', [])
reOptions.append('--nativeUI')
remoteExtras['options'] = reOptions
myextra['remoteExtras'] = remoteExtras
factory_kwargs.update(myextra)
else:
factory_kwargs.update(extra)

builddir = "%s_%s_test-%s" % (branch, slave_platform, suite)
slavebuilddir= 'test'
factory = factory_class(**factory_kwargs)
Expand Down Expand Up @@ -3064,9 +3075,10 @@ def generateTalosReleaseBranchObjects(branch, branch_config, PLATFORMS, SUITES,


def generateBlocklistBuilder(config, branch_name, platform, base_name, slaves) :
pf = config['platforms'].get(platform, {})
extra_args = ['-b', config['repo_path']]
if config['product_name'] is not None:
extra_args.extend(['-p', config['product_name']])
if pf['product_name'] is not None:
extra_args.extend(['-p', pf['product_name']])
if config['hg_username'] is not None:
extra_args.extend(['-u', config['hg_username']])
if config['hg_ssh_key'] is not None:
Expand Down
27 changes: 19 additions & 8 deletions process/factory.py
Expand Up @@ -4963,6 +4963,21 @@ def createPatches(self):
description=['patcher:', 'create patches'],
haltOnFailure=True
))
# XXX: For Firefox 10 betas we want the appVersion in the snippets to
# show a version change with each one, so we change them from the
# the appVersion (which is always "10") to the version, which has
# a beta marker, like "10.0b2".
# This is talked about in detail in bug 711275.
if self.productName == 'firefox' and self.version.startswith('10.0b'):
cmd = ['bash', WithProperties('%(toolsdir)s/release/edit-snippets.sh'),
'appVersion', self.version]
cmd.extend(self.dirMap.keys())
self.addStep(ShellCommand(
name='switch_appv_in_snippets',
command=cmd,
haltOnFailure=True,
workdir=self.updateDir,
))

def createBuildNSnippets(self):
command = ['python',
Expand Down Expand Up @@ -7062,13 +7077,9 @@ def __init__(self, OS, supportUrlBase, envName, buildBranch, branchName,
self.addRunTestStep()
self.addRebootStep()

def python25(self, platform):
if (platform.startswith('fedora')):
return "/home/cltbld/bin/python"
elif (platform == "leopard"):
return "/usr/bin/python"
elif (platform in ("snowleopard", "lion")):
return "/Users/cltbld/bin/python"
def pythonWithSimpleJson(self, platform):
if (platform in ("fedora", "fedora64", "leopard", "snowleopard", "lion")):
return "/tools/buildbot/bin/python"
elif (platform in ('w764', 'win7', 'xp')):
return "C:\\mozilla-build\\python25\\python.exe"

Expand Down Expand Up @@ -7337,7 +7348,7 @@ def addSetupSteps(self):
))
self.addStep(ShellCommand(
name='retrieve specified talos.zip in talos.json',
command=[self.python25(self.OS), 'talos_from_code.py', \
command=[self.pythonWithSimpleJson(self.OS), 'talos_from_code.py', \
'--talos_json_url', \
WithProperties('%(repo_path)s/raw-file/%(revision)s/testing/talos/talos.json')],
workdir=self.workdirBase,
Expand Down

0 comments on commit 7ea9e82

Please sign in to comment.