Commit 52fbcefe authored by Alexander Aprelev's avatar Alexander Aprelev Committed by GitHub

Link platform.dill only into app kernel file used for build aot. (#12571)

gen_snapshot loads all packages from single app kernel file.
parent 1f82733a
......@@ -307,6 +307,7 @@ Future<String> _buildAotSnapshot(
sdkRoot: artifacts.getArtifactPath(Artifact.flutterPatchedSdkPath),
mainPath: mainPath,
extraFrontEndOptions: extraFrontEndOptions,
linkPlatformKernelIn : true,
);
}
......
......@@ -59,6 +59,7 @@ class _StdoutHandler {
Future<String> compile(
{String sdkRoot,
String mainPath,
bool linkPlatformKernelIn : false,
List<String> extraFrontEndOptions}) async {
final String frontendServer = artifacts.getArtifactPath(
Artifact.frontendServerSnapshotForEngineDartSdk
......@@ -73,6 +74,8 @@ Future<String> compile(
'--sdk-root',
sdkRoot,
];
if (!linkPlatformKernelIn)
command.add('--no-link-platform');
if (extraFrontEndOptions != null)
command.addAll(extraFrontEndOptions);
command.add(mainPath);
......
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