Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit ec2c624

Browse files
authored
Revert "Add support for the Metal backend on all iOS builds. (#17080)" (#17088)
This reverts commit e8e0e0b.
1 parent c6aa4d2 commit ec2c624

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

tools/gn

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,9 @@ def get_out_dir(args):
4444
if args.enable_vulkan:
4545
target_dir.append('vulkan')
4646

47+
if args.enable_metal and args.target_os == 'ios':
48+
target_dir.append('metal')
49+
4750
return os.path.join(args.out_dir, 'out', '_'.join(target_dir))
4851

4952
def to_command_line(gn_args):
@@ -216,18 +219,17 @@ def to_gn_args(args):
216219
gn_args['use_goma'] = False
217220
gn_args['goma_dir'] = None
218221

222+
if args.enable_metal:
223+
gn_args['skia_use_metal'] = True
224+
gn_args['shell_enable_metal'] = True
225+
gn_args['allow_deprecated_api_calls'] = True
226+
219227
if args.enable_vulkan:
220228
# Enable vulkan in the Flutter shell.
221229
gn_args['shell_enable_vulkan'] = True
222230
# Configure Skia for Vulkan support.
223231
gn_args['skia_use_vulkan'] = True
224232

225-
# Enable Metal on non-simulator iOS builds.
226-
if args.target_os == 'ios':
227-
gn_args['skia_use_metal'] = not args.simulator
228-
gn_args['shell_enable_metal'] = not args.simulator
229-
gn_args['allow_deprecated_api_calls'] = not args.simulator
230-
231233
# The buildroot currently isn't set up to support Vulkan in the
232234
# Windows ANGLE build, so disable it regardless of enable_vulkan's value.
233235
if sys.platform.startswith(('cygwin', 'win')):

0 commit comments

Comments
 (0)