Upstream-Status: Pending Description: Defer packaging fastdeploy with adb for 29.x.x tags. Forwarded: not-needed --- a/system/core/adb/client/commandline.cpp +++ b/system/core/adb/client/commandline.cpp @@ -59,7 +59,6 @@ #include "bugreport.h" #include "client/file_sync_client.h" #include "commandline.h" -#include "fastdeploy.h" #include "services.h" #include "shell_protocol.h" #include "sysdeps/chrono.h" --- a/system/core/adb/client/adb_install.cpp +++ b/system/core/adb/client/adb_install.cpp @@ -35,7 +35,6 @@ #include "adb_utils.h" #include "client/file_sync_client.h" #include "commandline.h" -#include "fastdeploy.h" static constexpr int kFastDeployMinApi = 24; @@ -167,14 +166,6 @@ } if (use_fastdeploy) { - auto metadata = extract_metadata(file); - if (metadata.has_value()) { - // pass all but 1st (command) and last (apk path) parameters through to pm for - // session creation - std::vector pm_args{argv + 1, argv + argc - 1}; - auto patchFd = install_patch(pm_args.size(), pm_args.data()); - return stream_patch(file, std::move(metadata.value()), std::move(patchFd)); - } } struct stat sb; @@ -267,16 +258,6 @@ argv[last_apk] = apk_dest.c_str(); /* destination name, not source location */ if (use_fastdeploy) { - auto metadata = extract_metadata(apk_file[0]); - if (metadata.has_value()) { - auto patchFd = apply_patch_on_device(apk_dest.c_str()); - int status = stream_patch(apk_file[0], std::move(metadata.value()), std::move(patchFd)); - - result = pm_command(argc, argv); - delete_device_file(apk_dest); - - return status; - } } if (do_sync_push(apk_file, apk_dest.c_str(), false)) { @@ -292,7 +273,6 @@ InstallMode installMode = INSTALL_DEFAULT; bool use_fastdeploy = false; bool is_reinstall = false; - FastDeploy_AgentUpdateStrategy agent_update_strategy = FastDeploy_AgentUpdateDifferentVersion; for (int i = 1; i < argc; i++) { if (!strcmp(argv[i], "--streaming")) { @@ -313,13 +293,10 @@ use_fastdeploy = false; } else if (!strcmp(argv[i], "--force-agent")) { processedArgIndicies.push_back(i); - agent_update_strategy = FastDeploy_AgentUpdateAlways; } else if (!strcmp(argv[i], "--date-check-agent")) { processedArgIndicies.push_back(i); - agent_update_strategy = FastDeploy_AgentUpdateNewerTimeStamp; } else if (!strcmp(argv[i], "--version-check-agent")) { processedArgIndicies.push_back(i); - agent_update_strategy = FastDeploy_AgentUpdateDifferentVersion; } } @@ -331,13 +308,11 @@ error_exit("Attempting to use streaming install on unsupported device"); } - if (use_fastdeploy && get_device_api_level() < kFastDeployMinApi) { - printf("Fast Deploy is only compatible with devices of API version %d or higher, " - "ignoring.\n", - kFastDeployMinApi); + if (use_fastdeploy) { + printf("Fast Deploy is unavailable in this build of adb, " + "ignoring.\n"); use_fastdeploy = false; } - fastdeploy_set_agent_update_strategy(agent_update_strategy); std::vector passthrough_argv; for (int i = 0; i < argc; i++) {