Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions lib/snapshot/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

import("//build/compiled_action.gni")
import("//build/fuchsia/sdk.gni")
import("//flutter/build/zip_bundle.gni")
import("//flutter/common/config.gni")
import("//flutter/lib/ui/dart_ui.gni")
import("//flutter/sky/tools/macos_snapshots.gni")
Expand Down Expand Up @@ -290,3 +291,16 @@ compile_platform("strong_platform") {
group("kernel_platform_files") {
public_deps = [ ":strong_platform" ]
}

if (is_win) {
zip_bundle("archive_win_gen_snapshot") {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Who is the caller of this target definition? Is this patch complete?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was for experimenting with building the windows archives but we are currently blocked on arm support.

deps = [ "//third_party/dart/runtime/bin:gen_snapshot" ]
output = "$target_platform_name-$target_cpu-$flutter_runtime_mode/windows-x64.zip"
files = [
{
source = "$root_out_dir/gen_snapshot.exe"
destination = "gen_snapshot.exe"
},
]
}
}
6 changes: 0 additions & 6 deletions tools/gn
Original file line number Diff line number Diff line change
Expand Up @@ -288,12 +288,6 @@ def to_gn_args(args):
gn_args['target_cpu'] = get_target_cpu(args)
gn_args['dart_target_arch'] = gn_args['target_cpu']

# No cross-compilation on Windows (for now). Use host toolchain that
# matches the bit-width of the target architecture.
if sys.platform.startswith(('cygwin', 'win')) and args.target_os != 'win':
gn_args['host_cpu'] = cpu_for_target_arch(gn_args['target_cpu'])
gn_args['target_cpu'] = cpu_for_target_arch(gn_args['target_cpu'])

# macOS host builds (whether x64 or arm64) must currently be built under
# Rosetta on Apple Silicon Macs.
# TODO(cbracken): https://github.com/flutter/flutter/issues/103386
Expand Down