Unverified Commit ac8b906c authored by Chris Bracken's avatar Chris Bracken Committed by GitHub

Eliminate support for Dart 1 in AOT snapshotter (#21388)

parent ed0b8be0
......@@ -75,7 +75,6 @@ class AOTSnapshotter {
@required String mainPath,
@required String packagesPath,
@required String outputPath,
@required bool previewDart2,
@required bool buildSharedLibrary,
IOSArch iosArch,
List<String> extraGenSnapshotOptions = const <String>[],
......@@ -130,13 +129,11 @@ class AOTSnapshotter {
'--embedder_entry_points_manifest=$vmEntryPoints',
'--embedder_entry_points_manifest=$ioEntryPoints',
];
if (previewDart2) {
genSnapshotArgs.addAll(<String>[
'--reify-generic-functions',
'--strong',
'--sync-async',
]);
}
genSnapshotArgs.addAll(<String>[
'--reify-generic-functions',
'--strong',
'--sync-async',
]);
if (extraGenSnapshotOptions != null && extraGenSnapshotOptions.isNotEmpty) {
printTrace('Extra gen_snapshot options: $extraGenSnapshotOptions');
genSnapshotArgs.addAll(extraGenSnapshotOptions);
......@@ -191,7 +188,6 @@ class AOTSnapshotter {
'buildMode': buildMode.toString(),
'targetPlatform': platform.toString(),
'entryPoint': mainPath,
'dart2': previewDart2.toString(),
'sharedLib': buildSharedLibrary.toString(),
'extraGenSnapshotOptions': extraGenSnapshotOptions.join(' '),
},
......
......@@ -110,7 +110,6 @@ class BuildAotCommand extends BuildSubCommand {
mainPath: mainPath,
packagesPath: PackageMap.globalPackagesPath,
outputPath: outputPath,
previewDart2: true,
buildSharedLibrary: false,
extraGenSnapshotOptions: argResults[FlutterOptions.kExtraGenSnapshotOptions],
).then((int buildExitCode) {
......@@ -141,7 +140,6 @@ class BuildAotCommand extends BuildSubCommand {
mainPath: mainPath,
packagesPath: PackageMap.globalPackagesPath,
outputPath: outputPath,
previewDart2: true,
buildSharedLibrary: argResults['build-shared-library'],
extraGenSnapshotOptions: argResults[FlutterOptions.kExtraGenSnapshotOptions],
);
......
......@@ -146,7 +146,6 @@ void main() {
packagesPath: '.packages',
outputPath: outputPath,
buildSharedLibrary: false,
previewDart2: true,
), isNot(equals(0)));
}, overrides: contextOverrides);
......@@ -159,7 +158,6 @@ void main() {
packagesPath: '.packages',
outputPath: outputPath,
buildSharedLibrary: false,
previewDart2: true,
), isNot(0));
}, overrides: contextOverrides);
......@@ -172,7 +170,6 @@ void main() {
packagesPath: '.packages',
outputPath: outputPath,
buildSharedLibrary: false,
previewDart2: true,
), isNot(0));
}, overrides: contextOverrides);
......@@ -198,7 +195,6 @@ void main() {
packagesPath: '.packages',
outputPath: outputPath,
buildSharedLibrary: false,
previewDart2: true,
iosArch: IOSArch.armv7,
);
......@@ -245,7 +241,6 @@ void main() {
packagesPath: '.packages',
outputPath: outputPath,
buildSharedLibrary: false,
previewDart2: true,
iosArch: IOSArch.arm64,
);
......@@ -293,7 +288,6 @@ void main() {
packagesPath: '.packages',
outputPath: outputPath,
buildSharedLibrary: false,
previewDart2: true,
);
expect(genSnapshotExitCode, 0);
......@@ -345,7 +339,6 @@ void main() {
packagesPath: '.packages',
outputPath: outputPath,
buildSharedLibrary: false,
previewDart2: true,
);
expect(genSnapshotExitCode, 0);
......@@ -392,7 +385,6 @@ void main() {
packagesPath: '.packages',
outputPath: outputPath,
buildSharedLibrary: false,
previewDart2: true,
iosArch: IOSArch.armv7,
);
......@@ -439,7 +431,6 @@ void main() {
packagesPath: '.packages',
outputPath: outputPath,
buildSharedLibrary: false,
previewDart2: true,
iosArch: IOSArch.arm64,
);
......@@ -474,7 +465,6 @@ void main() {
packagesPath: '.packages',
outputPath: outputPath,
buildSharedLibrary: true,
previewDart2: true,
);
expect(genSnapshotExitCode, isNot(0));
......@@ -506,7 +496,6 @@ void main() {
packagesPath: '.packages',
outputPath: outputPath,
buildSharedLibrary: false,
previewDart2: true,
);
expect(genSnapshotExitCode, 0);
......@@ -558,7 +547,6 @@ void main() {
packagesPath: '.packages',
outputPath: outputPath,
buildSharedLibrary: false,
previewDart2: true,
);
expect(genSnapshotExitCode, 0);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment