From b45a8f464d67ee3733cd5d485606285fc993afdf Mon Sep 17 00:00:00 2001 From: Greg Spencer Date: Thu, 21 Feb 2019 08:47:24 -0800 Subject: [PATCH] Revert "Remove unused --packages argument to gen_snapshot. (#28101)" (#28265) This reverts commit 1c021506df23434dd5e881ba0e4d8c5a9f88df8d. The pre-commit tests never actually ran, so it looked green when it wasn't. This breaks 16 tests that depend on the argument existing, even though it isn't actually used. --- packages/flutter_tools/lib/src/base/build.dart | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/flutter_tools/lib/src/base/build.dart b/packages/flutter_tools/lib/src/base/build.dart index 8e60120428..7be3b8c203 100644 --- a/packages/flutter_tools/lib/src/base/build.dart +++ b/packages/flutter_tools/lib/src/base/build.dart @@ -46,11 +46,13 @@ class GenSnapshot { Future run({ @required SnapshotType snapshotType, + @required String packagesPath, IOSArch iosArch, Iterable additionalArgs = const [], }) { final List args = [ '--causal_async_stacks', + '--packages=$packagesPath', ]..addAll(additionalArgs); final String snapshotterPath = getSnapshotterPath(snapshotType); @@ -191,6 +193,7 @@ class AOTSnapshotter { final SnapshotType snapshotType = SnapshotType(platform, buildMode); final int genSnapshotExitCode = await genSnapshot.run( snapshotType: snapshotType, + packagesPath: packageMap.packagesPath, additionalArgs: genSnapshotArgs, iosArch: iosArch, ); @@ -534,6 +537,7 @@ class JITSnapshotter { final SnapshotType snapshotType = SnapshotType(platform, buildMode); final int genSnapshotExitCode = await genSnapshot.run( snapshotType: snapshotType, + packagesPath: packagesPath, additionalArgs: genSnapshotArgs, ); if (genSnapshotExitCode != 0) {