Snap for 15098574 from a73efa4164c3ffb4b46a5bd1e20aae101d98494b to 26Q2-release

Change-Id: I4c5958db7c9c156fa62bc050961422f4bb9f85c3
diff --git a/apexd/Android.bp b/apexd/Android.bp
index 6f630b2..17f2311 100644
--- a/apexd/Android.bp
+++ b/apexd/Android.bp
@@ -67,6 +67,9 @@
     ] + select(release_flag("RELEASE_AVF_ENABLE_EARLY_VM"), {
         true: ["-DRELEASE_AVF_ENABLE_EARLY_VM"],
         default: [],
+    }) + select(release_flag("RELEASE_DEPRECATE_RUNTIME_APEX"), {
+        true: ["-DRELEASE_DEPRECATE_RUNTIME_APEX"],
+        default: [],
     }),
     tidy: true,
     tidy_checks: tidy_errors,
diff --git a/apexd/apexd.cpp b/apexd/apexd.cpp
index d942c82..42bac2d 100644
--- a/apexd/apexd.cpp
+++ b/apexd/apexd.cpp
@@ -170,7 +170,9 @@
     ([]() {
       std::vector<std::string> ret = {
           "com.android.i18n",
+#ifndef RELEASE_DEPRECATE_RUNTIME_APEX
           "com.android.runtime",
+#endif
           "com.android.tzdata",
 #ifdef RELEASE_AVF_ENABLE_EARLY_VM
           "com.android.virt",
@@ -519,7 +521,7 @@
     mount_device = linear_dev.GetDevPath();
   } else if (IsFileBackedMountEnabled() && fs_type == "erofs" &&
              !mount_on_verity) {
-    mount_options = std::format("directio,fsoffset={}", *apex.GetImageOffset());
+    mount_options = std::format("fsoffset={}", *apex.GetImageOffset());
     mount_device = apex.GetPath();
 #if COM_ANDROID_APEX_FLAGS_MICRODROID_NO_LOOP_DEVICE
   } else if (instance.IsBlockApex(apex)) {
diff --git a/apexd/apexservice_test.cpp b/apexd/apexservice_test.cpp
index 5e0ebb6..71406cd 100644
--- a/apexd/apexservice_test.cpp
+++ b/apexd/apexservice_test.cpp
@@ -1536,7 +1536,9 @@
 }
 
 static const std::vector<std::string> kEarlyApexes = {
+#ifndef RELEASE_DEPRECATE_RUNTIME_APEX
     "/apex/com.android.runtime",
+#endif
     "/apex/com.android.tzdata",
 };
 
diff --git a/libs/libapexutil/Android.bp b/libs/libapexutil/Android.bp
index a37a5a7..97195a2 100644
--- a/libs/libapexutil/Android.bp
+++ b/libs/libapexutil/Android.bp
@@ -22,12 +22,17 @@
     name: "libapexutil-deps",
     shared_libs: [
         "libbase",
-    ],
+    ] + select(release_flag("RELEASE_DEPRECATE_RUNTIME_APEX"), {
+        true: ["liblog"],
+        default: [],
+    }),
     static_libs: [
-        "liblog_for_runtime_apex",
         "libprotobuf-cpp-lite",
         "lib_apex_manifest_proto_lite",
-    ],
+    ] + select(release_flag("RELEASE_DEPRECATE_RUNTIME_APEX"), {
+        true: [],
+        default: ["liblog_for_runtime_apex"],
+    }),
 }
 
 cc_library_static {