diff --git a/build_overrides/angle.gni b/build_overrides/angle.gni new file mode 100644 index 0000000000000..e1ad74b94e2a6 --- /dev/null +++ b/build_overrides/angle.gni @@ -0,0 +1,38 @@ +# Copyright 2019 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. + +# Ensure use_xcode_clang is visibile to ANGLE. +import("//build/toolchain/toolchain.gni") + +# The ANGLE build requires this file to point to the location of third-party +# dependencies. +angle_root = "//third_party/angle" + +angle_vma_version = 30000001 + +# Flutter's buildroot looks enough like Chromium to satisfy Angle, and enough +# to cause GN variable collisions if we don't set this. +if (!is_fuchsia) { + angle_has_build = true +} + +# Overrides for ANGLE's dependencies. +angle_abseil_cpp_dir = "//flutter/third_party/abseil-cpp" +angle_glslang_dir = "//flutter/third_party/vulkan-deps/glslang/src" +angle_googletest_dir = "//third_party/googletest/googletest/src" + +# Note: This path doesn't actually exist; see +# //build/secondary/third_party/jsoncpp/BUILD.gn +angle_jsoncpp_dir = "//third_party/jsoncpp" +angle_libjpeg_turbo_dir = "//third_party/libjpeg_turbo" +angle_libpng_dir = "//flutter/third_party/libpng" +angle_spirv_headers_dir = "//flutter/third_party/vulkan-deps/spirv-headers/src" +angle_spirv_tools_dir = "//flutter/third_party/vulkan-deps/spirv-tools/src" +angle_spirv_cross_dir = "//flutter/third_party/vulkan-deps/spirv-cross/src" +angle_spirv_headers_dir = "//flutter/third_party/vulkan-deps/spirv-headers/src" +angle_vulkan_memory_allocator_dir = "//third_party/vulkan_memory_allocator" + +# This is a general Chromium flag, but in the Flutter build only ANGLE needs it +# so it is defined here. +is_cfi = false diff --git a/build_overrides/build.gni b/build_overrides/build.gni new file mode 100644 index 0000000000000..b18ce161d9968 --- /dev/null +++ b/build_overrides/build.gni @@ -0,0 +1,13 @@ +# Copyright 2019 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. + +# The engine build uses some Chromium-sourced versions of third-party +# dependencies (e.g, ANGLE, abseil) to use their GN build files, but we don't +# want the Chromium-specific parts of the build. +build_with_chromium = false + +# Perfetto targets fail to build without this variable. It is used by Perfetto +# targets to distinguish embedder builds from Perfetto standalone builds, and +# builds in the Android tree. +perfetto_build_with_embedder = true diff --git a/build_overrides/glslang.gni b/build_overrides/glslang.gni new file mode 100644 index 0000000000000..cf25687630f3e --- /dev/null +++ b/build_overrides/glslang.gni @@ -0,0 +1,6 @@ +# Copyright 2019 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. + +glslang_spirv_tools_dir = "//flutter/third_party/vulkan-deps/spirv-tools/src" +spirv_tools_dir = "//flutter/third_party/vulkan-deps/spirv-tools/src" diff --git a/build_overrides/spirv_tools.gni b/build_overrides/spirv_tools.gni new file mode 100644 index 0000000000000..1f1494927e92d --- /dev/null +++ b/build_overrides/spirv_tools.gni @@ -0,0 +1,11 @@ +# Copyright 2019 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. + +# We are building inside Flutter. +spirv_tools_standalone = false + +# Paths to SPIRV-Tools dependencies in Flutter. +spirv_tools_googletest_dir = "//third_party/googletest/googletest/src" +spirv_tools_spirv_headers_dir = + "//flutter/third_party/vulkan-deps/spirv-headers/src" diff --git a/build_overrides/swiftshader.gni b/build_overrides/swiftshader.gni new file mode 100644 index 0000000000000..466a544874711 --- /dev/null +++ b/build_overrides/swiftshader.gni @@ -0,0 +1,9 @@ +# Copyright 2019 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. + +# We are building SwiftShader in Flutter. +swiftshader_standalone = false + +# Path to SwiftShader. +swiftshader_dir = "//flutter/third_party/swiftshader" diff --git a/build_overrides/vulkan_headers.gni b/build_overrides/vulkan_headers.gni new file mode 100644 index 0000000000000..5efa852344924 --- /dev/null +++ b/build_overrides/vulkan_headers.gni @@ -0,0 +1,11 @@ +# Copyright 2020 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. + +# This file is needed by the vulkan-headers build, but doesn't need to actually +# set anything. + +if (is_linux) { + vulkan_use_x11 = true + vulkan_use_wayland = true +} diff --git a/build_overrides/vulkan_loader.gni b/build_overrides/vulkan_loader.gni new file mode 100644 index 0000000000000..b828448e8b457 --- /dev/null +++ b/build_overrides/vulkan_loader.gni @@ -0,0 +1,8 @@ +# Copyright 2020 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. + +vulkan_headers_dir = "//flutter/third_party/vulkan-deps/vulkan-headers/src" + +# Vulkan loader build options +vulkan_loader_shared = true diff --git a/build_overrides/vulkan_tools.gni b/build_overrides/vulkan_tools.gni new file mode 100644 index 0000000000000..a0fbede405393 --- /dev/null +++ b/build_overrides/vulkan_tools.gni @@ -0,0 +1,9 @@ +# Copyright 2020 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. + +vulkan_headers_dir = "//flutter/third_party/vulkan-deps/vulkan-headers/src" + +# Subdirectories for generated files +vulkan_data_subdir = "" +vulkan_gen_subdir = "" diff --git a/build_overrides/vulkan_utility_libraries.gni b/build_overrides/vulkan_utility_libraries.gni new file mode 100644 index 0000000000000..245ffceecaa6b --- /dev/null +++ b/build_overrides/vulkan_utility_libraries.gni @@ -0,0 +1,5 @@ +# 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. + +vulkan_headers_dir = "//flutter/third_party/vulkan-deps/vulkan-headers/src" diff --git a/build_overrides/vulkan_validation_layers.gni b/build_overrides/vulkan_validation_layers.gni new file mode 100644 index 0000000000000..1378a5a9de752 --- /dev/null +++ b/build_overrides/vulkan_validation_layers.gni @@ -0,0 +1,15 @@ +# Copyright 2020 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. + +vulkan_headers_dir = "//flutter/third_party/vulkan-deps/vulkan-headers/src" +vulkan_utility_libraries_dir = + "//flutter/third_party/vulkan-deps/vulkan-utility-libraries/src" +vvl_spirv_tools_dir = "//flutter/third_party/vulkan-deps/spirv-tools/src" +vvl_glslang_dir = "//flutter/third_party/vulkan-deps/spirv-tools/src" + +# robin_hood_headers_dir = "//external/robin-hood-hashing/src/include" + +# Subdirectories for generated files +vulkan_data_subdir = "vulkan-data" +vulkan_gen_subdir = "" diff --git a/build_overrides/wayland.gni b/build_overrides/wayland.gni new file mode 100644 index 0000000000000..d3d82c33c824a --- /dev/null +++ b/build_overrides/wayland.gni @@ -0,0 +1,8 @@ +# Copyright 2019 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. + +# ANGLE expects this to be here. + +# Flutter has no wayland third-party dir +wayland_gn_dir = "" diff --git a/ci/licenses_golden/excluded_files b/ci/licenses_golden/excluded_files index e444d9059a080..2b05fe5155d02 100644 --- a/ci/licenses_golden/excluded_files +++ b/ci/licenses_golden/excluded_files @@ -26,6 +26,7 @@ ../../../flutter/README.md ../../../flutter/analysis_options.yaml ../../../flutter/build +../../../flutter/build_overrides ../../../flutter/ci ../../../flutter/common/README.md ../../../flutter/display_list/benchmarking/dl_complexity_unittests.cc diff --git a/ci/licenses_golden/licenses_dart b/ci/licenses_golden/licenses_dart index 7f60a770b4d5b..eb553dd422119 100644 --- a/ci/licenses_golden/licenses_dart +++ b/ci/licenses_golden/licenses_dart @@ -4747,7 +4747,7 @@ Exhibit B - "Incompatible With Secondary Licenses" Notice This Source Code Form is "Incompatible With Secondary Licenses", as defined by the Mozilla Public License, v. 2.0. -You may obtain a copy of this library's Source Code Form from: https://dart.googlesource.com/sdk/+/3538739eeea98ec50f66bd45934b53d2d1a6a787 +You may obtain a copy of this library's Source Code Form from: https://dart.googlesource.com/sdk/+/4bc97350dc47dfc431469f9f30108f720ee42ce4 /third_party/fallback_root_certificates/ ==================================================================================================== diff --git a/ci/licenses_golden/tool_signature b/ci/licenses_golden/tool_signature index bb685ec034f0b..22d0c3900c072 100644 --- a/ci/licenses_golden/tool_signature +++ b/ci/licenses_golden/tool_signature @@ -1,2 +1,2 @@ -Signature: 5517be1afb4a2e347b9c4f018c1d5e5f +Signature: 6869bf83ae9a2e71a9302f51626429a0 diff --git a/tools/clang_tidy/test/header_filter_regex_test.dart b/tools/clang_tidy/test/header_filter_regex_test.dart index a39cacf4ccf9b..4a700bac8dae7 100644 --- a/tools/clang_tidy/test/header_filter_regex_test.dart +++ b/tools/clang_tidy/test/header_filter_regex_test.dart @@ -38,6 +38,7 @@ void main() { const Set intentionallyOmitted = { '.git', '.github', + 'build_overrides', 'prebuilts', 'third_party', }; diff --git a/tools/licenses/lib/paths.dart b/tools/licenses/lib/paths.dart index 38cdfe7851eb6..6725109499466 100644 --- a/tools/licenses/lib/paths.dart +++ b/tools/licenses/lib/paths.dart @@ -21,6 +21,7 @@ final Set skippedPaths = { r'build_overrides', // only used by build r'buildtools', // only used by build r'flutter/build', + r'flutter/build_overrides', // only used by build r'flutter/ci', r'flutter/docs', r'flutter/flutter_frontend_server',