1

I've got a motorola g4. Bootloader unlocked, twrp installed, lineageos installed, opengapps installed, non-rooted. Been using it for about a year.

I want to try lineageos-for-microg: https://lineage.microg.org/

I want to keep my current data/apps (including some enduser google apps like their pdf viewer) as much as possible and migrate to microg, removing only the "core" google stuff a user doesn't generally care about directly that will be replaced by microg. So, I'm following the dirty install process.

--

I have none of the listed apps installed.

I have tried removing opengapps, but it doesn't seem to work. Using the aroma installer to choose settings until the config at the end is "Include" with no apps listed, some google apps are still installed (notably, the play store) after rebooting. The opengapps installer process also mentions removing existing/obsolete apps for only a short time, then moves to the next step "installing gapps" which takes a long time. This seems to contradict the settings I gave it, namely to leave none installed, but is consistent with the fact that they don't seem to get uninstalled.

I have also flashed https://github.com/CHEF-KOCH/Remove-Gapps to try to get rid of them but some gapps (like the play store) still survive.

--

After any combination of attempts to follow the instructions and remove the gapps, I flash the key migration zip followed by the lineage-microg zip for my device (athene). I also make sure to wipe the dalvik and cache partitions before rebooting.

After all this, every time I reboot, my system is almost exactly like it was before I did anything: google services installed (though the play store does not actually work, it's still there), the microg settings app is not installed, etc. A few things are broken (some notifications of apps crashing) but overall nothing noteworthy has happened.

I've resorted to even wiping /system before a migration attempt, but even this achieves nothing.

--

I got a partial success once by manually going through /system/app, /system/priv-app, and /data/app and removing anything that looked google-y, then performing the migration. Upon rebooting, the microg settings app was present and the self-check section looked like it should look on a clean install, but the play store was still present. I don't know to what extent this migration was a success.

I'm not familiar with the android/google ecosystem's insides and app politics, just the userland, so when I'm manually going around deleting files I have little knowledge of what I'm doing, so I don't consider this attempt a success.

--

Now that all the info has been laid out, could someone please help me cleanly perform the migration to lineage-microg, without excessive butchering of my system or leaving things that should not be left? Why does the dirty install procedure laid out by the lineage-microg team fail? Why do the gapps removal tools fail? What exactly is necessary to correctly and cleanly migrate lineage to lineage-microg?

  • Will be a bit more effort but should work: Performing an adb backup of your apps (hopefully none opted out or you'd need Xposed an the BackupAllApps module; my tool Adebar may help you by creating a script for backup and restore) minus the GApps you want to get rid of, then wipe system, cache and data, install µG-LOS, restore the ADB backup. That's what I usually do for a "clean flash" – but it of course means some configuration to be done afterwards. – Izzy Jan 8 '18 at 8:00
  • @Izzy adb backup/restore will reinstall the apps but their data will still be lost, basically resetting each app to a clean install state, no? – Marnes Jan 8 '18 at 11:48
  • Apparently the command adb backup -f “x:\bla” -all -apk -nosystem will be useful, since they say it backs up/restores apps and their data. I can back up the internal storage separately. With that, I should have the essence of my phone backed up, that should be all I need to restore all my stuff after flashing a new system. Thanks @Izzy – Marnes Jan 8 '18 at 11:57
  • Keep in mind that with the syntax you used it will result in one big archive – and might contain stuff you just want to get rid of. That's why I mentioned Adebar and the script it generates – which then creates separate backup archives, one per app (and the restore script considers that as well, of course). That way you could check the script before running it, and simply remove or comment out things you don't want (maybe not in the backup script, just in case, but at least in the restore script – as you could then restore "skipped stuff" any time later). – Izzy Jan 8 '18 at 20:09
  • Unfortunately my OS is named after glass panes, which adebar is not a fan of – Marnes Jan 8 '18 at 22:02
0

You can do this:

  • Flash the "microG unofficial installer" (Disclaimer: a flashable zip created by me) that remove the base of GApps from all partitions in addition to installing microG
  • Wipe /system to remove traces of the installer
  • Flash LineageOS for microG

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.