Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit d8db75f

Browse files
Merge remote-tracking branch 'upstream/main' into skia_paragraph_builder_strut_half_leading
2 parents 8cafa8f + 0a527fd commit d8db75f

File tree

163 files changed

+8129
-6085
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

163 files changed

+8129
-6085
lines changed

.clang-tidy

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,4 +61,4 @@ CheckOptions:
6161
# updated.
6262
#
6363
# tl;dr: I'm sorry.
64-
HeaderFilterRegex: "[..\/]+\/flutter\/(assets|benchmarking|build|ci|common|display_list|docs|examples|flow|flutter_frontend_server|flutter_vma|fml|impeller|lib|runtime|shell|skia|sky|testing|tools|vulkan|wasm|web_sdk)\/.*"
64+
HeaderFilterRegex: "[..\/]+\/flutter\/(assets|benchmarking|bin|build|ci|common|display_list|docs|examples|flow|flutter_frontend_server|flutter_vma|fml|impeller|lib|runtime|shell|skia|sky|testing|tools|vulkan|wasm|web_sdk)\/.*"

.github/workflows/third_party_scan.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ jobs:
4141
name: Vulnerability scanning
4242
needs:
4343
extract-deps
44-
uses: "google/osv-scanner/.github/workflows/osv-scanner-reusable.yml@main"
44+
uses: "google/osv-scanner-action/.github/workflows/osv-scanner-reusable.yml@v1.6.2-beta1"
4545
with:
4646
# Download the artifact uploaded in extract-deps step
4747
download-artifact: osv-lockfile-${{github.sha}}

BUILD.gn

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import("//flutter/examples/examples.gni")
88
import("//flutter/shell/platform/config.gni")
99
import("//flutter/shell/platform/glfw/config.gni")
1010
import("//flutter/testing/testing.gni")
11-
import("//third_party/dart/build/dart/copy_tree.gni")
11+
import("$dart_src/build/dart/copy_tree.gni")
1212

1313
# Whether to build the dartdevc sdk, libraries, and source files
1414
# required for the flutter web sdk.
@@ -104,7 +104,7 @@ group("flutter") {
104104
# This must be listed explicitly for desktop cross-builds since
105105
# //flutter/lib/snapshot:generate_snapshot_bin will only build
106106
# gen_snapshot for the host and not the target.
107-
"//third_party/dart/runtime/bin:gen_snapshot",
107+
"$dart_src/runtime/bin:gen_snapshot",
108108

109109
# Impeller artifacts - compiler and libtessellator
110110
"//flutter/impeller/compiler:impellerc",
@@ -117,7 +117,7 @@ group("flutter") {
117117
if (host_os == "linux") {
118118
public_deps += [
119119
# Built alongside gen_snapshot for 64 bit targets
120-
"//third_party/dart/runtime/bin:analyze_snapshot",
120+
"$dart_src/runtime/bin:analyze_snapshot",
121121
]
122122
}
123123

@@ -300,8 +300,7 @@ if (is_fuchsia && enable_unittests) {
300300
# Dart tree, and is less ambiguous than specifying the binary to build since
301301
# we can specify the toolchain to use, too.
302302
if (host_os == "win") {
303-
_gen_snapshot_target =
304-
"//third_party/dart/runtime/bin:gen_snapshot($host_toolchain)"
303+
_gen_snapshot_target = "$dart_src/runtime/bin:gen_snapshot($host_toolchain)"
305304
copy("gen_snapshot") {
306305
deps = [ _gen_snapshot_target ]
307306

DEPS

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ vars = {
1414
'flutter_git': 'https://flutter.googlesource.com',
1515
'skia_git': 'https://skia.googlesource.com',
1616
'llvm_git': 'https://llvm.googlesource.com',
17-
'skia_revision': 'd650dcaf4b49a7f10733a4d5c497a81db867ebdb',
17+
'skia_revision': '3cbb5d6a71fe061b54a307a78bd20248a4a37d48',
1818

1919
# WARNING: DO NOT EDIT canvaskit_cipd_instance MANUALLY
2020
# See `lib/web_ui/README.md` for how to roll CanvasKit to a new version.
@@ -62,11 +62,11 @@ vars = {
6262
# Dart is: https://github.com/dart-lang/sdk/blob/main/DEPS
6363
# You can use //tools/dart/create_updated_flutter_deps.py to produce
6464
# updated revision list of existing dependencies.
65-
'dart_revision': '032323fa534b4e569bd4215878d2701ae9a23185',
65+
'dart_revision': '9bbac4d40725d5fe1a3c60007d08b965083f3128',
6666

6767
# WARNING: DO NOT EDIT MANUALLY
6868
# The lines between blank lines above and below are generated by a script. See create_updated_flutter_deps.py
69-
'dart_binaryen_rev': 'f172920b90f9745494c2efeb1696468fa26be506',
69+
'dart_binaryen_rev': '9784f012848a7eb321c2037bdb363dfe0eab8bc9',
7070
'dart_boringssl_gen_rev': '9c7294fd58261a79794f5afaa26598cf1442ad20',
7171
'dart_boringssl_rev': 'd24a38200fef19150eef00cad35b138936c08767',
7272
'dart_browser_launcher_rev': '74a0efe937a29d4d9aff50c145579c6e6479df1e',
@@ -252,7 +252,7 @@ vars = {
252252
# The version / instance id of the cipd:chromium/fuchsia/test-scripts which
253253
# will be used altogether with fuchsia-sdk to setup the build / test
254254
# environment.
255-
'fuchsia_test_scripts_version': 'MXOVCk7s_1bZ8hJZ5M5DgS_9i8FeSjYojkSGY8zpnxQC',
255+
'fuchsia_test_scripts_version': 'vf8imeAzGv_gjYQDoqub2laI-6nkB3gQNiGuVaFForMC',
256256
}
257257

258258
gclient_gn_args_file = 'src/third_party/dart/build/config/gclient_args.gni'
@@ -315,13 +315,13 @@ deps = {
315315
'src/third_party/googletest':
316316
Var('chromium_git') + '/external/github.com/google/googletest' + '@' + '7f036c5563af7d0329f20e8bb42effb04629f0c0',
317317

318-
'src/third_party/boringssl':
318+
'src/flutter/third_party/boringssl':
319319
Var('dart_git') + '/boringssl_gen.git' + '@' + Var('dart_boringssl_gen_rev'),
320320

321321
'src/flutter/third_party/yapf':
322322
Var('flutter_git') + '/third_party/yapf' + '@' + '212c5b5ad8e172d2d914ae454c121c89cccbcb35',
323323

324-
'src/third_party/boringssl/src':
324+
'src/flutter/third_party/boringssl/src':
325325
'https://boringssl.googlesource.com/boringssl.git' + '@' + Var('dart_boringssl_rev'),
326326

327327
'src/third_party/perfetto':
@@ -339,7 +339,7 @@ deps = {
339339
# WARNING: Unused Dart dependencies in the list below till "WARNING:" marker are removed automatically - see create_updated_flutter_deps.py.
340340

341341
'src/third_party/dart/third_party/binaryen/src':
342-
Var('chromium_git') + '/external/github.com/WebAssembly/binaryen.git@f172920b90f9745494c2efeb1696468fa26be506',
342+
Var('chromium_git') + '/external/github.com/WebAssembly/binaryen.git@9784f012848a7eb321c2037bdb363dfe0eab8bc9',
343343

344344
'src/third_party/dart/third_party/devtools':
345345
{'dep_type': 'cipd', 'packages': [{'package': 'dart/third_party/flutter/devtools', 'version': 'git_revision:1f208c84965e9edddea11485fb73b170dba1cd96'}]},
@@ -429,7 +429,7 @@ deps = {
429429
Var('dart_git') + '/mockito.git@7d6632fd679f0f6aae32ee74038ba8cb6b64a607',
430430

431431
'src/third_party/dart/third_party/pkg/native':
432-
Var('dart_git') + '/native.git@cb9bd7ef604f71f2c51d0acbb3214cfe06e952be',
432+
Var('dart_git') + '/native.git@0901a3323022fdb59657cc2cb00ea5c80a8468a6',
433433

434434
'src/third_party/dart/third_party/pkg/package_config':
435435
Var('dart_git') + '/package_config.git@4a7042bb286cf0b41b26e87972bc28bda535f8b9',
@@ -996,7 +996,7 @@ deps = {
996996
'packages': [
997997
{
998998
'package': 'fuchsia/sdk/core/linux-amd64',
999-
'version': 'l6mWjvlO1xJg5ZFKKwU7YJDjzw-ncLCsu2BjKF1plHcC'
999+
'version': 'fXqP_YC4zTp9G2hA5alKfZo5rbWLmBPvlOVdqw9PCUYC'
10001000
}
10011001
],
10021002
'condition': 'host_os == "linux" and not download_fuchsia_sdk',
@@ -1184,7 +1184,7 @@ hooks = [
11841184
'python3',
11851185
'src/flutter/tools/fuchsia/with_envs.py',
11861186
'src/flutter/tools/fuchsia/test_scripts/update_product_bundles.py',
1187-
'terminal.x64',
1187+
'terminal.x64,terminal.qemu-arm64',
11881188
]
11891189
}
11901190
]

bin/et

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
#!/bin/bash
2+
#
3+
# Copyright 2013 The Flutter Authors. All rights reserved.
4+
# Use of this source code is governed by a BSD-style license that can be
5+
# found in the LICENSE file.
6+
7+
set -e
8+
9+
# Needed because if it is set, cd may print the path it changed to.
10+
unset CDPATH
11+
12+
# On Mac OS, readlink -f doesn't work, so follow_links traverses the path one
13+
# link at a time, and then cds into the link destination and find out where it
14+
# ends up.
15+
#
16+
# The function is enclosed in a subshell to avoid changing the working directory
17+
# of the caller.
18+
function follow_links() (
19+
cd -P "$(dirname -- "$1")"
20+
file="$PWD/$(basename -- "$1")"
21+
while [[ -h "$file" ]]; do
22+
cd -P "$(dirname -- "$file")"
23+
file="$(readlink -- "$file")"
24+
cd -P "$(dirname -- "$file")"
25+
file="$PWD/$(basename -- "$file")"
26+
done
27+
echo "$file"
28+
)
29+
30+
SCRIPT_DIR=$(follow_links "$(dirname -- "${BASH_SOURCE[0]}")")
31+
ENGINE_DIR="$(cd "$SCRIPT_DIR/.."; pwd -P)"
32+
33+
case "$(uname -s)" in
34+
Linux)
35+
OS="linux"
36+
;;
37+
Darwin)
38+
OS="macos"
39+
;;
40+
*)
41+
echo "The host platform is not supported by this tool"
42+
exit 1
43+
esac
44+
45+
case "$(uname -m)" in
46+
arm64)
47+
CPU="arm64"
48+
;;
49+
x86_64)
50+
CPU="x64"
51+
;;
52+
*)
53+
echo "The host platform is not supported by this tool"
54+
exit 1
55+
esac
56+
57+
PLATFORM="${OS}-${CPU}"
58+
DART_SDK_DIR="${ENGINE_DIR}/prebuilts/${PLATFORM}/dart-sdk"
59+
DART="${DART_SDK_DIR}/bin/dart"
60+
61+
cd "${ENGINE_DIR}/tools/engine_tool"
62+
63+
if [ ! -d ".dart_tool" ]; then
64+
echo "You must run 'gclient sync -D' before using this tool."
65+
exit 1
66+
fi
67+
68+
"${DART}" --disable-dart-dev bin/et.dart "$@"

build/archives/BUILD.gn

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,13 @@ generated_file("artifacts_entitlement_config") {
2424
if (build_engine_artifacts && !is_android) {
2525
zip_bundle("artifacts") {
2626
deps = [
27+
"$dart_src/runtime/bin:gen_snapshot",
2728
"//flutter/flutter_frontend_server:frontend_server",
2829
"//flutter/impeller/compiler:impellerc",
2930
"//flutter/impeller/tessellator:tessellator_shared",
3031
"//flutter/lib/snapshot:generate_snapshot_bin",
3132
"//flutter/shell/testing:testing",
3233
"//flutter/tools/path_ops:path_ops",
33-
"//third_party/dart/runtime/bin:gen_snapshot",
3434
]
3535
if (is_mac) {
3636
# TODO(godofredoc): Remove after paths are standardized flutter/flutter#105351.
@@ -196,7 +196,7 @@ if (build_engine_artifacts && flutter_prebuilt_dart_sdk) {
196196
# If there is no prebuilt sdk, create the dart sdk archive from the built sdk.
197197
if (build_engine_artifacts && !flutter_prebuilt_dart_sdk) {
198198
zip_bundle_from_file("dart_sdk_archive") {
199-
deps = [ "//third_party/dart:create_sdk" ]
199+
deps = [ "$dart_src:create_sdk" ]
200200
output = "dart-sdk-$full_target_platform_name.zip"
201201
files = [
202202
{

build/bin_to_obj.gni

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
# Use of this source code is governed by a BSD-style license that can be
33
# found in the LICENSE file.
44

5+
import("//flutter/build/dart/dart.gni")
6+
57
# Generates an assembly file defining a given symbol with the bytes from a
68
# binary file. Places the symbol in a text section if 'executable' is true,
79
# otherwise places the symbol in a read-only data section.
@@ -13,7 +15,7 @@ template("bin_to_assembly") {
1315

1416
action(target_name) {
1517
deps = invoker.deps
16-
script = "//third_party/dart/runtime/tools/bin_to_assembly.py"
18+
script = "$dart_src/runtime/tools/bin_to_assembly.py"
1719
output = "$target_gen_dir/${invoker.input}.S"
1820
args = [
1921
"--input",
@@ -57,7 +59,7 @@ template("bin_to_coff") {
5759

5860
action(target_name) {
5961
deps = invoker.deps
60-
script = "//third_party/dart/runtime/tools/bin_to_coff.py"
62+
script = "$dart_src/runtime/tools/bin_to_coff.py"
6163
output = "$target_gen_dir/${invoker.input}.o"
6264
args = [
6365
"--input",

build/dart/BUILD.gn

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,10 @@
33
# found in the LICENSE file.
44

55
import("//flutter/build/concurrent_jobs.gni")
6+
import("//flutter/build/dart/dart.gni")
67
import("//flutter/common/config.gni")
7-
import("//third_party/dart/build/dart/copy_tree.gni")
8+
9+
import("$dart_src/build/dart/copy_tree.gni")
810

911
declare_args() {
1012
# Maximum number of Dart processes to run in parallel.
@@ -35,7 +37,7 @@ if (build_engine_artifacts) {
3537
}
3638
} else {
3739
group("dart_sdk") {
38-
public_deps = [ "//third_party/dart:create_sdk" ]
40+
public_deps = [ "$dart_src:create_sdk" ]
3941
}
4042
}
4143
}

build/dart/dart.gni

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Copyright 2013 The Flutter Authors. All rights reserved.
2+
# Use of this source code is governed by a BSD-style license that can be
3+
# found in the LICENSE file.
4+
5+
declare_args() {
6+
dart_src = "//third_party/dart"
7+
}

build/dart/rules.gni

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,11 @@
66

77
import("//build/compiled_action.gni")
88
import("//build/module_args/dart.gni")
9+
import("//flutter/build/dart/dart.gni")
910
import("//flutter/common/config.gni")
10-
import("//third_party/dart/build/dart/dart_action.gni")
11-
import("//third_party/dart/sdk_args.gni")
11+
12+
import("$dart_src/build/dart/dart_action.gni")
13+
import("$dart_src/sdk_args.gni")
1214

1315
# Generates a Dart kernel snapshot using flutter_frontend_server.
1416
#
@@ -108,7 +110,7 @@ template("flutter_frontend_server") {
108110
[ "pool" ])
109111
deps = common_deps
110112
pool = "//flutter/build/dart:dart_pool"
111-
script = "//third_party/dart/pkg/frontend_server/bin/frontend_server_starter.dart"
113+
script = "$dart_src/pkg/frontend_server/bin/frontend_server_starter.dart"
112114
inputs = [ invoker.main_dart ]
113115
outputs = [ invoker.kernel_output ]
114116
depfile = snapshot_depfile
@@ -179,10 +181,10 @@ template("flutter_snapshot") {
179181
# By default Dart will create a 32-bit gen_snapshot host binary if the target
180182
# platform is 32-bit. Override this to create a 64-bit gen_snapshot for x86
181183
# targets because some host platforms may not support 32-bit binaries.
182-
tool = "//third_party/dart/runtime/bin:gen_snapshot_host_targeting_host"
184+
tool = "$dart_src/runtime/bin:gen_snapshot_host_targeting_host"
183185
toolchain = "//build/toolchain/$host_os:clang_x64"
184186
} else {
185-
tool = "//third_party/dart/runtime/bin:gen_snapshot"
187+
tool = "$dart_src/runtime/bin:gen_snapshot"
186188
}
187189

188190
inputs = [ kernel_output ]

0 commit comments

Comments
 (0)