зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1317976 - enable generate-build-stats on tc win builds r=gps,ted
MozReview-Commit-ID: 7iDpPfRFibW --HG-- extra : rebase_source : 4e2c37e517420890e50e4dadaa25892f9bf87e02
This commit is contained in:
Родитель
cd9f4c2998
Коммит
0b747dd41e
|
@ -16,6 +16,7 @@ config = {
|
|||
'clone-tools',
|
||||
'build',
|
||||
'check-test',
|
||||
'generate-build-stats'
|
||||
],
|
||||
'exes': {
|
||||
'python2.7': sys.executable,
|
||||
|
|
|
@ -16,6 +16,7 @@ config = {
|
|||
'clone-tools',
|
||||
'build',
|
||||
'check-test',
|
||||
'generate-build-stats'
|
||||
],
|
||||
'exes': {
|
||||
'python2.7': sys.executable,
|
||||
|
|
|
@ -16,6 +16,7 @@ config = {
|
|||
'clone-tools',
|
||||
'build',
|
||||
'check-test',
|
||||
'generate-build-stats'
|
||||
],
|
||||
'exes': {
|
||||
'python2.7': sys.executable,
|
||||
|
|
|
@ -16,6 +16,7 @@ config = {
|
|||
'clone-tools',
|
||||
'build',
|
||||
'check-test',
|
||||
'generate-build-stats'
|
||||
],
|
||||
'exes': {
|
||||
'python2.7': sys.executable,
|
||||
|
|
|
@ -1888,6 +1888,12 @@ or run without that action (ie: --no-{action})"
|
|||
|
||||
return data
|
||||
|
||||
def get_firefox_version(self):
|
||||
versionFilePath = os.path.join(
|
||||
self.query_abs_dirs()['abs_src_dir'], 'browser/config/version.txt')
|
||||
with open(versionFilePath, 'r') as versionFile:
|
||||
return versionFile.readline().strip()
|
||||
|
||||
def generate_build_stats(self):
|
||||
"""grab build stats following a compile.
|
||||
|
||||
|
@ -1918,12 +1924,20 @@ or run without that action (ie: --no-{action})"
|
|||
# then assume we are using MOZ_SIMPLE_PACKAGE_NAME, which means the
|
||||
# package is named one of target.{tar.bz2,zip,dmg}.
|
||||
if not packageName:
|
||||
firefox_version = self.get_firefox_version()
|
||||
dist_dir = os.path.join(dirs['abs_obj_dir'], 'dist')
|
||||
for ext in ['apk', 'dmg', 'tar.bz2', 'zip']:
|
||||
name = 'target.' + ext
|
||||
if os.path.exists(os.path.join(dist_dir, name)):
|
||||
packageName = name
|
||||
break
|
||||
# if we are not using MOZ_SIMPLE_PACKAGE_NAME, check for the
|
||||
# default package naming convention
|
||||
name = 'firefox-{}.en-US.{}.{}'.format(
|
||||
firefox_version, c.get('platform'), ext)
|
||||
if os.path.exists(os.path.join(dist_dir, name)):
|
||||
packageName = name
|
||||
break
|
||||
else:
|
||||
self.fatal("could not determine packageName")
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче