Skip to content

Commit

Permalink
Merge branch 'main' into default_non_stripped
Browse files Browse the repository at this point in the history
  • Loading branch information
gmackall committed Feb 15, 2024
2 parents 9837b9d + 4503a5b commit 3312fb1
Show file tree
Hide file tree
Showing 154 changed files with 8,053 additions and 6,006 deletions.
2 changes: 1 addition & 1 deletion .clang-tidy
Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,4 @@ CheckOptions:
# updated.
#
# tl;dr: I'm sorry.
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)\/.*"
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)\/.*"
2 changes: 1 addition & 1 deletion .github/workflows/third_party_scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
name: Vulnerability scanning
needs:
extract-deps
uses: "google/osv-scanner/.github/workflows/osv-scanner-reusable.yml@main"
uses: "google/osv-scanner-action/.github/workflows/osv-scanner-reusable.yml@v1.6.2-beta1"
with:
# Download the artifact uploaded in extract-deps step
download-artifact: osv-lockfile-${{github.sha}}
Expand Down
9 changes: 4 additions & 5 deletions BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import("//flutter/examples/examples.gni")
import("//flutter/shell/platform/config.gni")
import("//flutter/shell/platform/glfw/config.gni")
import("//flutter/testing/testing.gni")
import("//third_party/dart/build/dart/copy_tree.gni")
import("$dart_src/build/dart/copy_tree.gni")

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

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

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

Expand Down
20 changes: 10 additions & 10 deletions DEPS
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ vars = {
'flutter_git': 'https://flutter.googlesource.com',
'skia_git': 'https://skia.googlesource.com',
'llvm_git': 'https://llvm.googlesource.com',
'skia_revision': 'b8acfa559db0438cb0c3dbf54d78844a5d9b38e4',
'skia_revision': 'a8e4db1afac5a39e49f8a060d126bc529a06e660',

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

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

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

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

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

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

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

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

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

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

'src/third_party/dart/third_party/pkg/package_config':
Var('dart_git') + '/package_config.git@4a7042bb286cf0b41b26e87972bc28bda535f8b9',
Expand Down Expand Up @@ -996,7 +996,7 @@ deps = {
'packages': [
{
'package': 'fuchsia/sdk/core/linux-amd64',
'version': 'l6mWjvlO1xJg5ZFKKwU7YJDjzw-ncLCsu2BjKF1plHcC'
'version': 'fXqP_YC4zTp9G2hA5alKfZo5rbWLmBPvlOVdqw9PCUYC'
}
],
'condition': 'host_os == "linux" and not download_fuchsia_sdk',
Expand Down Expand Up @@ -1184,7 +1184,7 @@ hooks = [
'python3',
'src/flutter/tools/fuchsia/with_envs.py',
'src/flutter/tools/fuchsia/test_scripts/update_product_bundles.py',
'terminal.x64',
'terminal.x64,terminal.qemu-arm64',
]
}
]
68 changes: 68 additions & 0 deletions bin/et
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
#!/bin/bash
#
# Copyright 2013 The Flutter Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

set -e

# Needed because if it is set, cd may print the path it changed to.
unset CDPATH

# On Mac OS, readlink -f doesn't work, so follow_links traverses the path one
# link at a time, and then cds into the link destination and find out where it
# ends up.
#
# The function is enclosed in a subshell to avoid changing the working directory
# of the caller.
function follow_links() (
cd -P "$(dirname -- "$1")"
file="$PWD/$(basename -- "$1")"
while [[ -h "$file" ]]; do
cd -P "$(dirname -- "$file")"
file="$(readlink -- "$file")"
cd -P "$(dirname -- "$file")"
file="$PWD/$(basename -- "$file")"
done
echo "$file"
)

SCRIPT_DIR=$(follow_links "$(dirname -- "${BASH_SOURCE[0]}")")
ENGINE_DIR="$(cd "$SCRIPT_DIR/.."; pwd -P)"

case "$(uname -s)" in
Linux)
OS="linux"
;;
Darwin)
OS="macos"
;;
*)
echo "The host platform is not supported by this tool"
exit 1
esac

case "$(uname -m)" in
arm64)
CPU="arm64"
;;
x86_64)
CPU="x64"
;;
*)
echo "The host platform is not supported by this tool"
exit 1
esac

PLATFORM="${OS}-${CPU}"
DART_SDK_DIR="${ENGINE_DIR}/prebuilts/${PLATFORM}/dart-sdk"
DART="${DART_SDK_DIR}/bin/dart"

cd "${ENGINE_DIR}/tools/engine_tool"

if [ ! -d ".dart_tool" ]; then
echo "You must run 'gclient sync -D' before using this tool."
exit 1
fi

"${DART}" --disable-dart-dev bin/et.dart "$@"
4 changes: 2 additions & 2 deletions build/archives/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ generated_file("artifacts_entitlement_config") {
if (build_engine_artifacts && !is_android) {
zip_bundle("artifacts") {
deps = [
"$dart_src/runtime/bin:gen_snapshot",
"//flutter/flutter_frontend_server:frontend_server",
"//flutter/impeller/compiler:impellerc",
"//flutter/impeller/tessellator:tessellator_shared",
"//flutter/lib/snapshot:generate_snapshot_bin",
"//flutter/shell/testing:testing",
"//flutter/tools/path_ops:path_ops",
"//third_party/dart/runtime/bin:gen_snapshot",
]
if (is_mac) {
# TODO(godofredoc): Remove after paths are standardized flutter/flutter#105351.
Expand Down Expand Up @@ -196,7 +196,7 @@ if (build_engine_artifacts && flutter_prebuilt_dart_sdk) {
# If there is no prebuilt sdk, create the dart sdk archive from the built sdk.
if (build_engine_artifacts && !flutter_prebuilt_dart_sdk) {
zip_bundle_from_file("dart_sdk_archive") {
deps = [ "//third_party/dart:create_sdk" ]
deps = [ "$dart_src:create_sdk" ]
output = "dart-sdk-$full_target_platform_name.zip"
files = [
{
Expand Down
6 changes: 4 additions & 2 deletions build/bin_to_obj.gni
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

import("//flutter/build/dart/dart.gni")

# Generates an assembly file defining a given symbol with the bytes from a
# binary file. Places the symbol in a text section if 'executable' is true,
# otherwise places the symbol in a read-only data section.
Expand All @@ -13,7 +15,7 @@ template("bin_to_assembly") {

action(target_name) {
deps = invoker.deps
script = "//third_party/dart/runtime/tools/bin_to_assembly.py"
script = "$dart_src/runtime/tools/bin_to_assembly.py"
output = "$target_gen_dir/${invoker.input}.S"
args = [
"--input",
Expand Down Expand Up @@ -57,7 +59,7 @@ template("bin_to_coff") {

action(target_name) {
deps = invoker.deps
script = "//third_party/dart/runtime/tools/bin_to_coff.py"
script = "$dart_src/runtime/tools/bin_to_coff.py"
output = "$target_gen_dir/${invoker.input}.o"
args = [
"--input",
Expand Down
6 changes: 4 additions & 2 deletions build/dart/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,10 @@
# found in the LICENSE file.

import("//flutter/build/concurrent_jobs.gni")
import("//flutter/build/dart/dart.gni")
import("//flutter/common/config.gni")
import("//third_party/dart/build/dart/copy_tree.gni")

import("$dart_src/build/dart/copy_tree.gni")

declare_args() {
# Maximum number of Dart processes to run in parallel.
Expand Down Expand Up @@ -35,7 +37,7 @@ if (build_engine_artifacts) {
}
} else {
group("dart_sdk") {
public_deps = [ "//third_party/dart:create_sdk" ]
public_deps = [ "$dart_src:create_sdk" ]
}
}
}
7 changes: 7 additions & 0 deletions build/dart/dart.gni
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Copyright 2013 The Flutter Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

declare_args() {
dart_src = "//third_party/dart"
}
12 changes: 7 additions & 5 deletions build/dart/rules.gni
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@

import("//build/compiled_action.gni")
import("//build/module_args/dart.gni")
import("//flutter/build/dart/dart.gni")
import("//flutter/common/config.gni")
import("//third_party/dart/build/dart/dart_action.gni")
import("//third_party/dart/sdk_args.gni")

import("$dart_src/build/dart/dart_action.gni")
import("$dart_src/sdk_args.gni")

# Generates a Dart kernel snapshot using flutter_frontend_server.
#
Expand Down Expand Up @@ -108,7 +110,7 @@ template("flutter_frontend_server") {
[ "pool" ])
deps = common_deps
pool = "//flutter/build/dart:dart_pool"
script = "//third_party/dart/pkg/frontend_server/bin/frontend_server_starter.dart"
script = "$dart_src/pkg/frontend_server/bin/frontend_server_starter.dart"
inputs = [ invoker.main_dart ]
outputs = [ invoker.kernel_output ]
depfile = snapshot_depfile
Expand Down Expand Up @@ -179,10 +181,10 @@ template("flutter_snapshot") {
# By default Dart will create a 32-bit gen_snapshot host binary if the target
# platform is 32-bit. Override this to create a 64-bit gen_snapshot for x86
# targets because some host platforms may not support 32-bit binaries.
tool = "//third_party/dart/runtime/bin:gen_snapshot_host_targeting_host"
tool = "$dart_src/runtime/bin:gen_snapshot_host_targeting_host"
toolchain = "//build/toolchain/$host_os:clang_x64"
} else {
tool = "//third_party/dart/runtime/bin:gen_snapshot"
tool = "$dart_src/runtime/bin:gen_snapshot"
}

inputs = [ kernel_output ]
Expand Down
7 changes: 7 additions & 0 deletions build/secondary/third_party/boringssl/BUILD.gn
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Copyright 2013 The Flutter Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

group("boringssl") {
public_deps = [ "//flutter/third_party/boringssl" ]
}
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ dart_library("matcher") {

language_version = "2.12"

deps = [ "//third_party/dart/third_party/pkg/stack_trace" ]
deps = [ "$dart_src/third_party/pkg/stack_trace" ]

sources = [
"expect.dart",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ dart_library("stack_trace") {

language_version = "2.12"

deps = [ "//third_party/dart/third_party/pkg/path" ]
deps = [ "$dart_src/third_party/pkg/path" ]

sources = [
"src/chain.dart",
Expand Down
4 changes: 2 additions & 2 deletions build/secondary/third_party/libsrtp/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,8 @@ if (use_system_libsrtp) {
}

if (use_srtp_boringssl) {
deps = [ "//third_party/boringssl:boringssl" ]
public_deps = [ "//third_party/boringssl:boringssl" ]
deps = [ "//flutter/third_party/boringssl:boringssl" ]
public_deps = [ "//flutter/third_party/boringssl:boringssl" ]
sources -= [
"srtp/crypto/cipher/aes_cbc.c",
"srtp/crypto/cipher/aes_icm.c",
Expand Down
4 changes: 2 additions & 2 deletions build/secondary/third_party/pkg/quiver/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ dart_library("quiver") {
language_version = "2.0"

deps = [
"//third_party/dart/pkg/meta",
"//third_party/dart/third_party/pkg/matcher",
"$dart_src/pkg/meta",
"$dart_src/third_party/pkg/matcher",
]

sources = [
Expand Down
Loading

0 comments on commit 3312fb1

Please sign in to comment.