Skip to content

Commit c5cdbeb

Browse files
committed
Reject --use-tcore on Tizen <10 and fix transitive includes
Three independent fixes that surfaced when somebody tried 'tools/gn --use-tcore --api-version 6.5': 1. tools/gn now rejects --use-tcore for api_version < 10.0 with a clear error message. The tizen-core / tizen-core-imf / tizen-core-wl packages are only published in the Tizen 11+ repository, so building the use_tcore variant against a 6.5/8.0 sysroot can never succeed. 2. Move '#include <tizen_core_wl.h>' from tizen_input_method_context_tcore.h to the .cc. The public interface only exposes tizen_core_imf_* types (events go through void*), so the .h does not need the wl header. This also stops the header from blowing up earlier-than-necessary when somebody mis-configures the build. 3. external_texture_surface_vulkan_buffer_dma.cc: add explicit '#include <unistd.h>' for close(). The Tizen 11 gcc 14 stdlib no longer pulls it in transitively, so the experimental Vulkan target failed to compile against sysroot-11.0.
1 parent c8fe16a commit c5cdbeb

4 files changed

Lines changed: 15 additions & 1 deletion

File tree

flutter/shell/platform/tizen/external_texture_surface_vulkan_buffer_dma.cc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
// found in the LICENSE file.
44

55
#include "flutter/shell/platform/tizen/external_texture_surface_vulkan_buffer_dma.h"
6+
7+
#include <unistd.h>
8+
69
#include "flutter/shell/platform/tizen/logger.h"
710

811
namespace flutter {

flutter/shell/platform/tizen/tizen_input_method_context_tcore.cc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44

55
#include "tizen_input_method_context_tcore.h"
66

7+
#include <tizen_core_wl.h>
8+
79
#include "flutter/shell/platform/tizen/logger.h"
810

911
namespace {

flutter/shell/platform/tizen/tizen_input_method_context_tcore.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
#define EMBEDDER_TIZEN_INPUT_METHOD_CONTEXT_H_
77

88
#include <tizen_core_imf.h>
9-
#include <tizen_core_wl.h>
109

1110
#include <functional>
1211
#include <string>

tools/gn

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,16 @@ def parse_args(args):
120120
def main():
121121
args = parse_args(sys.argv)
122122

123+
if args.use_tcore:
124+
try:
125+
api_value = float(args.api_version)
126+
except ValueError:
127+
api_value = 0.0
128+
if api_value < 10.0:
129+
sys.exit('--use-tcore requires --api-version 10.0 or higher '
130+
'(tizen-core packages are only published for Tizen 11+). '
131+
'Got --api-version {}.'.format(args.api_version))
132+
123133
root_dir = Path(__file__).parent.parent.resolve()
124134
gn = root_dir / 'third_party' / 'gn' / 'gn'
125135
command = [gn, 'gen', '--check', '--export-compile-commands']

0 commit comments

Comments
 (0)