As stated in the title, my question is if there is any way to install the F-Droid Privileged Extension as a system app to a standard /e/ OS installation without any third-party modifications (e.g. TWRP, Magisk, etc.) – and if so, how to do it. So far, I haven’t figured out a way that works.
I tried booting into recovery mode and selecting “Apply update → Apply from ADB” and installing the F-Droid OTA .zip using adb sideload, which does copy the files to /dev/block/by-name/system_a or /dev/block/by-name/system_b. However, when I reboot normally after that and look at the file system, none of the previously copied files show up in /system/priv-app/ and /system/app/. Back in recovery mode, they’re still there, but in “normal” mode, /system/ remains unchanged. Is there some way to make this work or is it required to install something like TWRP?
As far as I understand, root permissions are not particularly relevant (i.e. just having root access is not enough to install to priv-app). But in any case, this shouldn’t be a problem since one can enable root access through ADB on /e/ OS in the developer settings, right?
Ah OK, I wasn’t aware that it’s possible to use TWRP without permanently installing it. I was planning on locking the bootloader after installing everything, though. So, is it possible to do the following: install the Privileged Extension using TWRP, get rid of TWRP, lock the bootloader and then keep using /e/ normally with the Privileged Extension (across system updates etc.)?
Yes. You can also use the command adb root in a shell to start the adb daemon with root permissions. But I think that changes made will not be persistent after a reboot because they need root permissions again.
Thanks for the suggestion, but the result using NanoDroid was the same as with the official F-Droid OTA .zip: The files are installed to the system partition, but don’t actually show up when I boot the device normally. So there must be some kind of important difference between the Fairphone 3 and the Pocophone F1?
Hm, I am a bit surprised. I haven’t installed anything on a Fairphone yet, but the installation process with various phones that I have tried so far are very similar. So, I would be surprised about any profound differences.
For now I could only imagine 2 things:
the recovery that is used on your system is the things that blocks. But I do not know what recovery is actually used on your phone.
your prior tweaks cause the hick-ups now.(in this case it could help to factory reset the phone, I suppose).
I wipe and re-flash the /e/ .img files every time I try something new, so this shouldn’t affect anything. The installed recovery is the one that comes with /e/ (LineageOS recovery, as far as I understand).
OK, I just discovered something strange. I wanted to try if I could just get it to work by using Magisk after all. After installing Magisk, F-Droid and its Privileged Extension, which were still left over from an earlier installation attempt, magically appeared alongside the newly-installed Magisk Manager app! Does that mean that the standard /e/ boot image somehow ensures that the OS only sees an unmodified system partition, but now that it’s been replaced by Magisk, this mechanism is disabled and the modifications to the system partition have become visible?