diff --git a/fastboot/Android.bp b/fastboot/Android.bp index 978eed0be..546bce258 100644 --- a/fastboot/Android.bp +++ b/fastboot/Android.bp @@ -143,6 +143,10 @@ cc_binary { static_libs: [ "libhealthhalutils", ], + + header_libs: [ + "libsnapshot_headers", + ] } cc_defaults { diff --git a/fastboot/device/flashing.cpp b/fastboot/device/flashing.cpp index 99854c99f..102ebdb3e 100644 --- a/fastboot/device/flashing.cpp +++ b/fastboot/device/flashing.cpp @@ -32,6 +32,7 @@ #include #include #include +#include #include #include "fastboot_device.h" @@ -171,6 +172,11 @@ bool UpdateSuper(FastbootDevice* device, const std::string& super_name, bool wip if (!slot_suffix.empty() && GetPartitionSlotSuffix(partition_name) == slot_suffix) { continue; } + std::string group_name = GetPartitionGroupName(old_metadata->groups[partition.group_index]); + // Skip partitions in the COW group + if (group_name == android::snapshot::kCowGroupName) { + continue; + } partitions_to_keep.emplace(partition_name); } diff --git a/fs_mgr/libsnapshot/Android.bp b/fs_mgr/libsnapshot/Android.bp index abf7afce4..f2b6141b8 100644 --- a/fs_mgr/libsnapshot/Android.bp +++ b/fs_mgr/libsnapshot/Android.bp @@ -56,6 +56,12 @@ filegroup { ], } +cc_library_headers { + name: "libsnapshot_headers", + recovery_available: true, + defaults: ["libsnapshot_defaults"], +} + cc_library_static { name: "libsnapshot", defaults: ["libsnapshot_defaults"],