-
Notifications
You must be signed in to change notification settings - Fork 121
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update //build to m114.0.5735.331. (#2100)
b/313662336
- Loading branch information
1 parent
d0d3d1d
commit fd2b36a
Showing
1,176 changed files
with
51,193 additions
and
29,491 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,34 @@ | ||
set noparent | ||
# NOTE: keep this in sync with [email protected] owners | ||
# by emailing [email protected] when this list changes. | ||
[email protected] | ||
[email protected] | ||
[email protected] | ||
[email protected] | ||
[email protected] | ||
[email protected] | ||
[email protected] | ||
[email protected] | ||
|
||
# Clang build config changes: | ||
[email protected] | ||
file://tools/clang/scripts/OWNERS | ||
|
||
# For java build changes: | ||
[email protected] | ||
[email protected] | ||
|
||
# NOTE: keep this in sync with [email protected] owners | ||
# by emailing [email protected] when this list changes. | ||
|
||
per-file .gitignore=* | ||
per-file check_gn_headers_whitelist.txt=* | ||
# Mac build changes: | ||
per-file [email protected] | ||
per-file [email protected] | ||
per-file mac_toolchain.py=file://build/mac/OWNERS | ||
per-file xcode_binaries.yaml=file://build/mac/OWNERS | ||
|
||
per-file .gitignore=* | ||
per-file check_gn_headers_whitelist.txt=* | ||
per-file whitespace_file.txt=* | ||
per-file OWNERS.status=* | ||
per-file OWNERS.setnoparent=set noparent | ||
per-file OWNERS.setnoparent=file://ENG_REVIEW_OWNERS | ||
per-file OWNERS.setnoparent=file://ATL_OWNERS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
# Copyright 2022 The Chromium Authors | ||
# Use of this source code is governed by a BSD-style license that can be | ||
# found in the LICENSE file. | ||
|
||
PRESUBMIT_VERSION = '2.0.0' | ||
|
||
# This line is 'magic' in that git-cl looks for it to decide whether to | ||
# use Python3 instead of Python2 when running the code in this file. | ||
USE_PYTHON3 = True | ||
|
||
import textwrap | ||
|
||
|
||
def CheckNoBadDeps(input_api, output_api): | ||
"""Prevent additions of bad dependencies from the //build prefix.""" | ||
build_file_patterns = [ | ||
r'(.+/)?BUILD\.gn', | ||
r'.+\.gni', | ||
] | ||
blocklist_pattern = input_api.re.compile(r'^[^#]*"//(?!build).+?/.*"') | ||
allowlist_pattern = input_api.re.compile(r'^[^#]*"//third_party/junit') | ||
|
||
warning_message = textwrap.dedent(""" | ||
The //build directory is meant to be as hermetic as possible so that | ||
other projects (webrtc, v8, angle) can make use of it. If you are adding | ||
a new dep from //build onto another directory, you should consider: | ||
1) Can that dep live within //build? | ||
2) Can the dep be guarded by "build_with_chromium"? | ||
3) Have you made this new dep easy to pull in for other projects (ideally | ||
a matter of adding a DEPS entry).:""") | ||
|
||
def FilterFile(affected_file): | ||
return input_api.FilterSourceFile(affected_file, | ||
files_to_check=build_file_patterns) | ||
|
||
problems = [] | ||
for f in input_api.AffectedSourceFiles(FilterFile): | ||
local_path = f.LocalPath() | ||
for line_number, line in f.ChangedContents(): | ||
if blocklist_pattern.search(line) and not allowlist_pattern.search(line): | ||
problems.append('%s:%d\n %s' % | ||
(local_path, line_number, line.strip())) | ||
if problems: | ||
return [output_api.PresubmitPromptOrNotify(warning_message, problems)] | ||
else: | ||
return [] | ||
|
||
|
||
def CheckPythonTests(input_api, output_api): | ||
return input_api.RunTests( | ||
input_api.canned_checks.GetUnitTestsInDirectory( | ||
input_api, | ||
output_api, | ||
input_api.PresubmitLocalPath(), | ||
files_to_check=[r'.+_(?:unit)?test\.py$'], | ||
run_on_python2=False, | ||
run_on_python3=True)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
#!/usr/bin/env python3 | ||
# Copyright 2022 The Chromium Authors | ||
# Use of this source code is governed by a BSD-style license that can be | ||
# found in the LICENSE file. | ||
|
||
import os | ||
import sys | ||
import unittest | ||
|
||
import PRESUBMIT | ||
|
||
sys.path.append(os.path.join(os.path.dirname(__file__), '..')) | ||
|
||
from PRESUBMIT_test_mocks import MockAffectedFile | ||
from PRESUBMIT_test_mocks import MockInputApi, MockOutputApi | ||
|
||
USE_PYTHON3 = True | ||
|
||
|
||
def _fails_deps_check(line, filename='BUILD.gn'): | ||
mock_input_api = MockInputApi() | ||
mock_input_api.files = [MockAffectedFile(filename, [line])] | ||
errors = PRESUBMIT.CheckNoBadDeps(mock_input_api, MockOutputApi()) | ||
return bool(errors) | ||
|
||
|
||
class CheckNoBadDepsTest(unittest.TestCase): | ||
def testComments(self): | ||
self.assertFalse(_fails_deps_check('no # import("//third_party/foo")')) | ||
|
||
def testFiles(self): | ||
self.assertFalse( | ||
_fails_deps_check('import("//third_party/foo")', filename='foo.txt')) | ||
self.assertTrue( | ||
_fails_deps_check('import("//third_party/foo")', filename='foo.gni')) | ||
|
||
def testPaths(self): | ||
self.assertFalse(_fails_deps_check('import("//build/things.gni")')) | ||
self.assertTrue(_fails_deps_check('import("//chrome/things.gni")')) | ||
|
||
|
||
if __name__ == '__main__': | ||
unittest.main() |
Oops, something went wrong.