summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGrant Yoshida <gyoshida@google.com>2019-08-23 11:09:13 -0700
committerGrant Yoshida <gyoshida@google.com>2019-08-23 18:12:00 +0000
commit9f4af42319b1854f001a89f613abca83a1d7952f (patch)
treec666438ea4e7a2490eddec5aba468baf6a23a3d4
parent74b8bd1ee30d1b4d1a94a29be085b697db209d9f (diff)
downloadvrservices-9f4af42319b1854f001a89f613abca83a1d7952f.tar.gz
Update boot-to-vr.sh to replace the init.xr.rc file.
Somehow this was missed when this file was moved from vendor. Test: "adb shell boot-to-vr.sh true" on an MTP. Change-Id: Ic67fb1638f4196287daeba8a0fbf84c0806d0ef8
-rwxr-xr-xxr/scripts/boot-to-vr.sh7
1 files changed, 6 insertions, 1 deletions
diff --git a/xr/scripts/boot-to-vr.sh b/xr/scripts/boot-to-vr.sh
index 853efb9..484f380 100755
--- a/xr/scripts/boot-to-vr.sh
+++ b/xr/scripts/boot-to-vr.sh
@@ -2,6 +2,7 @@
# This script finds the init.rc file for a certain Pixel XR device and updates
# the value of ro.boot.vr being set during the init process.
#
+SYSTEM_INIT_XR_RC_FILE="/system/etc/init/init.xr.rc"
PROP_RO_HARDWARE="$(getprop ro.hardware)"
PROP_RO_BOOT_HARDWARE_PLATFORM="$(getprop ro.boot.hardware.platform)"
PROP_RO_PRODUCT_NAME="$(getprop ro.product.name)"
@@ -24,7 +25,11 @@ function get_hardware_name() {
}
function get_init_rc_file() {
- echo "/vendor/etc/init/hw/init.$(get_hardware_name).rc"
+ if [ -f $SYSTEM_INIT_XR_RC_FILE ]; then
+ echo $SYSTEM_INIT_XR_RC_FILE
+ else
+ echo "/vendor/etc/init/hw/init.$(get_hardware_name).rc"
+ fi
}
function print_init_rc() {