Skip to content

Commit 58bd79e

Browse files
committed
[Tizen] Cherrypicks from flutter-3.27.1 of flutter-tizen/engine
1 parent be698c4 commit 58bd79e

File tree

8 files changed

+19
-28
lines changed

8 files changed

+19
-28
lines changed

DEPS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ vars = {
127127
"checkout_llvm": False,
128128

129129
# Setup Git hooks by default.
130-
'setup_githooks': True,
130+
'setup_githooks': False,
131131

132132
# When this is true, the Flutter Engine's configuration files and scripts for
133133
# RBE will be downloaded from CIPD. This option is only usable by Googlers.

engine/src/flutter/common/config.gni

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,4 @@ if (flutter_prebuilt_dart_sdk) {
157157
# TODO: We can't build the engine artifacts for arm (32-bit) right now;
158158
# see https://github.com/flutter/flutter/issues/74322.
159159
build_engine_artifacts =
160-
flutter_build_engine_artifacts && !is_android &&
161-
(current_toolchain == host_toolchain ||
162-
(is_linux && !is_chromeos && current_cpu != "arm") || is_mac || is_win)
160+
flutter_build_engine_artifacts && current_toolchain == host_toolchain

engine/src/flutter/display_list/testing/BUILD.gn

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ surface_provider_include_software = !is_android && !is_ios
3131
# But, since benchmarks do not run on Windows and rendertests only
3232
# runs on SW by default, this restriction currently only limits the
3333
# ability to manually cross-check OpenGL on Windows for rendertests
34-
surface_provider_include_gl = !is_fuchsia && !is_ios && !is_win && !is_mac
34+
surface_provider_include_gl =
35+
!is_fuchsia && !is_ios && !is_win && !is_mac && !is_linux
3536

3637
# TODO (https://github.com/flutter/flutter/issues/107357):
3738
# impeller_enable_vulkan currently requires skia to not use VMA, which in turn

engine/src/flutter/impeller/tools/args.gni

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ declare_args() {
1717
enable_unittests) && target_os != "fuchsia"
1818

1919
# Whether the Vulkan backend is enabled.
20-
impeller_enable_vulkan = (is_linux || is_win || is_android || is_mac ||
20+
impeller_enable_vulkan = (is_win || is_android || is_mac ||
2121
enable_unittests) && target_os != "fuchsia"
2222
}
2323

engine/src/flutter/shell/config.gni

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,6 @@ declare_args() {
1717
test_enable_metal = shell_enable_metal
1818

1919
# The Vulkan unittests are combined with the GL unittests.
20-
test_enable_vulkan = is_fuchsia || shell_enable_gl
20+
test_enable_vulkan = is_fuchsia
2121
test_enable_software = shell_enable_software
2222
}

engine/src/flutter/testing/BUILD.gn

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ source_set("testing") {
5353

5454
if (enable_unittests && is_linux) {
5555
# So that we can call gtk_init in main().
56-
configs += [ "//flutter/shell/platform/linux/config:gtk" ]
56+
# configs += [ "//flutter/shell/platform/linux/config:gtk" ]
5757
}
5858

5959
public_deps = [ ":testing_lib" ]

engine/src/flutter/tools/gn

Lines changed: 11 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -89,18 +89,7 @@ def to_command_line(gn_args):
8989

9090

9191
def is_host_build(args):
92-
# If target_os == None, then this is a host build.
93-
if args.target_os is None:
94-
return True
95-
# For linux arm64 builds, we cross compile from x64 hosts, so the
96-
# target_os='linux' and linux-cpu='arm64'
97-
if args.target_os == 'linux' and args.linux_cpu == 'arm64':
98-
return True
99-
# The Mac and host targets are redundant. Again, necessary to disambiguate
100-
# during cross-compilation.
101-
if args.target_os == 'mac':
102-
return True
103-
return False
92+
return args.target_os is None
10493

10594

10695
# Determines whether a prebuilt Dart SDK can be used instead of building one.
@@ -502,7 +491,7 @@ def to_gn_args(args):
502491
# does not exist. Further, we set the 'host_cpu' so that it shares the
503492
# bitwidth of the 32-bit arm target.
504493
if sys.platform.startswith(
505-
('cygwin', 'win')) and args.target_os == 'android' and gn_args['target_cpu'] == 'arm':
494+
('cygwin', 'win')) and args.target_os != 'win' and gn_args['target_cpu'] == 'arm':
506495
gn_args['host_cpu'] = 'x86'
507496
gn_args['current_cpu'] = 'x86'
508497

@@ -599,7 +588,7 @@ def to_gn_args(args):
599588
else:
600589
gn_args['skia_use_gl'] = args.target_os != 'fuchsia'
601590

602-
if sys.platform == 'darwin' and args.target_os not in ['android', 'fuchsia']:
591+
if sys.platform == 'darwin' and args.target_os not in ['android', 'fuchsia', 'linux']:
603592
# OpenGL is deprecated on macOS > 10.11.
604593
# This is not necessarily needed but enabling this until we have a way to
605594
# build a macOS metal only shell and a gl only shell.
@@ -610,7 +599,7 @@ def to_gn_args(args):
610599
# Enable Vulkan on all platforms except for iOS. This is just
611600
# to save on mobile binary size, as there's no reason the Vulkan embedder
612601
# features can't work on these platforms.
613-
if gn_args['target_os'] not in ['ios', 'mac']:
602+
if gn_args['target_os'] not in ['ios', 'mac', 'linux']:
614603
gn_args['skia_use_vulkan'] = True
615604
gn_args['skia_use_vma'] = False
616605
gn_args['shell_enable_vulkan'] = True
@@ -711,13 +700,17 @@ def to_gn_args(args):
711700

712701
# Enable pointer compression on 64-bit mobile targets. iOS is excluded due to
713702
# its inability to allocate address space without allocating memory.
714-
if args.target_os in ['android'] and gn_args['target_cpu'] in ['x64', 'arm64']:
703+
if args.target_os in ['android', 'linux'] and gn_args['target_cpu'] in ['x64', 'arm64']:
715704
gn_args['dart_use_compressed_pointers'] = True
716705

717706
if args.target_os == 'fuchsia':
718707
gn_args['gn_configs_path'] = '//flutter/build/config/fuchsia/gn_configs.gni'
719708
gn_args['fuchsia_gn_sdk'] = '//flutter/tools/fuchsia/gn-sdk'
720709

710+
# Don't use the default Linux sysroot when buliding for Linux on macOS.
711+
if sys.platform == 'darwin' and args.target_os == 'linux':
712+
gn_args['use_default_linux_sysroot'] = False
713+
721714
# Flags for Dart features:
722715
if args.use_mallinfo2:
723716
gn_args['dart_use_mallinfo2'] = args.use_mallinfo2
@@ -743,9 +736,8 @@ def to_gn_args(args):
743736
# gen_snapshot, but the build defines otherwise make it look like the build is
744737
# for a host Windows build and make GN think we will be building ANGLE.
745738
# Angle is not used on Mac hosts as there are no tests for the OpenGL backend.
746-
if is_host_build(args) or (args.target_os == 'android' and get_host_os() == 'win'):
747-
# Don't include git commit information.
748-
gn_args['angle_enable_commit_id'] = False
739+
if (is_host_build(args) and gn_args['host_os'] != 'mac') or (args.target_os == 'linux' and
740+
get_host_os() == 'win'):
749741
# Do not build unnecessary parts of the ANGLE tree.
750742
gn_args['angle_build_all'] = False
751743
gn_args['angle_has_astc_encoder'] = False

engine/src/flutter/txt/src/txt/platform_linux.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
namespace txt {
2020

2121
std::vector<std::string> GetDefaultFontFamilies() {
22-
return {"Ubuntu", "Cantarell", "DejaVu Sans", "Liberation Sans", "Arial"};
22+
return {"TizenDefaultFont", "SamsungOneUI"};
2323
}
2424

2525
sk_sp<SkFontMgr> GetDefaultFontManager(uint32_t font_initialization_data) {

0 commit comments

Comments
 (0)