Merge mozilla-central to autoland.

This commit is contained in:
Cosmin Sabou 2020-02-14 15:17:39 +02:00
Родитель b974090591 ff39f9206d
Коммит 8b4eabd7c2
74 изменённых файлов: 76 добавлений и 253 удалений

Просмотреть файл

@ -60,7 +60,6 @@ else:
GeneratedFile(
'xpcAccEvents.h', 'xpcAccEvents.cpp',
script='AccEventGen.py', entry_point='gen_files',
py2=True,
inputs=[
'AccEvents.conf',
'!/xpcom/idl-parser/xpidl/xpidllex.py',

Просмотреть файл

@ -46,7 +46,6 @@ if CONFIG['COMPILE_ENVIRONMENT']:
'%sntdll_freestanding.%s' % (CONFIG['LIB_PREFIX'],
CONFIG['LIB_SUFFIX']),
script='gen_ntdll_freestanding_lib.py',
py2=True,
inputs=['ntdll_freestanding.def'],
flags=[CONFIG['LLVM_DLLTOOL']] + CONFIG['LLVM_DLLTOOL_FLAGS'])

Просмотреть файл

@ -20,7 +20,6 @@ if CONFIG['MOZ_UPDATER']:
'en-US/updater/updater.ini',
'../installer/windows/nsis/updater_append.ini',
]
updater.py2 = True
# Yes, this is weird, but what can you do? This file doesn't want to be in the DIST_SUBDIR,
# but we can't really move it to a different directory until we change how locale repacks
# work.
@ -35,7 +34,6 @@ bookmarks.inputs = [
# The `locales/en-US/` will be rewritten to the locale-specific path.
'en-US/profile/bookmarks.inc',
]
bookmarks.py2 = True
with Files("**"):
BUG_COMPONENT = ("Firefox Build System", "General")

Просмотреть файл

@ -62,7 +62,6 @@ if CONFIG['ENABLE_MOZSEARCH_PLUGIN']:
]
GeneratedFile('ThirdPartyPaths.cpp', script="ThirdPartyPaths.py",
py2=True,
entry_point="generate", inputs=[
'/tools/rewriting/ThirdPartyPaths.txt',
'/tools/rewriting/Generated.txt',

Просмотреть файл

@ -87,7 +87,6 @@ if CONFIG['MOZ_APP_BASENAME']:
script='../python/mozbuild/mozbuild/action/preprocessor.py',
entry_point='generate',
inputs=['application.ini.in'],
py2=True,
flags=['-D%s=%s' % (k, '1' if v is True else v)
for k, v in appini_defines.iteritems()])
@ -96,12 +95,10 @@ if CONFIG['MOZ_APP_BASENAME']:
FINAL_TARGET_PP_FILES += ['update-settings.ini']
GeneratedFile('application.ini.h', script='appini_header.py',
py2=True,
inputs=['!application.ini'])
if CONFIG['ENABLE_TESTS']:
GeneratedFile('automation.py', script='gen_automation.py',
py2=True,
inputs=['automation.py.in'])
TEST_HARNESS_FILES.reftest += [

Просмотреть файл

@ -180,7 +180,6 @@ def GeneratedFile(name, *names, **kwargs):
inputs = kwargs.get('inputs', [])
flags = kwargs.get('flags', [])
force = kwargs.get('force', False)
py2 = kwargs.get('py2', False)
if entry_point and not script:
error('entry_point cannot be provided if script is not provided')
if script and ':' in script:
@ -198,7 +197,6 @@ def GeneratedFile(name, *names, **kwargs):
generated_file.inputs = inputs
generated_file.flags = flags
generated_file.force = force
generated_file.py2 = py2
include('gecko_templates.mozbuild')
include('test_templates.mozbuild')

Просмотреть файл

@ -9,7 +9,6 @@ def GeneratedTestCertificate(name):
if not CONFIG['COMPILE_ENVIRONMENT']:
return
GeneratedFile(name, script='/security/manager/ssl/tests/unit/pycert.py',
py2=True,
inputs=['%s.certspec' % name])
# Turn RELATIVEDIR into list entry: like
# 'security/manager/ssl/tests/unit/bad_certs' ->
@ -24,7 +23,6 @@ def GeneratedTestKey(name):
if not CONFIG['COMPILE_ENVIRONMENT']:
return
GeneratedFile(name, script='/security/manager/ssl/tests/unit/pykey.py',
py2=True,
inputs=['%s.keyspec' % name])
# Turn RELATIVEDIR into list entry: like
# 'security/manager/ssl/tests/unit/bad_certs' ->

Просмотреть файл

@ -14,7 +14,6 @@ cpu = CONFIG['CPU_ARCH']
gen_src = '%s.c' % cpu
GeneratedFile(gen_src, script='copy_source.py', entry_point='copy',
py2=True,
inputs = ['../inject.c'])
SOURCES += [

4
config/external/ffi/moz.build поставляемый
Просмотреть файл

@ -17,7 +17,6 @@ else:
]
GeneratedFile('../../../js/src/ctypes/libffi/include/ffi.h',
script='subst_header.py',
py2=True,
inputs=['../../../js/src/ctypes/libffi/include/ffi.h.in'])
LOCAL_INCLUDES += [
@ -86,7 +85,6 @@ else:
'!../../../js/src/ctypes/libffi/include/ffi.h',
],
script='preprocess_libffi_asm.py',
py2=True,
flags=['$(DEFINES)', '$(LOCAL_INCLUDES)'])
SOURCES += ['!win64_aarch.asm']
elif CONFIG['FFI_TARGET'] == 'X86':
@ -106,7 +104,6 @@ else:
'!../../../js/src/ctypes/libffi/fficonfig.h',
'!../../../js/src/ctypes/libffi/include/ffi.h',
], script='preprocess_libffi_asm.py',
py2=True,
flags=['$(DEFINES)', '$(LOCAL_INCLUDES)'])
SOURCES += ['!win32.asm']
ASFLAGS += ['-safeseh']
@ -123,7 +120,6 @@ else:
'!../../../js/src/ctypes/libffi/fficonfig.h',
'!../../../js/src/ctypes/libffi/include/ffi.h',
], script='preprocess_libffi_asm.py',
py2=True,
flags=['$(DEFINES)', '$(LOCAL_INCLUDES)'])
SOURCES += ['!win64.asm']
elif CONFIG['FFI_TARGET'] == 'X86_DARWIN':

1
config/external/icu/data/moz.build поставляемый
Просмотреть файл

@ -25,7 +25,6 @@ LOCAL_INCLUDES += ['.']
if CONFIG['OS_TARGET'] == 'WINNT' and CONFIG['CPU_ARCH'] == 'aarch64':
icudata = 'icudata.asm'
GeneratedFile(icudata, script='genicudata.py',
py2=True,
inputs=[CONFIG['ICU_DATA_FILE']], flags=[data_symbol])
SOURCES += ['!%s' % icudata]
elif CONFIG['HAVE_YASM']:

Просмотреть файл

@ -62,7 +62,6 @@ if CONFIG['WRAP_STL_INCLUDES']:
stl.script = 'make-stl-wrappers.py:gen_wrappers'
stl.flags = [output_dir, stl_compiler, template_file]
stl.flags.extend(stl_headers)
stl.py2 = True
# Wrap <windows.h> to make it easier to use correctly
# NOTE: If we aren't wrapping STL includes, we're building part of the browser
@ -72,7 +71,6 @@ if CONFIG['WRAP_STL_INCLUDES']:
GeneratedFile('../dist/stl_wrappers/windows.h',
script='make-windows-h-wrapper.py',
entry_point='generate',
py2=True,
inputs = ['windows-h-constant.decls.h',
'windows-h-unicode.decls.h',
'windows-h-wrapper.template.h'],
@ -88,4 +86,3 @@ if CONFIG['WRAP_SYSTEM_INCLUDES']:
system.flags = [output_dir]
system.flags.extend(stl_headers)
system.flags.extend(system_headers)
system.py2 = True

Просмотреть файл

@ -4,12 +4,7 @@
from __future__ import absolute_import
import inspect
import io
import os
from six import (
BytesIO,
StringIO,
)
import sys
import unittest
from unittest import TextTestRunner as _TestRunner, TestResult as _TestResult
@ -29,6 +24,8 @@ except ImportError:
build = MozbuildObject.from_environment(cwd=here)
topsrcdir = build.topsrcdir
StringIO = six.StringIO
'''Helper to make python unit tests report the way that the Mozilla
unit test infrastructure expects tests to report.
@ -116,18 +113,15 @@ class MozTestRunner(_TestRunner):
return result
def _mocked_file(cls):
'''Create a mocked file class that inherits from the given class.
'''
class MockedFile(cls):
def __init__(self, context, filename, content):
class MockedFile(StringIO):
def __init__(self, context, filename, content=''):
self.context = context
self.name = filename
cls.__init__(self, content)
StringIO.__init__(self, content)
def close(self):
self.context.files[self.name] = self.getvalue()
cls.close(self)
StringIO.close(self)
def __enter__(self):
return self
@ -135,12 +129,6 @@ def _mocked_file(cls):
def __exit__(self, type, value, traceback):
self.close()
return MockedFile
MockedStringFile = _mocked_file(StringIO)
MockedBytesFile = _mocked_file(BytesIO)
def normcase(path):
'''
@ -154,60 +142,6 @@ def normcase(path):
return path
class _MockBaseOpen(object):
'''Callable that acts like the open() function; see MockedOpen for more
info.
'''
def __init__(self, open, files):
self.open = open
self.files = files
def __call__(self, name, mode='r', buffering=None, encoding=None):
# open() can be called with an integer "name" (i.e. a file descriptor).
# We don't generally do this in our codebase, but internal Python
# libraries sometimes do and we want to handle that cleanly.
if isinstance(name, int):
return self.open(name, mode=mode, buffering=buffering,
encoding=encoding)
# buffering is ignored.
absname = normcase(os.path.abspath(name))
if 'w' in mode:
file = self._mocked_file(absname, mode)
elif absname in self.files:
content = self.files[absname]
if content is None:
raise IOError(2, 'No such file or directory')
file = self._mocked_file(absname, mode, content)
elif 'a' in mode:
read_mode = 'rb' if 'b' in mode else 'r'
file = self._mocked_file(
absname, mode, self.open(name, read_mode).read())
else:
file = self.open(name, mode)
if 'a' in mode:
file.seek(0, os.SEEK_END)
return file
def _mocked_file(self, name, mode, content=None):
raise NotImplementedError('subclass must implement')
class _MockPy2Open(_MockBaseOpen):
def _mocked_file(self, name, mode, content=None):
content = six.ensure_binary(content or b'')
return MockedBytesFile(self, name, content)
class _MockOpen(_MockBaseOpen):
def _mocked_file(self, name, mode, content=None):
if 'b' in mode:
content = six.ensure_binary(content or b'')
return MockedBytesFile(self, name, content)
else:
content = six.ensure_text(content or u'')
return MockedStringFile(self, name, content)
class MockedOpen(object):
'''
Context manager diverting the open builtin such that opening files
@ -236,16 +170,31 @@ class MockedOpen(object):
for name, content in files.items():
self.files[normcase(os.path.abspath(name))] = content
def __call__(self, name, mode='r', buffering=None, encoding=None):
# buffering is ignored.
absname = normcase(os.path.abspath(name))
if 'w' in mode:
file = MockedFile(self, absname)
elif absname in self.files:
content = self.files[absname]
if content is None:
raise IOError(2, 'No such file or directory')
file = MockedFile(self, absname, content)
elif 'a' in mode:
file = MockedFile(self, absname, self.open(name, 'r').read())
else:
file = self.open(name, mode)
if 'a' in mode:
file.seek(0, os.SEEK_END)
return file
def __enter__(self):
import six.moves.builtins
self.open = six.moves.builtins.open
self.io_open = io.open
self._orig_path_exists = os.path.exists
self._orig_path_isdir = os.path.isdir
self._orig_path_isfile = os.path.isfile
builtin_cls = _MockPy2Open if six.PY2 else _MockOpen
six.moves.builtins.open = builtin_cls(self.open, self.files)
io.open = _MockOpen(self.io_open, self.files)
six.moves.builtins.open = self
os.path.exists = self._wrapped_exists
os.path.isdir = self._wrapped_isdir
os.path.isfile = self._wrapped_isfile
@ -253,7 +202,6 @@ class MockedOpen(object):
def __exit__(self, type, value, traceback):
import six.moves.builtins
six.moves.builtins.open = self.open
io.open = self.io_open
os.path.exists = self._orig_path_exists
os.path.isdir = self._orig_path_isdir
os.path.isfile = self._orig_path_isfile

Просмотреть файл

@ -29,7 +29,6 @@ def CompiledModules(*modules):
"node.stub", *[final + '/' + module for module in modules],
script='/python/mozbuild/mozbuild/action/node.py',
entry_point='generate',
py2=True,
inputs=['/devtools/client/shared/build/build.js'] +
[module for module in modules],
flags=[final])

Просмотреть файл

@ -20,7 +20,6 @@ for dir in RELATIVEDIR.split('/'):
base += ["!reserved-js-words.js"]
GeneratedFile('reserved-js-words.js', script='GenerateReservedWordsJS.py',
py2=True,
inputs = ['/js/src/frontend/ReservedWords.h'])
DevToolsModules(

Просмотреть файл

@ -546,11 +546,9 @@ if CONFIG['MOZ_X11']:
CXXFLAGS += CONFIG['TK_CFLAGS']
GeneratedFile('UseCounterList.h', script='gen-usecounters.py',
py2=True,
entry_point='use_counter_list', inputs=['UseCounters.conf'])
GeneratedFile('UseCounterWorkerList.h', script='gen-usecounters.py',
py2=True,
entry_point='use_counter_list', inputs=['UseCountersWorker.conf'])
if CONFIG['CC_TYPE'] in ('clang', 'gcc'):

Просмотреть файл

@ -176,7 +176,6 @@ if CONFIG['CC_TYPE'] in ('clang', 'gcc'):
if CONFIG['COMPILE_ENVIRONMENT']:
GeneratedFile('CSS2Properties.webidl',
script='GenerateCSS2PropertiesWebIDL.py',
py2=True,
entry_point='generate',
inputs=[
'/dom/webidl/CSS2Properties.webidl.in',

Просмотреть файл

@ -34,12 +34,11 @@ prefixes = (
for prefix in prefixes:
input_file = prefix + '.properties'
header = prefix + '.properties.h'
GeneratedFile(header, script=props2arrays, inputs=[input_file], py2=True)
GeneratedFile(header, script=props2arrays, inputs=[input_file])
input_file = 'nonparticipatingdomains.properties'
header = input_file + '.h'
GeneratedFile(header, script='../../intl/locale/props2arrays.py',
py2=True,
inputs=[input_file])
MOCHITEST_MANIFESTS += [

Просмотреть файл

@ -15,7 +15,6 @@ if CONFIG['COMPILE_ENVIRONMENT']:
GeneratedFile('wgpu_ffi_generated.h',
script='/layout/style/RunCbindgen.py',
entry_point='generate',
py2=True,
inputs=[
'/gfx/wgpu/wgpu-remote',
])

Просмотреть файл

@ -589,10 +589,8 @@ include('/ipc/chromium/chromium-config.mozbuild')
if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
GeneratedFile('CompositorD3D11Shaders.h', script='d3d11/genshaders.py',
py2=True,
inputs=['d3d11/shaders.manifest'])
GeneratedFile('MLGShaders.h', script='d3d11/genshaders.py',
py2=True,
inputs=['d3d11/mlgshaders/shaders.manifest'])
LOCAL_INCLUDES += [

Просмотреть файл

@ -93,7 +93,6 @@ if CONFIG['COMPILE_ENVIRONMENT']:
GeneratedFile('webrender_ffi_generated.h',
script='/layout/style/RunCbindgen.py', entry_point='generate',
py2=True,
inputs=[
'/gfx/webrender_bindings',
'/gfx/wr/webrender',

Просмотреть файл

@ -31,4 +31,3 @@ if CONFIG['COMPILE_ENVIRONMENT']:
generated.inputs = [
'/third_party/rust/mapped_hyph'
]
generated.py2 = True

Просмотреть файл

@ -77,7 +77,7 @@ prefixes = (
for prefix in prefixes:
input_file = prefix + '.properties'
header = prefix + '.properties.h'
GeneratedFile(header, script='props2arrays.py', inputs=[input_file], py2=True)
GeneratedFile(header, script='props2arrays.py', inputs=[input_file])
if CONFIG['ENABLE_TESTS']:
DIRS += ['tests/gtest']
@ -98,11 +98,9 @@ if CONFIG['COMPILE_ENVIRONMENT']:
ffi_generated.inputs = [
'/intl/locale/rust/unic-langid-ffi',
]
ffi_generated.py2 = True
ffi_generated = GENERATED_FILES['fluent_langneg_ffi_generated.h']
ffi_generated.script = '/layout/style/RunCbindgen.py:generate'
ffi_generated.inputs = [
'/intl/locale/rust/fluent-langneg-ffi',
]
ffi_generated.py2 = True

Просмотреть файл

@ -30,7 +30,6 @@ if CONFIG['JS_SHARED_LIBRARY']:
# with those in libxul.
if CONFIG['OS_TARGET'] == 'Linux':
GeneratedFile('symverscript', script='/build/gen_symverscript.py',
py2=True,
inputs=['symverscript.in'],
flags=[CONFIG['JS_LIBRARY_NAME'].replace('-', '_')])
SYMBOLS_FILE = '!symverscript'
@ -86,7 +85,6 @@ DIST_INSTALL = True
# running the script for no-op builds.
GeneratedFile(
'spidermonkey_checks', script='/config/run_spidermonkey_checks.py',
py2=True,
inputs=[
'!%sjs_static.%s' % (CONFIG['LIB_PREFIX'], CONFIG['LIB_SUFFIX']),
'/config/check_spidermonkey_style.py',

Просмотреть файл

@ -18,7 +18,6 @@ include('../js-cxxflags.mozbuild')
# Generate frontend/ReservedWordsGenerated.h from frontend/ReservedWords.h
GeneratedFile('ReservedWordsGenerated.h', script='GenerateReservedWords.py',
py2=True,
inputs=['ReservedWords.h'])

Просмотреть файл

@ -18,10 +18,8 @@ include('../js-cxxflags.mozbuild')
# Generate GC statistics phase data.
GeneratedFile('StatsPhasesGenerated.h',
py2=True,
script='GenerateStatsPhases.py', entry_point='generateHeader')
GeneratedFile('StatsPhasesGenerated.inc',
py2=True,
script='GenerateStatsPhases.py', entry_point='generateCpp')
UNIFIED_SOURCES += [

Просмотреть файл

@ -241,7 +241,6 @@ elif CONFIG['JS_CODEGEN_MIPS32'] or CONFIG['JS_CODEGEN_MIPS64']:
# Generate jit/MOpcodes.h from jit/MIR.h
GeneratedFile('MOpcodes.h',
script='GenerateOpcodeFiles.py',
py2=True,
entry_point='generate_mir_header',
inputs=['MIR.h'])
@ -249,6 +248,5 @@ GeneratedFile('MOpcodes.h',
# platform-specific LIR files.
GeneratedFile('LOpcodes.h',
script='GenerateOpcodeFiles.py',
py2=True,
entry_point='generate_lir_header',
inputs=lir_inputs)

Просмотреть файл

@ -515,7 +515,6 @@ selfhosted_inputs = [
# Prepare self-hosted JS code for embedding
GeneratedFile('selfhosted.out.h', 'selfhosted.js',
script='builtin/embedjs.py',
py2=True,
entry_point='generate_selfhosted',
inputs=selfhosted_inputs)

Просмотреть файл

@ -40,7 +40,6 @@ OS_LIBS += CONFIG['EDITLINE_LIBS']
# Prepare module loader JS code for embedding
GeneratedFile('shellmoduleloader.out.h', 'shellmoduleloader.js',
script='../builtin/embedjs.py',
py2=True,
entry_point='generate_shellmoduleloader',
inputs=[
'../js.msg',

Просмотреть файл

@ -232,11 +232,9 @@ SOURCES += [
GeneratedFile('FrameIdList.h',
script='GenerateFrameLists.py',
py2=True,
entry_point='generate_frame_id_list_h')
GeneratedFile('FrameTypeList.h',
script='GenerateFrameLists.py',
py2=True,
entry_point='generate_frame_type_list_h')
include('/ipc/chromium/chromium-config.mozbuild')

Просмотреть файл

@ -262,17 +262,14 @@ CONTENT_ACCESSIBLE_FILES += [
GeneratedFile('nsCSSPropertyID.h', script='GenerateCSSPropertyID.py',
py2=True,
entry_point='generate',
inputs=['nsCSSPropertyID.h.in', '!ServoCSSPropList.py'])
GeneratedFile('ServoCSSPropList.h',
script='GenerateServoCSSPropList.py',
py2=True,
entry_point='generate_header',
inputs=['!ServoCSSPropList.py'])
GeneratedFile('ServoCSSPropList.py',
script='GenerateServoCSSPropList.py', entry_point='generate_data',
py2=True,
inputs=['ServoCSSPropList.mako.py'])
if CONFIG['COMPILE_ENVIRONMENT']:
@ -284,29 +281,24 @@ if CONFIG['COMPILE_ENVIRONMENT']:
GeneratedFile('CompositorAnimatableProperties.h',
script='GenerateCompositorAnimatableProperties.py',
py2=True,
entry_point='generate',
inputs=['!ServoCSSPropList.py'])
GeneratedFile(
'CountedUnknownProperties.h',
script='GenerateCountedUnknownProperties.py',
py2=True,
entry_point='generate',
inputs=[
'/servo/components/style/properties/counted_unknown_properties.py',
])
GeneratedFile('nsComputedDOMStyleGenerated.inc',
script='GenerateComputedDOMStyleGenerated.py',
py2=True,
entry_point='generate',
inputs=['!ServoCSSPropList.py'])
GeneratedFile('nsCSSPropsGenerated.inc',
script='GenerateCSSPropsGenerated.py',
py2=True,
entry_point='generate',
inputs=['!ServoCSSPropList.py'])
GeneratedFile('ServoStyleConsts.h', script='RunCbindgen.py',
py2=True,
entry_point='generate',
inputs = ['/servo/ports/geckolib', '/servo/components/style'])

Просмотреть файл

@ -17,7 +17,6 @@ LOCAL_INCLUDES += [
GeneratedFile('ExampleStylesheet.h',
script='generate_example_stylesheet.py',
py2=True,
inputs=['example.css'])
FINAL_LIBRARY = 'xul-gtest'

Просмотреть файл

@ -149,5 +149,4 @@ if CONFIG['COMPILE_ENVIRONMENT']:
'css_properties_like_longhand.js',
'!host_ListCSSProperties%s' % CONFIG['HOST_BIN_SUFFIX'],
]
GENERATED_FILES['css_properties.js'].py2 = True
TEST_HARNESS_FILES.testing.mochitest.tests.layout.style.test += ['!css_properties.js']

Просмотреть файл

@ -126,7 +126,6 @@ if CONFIG['CPU_ARCH'] in ('x86', 'x86_64'):
a.script = '../generate_source.py:add_define'
a.inputs = [relative_path + f]
a.flags = ['BITDEPTH', '16']
a.py2 = True
GENERATED_FILES += [
'8bd_%s' % p for p in bitdepth_basenames
@ -141,7 +140,6 @@ if CONFIG['CPU_ARCH'] in ('x86', 'x86_64'):
a.script = '../generate_source.py:add_define'
a.inputs = [relative_path + f]
a.flags = ['BITDEPTH', '8']
a.py2 = True
elif CONFIG['CPU_ARCH'] == 'arm' or CONFIG['CPU_ARCH'] == 'aarch64':
SOURCES += [
'../../../third_party/dav1d/src/arm/cpu.c',
@ -175,7 +173,6 @@ elif CONFIG['CPU_ARCH'] == 'arm' or CONFIG['CPU_ARCH'] == 'aarch64':
a.script = '../generate_source.py:add_define'
a.inputs = [relative_path + f]
a.flags = ['BITDEPTH', '16']
a.py2 = True
GENERATED_FILES += [
'8bd_%s' % p for p in bitdepth_basenames
@ -190,7 +187,6 @@ elif CONFIG['CPU_ARCH'] == 'arm' or CONFIG['CPU_ARCH'] == 'aarch64':
a.script = '../generate_source.py:add_define'
a.inputs = [relative_path + f]
a.flags = ['BITDEPTH', '8']
a.py2 = True
# BITDEPTH .S files
if CONFIG['CPU_ARCH'] == 'aarch64':

Просмотреть файл

@ -145,13 +145,11 @@ for f in bitdepth_basenames:
GeneratedFile(file_bd16,
script='generate_source.py',
py2=True,
entry_point='add_define',
inputs=[relative_path + f],
flags=['BITDEPTH', '16'])
GeneratedFile(file_bd8,
script='generate_source.py',
py2=True,
entry_point='add_define',
inputs=[relative_path + f],
flags=['BITDEPTH', '8'])

Просмотреть файл

@ -20,4 +20,3 @@ t = ('android_apks',)
GENERATED_FILES += [t]
GENERATED_FILES[t].force = True
GENERATED_FILES[t].script = '/mobile/android/gradle.py:assemble_app'
GENERATED_FILES[t].py2 = True

Просмотреть файл

@ -17,7 +17,6 @@ for addon in addons:
GENERATED_FILES += [xpi]
GENERATED_FILES[xpi].script = '../../../../../../toolkit/mozapps/extensions/test/create_xpi.py'
GENERATED_FILES[xpi].py2 = True
GENERATED_FILES[xpi].inputs = [indir]
TEST_HARNESS_FILES.testing.mochitest.tests.junit += ['!%s' % xpi]

Просмотреть файл

@ -126,7 +126,6 @@ GENERATED_FILES += [gen_all_tuple]
static_pref_list = GENERATED_FILES[gen_all_tuple]
static_pref_list.script = 'init/generate_static_pref_list.py:emit_code'
static_pref_list.inputs = ['init/StaticPrefList.yaml']
static_pref_list.py2 = True
PYTHON_UNITTEST_MANIFESTS += [
'test/python.ini',

Просмотреть файл

@ -164,8 +164,6 @@ if not CONFIG['JS_STANDALONE'] or not CONFIG['MOZ_BUILD_APP']:
GENERATED_FILES['buildid.h'].script = 'build/variables.py:buildid_header'
GENERATED_FILES['source-repo.h'].script = 'build/variables.py:source_repo_header'
GENERATED_FILES['buildid.h'].py2 = True
GENERATED_FILES['source-repo.h'].py2 = True
DIRS += [
'build',

Просмотреть файл

@ -53,7 +53,6 @@ GENERATED_FILES += [
blocklist_defs = GENERATED_FILES[blocklist_files]
blocklist_defs.script = 'gen_dll_blocklist_defs.py:gen_blocklists'
blocklist_defs.inputs = ['WindowsDllBlocklistDefs.in']
blocklist_defs.py2 = True
EXPORTS.mozilla += ['!' + hdr for hdr in blocklist_files]
FINAL_LIBRARY = 'mozglue'

Просмотреть файл

@ -75,7 +75,6 @@ include('/ipc/chromium/chromium-config.mozbuild')
FINAL_LIBRARY = 'xul'
GeneratedFile('etld_data.inc', script='prepare_tlds.py',
py2=True,
inputs=['effective_tld_names.dat'])
# need to include etld_data.inc

Просмотреть файл

@ -10,6 +10,5 @@ fake_remote_dafsa = GENERATED_FILES['fake_remote_dafsa.bin']
fake_remote_dafsa.script = '../../../prepare_tlds.py'
fake_remote_dafsa.inputs = ['fake_public_suffix_list.dat']
fake_remote_dafsa.flags = ['bin']
fake_remote_dafsa.py2 = True
TEST_HARNESS_FILES.xpcshell.netwerk.dns.tests.unit.data += ['!fake_remote_dafsa.bin']

Просмотреть файл

@ -17,7 +17,6 @@ if CONFIG['COMPILE_ENVIRONMENT']:
GeneratedFile('neqo_glue_ffi_generated.h',
script='/layout/style/RunCbindgen.py',
entry_point='generate',
py2=True,
inputs=['/netwerk/socket/neqo_glue'])
EXPORTS.mozilla.net += [

Просмотреть файл

@ -88,14 +88,10 @@ class MakeBackend(CommonBackend):
ret.append('GARBAGE += %s' % stub_file)
ret.append('EXTRA_MDDEPEND_FILES += %s' % dep_file)
if obj.py2:
action = 'py_action'
else:
action = 'py3_action'
ret.append((
"""{stub}: {script}{inputs}{backend}{force}
\t$(REPORT_BUILD)
\t$(call {action},file_generate,{locale}{script} """ # wrap for E501
\t$(call py_action,file_generate,{locale}{script} """ # wrap for E501
"""{method} {output} {dep_file} {stub}{inputs}{flags})
\t@$(TOUCH) $@
""").format(
@ -110,7 +106,6 @@ class MakeBackend(CommonBackend):
# with a different locale as input. IS_LANGUAGE_REPACK will reliably be set
# in this situation, so simply force the generation to run in that case.
force=force,
action=action,
locale='--locale=$(AB_CD) ' if obj.localized else '',
script=obj.script,
method=obj.method

Просмотреть файл

@ -1027,7 +1027,6 @@ GeneratedFilesList = StrictOrderingOnAppendListWithFlagsFactory({
'script': six.text_type,
'inputs': list,
'force': bool,
'py2': bool,
'flags': list, })

Просмотреть файл

@ -1237,12 +1237,10 @@ class GeneratedFile(ContextDerived):
'required_during_compile',
'localized',
'force',
'py2',
)
def __init__(self, context, script, method, outputs, inputs,
flags=(), localized=False, force=False,
py2=False):
flags=(), localized=False, force=False):
ContextDerived.__init__(self, context)
self.script = script
self.method = method
@ -1251,7 +1249,6 @@ class GeneratedFile(ContextDerived):
self.flags = flags
self.localized = localized
self.force = force
self.py2 = py2
suffixes = [
'.h',

Просмотреть файл

@ -845,7 +845,7 @@ class TreeMetadataEmitter(LoggingMixin):
defines = lib.defines.get_defines()
yield GeneratedFile(context, script,
'generate_symbols_file', lib.symbols_file,
[symbols_file], defines, py2=True)
[symbols_file], defines)
if static_lib:
is_rust_library = context.get('IS_RUST_LIBRARY')
if is_rust_library:
@ -1483,7 +1483,7 @@ class TreeMetadataEmitter(LoggingMixin):
'action', 'process_define_files.py')
yield GeneratedFile(context, script, 'process_define_file',
unicode(path),
[Path(context, path + '.in')], py2=True)
[Path(context, path + '.in')])
generated_files = context.get('GENERATED_FILES') or []
localized_generated_files = context.get('LOCALIZED_GENERATED_FILES') or []
@ -1526,8 +1526,7 @@ class TreeMetadataEmitter(LoggingMixin):
inputs.append(p)
yield GeneratedFile(context, script, method, outputs, inputs,
flags.flags, localized=localized, force=flags.force,
py2=flags.py2)
flags.flags, localized=localized, force=flags.force)
def _process_test_manifests(self, context):
for prefix, info in TEST_MANIFESTS.items():

Просмотреть файл

@ -100,7 +100,6 @@ def handle_actions(actions, context, action_overrides):
g = context['GENERATED_FILES'][output]
g.script = action_overrides[name]
g.inputs = action['inputs']
g.py2 = True
def handle_copies(copies, context):

Просмотреть файл

@ -10,17 +10,16 @@ See the documentation for jar.mn on MDC for further details on the format.
from __future__ import absolute_import, print_function, unicode_literals
import errno
import io
import logging
import sys
import os
import errno
import re
import six
from six import BytesIO
import sys
import logging
from time import localtime
from MozZipFile import ZipFile
from six import BytesIO
from mozbuild.preprocessor import Preprocessor
from mozbuild.action.buildlist import addEntriesToListFile
from mozbuild.util import ensure_bytes
@ -468,8 +467,8 @@ class JarMaker(object):
self._seen_output.add(out)
if e.preprocess:
outf = outHelper.getOutput(out, mode='w')
inf = io.open(realsrc, encoding='utf-8')
outf = outHelper.getOutput(out)
inf = open(realsrc)
pp = self.pp.clone()
if src[-4:] == '.css':
pp.setMarker('%')
@ -508,7 +507,7 @@ class JarMaker(object):
except Exception:
return localtime(0)
def getOutput(self, name, mode='wb'):
def getOutput(self, name):
return ZipEntry(name, self.jarfile)
class OutputHelper_flat(object):
@ -523,7 +522,7 @@ class JarMaker(object):
def getDestModTime(self, aPath):
return getModTime(os.path.join(self.basepath, aPath))
def getOutput(self, name, mode='wb'):
def getOutput(self, name):
out = self.ensureDirFor(name)
# remove previous link or file
@ -532,10 +531,7 @@ class JarMaker(object):
except OSError as e:
if e.errno != errno.ENOENT:
raise
if 'b' in mode:
return io.open(out, mode)
else:
return io.open(out, mode, encoding='utf-8', newline='\n')
return open(out, 'wb')
def ensureDirFor(self, name):
out = os.path.join(self.basepath, name)

Просмотреть файл

@ -24,14 +24,12 @@ value :
from __future__ import absolute_import, print_function, unicode_literals
import errno
import io
from optparse import OptionParser
import sys
import os
import re
import six
import sys
from optparse import OptionParser
import errno
from mozbuild.makeutil import Makefile
# hack around win32 mangling our line endings
@ -494,7 +492,7 @@ class Preprocessor:
except OSError as error:
if error.errno != errno.EEXIST:
raise
return io.open(path, 'w', encoding='utf-8', newline='\n')
return open(path, 'wb')
p = self.getCommandLineParser()
options, args = p.parse_args(args=args)
@ -516,7 +514,7 @@ class Preprocessor:
if args:
for f in args:
with io.open(f, 'rU', encoding='utf-8') as input:
with open(f, 'rU') as input:
self.processFile(input=input, output=out)
if depfile:
mk = Makefile()
@ -806,7 +804,7 @@ class Preprocessor:
args = self.applyFilters(args)
if not os.path.isabs(args):
args = os.path.join(self.curdir, args)
args = io.open(args, 'rU', encoding='utf-8')
args = open(args, 'rU')
except Preprocessor.Error:
raise
except Exception:
@ -861,7 +859,7 @@ def preprocess(includes=[sys.stdin], defines={},
pp = Preprocessor(defines=defines,
marker=marker)
for f in includes:
with io.open(f, 'rU', encoding='utf-8') as input:
with open(f, 'rU') as input:
pp.processFile(input=input, output=output)
return pp.includes

Просмотреть файл

@ -151,8 +151,11 @@ class TestBuild(unittest.TestCase):
test_path = os.sep.join(('$SRCDIR', 'python', 'mozbuild', 'mozbuild',
'test', 'backend', 'data', 'build')) + os.sep
# We want unicode instances out of the files, because having plain str
# makes assertEqual diff output in case of error extra verbose because
# of the difference in type.
result = {
p: f.open(mode='r').read()
p: f.open().read().decode('utf-8')
for p, f in FileFinder(mozpath.join(config.topobjdir, 'dist'))
}
self.assertTrue(len(result))

Просмотреть файл

@ -414,7 +414,7 @@ class TestRecursiveMakeBackend(BackendTester):
'EXTRA_MDDEPEND_FILES += $(MDDEPDIR)/bar.c.pp',
'$(MDDEPDIR)/bar.c.stub: %s/generate-bar.py' % env.topsrcdir,
'$(REPORT_BUILD)',
'$(call py3_action,file_generate,%s/generate-bar.py baz bar.c $(MDDEPDIR)/bar.c.pp $(MDDEPDIR)/bar.c.stub)' % env.topsrcdir, # noqa
'$(call py_action,file_generate,%s/generate-bar.py baz bar.c $(MDDEPDIR)/bar.c.pp $(MDDEPDIR)/bar.c.stub)' % env.topsrcdir, # noqa
'@$(TOUCH) $@',
'',
'export:: $(MDDEPDIR)/foo.h.stub',
@ -424,7 +424,7 @@ class TestRecursiveMakeBackend(BackendTester):
'EXTRA_MDDEPEND_FILES += $(MDDEPDIR)/foo.h.pp',
'$(MDDEPDIR)/foo.h.stub: %s/generate-foo.py $(srcdir)/foo-data' % (env.topsrcdir),
'$(REPORT_BUILD)',
'$(call py3_action,file_generate,%s/generate-foo.py main foo.h $(MDDEPDIR)/foo.h.pp $(MDDEPDIR)/foo.h.stub $(srcdir)/foo-data)' % (env.topsrcdir), # noqa
'$(call py_action,file_generate,%s/generate-foo.py main foo.h $(MDDEPDIR)/foo.h.pp $(MDDEPDIR)/foo.h.stub $(srcdir)/foo-data)' % (env.topsrcdir), # noqa
'@$(TOUCH) $@',
'',
]
@ -447,7 +447,7 @@ class TestRecursiveMakeBackend(BackendTester):
'EXTRA_MDDEPEND_FILES += $(MDDEPDIR)/bar.c.pp',
'$(MDDEPDIR)/bar.c.stub: %s/generate-bar.py FORCE' % env.topsrcdir,
'$(REPORT_BUILD)',
'$(call py3_action,file_generate,%s/generate-bar.py baz bar.c $(MDDEPDIR)/bar.c.pp $(MDDEPDIR)/bar.c.stub)' % env.topsrcdir, # noqa
'$(call py_action,file_generate,%s/generate-bar.py baz bar.c $(MDDEPDIR)/bar.c.pp $(MDDEPDIR)/bar.c.stub)' % env.topsrcdir, # noqa
'@$(TOUCH) $@',
'',
'foo.c: $(MDDEPDIR)/foo.c.stub ;',
@ -456,7 +456,7 @@ class TestRecursiveMakeBackend(BackendTester):
'EXTRA_MDDEPEND_FILES += $(MDDEPDIR)/foo.c.pp',
'$(MDDEPDIR)/foo.c.stub: %s/generate-foo.py $(srcdir)/foo-data' % (env.topsrcdir),
'$(REPORT_BUILD)',
'$(call py3_action,file_generate,%s/generate-foo.py main foo.c $(MDDEPDIR)/foo.c.pp $(MDDEPDIR)/foo.c.stub $(srcdir)/foo-data)' % (env.topsrcdir), # noqa
'$(call py_action,file_generate,%s/generate-foo.py main foo.c $(MDDEPDIR)/foo.c.pp $(MDDEPDIR)/foo.c.stub $(srcdir)/foo-data)' % (env.topsrcdir), # noqa
'@$(TOUCH) $@',
'',
]
@ -480,7 +480,7 @@ class TestRecursiveMakeBackend(BackendTester):
'EXTRA_MDDEPEND_FILES += $(MDDEPDIR)/foo.xyz.pp',
'$(MDDEPDIR)/foo.xyz.stub: %s/generate-foo.py $(call MERGE_FILE,localized-input) $(srcdir)/non-localized-input $(if $(IS_LANGUAGE_REPACK),FORCE)' % env.topsrcdir, # noqa
'$(REPORT_BUILD)',
'$(call py3_action,file_generate,--locale=$(AB_CD) %s/generate-foo.py main foo.xyz $(MDDEPDIR)/foo.xyz.pp $(MDDEPDIR)/foo.xyz.stub $(call MERGE_FILE,localized-input) $(srcdir)/non-localized-input)' % env.topsrcdir, # noqa
'$(call py_action,file_generate,--locale=$(AB_CD) %s/generate-foo.py main foo.xyz $(MDDEPDIR)/foo.xyz.pp $(MDDEPDIR)/foo.xyz.stub $(call MERGE_FILE,localized-input) $(srcdir)/non-localized-input)' % env.topsrcdir, # noqa
'@$(TOUCH) $@',
'',
'LOCALIZED_FILES_0_FILES += foo.xyz',
@ -508,7 +508,7 @@ class TestRecursiveMakeBackend(BackendTester):
'EXTRA_MDDEPEND_FILES += $(MDDEPDIR)/foo.xyz.pp',
'$(MDDEPDIR)/foo.xyz.stub: %s/generate-foo.py $(call MERGE_FILE,localized-input) $(srcdir)/non-localized-input $(if $(IS_LANGUAGE_REPACK),FORCE)' % env.topsrcdir, # noqa
'$(REPORT_BUILD)',
'$(call py3_action,file_generate,--locale=$(AB_CD) %s/generate-foo.py main foo.xyz $(MDDEPDIR)/foo.xyz.pp $(MDDEPDIR)/foo.xyz.stub $(call MERGE_FILE,localized-input) $(srcdir)/non-localized-input)' % env.topsrcdir, # noqa
'$(call py_action,file_generate,--locale=$(AB_CD) %s/generate-foo.py main foo.xyz $(MDDEPDIR)/foo.xyz.pp $(MDDEPDIR)/foo.xyz.stub $(call MERGE_FILE,localized-input) $(srcdir)/non-localized-input)' % env.topsrcdir, # noqa
'@$(TOUCH) $@',
'',
'libs:: $(MDDEPDIR)/abc.xyz.stub',
@ -518,7 +518,7 @@ class TestRecursiveMakeBackend(BackendTester):
'EXTRA_MDDEPEND_FILES += $(MDDEPDIR)/abc.xyz.pp',
'$(MDDEPDIR)/abc.xyz.stub: %s/generate-foo.py $(call MERGE_FILE,localized-input) $(srcdir)/non-localized-input FORCE' % env.topsrcdir, # noqa
'$(REPORT_BUILD)',
'$(call py3_action,file_generate,--locale=$(AB_CD) %s/generate-foo.py main abc.xyz $(MDDEPDIR)/abc.xyz.pp $(MDDEPDIR)/abc.xyz.stub $(call MERGE_FILE,localized-input) $(srcdir)/non-localized-input)' % env.topsrcdir, # noqa
'$(call py_action,file_generate,--locale=$(AB_CD) %s/generate-foo.py main abc.xyz $(MDDEPDIR)/abc.xyz.pp $(MDDEPDIR)/abc.xyz.stub $(call MERGE_FILE,localized-input) $(srcdir)/non-localized-input)' % env.topsrcdir, # noqa
'@$(TOUCH) $@',
'',
]
@ -543,7 +543,7 @@ class TestRecursiveMakeBackend(BackendTester):
'EXTRA_MDDEPEND_FILES += $(MDDEPDIR)/foo$(AB_CD).xyz.pp',
'$(MDDEPDIR)/foo$(AB_CD).xyz.stub: %s/generate-foo.py $(call MERGE_FILE,localized-input) $(srcdir)/non-localized-input $(if $(IS_LANGUAGE_REPACK),FORCE)' % env.topsrcdir, # noqa
'$(REPORT_BUILD)',
'$(call py3_action,file_generate,--locale=$(AB_CD) %s/generate-foo.py main foo$(AB_CD).xyz $(MDDEPDIR)/foo$(AB_CD).xyz.pp $(MDDEPDIR)/foo$(AB_CD).xyz.stub $(call MERGE_FILE,localized-input) $(srcdir)/non-localized-input)' % env.topsrcdir, # noqa
'$(call py_action,file_generate,--locale=$(AB_CD) %s/generate-foo.py main foo$(AB_CD).xyz $(MDDEPDIR)/foo$(AB_CD).xyz.pp $(MDDEPDIR)/foo$(AB_CD).xyz.stub $(call MERGE_FILE,localized-input) $(srcdir)/non-localized-input)' % env.topsrcdir, # noqa
'@$(TOUCH) $@',
'',
'bar$(AB_rCD).xyz: $(MDDEPDIR)/bar$(AB_rCD).xyz.stub ;',
@ -552,7 +552,7 @@ class TestRecursiveMakeBackend(BackendTester):
'EXTRA_MDDEPEND_FILES += $(MDDEPDIR)/bar$(AB_rCD).xyz.pp',
'$(MDDEPDIR)/bar$(AB_rCD).xyz.stub: %s/generate-foo.py $(call MERGE_RELATIVE_FILE,localized-input,inner/locales) $(srcdir)/non-localized-input $(if $(IS_LANGUAGE_REPACK),FORCE)' % env.topsrcdir, # noqa
'$(REPORT_BUILD)',
'$(call py3_action,file_generate,--locale=$(AB_CD) %s/generate-foo.py main bar$(AB_rCD).xyz $(MDDEPDIR)/bar$(AB_rCD).xyz.pp $(MDDEPDIR)/bar$(AB_rCD).xyz.stub $(call MERGE_RELATIVE_FILE,localized-input,inner/locales) $(srcdir)/non-localized-input)' % env.topsrcdir, # noqa
'$(call py_action,file_generate,--locale=$(AB_CD) %s/generate-foo.py main bar$(AB_rCD).xyz $(MDDEPDIR)/bar$(AB_rCD).xyz.pp $(MDDEPDIR)/bar$(AB_rCD).xyz.stub $(call MERGE_RELATIVE_FILE,localized-input,inner/locales) $(srcdir)/non-localized-input)' % env.topsrcdir, # noqa
'@$(TOUCH) $@',
'',
'zot$(AB_rCD).xyz: $(MDDEPDIR)/zot$(AB_rCD).xyz.stub ;',
@ -561,7 +561,7 @@ class TestRecursiveMakeBackend(BackendTester):
'EXTRA_MDDEPEND_FILES += $(MDDEPDIR)/zot$(AB_rCD).xyz.pp',
'$(MDDEPDIR)/zot$(AB_rCD).xyz.stub: %s/generate-foo.py $(call MERGE_RELATIVE_FILE,localized-input,locales) $(srcdir)/non-localized-input $(if $(IS_LANGUAGE_REPACK),FORCE)' % env.topsrcdir, # noqa
'$(REPORT_BUILD)',
'$(call py3_action,file_generate,--locale=$(AB_CD) %s/generate-foo.py main zot$(AB_rCD).xyz $(MDDEPDIR)/zot$(AB_rCD).xyz.pp $(MDDEPDIR)/zot$(AB_rCD).xyz.stub $(call MERGE_RELATIVE_FILE,localized-input,locales) $(srcdir)/non-localized-input)' % env.topsrcdir, # noqa
'$(call py_action,file_generate,--locale=$(AB_CD) %s/generate-foo.py main zot$(AB_rCD).xyz $(MDDEPDIR)/zot$(AB_rCD).xyz.pp $(MDDEPDIR)/zot$(AB_rCD).xyz.stub $(call MERGE_RELATIVE_FILE,localized-input,locales) $(srcdir)/non-localized-input)' % env.topsrcdir, # noqa
'@$(TOUCH) $@',
'',
]

Просмотреть файл

@ -47,5 +47,4 @@ headers_arrays_certs = [
for header, array_name, cert in headers_arrays_certs:
GeneratedFile(header, script='gen_cert_header.py',
py2=True,
entry_point=array_name, inputs=[cert])

Просмотреть файл

@ -13,7 +13,6 @@ def STHTestFile(name):
props = GENERATED_FILES[name]
props.script = 'createSTHTestData.py'
props.inputs = ['%s.tbs' % name]
props.py2 = True
STHTestFile('valid-sth.inc')
STHTestFile('valid-with-extension-sth.inc')

Просмотреть файл

@ -226,7 +226,6 @@ LOCAL_INCLUDES += [
GeneratedFile('nsSTSPreloadList.h',
script='../../../xpcom/ds/tools/make_dafsa.py',
py2=True,
inputs=['nsSTSPreloadList.inc'])
DEFINES['SSL_DISABLE_DEPRECATED_CIPHER_SUITE_NAMES'] = 'True'

Просмотреть файл

@ -14,7 +14,6 @@ def SignedAppFile(name, flags, app_directory='app/'):
props.script = '/security/manager/ssl/tests/unit/sign_app.py'
props.inputs = [app_directory]
props.flags = flags
props.py2 = True
# Turn RELATIVEDIR into list entry: like
# 'security/manager/ssl/tests/unit/test_signed_apps' ->
# TEST_HARNESS_FILES.xpcshell.security.manager.ssl.tests.unit.test_signed_apps.

Просмотреть файл

@ -15,5 +15,4 @@ PYTHON_UNITTEST_MANIFESTS += ['test/python/python.ini']
JAR_MANIFESTS += ['jar.mn']
GeneratedFile('feature_definitions.json', script='gen_feature_definitions.py',
py2=True,
inputs=['Features.toml'])

Просмотреть файл

@ -21,6 +21,5 @@ for addon in addons:
GENERATED_FILES += [xpi]
GENERATED_FILES[xpi].script = '../create_xpi.py'
GENERATED_FILES[xpi].inputs = [indir]
GENERATED_FILES[xpi].py2 = True
output_dir += ['!%s' % xpi]

Просмотреть файл

@ -148,15 +148,12 @@ if CONFIG['MOZ_TELEMETRY_EXTRA_HISTOGRAM_FILES']:
GeneratedFile('TelemetryHistogramData.inc',
script='build_scripts/gen_histogram_data.py',
py2=True,
inputs=histogram_files)
GeneratedFile('TelemetryHistogramEnums.h',
script='build_scripts/gen_histogram_enum.py',
py2=True,
inputs=histogram_files)
GeneratedFile('TelemetryHistogramNameMap.h',
script='build_scripts/gen_histogram_phf.py',
py2=True,
inputs=histogram_files)
# Generate scalar files.
@ -168,11 +165,9 @@ if CONFIG['MOZ_TELEMETRY_EXTRA_SCALAR_FILES']:
GeneratedFile('TelemetryScalarData.h',
script='build_scripts/gen_scalar_data.py',
py2=True,
inputs=scalar_files)
GeneratedFile('TelemetryScalarEnums.h',
script='build_scripts/gen_scalar_enum.py',
py2=True,
inputs=scalar_files)
# Generate the JSON scalar definitions. They will only be
@ -180,7 +175,6 @@ GeneratedFile('TelemetryScalarEnums.h',
GeneratedFile(
'ScalarArtifactDefinitions.json',
script='build_scripts/gen_scalar_data.py',
py2=True,
entry_point='generate_JSON_definitions',
inputs=scalar_files)
@ -195,18 +189,15 @@ if CONFIG['MOZ_TELEMETRY_EXTRA_EVENT_FILES']:
event_files.extend(CONFIG['MOZ_TELEMETRY_EXTRA_EVENT_FILES'])
GeneratedFile('TelemetryEventData.h', script='build_scripts/gen_event_data.py',
py2=True,
inputs=event_files)
GeneratedFile('TelemetryEventEnums.h', script='build_scripts/gen_event_enum.py',
py2=True,
inputs=event_files)
# Generate the JSON event definitions. They will only be
# used in artifact or "build faster" builds.
GeneratedFile('EventArtifactDefinitions.json',
script='build_scripts/gen_event_data.py',
py2=True,
entry_point='generate_JSON_definitions', inputs=event_files)
# Move the events JSON file to the directory where the Firefox binary is.
@ -219,13 +210,11 @@ processes_files = [
GeneratedFile('TelemetryProcessEnums.h',
script='build_scripts/gen_process_enum.py',
py2=True,
inputs=processes_files)
GeneratedFile('TelemetryProcessData.h',
script='build_scripts/gen_process_data.py',
py2=True,
inputs=processes_files)
# Add support for GeckoView: please note that building GeckoView

Просмотреть файл

@ -129,7 +129,6 @@ else:
# Generate CrashAnnotations.h
GeneratedFile('CrashAnnotations.h', script='generate_crash_reporter_sources.py',
py2=True,
entry_point='emit_header', inputs=[
'CrashAnnotations.h.in',
'CrashAnnotations.yaml',

Просмотреть файл

@ -25,6 +25,5 @@ if CONFIG['COMPILE_ENVIRONMENT']:
)
GeneratedFile('dependentlibs.list', 'dependentlibs.list.gtest',
script='dependentlibs.py', entry_point='gen_list',
py2=True,
inputs=['!%s' % full_libname])
FINAL_TARGET_FILES += ['!dependentlibs.list', '!dependentlibs.list.gtest']

Просмотреть файл

@ -85,7 +85,6 @@ def Libxul(name, output_category=None):
if CONFIG['OS_ARCH'] == 'Linux' and CONFIG['OS_TARGET'] != 'Android':
GeneratedFile('symverscript', script='/build/gen_symverscript.py',
inputs=['../symverscript.in'],
py2=True,
flags=['xul%s' % CONFIG['MOZILLA_SYMBOLVERSION']])
SYMBOLS_FILE = '!symverscript'
@ -377,6 +376,5 @@ else:
libxul_list = '%sxul_%s' % (
CONFIG['DLL_PREFIX'], CONFIG['DLL_SUFFIX'].lstrip('.').replace('.','_'))
GeneratedFile('buildid.cpp', script = 'gen_buildid.py',
py2=True,
inputs=['!build/%s.list' % libxul_list])

Просмотреть файл

@ -15,7 +15,7 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gtk':
JAR_MANIFESTS += ['jar.mn']
GeneratedFile('multilocale.txt', script='gen_multilocale.py', py2=True)
GeneratedFile('multilocale.txt', script='gen_multilocale.py')
FINAL_TARGET_FILES.res += [
'!multilocale.txt',
]
@ -34,5 +34,4 @@ if CONFIG['MOZ_CRASHREPORTER']:
LOCALIZED_GENERATED_FILES += ['update.locale']
update_locale = LOCALIZED_GENERATED_FILES['update.locale']
update_locale.script = 'generate_update_locale.py'
update_locale.py2 = True
LOCALIZED_FILES += ['!update.locale']

Просмотреть файл

@ -32,7 +32,6 @@ built_in_addons = 'built_in_addons.json'
GENERATED_FILES += [built_in_addons]
manifest = GENERATED_FILES[built_in_addons]
manifest.script = 'gen_built_in_addons.py'
manifest.py2 = True
if CONFIG['MOZ_BUILD_APP'] == 'browser':
manifest.flags = ['--features=browser/features']

Просмотреть файл

@ -26,7 +26,6 @@ for addon in addons:
GENERATED_FILES += [xpi]
GENERATED_FILES[xpi].script = '../create_xpi.py'
GENERATED_FILES[xpi].inputs = [indir]
GENERATED_FILES[xpi].py2 = True
output_dir += ['!%s' % xpi]

Просмотреть файл

@ -49,12 +49,6 @@ xpcshell_cert.script = 'gen_cert_header.py:create_header'
dep1_cert.script = 'gen_cert_header.py:create_header'
dep2_cert.script = 'gen_cert_header.py:create_header'
primary_cert.py2 = True
secondary_cert.py2 = True
xpcshell_cert.py2 = True
dep1_cert.py2 = True
dep2_cert.py2 = True
if CONFIG['MOZ_UPDATE_CHANNEL'] in ('beta', 'release', 'esr'):
primary_cert.inputs += ['release_primary.der']
secondary_cert.inputs += ['release_secondary.der']

Просмотреть файл

@ -40,7 +40,6 @@ t = tuple(['sdk_bindings'] +
GENERATED_FILES += [t]
GENERATED_FILES[t].script = '/mobile/android/gradle.py:generate_sdk_bindings'
GENERATED_FILES[t].inputs += ['%s-classes.txt' % stem for stem in generated]
GENERATED_FILES[t].py2 = True
FINAL_LIBRARY = 'xul'

Просмотреть файл

@ -82,7 +82,6 @@ include('/ipc/chromium/chromium-config.mozbuild')
GeneratedFile(
'generated_jni_wrappers', 'GeneratedJNINatives.h', 'GeneratedJNIWrappers.h',
'GeneratedJNIWrappers.cpp', script='/mobile/android/gradle.py',
py2=True,
entry_point='generate_generated_jni_wrappers')
FINAL_LIBRARY = 'xul'

Просмотреть файл

@ -202,12 +202,10 @@ if CONFIG['OS_TARGET'] == 'WINNT':
'MemoryInfo.cpp',
]
GeneratedFile("ErrorList.h", script="ErrorList.py", entry_point="error_list_h", py2=True)
GeneratedFile("ErrorList.h", script="ErrorList.py", entry_point="error_list_h")
GeneratedFile("ErrorNamesInternal.h", script="ErrorList.py",
py2=True,
entry_point="error_names_internal_h")
GeneratedFile("error_list.rs", script="ErrorList.py",
py2=True,
entry_point="error_list_rs")
if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
@ -226,7 +224,6 @@ if CONFIG['COMPILE_ENVIRONMENT']:
GeneratedFile('gk_rust_utils_ffi_generated.h',
script='/layout/style/RunCbindgen.py',
py2=True,
entry_point='generate', inputs=['/xpcom/rust/gkrust_utils'])
include('/ipc/chromium/chromium-config.mozbuild')

Просмотреть файл

@ -70,9 +70,9 @@ if CONFIG['OS_ARCH'] != 'WINNT':
'NSPRInterposer.cpp',
]
GeneratedFile('Services.cpp', script='Services.py', entry_point='services_cpp', py2=True)
GeneratedFile('Services.h', script='Services.py', entry_point='services_h', py2=True)
GeneratedFile('services.rs', script='Services.py', entry_point='services_rs', py2=True)
GeneratedFile('Services.cpp', script='Services.py', entry_point='services_cpp')
GeneratedFile('Services.h', script='Services.py', entry_point='services_h')
GeneratedFile('services.rs', script='Services.py', entry_point='services_rs')
include('/ipc/chromium/chromium-config.mozbuild')

Просмотреть файл

@ -41,7 +41,6 @@ if CONFIG['COMPILE_ENVIRONMENT']:
GeneratedFile(
'Components.h', 'StaticComponentData.h', 'StaticComponents.cpp',
script='gen_static_components.py',
py2=True,
inputs=['!manifest-lists.json', 'StaticComponents.cpp.in'])
UNIFIED_SOURCES += [

Просмотреть файл

@ -135,12 +135,10 @@ LOCAL_INCLUDES += [
]
GeneratedFile('nsGkAtomList.h', script='StaticAtoms.py',
py2=True,
entry_point='generate_nsgkatomlist_h',
inputs=['Atom.py', 'HTMLAtoms.py'])
GeneratedFile('nsGkAtomConsts.h', script='StaticAtoms.py',
py2=True,
entry_point='generate_nsgkatomconsts_h',
inputs=['Atom.py', 'HTMLAtoms.py'])

Просмотреть файл

@ -9,5 +9,4 @@ PYTHON_UNITTEST_MANIFESTS += [
]
GeneratedFile('xpidl.stub', 'xpidllex.py', 'xpidlyacc.py', script='header.py',
py2=True,
entry_point='main')

Просмотреть файл

@ -50,7 +50,6 @@ elif CONFIG['CPU_ARCH'] == 'aarch64':
for src in asm_files:
obj = src.replace('_asm_aarch64', '')
GeneratedFile(obj, script='preprocess.py', entry_point='preprocess',
py2=True,
inputs=[src])
SOURCES += ['!%s' % obj]

Просмотреть файл

@ -119,7 +119,6 @@ LOCAL_INCLUDES += [
GeneratedFile('dafsa_test_1.inc',
script='../../ds/tools/make_dafsa.py',
py2=True,
inputs=['dafsa_test_1.dat'])
TEST_HARNESS_FILES.gtest += [