Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(654)

Unified Diff: utils/compiler/create_snapshot_entry.dart

Issue 2442513003: GN: Build the SDK with app snapshots instead of script snapshots. (Closed)
Patch Set: . Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: utils/compiler/create_snapshot_entry.dart
diff --git a/utils/compiler/create_snapshot.dart b/utils/compiler/create_snapshot_entry.dart
similarity index 84%
copy from utils/compiler/create_snapshot.dart
copy to utils/compiler/create_snapshot_entry.dart
index c2ca95e2944703ca4731d4515638d2db3078d502..ea9c5113bab7f12e5d6f320f5939b0a8fc2ee65b 100644
--- a/utils/compiler/create_snapshot.dart
+++ b/utils/compiler/create_snapshot_entry.dart
@@ -61,21 +61,6 @@ void writeSnapshotFile(var path, var content) {
writer.close();
}
-Future createSnapshot(var dart_file) {
- return Process.run(Platform.executable,
- ["--packages=../../.packages",
- "--snapshot=$dart_file.snapshot",
- dart_file])
- .then((result) {
- if (result.exitCode != 0) {
- print("Could not generate snapshot: result code ${result.exitCode}");
- print(result.stdout);
- print(result.stderr);
- throw "Could not generate snapshot";
- }
- });
-}
-
/**
* Takes the following arguments:
* --output_dir=val The full path to the output_dir.
@@ -101,13 +86,10 @@ void main(List<String> arguments) {
getSnapshotGenerationFile(args, rootPath).then((result) {
var wrapper = "${args['output_dir']}/utils_wrapper.dart";
writeSnapshotFile(wrapper, result);
- createSnapshot(wrapper);
});
getDart2jsSnapshotGenerationFile(args, rootPath).then((result) {
var wrapper = "${args['output_dir']}/dart2js.dart";
writeSnapshotFile(wrapper, result);
- createSnapshot(wrapper);
});
-
}

Powered by Google App Engine
This is Rietveld 408576698