Manual Installation - (Part One):

NOTE: The beginning of the commands is actually an important indicator of "where" your supposed to be inputting the commands.

shell

$

root

#

BUT YOU MUST HAVE BUSYBOX INSTALLED FOR THESE COMMANDS TO WORK



There are a few different ways this step can be done so do whatever is easier for you. As my FireTV-v1 has a built-in Ethernet port + USB port I find it convenient to connect via ethernet, use the USB keyboard to enter recovery and then ADB into recovery and edit the build prop with the command-line text editor "vi". However only the FireTV-v1 makes doing it that way easy, and anyone who knows how to use vi can probably figure this part out on their own without any further instructions.



For the rest of you on FireTV-v2 or FireTV-Sticks here's probably the easiest way for you to complete this step. First make sure your device is powered on and connected to your wifi network with ADB Debugging enabled.



Code: ~$ adb connect "YOUR IP" ~$ adb shell [email protected]:/ $ exit Code: ~$ adb connect "YOUR IP" ~$ adb pull /system/build.prop ~/



NOTE : The first two lines are towards the top of of your build.prop file, while the last two lines should be the VERY BOTTOM. Also the first two lines already exist in the file and need to be modified, while the last two lines DO NOT already exist in your build.prop, you need to add them as the very last two lines.



Code: ro.build.version.number=573210520 --> ro.build.version.number=987654321 ro.build.characteristics=default --> ro.build.characteristics=tv

BOTTOM ٧

Code: ro.com.google.clientidbase=android-xiaomi-tv ro.com.google.gmsversion=5.1_r1_TV Once you have completed the required build.prop modifications, we need to push the edited file back into the FireTV's filesystem



Code: ~$ adb connect "YOUR IP" ~$ adb push ~/build.prop /sdcard/build.prop [email protected]:/ $ su [email protected]:/ # cp /sdcard/build.prop /system/build.prop && chmod 644 /system/build.prop && chown root:root /system/build.prop There are a few different ways this step can be done so do whatever is easier for you. As my FireTV-v1 has a built-in Ethernet port + USB port I find it convenient to connect via ethernet, use the USB keyboard to enter recovery and then ADB into recovery and edit the build prop with the command-line text editor "vi". However only the FireTV-v1 makes doing it that way easy, and anyone who knows how to use vi can probably figure this part out on their own without any further instructions.For the rest of you on FireTV-v2 or FireTV-Sticks here's probably the easiest way for you to complete this step. First make sure your device is powered on and connected to your wifi network with ADB Debugging enabled.If you get to a terminal prompt great, now type "exit". Now type "adb pull /system/build.prop/ ~/" this command should grab a copy of your build.prop and place it in your user's home directory. Now you need to edit the file using a good text editor (NOT Microsoft Word / WordPad / Any other "fancy" program that will add additional formatting, and wind up destroying the file). If on Windows I recommend NotePad++, if on any other operating system, you should be fine with the default text editor.: The first two lines are towards the top of of your build.prop file, while the last two lines should be the VERY BOTTOM. Also the first two lines already exist in the file and need to be modified, while the last two lines DO NOT already exist in your build.prop, you need to add them as the very last two lines.^ TOPBOTTOM ٧

Code: ~$ adb connect "YOUR IP" ~$ adb shell [email protected]:/ $ exit

Manual Installation - (Part Two):

note that everything on a single line should be copy/pasted as one command

Code: [email protected]:/ # mkdir /system/priv-app/TvSettings && chmod 755 /system/priv-app/TvSettings && cp /sdcard/PlayFire/PlayFire-TvSettings.apk /system/priv-app/TvSettings/TvSettings.apk && chmod 644 /system/priv-app/TvSettings/TvSettings.apk && chown root:root /system/priv-app/TvSettings/TvSettings.apk [email protected]:/ # mkdir /system/app/NoTouchAuthDelegate && chmod 755 /system/app/NoTouchAuthDelegate && cp /sdcard/PlayFire/TV-NoTouchGsf.apk /system/app/NoTouchAuthDelegate/NoTouchAuthDelegate.apk && chmod 644 /system/app/NoTouchAuthDelegate/NoTouchAuthDelegate.apk && chown root:root /system/app/NoTouchAuthDelegate/NoTouchAuthDelegate.apk [email protected]:/ # mv /sdcard/PlayFire/gapps-config.txt /sdcard/gapps-config.txt

Code: [email protected]:/ # cp /sdcard/PlayFire/android.hardware.wifi.direct.xml /system/etc/permissions/android.hardware.wifi.direct.xml && chmod 644 /system/etc/permissions/android.hardware.wifi.direct.xml && chown root:root /system/etc/permissions/android.hardware.wifi.direct.xml

Manual Installation - (Step Three):

install the final ZIP files of updated SuperSU v2.82, Xposed Framework v87, and finally OpenGApps TV-Stock itself

AFTER

REBOOT

the shell or command prompt on YOUR computer. With FireTV Utility you may need to type "exit" to get back to a "computer shell"= the shell on the FireTV device. The "firetv" part will change depending on your device nameNotice how the last part in red changed from $ --> # this is the difference between a normal user shell and a "root shell": @ stangri has provided some terminal commands that expertly accomplish the necessary build.prop modifications without needing to follow my old instructions to pull the file off the device, edit it and then push it back to the filesystem. Thanks to this contribution we can now edit build.prop with the following commands,Unfortunately each device's build.prop contains completely different information, and this can even change within the same device between different software versions, so I cannot post an example for this one, as it would be useless and dangerous if someone tried to use it on the wrong device / software version. But this modification is necessary, the "top" edits give the TV-Stock installer the correct information to know this is a TV Device (otherwise it will detect the FireTV as a "Phone" and skip installing some necessary libraries, while the bottom two lines allow the device to register correctly with the Play Store and prevents the issue a lot of us were having with updates to Google Play breaking things.If you get to the "FireTV" terminal prompt great, now type "exit" and proceed to the next set of commands. If you dont get to the "FireTV" terminal you need to double check you have ADB debugging enabled and your device is in fact connected to the appropriate network.- You should now have XposedInstaller.apk, XposedFramework.zip, HDXPosed-1.3.apk, SuperSU.zip, PlayFire.tar.gz, Busybox.apk or Busybox.zip TV-Stock.zip and TV-Stock.zip.md5 and a modified build.prop ready to go. Next you need to move all these files onto your device, and I am going to use the root of /sdcard/ and the /sdcard/PlayFire/ directory as defaults. You can use something else, but you will need to modify the following commands.Get your device up and running and. Once everything is on the root of your /sdcard/ run the following commands, andIf running these commands from TWRP recovery, everything will already work as TWRP comes with busybox. If running this connected to adb on a running FireTV system you must install busybox prior to running these commands. Install the ZIP through TWRP then boot into the system or use the APK to install busybox into your /system partition.- So the MAIN things that had been messing up installing TV-Stock GApps on FireTV or anything else for that matter isNo one was editing the /system/etc/permissions files appropriately andthat the OpenGApps TV-Stock installer includes a broken copy of NoTouchAuth which wont allow you to register with Google Play Services. In one of the above commands we installed a copy of NoTouchAuth I pulled from a Official AndroidTV box (so it actually works) and once you have completed the next steps and reboot, you will be able to log into Google Play without issue. Also at this point we have replaced the stock system build.prop with the modified one to allow a proper TV-Stock installation, and allow for proper authentication with Google Play Services, installed the modified copy of peleg's TvSettings.apk (ATV Settings Widget/Menu) which now does not require signature spoofing due to my removal of the "com.android.shared.uid" value from the Android Manifest, disabled Wifi-Direct broadcasting, and installed XposedInstaller.apk + HDXPosed.apk, along with theXposed Module "Xposed Edge" which is what will allow us to remap Buttons / Keycodes & provides the Running App List + Task Switcher + an unbelievable amount of other useful features and ability to customize just about anything.Due to issues with OpenGApps TV-Stock overwriting NoTouchAuth during installation, you must run the followingfinishing the TV-Stock installation to avoid the "spinning circle of doom" issue, which will prevent Google Play login. After running the commands belowand you should be able to login to Google Play without further problems.