Skip to content

Commit 71d8edb

Browse files
Always build GTK shell (flutter#17634)
1 parent f779f09 commit 71d8edb

File tree

7 files changed

+536
-279
lines changed

7 files changed

+536
-279
lines changed

DEPS

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ allowed_hosts = [
139139
]
140140

141141
deps = {
142-
'src': 'https://github.com/flutter/buildroot.git' + '@' + '0c64fd23eeedbad60c2bfa294710cd587ccb7c27',
142+
'src': 'https://github.com/flutter/buildroot.git' + '@' + '036715c76da60220b39312ea066cd65d32c2157d',
143143

144144
# Fuchsia compatibility
145145
#
@@ -179,6 +179,9 @@ deps = {
179179
'src/third_party/icu':
180180
Var('chromium_git') + '/chromium/deps/icu.git' + '@' + '5005010d694e16571b8dfbf07d70817841f80a69',
181181

182+
'src/third_party/khronos':
183+
Var('chromium_git') + '/chromium/src/third_party/khronos.git' + '@' + '7122230e90547962e0f0c627f62eeed3c701f275',
184+
182185
'src/third_party/boringssl':
183186
Var('github_git') + '/dart-lang/boringssl_gen.git' + '@' + Var('dart_boringssl_gen_rev'),
184187

ci/licenses_golden/licenses_gpu

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
Signature: ffe64a3daaf0ad982854594ad155dd56
2+
3+
UNUSED LICENSES:
4+
5+
6+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
7+
USED LICENSES:
8+
9+
====================================================================================================
10+
LIBRARY: gpu
11+
ORIGIN: ../../../flutter/LICENSE
12+
TYPE: LicenseType.bsd
13+
FILE: ../../../gpu/GLES2/gl2chromium.h
14+
FILE: ../../../gpu/command_buffer/client/gles2_c_lib_export.h
15+
----------------------------------------------------------------------------------------------------
16+
Copyright 2013 The Flutter Authors. All rights reserved.
17+
18+
Redistribution and use in source and binary forms, with or without modification,
19+
are permitted provided that the following conditions are met:
20+
21+
* Redistributions of source code must retain the above copyright
22+
notice, this list of conditions and the following disclaimer.
23+
* Redistributions in binary form must reproduce the above
24+
copyright notice, this list of conditions and the following
25+
disclaimer in the documentation and/or other materials provided
26+
with the distribution.
27+
* Neither the name of Google Inc. nor the names of its
28+
contributors may be used to endorse or promote products derived
29+
from this software without specific prior written permission.
30+
31+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
32+
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
33+
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
34+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
35+
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
36+
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
37+
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
38+
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
39+
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
40+
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
41+
====================================================================================================
42+
Total license count: 1

ci/licenses_golden/licenses_third_party

Lines changed: 250 additions & 122 deletions
Large diffs are not rendered by default.

shell/platform/linux/BUILD.gn

Lines changed: 40 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -5,23 +5,19 @@
55
assert(is_linux)
66

77
import("//flutter/shell/platform/glfw/config.gni")
8-
import("//flutter/shell/platform/linux/config.gni")
98

109
group("linux") {
11-
deps = []
10+
deps = [
11+
":flutter_linux_gtk",
12+
":publish_headers_linux",
13+
]
1214
if (build_glfw_shell) {
1315
deps += [
1416
":flutter_linux_glfw",
1517
"//flutter/shell/platform/glfw:publish_headers_glfw",
1618
"//flutter/shell/platform/glfw/client_wrapper:publish_wrapper_glfw",
1719
]
1820
}
19-
if (build_linux_shell) {
20-
deps += [
21-
":flutter_linux_gtk",
22-
":publish_headers_linux",
23-
]
24-
}
2521
}
2622

2723
# Temporary workaround for the issue describe in
@@ -46,50 +42,49 @@ if (build_glfw_shell) {
4642
}
4743
}
4844

49-
if (build_linux_shell) {
50-
_public_headers = [
51-
"public/flutter_linux/fl_dart_project.h",
52-
"public/flutter_linux/fl_view.h",
53-
"public/flutter_linux/flutter_linux.h",
54-
]
45+
_public_headers = [
46+
"public/flutter_linux/fl_dart_project.h",
47+
"public/flutter_linux/fl_view.h",
48+
"public/flutter_linux/flutter_linux.h",
49+
]
5550

56-
config("relative_flutter_linux_headers") {
57-
include_dirs = [ "public" ]
58-
}
51+
config("relative_flutter_linux_headers") {
52+
include_dirs = [ "public" ]
53+
}
5954

60-
source_set("flutter_linux") {
61-
public = _public_headers
55+
source_set("flutter_linux") {
56+
public = _public_headers
6257

63-
sources = [
64-
"fl_dart_project.cc",
65-
"fl_view.cc",
66-
]
58+
sources = [
59+
"fl_dart_project.cc",
60+
"fl_view.cc",
61+
]
6762

68-
configs += [
69-
"//flutter/shell/platform/linux/config:gtk",
70-
"//flutter/shell/platform/linux/config:egl",
71-
]
63+
configs += [
64+
"//flutter/shell/platform/linux/config:gtk",
65+
"//flutter/shell/platform/linux/config:egl",
66+
"//third_party/khronos:khronos_headers",
67+
]
7268

73-
# Set flag to stop headers being directly included (library users should not do this)
74-
defines = [ "FLUTTER_LINUX_COMPILATION" ]
69+
# Set flag to stop headers being directly included (library users should not do this)
70+
defines = [ "FLUTTER_LINUX_COMPILATION" ]
7571

76-
deps = [
77-
"//flutter/shell/platform/embedder:embedder_with_symbol_prefix",
78-
]
79-
}
72+
deps = [
73+
"//flutter/shell/platform/embedder:embedder_with_symbol_prefix",
74+
]
75+
}
8076

81-
shared_library("flutter_linux_gtk") {
82-
deps = [
83-
":flutter_linux",
84-
]
77+
shared_library("flutter_linux_gtk") {
78+
deps = [
79+
":flutter_linux",
80+
]
8581

86-
public_configs = [ "//flutter:config" ]
87-
}
82+
public_configs = [ "//flutter:config" ]
83+
}
8884

89-
copy("publish_headers_linux") {
90-
sources = _public_headers
91-
outputs = [
92-
"$root_out_dir/flutter_linux/{{source_file_part}}",
93-
]
94-
}
85+
copy("publish_headers_linux") {
86+
sources = _public_headers
87+
outputs = [
88+
"$root_out_dir/flutter_linux/{{source_file_part}}",
89+
]
9590
}

shell/platform/linux/config.gni

Lines changed: 0 additions & 11 deletions
This file was deleted.

shell/platform/linux/config/BUILD.gn

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

55
import("//build/config/linux/pkg_config.gni")
6-
import("//flutter/shell/platform/linux/config.gni")
76

87
pkg_config("x11") {
98
packages = [ "x11" ]
109
}
1110

12-
if (build_linux_shell) {
13-
pkg_config("gtk") {
14-
packages = [ "gtk+-3.0" ]
15-
}
16-
pkg_config("egl") {
17-
packages = [ "egl" ]
18-
}
11+
pkg_config("gtk") {
12+
packages = [ "gtk+-3.0" ]
13+
}
14+
15+
pkg_config("egl") {
16+
packages = [ "egl" ]
1917
}

0 commit comments

Comments
 (0)