[flutter_tools] Let CMake handle escaping (#70026)

This commit is contained in:
J-P Nurmi
2020-12-22 01:04:04 +01:00
committed by GitHub
parent de448c81ed
commit f2536da16f
10 changed files with 285 additions and 25 deletions

View File

@@ -7,12 +7,14 @@ import '../base/analyze_size.dart';
import '../base/common.dart';
import '../base/file_system.dart';
import '../base/logger.dart';
import '../base/project_migrator.dart';
import '../base/utils.dart';
import '../build_info.dart';
import '../cache.dart';
import '../cmake.dart';
import '../convert.dart';
import '../globals.dart' as globals;
import '../migrations/cmake_custom_command_migration.dart';
import '../plugins.dart';
import '../project.dart';
@@ -35,6 +37,15 @@ Future<void> buildLinux(
'to learn about adding Linux support to a project.');
}
final List<ProjectMigrator> migrators = <ProjectMigrator>[
CmakeCustomCommandMigration(linuxProject, globals.logger),
];
final ProjectMigration migration = ProjectMigration(migrators);
if (!migration.run()) {
throwToolExit('Unable to migrate project files');
}
// Build the environment that needs to be set for the re-entrant flutter build
// step.
final Map<String, String> environmentConfig = buildInfo.toEnvironmentConfig();