[deps] Roll native_assets_cli to internal import

https://dart-review.googlesource.com/c/sdk/+/346761 can't land,
because then flutter_tools in g3 breaks.
flutter_tools in g3 can't be forwarded because
https://github.com/dart-lang/native/pull/886 isn't in g3 yet.

Landing https://github.com/dart-lang/native/pull/886 in g3
should work, because it shouldn't break flutter_tools.

Change-Id: Ida60ed22093ace535c00114fc8b088ba2100eb1a
Cq-Include-Trybots: luci.dart.try:pkg-linux-debug-try,pkg-linux-release-arm64-try,pkg-mac-release-try,pkg-mac-release-arm64-try,pkg-win-release-try,pkg-win-release-arm64-try
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/346960
Reviewed-by: Moritz Sümmermann <mosum@google.com>
Commit-Queue: Daco Harkes <dacoharkes@google.com>
This commit is contained in:
Daco Harkes 2024-01-18 12:50:21 +00:00 committed by Commit Queue
parent d506f5064c
commit ae5db20deb
4 changed files with 11 additions and 10 deletions

2
DEPS
View file

@ -161,7 +161,7 @@ vars = {
"material_color_utilities_rev": "799b6ba2f3f1c28c67cc7e0b4f18e0c7d7f3c03e",
"mime_rev": "ca9f059d2334bb2657683e0a7f5949817cb4b0e6",
"mockito_rev": "e15e00086ed20f3175b2e677fd11611be4fa8e8e",
"native_rev": "14f6da1d58d23bb0b726e703dd92827a5dafeceb",
"native_rev": "153811080d9020c894c4e820053d2ede79ca9012",
"package_config_rev": "33dd24659147bd7ed2fa87aeacc52d199be766b4",
"path_rev": "57a049cff2e2be7a302dd9683b2b194c6d06e2d4",
"pool_rev": "4c490001446d8ba3d361b99d8befd6a4f61abc7a",

View file

@ -12,7 +12,7 @@ import 'package:dartdev/src/sdk.dart';
import 'package:front_end/src/api_prototype/compiler_options.dart'
show Verbosity;
import 'package:native_assets_builder/native_assets_builder.dart';
import 'package:native_assets_cli/native_assets_cli.dart';
import 'package:native_assets_cli/native_assets_cli_internal.dart';
import 'package:path/path.dart' as path;
import 'package:vm/target_os.dart'; // For possible --target-os values.
@ -152,16 +152,16 @@ Use linkMode as dynamic library instead.""");
stdout.writeln('Copying native assets.');
Asset targetLocation(Asset asset) {
final path = asset.path;
switch (path.runtimeType) {
case const (AssetSystemPath):
case const (AssetInExecutable):
case const (AssetInProcess):
switch (path) {
case AssetSystemPath _:
case AssetInExecutable _:
case AssetInProcess _:
return asset;
case const (AssetAbsolutePath):
case AssetAbsolutePath _:
return asset.copyWith(
path: AssetRelativePath(
Uri(
path: (path as AssetAbsolutePath).uri.pathSegments.last,
path: path.uri.pathSegments.last,
),
),
);

View file

@ -8,7 +8,7 @@ import 'dart:io';
import 'package:dartdev/src/sdk.dart';
import 'package:logging/logging.dart';
import 'package:native_assets_builder/native_assets_builder.dart';
import 'package:native_assets_cli/native_assets_cli.dart';
import 'package:native_assets_cli/native_assets_cli_internal.dart';
import 'core.dart';

View file

@ -7,7 +7,8 @@ import 'dart:convert';
import 'dart:ffi';
import 'dart:io';
import 'package:native_assets_cli/native_assets_cli.dart' show CCompilerConfig;
import 'package:native_assets_cli/native_assets_cli_internal.dart'
show CCompilerConfig;
import 'package:smith/configuration.dart';
import 'package:smith/smith.dart';