* GNU/Linux on your phone now
* GNU/Linux with Android APK compatibility layer
* Managing APK of a device
** Listing APK installed on the device
** Dumping an APK installed on the device
** Installing an APK onto the device from the computer
** Removing closed source spywares from your current Android system as a transition phase
Android will move from Linux kernel and open specs APK format to a more closed package format and to their closed source Fuschia kernel going away from Free Open Source software (FOSS) that make Google, Android, ChromeOS grow, but also that are used on most of the internet servers, on most of supercomputer in the world, on most spacecrafts, on most internet boxes, TVboxes, etc…
GNU/Linux on your phone now
At the same time GNU/Linux distributions for mobile grow a lot the 2 recent years, thanks to availability of PinePhone for developers for about 2 years. There are now at least 15 Linux distributions for phone and applications maturated a lot, including since few month MegaPixels hardware accelerted camera application, that use GL and other processor to accelerate rendering/computing of what camera receive.
PostMarketOS is a GNU/Linux distribution available for a bunch of available market phones, but not everything is managed an all devices.
GNU/Linux with Android APK compatibility layer
Just like there is Wine to run Windows application on GNU/Linux, there are also several systems allowing to run Android APK on your phone if needed. Jusr as Wine, beside the possibility of running Android in a qemu VM, you can also run these application inside your the standard GNU system.
AnBox allow to run APK/Android application inside a snap packaged container.
Google goes away from FOSS, afraid by the lost of market share, and they probably loose a lot from this, as Microsoft does by the past. Chinese company, thanks to Trump restrictions, embrace more FOSS.
Huawei the maker of the probably highest quality phones, that was going in first seller position just ahead Samsung, when Trump blocked it, already very active in Linux kernel and community for years, made HarmonyOS for their devices, a system, that continue tu uses Linux kernel for their power devices, and LiteOS for their low end/old devices. LiteOS is a FOSS embedded devices oriented light kernel. They keep the EMUI User Interface they used previously on Android, moving step by step away from it, and at the same time keep a compatibility layer with current APK open-source format.
Another Chinese company, JingOS, made high quality tablets, based on GNU/Linux distribution, that derivates from Ubuntu, with KDE tools and Android APK application compatibility using Anbox. And they are active with KDE and open source communities. Few demos here and here.
Managing APK of a device
For managing package of an Android device from a computer you need
adb. This command is available on
android-tools package on Arch Linux.
Listing APK installed on the device
adb shell pm list packages
See which one are related to facebook:
adb shell pm list packages facebook
Dumping an APK installed on the device
You need first to find the path of the APK with the commande
adb shell pm path :
adb shell pm path com.sec.android.app.myfiles package:/system/app/SecTabletMyFiles.apk
Then you can use this path (remove the initial
package:) to backup it on your file system with the
adb pull command:
adb pull /system/app/SecTabletMyFiles.apk
Installing an APK onto the device from the computer
Simply type the command install with the path of the APK on y”zour disk:
adb install f-droid.apk
Removing closed source spywares from your current Android system as a transition phase
Beside long time F-droid Free software apk app repository (I use it for year as main source of APK).
You can remove Android pre-installed (memory+cpu+bandwidth thieves) applications, including NSA compliant one like Google, Amazon, FaceBook, Microsoft ones using from a computer with adb. This allowed me to have less bloated phone and to gain few more days of on-battery usage.
For easier copy paste and have only the package name without
adb shell pm list packages | cut -d: -f 2
The corresponding application, can be checked by using in a web browser, this does not work for some system applications, for example, for com.google.android.videos:
Remove never at least first seen, never used application:
# FaceBook spyware adb shell pm uninstall --user 0 com.facebook.katana adb shell pm uninstall --user 0 com.facebook.system adb shell pm uninstall --user 0 com.facebook.appmanager # Microsoft stuff adb shell pm uninstall --user 0 com.microsoft.office.excel adb shell pm uninstall --user 0 com.microsoft.office.onenote adb shell pm uninstall --user 0 com.microsoft.office.powerpoint adb shell pm uninstall --user 0 com.microsoft.office.word adb shell pm uninstall --user 0 com.microsoft.skydrive # data thief adb shell pm uninstall --user 0 com.google.android.apps.docs # Google Drive (data thief) adb shell pm uninstall --user 0 com.google.android.apps.photos # Google photos (data thief) adb shell pm uninstall --user 0 com.google.android.googlequicksearchbox # Google Search box (behavior thief) adb shell pm uninstall --user 0 com.google.android.apps.maps # Gaogle Maps (location/move/destination search thief) adb shell pm uninstall --user 0 com.google.android.gm # GMail adb shell pm uninstall --user 0 com.google.android.talk # Hangouts adb shell pm uninstall --user 0 com.google.android.music # Google Play Music adb shell pm uninstall --user 0 com.google.android.videos # Google Play Film & Series adb shell pm uninstall --user 0 com.google.android.youtube # Youtube application
To be checked
adb shell pm uninstall --user 0 com.google.android.gms # Services Google Play