summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbig biff <bigbiff@teamw.in>2019-03-15 01:06:47 +0100
committerGerrit Code Review <gerrit2@gerrit.omnirom.org>2019-03-15 01:06:47 +0100
commit3ae89edb406e41592d61ee9e10cb34caa9cc2ae5 (patch)
treea91bf8134ebdb87b00753cca8258af4aaacc8564
parentMerge "Revert "Fix ld.config.txt errors on Android 8.1 system root devices"" into android-9.0 (diff)
parentFix build error on Pie with TW_NO_LEGACY_PROPS := true (diff)
downloadandroid_bootable_recovery-3ae89edb406e41592d61ee9e10cb34caa9cc2ae5.tar
android_bootable_recovery-3ae89edb406e41592d61ee9e10cb34caa9cc2ae5.tar.gz
android_bootable_recovery-3ae89edb406e41592d61ee9e10cb34caa9cc2ae5.tar.bz2
android_bootable_recovery-3ae89edb406e41592d61ee9e10cb34caa9cc2ae5.tar.lz
android_bootable_recovery-3ae89edb406e41592d61ee9e10cb34caa9cc2ae5.tar.xz
android_bootable_recovery-3ae89edb406e41592d61ee9e10cb34caa9cc2ae5.tar.zst
android_bootable_recovery-3ae89edb406e41592d61ee9e10cb34caa9cc2ae5.zip
-rw-r--r--twinstall.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/twinstall.cpp b/twinstall.cpp
index a2f54c941..f451ca551 100644
--- a/twinstall.cpp
+++ b/twinstall.cpp
@@ -67,10 +67,12 @@ extern "C" {
#define AB_OTA "payload_properties.txt"
+#ifndef TW_NO_LEGACY_PROPS
static const char* properties_path = "/dev/__properties__";
static const char* properties_path_renamed = "/dev/__properties_kk__";
static bool legacy_props_env_initd = false;
static bool legacy_props_path_modified = false;
+#endif
enum zip_type {
UNKNOWN_ZIP_TYPE = 0,
@@ -79,6 +81,7 @@ enum zip_type {
TWRP_THEME_ZIP_TYPE
};
+#ifndef TW_NO_LEGACY_PROPS
// to support pre-KitKat update-binaries that expect properties in the legacy format
static int switch_to_legacy_properties()
{
@@ -120,6 +123,7 @@ static int switch_to_new_properties()
return 0;
}
+#endif
static int Install_Theme(const char* path, ZipWrap *Zip) {
#ifdef TW_OEM_BUILD // We don't do custom themes in OEM builds
@@ -173,6 +177,7 @@ static int Prepare_Update_Binary(const char *path, ZipWrap *Zip, int* wipe_cache
return INSTALL_SUCCESS;
}
+#ifndef TW_NO_LEGACY_PROPS
static bool update_binary_has_legacy_properties(const char *binary) {
const char str_to_match[] = "ANDROID_PROPERTY_WORKSPACE";
int len_to_match = sizeof(str_to_match) - 1;
@@ -205,6 +210,7 @@ static bool update_binary_has_legacy_properties(const char *binary) {
return found;
}
+#endif
static int Run_Update_Binary(const char *path, ZipWrap *Zip, int* wipe_cache, zip_type ztype) {
int ret_val, pipe_fd[2], status, zip_verify;