forked from firka/flutter
Update buildtools to latest, account for GN updates and use Clang on Android. (flutter/engine#3064)
This commit is contained in:
@@ -3,6 +3,11 @@
|
||||
# found in the LICENSE file.
|
||||
|
||||
import("//mojo/dart/packages/mojo/sdk_ext_sources.gni")
|
||||
import("//flutter/common/config.gni") # for flutter_aot
|
||||
|
||||
if (target_os == "ios") {
|
||||
import("//build/config/ios/ios_sdk.gni") # For use_ios_simulator
|
||||
}
|
||||
|
||||
dart_host_toolchain = host_toolchain
|
||||
|
||||
|
||||
@@ -12,8 +12,8 @@
|
||||
#include "lib/tonic/dart_state.h"
|
||||
|
||||
namespace blink {
|
||||
struct DartJniIsolateData;
|
||||
class FontSelector;
|
||||
class DartJniIsolateData;
|
||||
class MojoServices;
|
||||
class Window;
|
||||
|
||||
|
||||
@@ -63,6 +63,7 @@ source_set("common") {
|
||||
"//mojo/public/cpp/bindings:utility",
|
||||
"//mojo/public/interfaces/application",
|
||||
"//mojo/services/vsync/interfaces",
|
||||
"//third_party/libjpeg",
|
||||
":generate_embedder_diagnostic_server_resources_cc",
|
||||
]
|
||||
}
|
||||
|
||||
@@ -41,18 +41,21 @@ executable("shell_standalone") {
|
||||
]
|
||||
}
|
||||
|
||||
resource_copy_mac("mac_desktop_resources") {
|
||||
app_name = "SkyShell"
|
||||
|
||||
resources = [
|
||||
"//third_party/icu/android/icudtl.dat",
|
||||
]
|
||||
|
||||
bundle_directory = "."
|
||||
}
|
||||
|
||||
mac_app("shell_application_bundle") {
|
||||
app_name = "SkyShell"
|
||||
info_plist = "Info.plist"
|
||||
xibs = [ "sky_mac.xib" ]
|
||||
|
||||
resource_copy_mac("mac_desktop_resources") {
|
||||
resources = [
|
||||
"//third_party/icu/android/icudtl.dat",
|
||||
]
|
||||
bundle_directory = "."
|
||||
}
|
||||
|
||||
deps = [
|
||||
":mac_desktop_platform",
|
||||
":mac_desktop_resources",
|
||||
|
||||
@@ -7,6 +7,8 @@ assert(is_ios)
|
||||
import("//build/config/ios/rules.gni")
|
||||
import("//build/config/ios/ios_sdk.gni")
|
||||
|
||||
_flutter_framework_dir = "$root_out_dir/Flutter.framework"
|
||||
|
||||
shared_library("flutter_framework_dylib") {
|
||||
visibility = [ ":*" ]
|
||||
|
||||
@@ -79,77 +81,75 @@ shared_library("flutter_framework_dylib") {
|
||||
]
|
||||
}
|
||||
|
||||
copy("framework_dylib") {
|
||||
visibility = [ ":*" ]
|
||||
sources = [ "$root_out_dir/libFlutter.dylib" ]
|
||||
outputs = [ "$_flutter_framework_dir/Flutter" ]
|
||||
|
||||
deps = [
|
||||
":flutter_framework_dylib",
|
||||
]
|
||||
}
|
||||
|
||||
action("framework_install_name") {
|
||||
visibility = [ ":*" ]
|
||||
stamp_file = "$root_out_dir/flutter_install_name_stamp"
|
||||
script = "//flutter/sky/tools/change_install_name.py"
|
||||
|
||||
inputs = [ "$_flutter_framework_dir/Flutter" ]
|
||||
outputs = [ stamp_file ]
|
||||
|
||||
args = [
|
||||
"--dylib",
|
||||
rebase_path("$_flutter_framework_dir/Flutter"),
|
||||
"--install_name",
|
||||
"@rpath/Flutter.framework/Flutter",
|
||||
"--stamp",
|
||||
rebase_path(stamp_file),
|
||||
]
|
||||
|
||||
deps = [
|
||||
":framework_dylib"
|
||||
]
|
||||
}
|
||||
|
||||
copy("framework_info_plist") {
|
||||
visibility = [ ":*" ]
|
||||
sources = [ "framework/Info.plist" ]
|
||||
outputs = [ "$_flutter_framework_dir/Info.plist" ]
|
||||
}
|
||||
|
||||
copy("framework_module_map") {
|
||||
visibility = [ ":*" ]
|
||||
sources = [ "framework/module.modulemap" ]
|
||||
outputs = [ "$_flutter_framework_dir/Modules/module.modulemap" ]
|
||||
}
|
||||
|
||||
copy("framework_headers") {
|
||||
visibility = [ ":*" ]
|
||||
sources = [
|
||||
"framework/Headers/Flutter.h",
|
||||
"framework/Headers/FlutterAppDelegate.h",
|
||||
"framework/Headers/FlutterAsyncMessageListener.h",
|
||||
"framework/Headers/FlutterDartProject.h",
|
||||
"framework/Headers/FlutterMacros.h",
|
||||
"framework/Headers/FlutterMessageListener.h",
|
||||
"framework/Headers/FlutterViewController.h",
|
||||
]
|
||||
outputs = [ "$_flutter_framework_dir/Headers/{{source_file_part}}" ]
|
||||
}
|
||||
|
||||
copy("framework_icu") {
|
||||
visibility = [ ":*" ]
|
||||
set_sources_assignment_filter([])
|
||||
sources = [
|
||||
"//third_party/icu/android/icudtl.dat",
|
||||
]
|
||||
set_sources_assignment_filter(sources_assignment_filter)
|
||||
outputs = [ "$_flutter_framework_dir/{{source_file_part}}" ]
|
||||
}
|
||||
|
||||
group("flutter_framework") {
|
||||
framework_dir = "$root_out_dir/Flutter.framework"
|
||||
|
||||
copy("framework_dylib") {
|
||||
visibility = [ ":*" ]
|
||||
sources = [ "$root_out_dir/libFlutter.dylib" ]
|
||||
outputs = [ "$framework_dir/Flutter" ]
|
||||
|
||||
deps = [
|
||||
":flutter_framework_dylib",
|
||||
]
|
||||
}
|
||||
|
||||
action("framework_install_name") {
|
||||
visibility = [ ":*" ]
|
||||
stamp_file = "$root_out_dir/flutter_install_name_stamp"
|
||||
script = "//flutter/sky/tools/change_install_name.py"
|
||||
|
||||
inputs = [ "$framework_dir/Flutter" ]
|
||||
outputs = [ stamp_file ]
|
||||
|
||||
args = [
|
||||
"--dylib",
|
||||
rebase_path("$framework_dir/Flutter"),
|
||||
"--install_name",
|
||||
"@rpath/Flutter.framework/Flutter",
|
||||
"--stamp",
|
||||
rebase_path(stamp_file),
|
||||
]
|
||||
|
||||
deps = [
|
||||
":framework_dylib"
|
||||
]
|
||||
}
|
||||
|
||||
copy("framework_info_plist") {
|
||||
visibility = [ ":*" ]
|
||||
sources = [ "framework/Info.plist" ]
|
||||
outputs = [ "$framework_dir/Info.plist" ]
|
||||
}
|
||||
|
||||
copy("framework_module_map") {
|
||||
visibility = [ ":*" ]
|
||||
sources = [ "framework/module.modulemap" ]
|
||||
outputs = [ "$framework_dir/Modules/module.modulemap" ]
|
||||
}
|
||||
|
||||
copy("framework_headers") {
|
||||
visibility = [ ":*" ]
|
||||
sources = [
|
||||
"framework/Headers/Flutter.h",
|
||||
"framework/Headers/FlutterAppDelegate.h",
|
||||
"framework/Headers/FlutterAsyncMessageListener.h",
|
||||
"framework/Headers/FlutterDartProject.h",
|
||||
"framework/Headers/FlutterMacros.h",
|
||||
"framework/Headers/FlutterMessageListener.h",
|
||||
"framework/Headers/FlutterViewController.h",
|
||||
]
|
||||
outputs = [ "$framework_dir/Headers/{{source_file_part}}" ]
|
||||
}
|
||||
|
||||
copy("framework_icu") {
|
||||
visibility = [ ":*" ]
|
||||
set_sources_assignment_filter([])
|
||||
sources = [
|
||||
"//third_party/icu/android/icudtl.dat",
|
||||
]
|
||||
set_sources_assignment_filter(sources_assignment_filter)
|
||||
outputs = [ "$framework_dir/{{source_file_part}}" ]
|
||||
}
|
||||
|
||||
public_deps = [
|
||||
":framework_dylib",
|
||||
":framework_headers",
|
||||
|
||||
@@ -484,7 +484,7 @@ component("skia") {
|
||||
configs += [ "//build/config/compiler:optimize_max" ]
|
||||
}
|
||||
|
||||
if (use_glfw) {
|
||||
if (is_linux) {
|
||||
deps += [ "//third_party/glfw" ]
|
||||
}
|
||||
}
|
||||
|
||||
2
engine/src/flutter/sky/dist/BUILD.gn
vendored
2
engine/src/flutter/sky/dist/BUILD.gn
vendored
@@ -41,6 +41,7 @@ if (is_android) {
|
||||
|
||||
deps = [
|
||||
"//flutter/sky/packages/sky_engine",
|
||||
"//flutter/sky/packages/sky_engine:sky_engine_pkg_helper",
|
||||
]
|
||||
}
|
||||
|
||||
@@ -62,6 +63,7 @@ if (is_android) {
|
||||
|
||||
deps = [
|
||||
"//flutter/sky/packages/sky_services",
|
||||
"//flutter/sky/packages/sky_services:sky_services_pkg_helper",
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,7 +47,7 @@ def to_gn_args(args):
|
||||
gn_args = {}
|
||||
|
||||
gn_args['is_debug'] = args.unoptimized
|
||||
gn_args['is_clang'] = args.clang and args.target_os not in ['android']
|
||||
gn_args['is_clang'] = True
|
||||
|
||||
ios_target_cpu = 'arm64'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user