Slimming Your Android Install

I did this on my HTC Desire running OxygeN 2.0 RC7 ROM, and requires you have a root access to the ROM, and have a knowledge of adb from Android SDK install. As this just a quick how to I am not going to go into how to connect your phone etc, I sure you can Google that info.

Before we start remember to do a NAND backup

YOU are choosing to make these modifications, and if you point the finger at me for messing up your device, I will laugh at you.

First we have to connect to the phone and to check that do:

 # ./adb devices

you should see the serial number of your phone.

Now were ready to rock n roll and connect to the device:

 #./adb shell

This gives use shell on the phone

Here is a list of apps that are installed in the default OxygeN 2.0 RC7 ROM

# ls /system/app
AccountAndSyncSettings.apk     Maps.apk
ApplicationsProvider.apk       MarketUpdater.apk
Bluetooth.apk                  MediaProvider.apk
Browser.apk                    MediaUploader.apk
Calculator.apk                 Mms.apk
Calendar.apk                   Music.apk
CalendarProvider.apk           NetworkLocation.apk
Camera.apk                     OneTimeInitializer.apk
CertInstaller.apk              OxygenSettings.apk
Contacts.apk                   OxygenUpdater.apk
ContactsProvider.apk           PackageInstaller.apk
DefaultContainerService.apk    Phone.apk
DeskClock.apk                  PicoTts.apk
DownloadProvider.apk           Settings.apk
DownloadProviderUi.apk         SettingsProvider.apk
DrmProvider.apk                SetupWizard.apk
Email.apk                      Stk.apk
FM.apk                         Street.apk
Gallery3D.apk                  Superuser.apk
GenieWidget.apk                SystemUI.apk
Gmail.apk                      Talk.apk
GoogleBackupTransport.apk      TelephonyProvider.apk
GoogleCalendarSyncAdapter.apk  TtsService.apk
GoogleContactsSyncAdapter.apk  UserDictionaryProvider.apk
GoogleFeedback.apk             Vending.apk
GooglePartnerSetup.apk         VoiceDialer.apk
GoogleQuickSearchBox.apk       VoiceSearch.apk
GoogleServicesFramework.apk    VpnServices.apk
HTMLViewer.apk                 YouTube.apk
LatinIME.apk                   ZeamLauncher.apk
LatinImeTutorial.apk           kickback.apk
LiveWallpapers.apk             soundback.apk
LiveWallpapersPicker.apk       talkback.apk

Now mount the /system directory for write access

 # mount -o rw,remount /system

No we can remove the apps we not want and swap for other etc:

 # rm -f /system/app/.apk

You can remove batch of packages too like this:

 # rm -f /system/app/Google*.apk

Now to uninstall the packages:

 # pm uninstall 

example:

 # pm uninstall com.google.android.apps.genie.geniewidget

Remember to do this after you removed the packages you wanted

And after removing apps we are left with

# ls /system/app
AccountAndSyncSettings.apk   MediaProvider.apk
ApplicationsProvider.apk     MediaUploader.apk
Bluetooth.apk                Mms.apk
Browser.apk                  Music.apk
Calculator.apk               OxygenSettings.apk
Calendar.apk                 OxygenUpdater.apk
CalendarProvider.apk         PackageInstaller.apk
Camera.apk                   Phone.apk
CertInstaller.apk            PicoTts.apk
Contacts.apk                 Settings.apk
ContactsProvider.apk         SettingsProvider.apk
DefaultContainerService.apk  Stk.apk
DeskClock.apk                Superuser.apk
DownloadProvider.apk         SystemUI.apk
DownloadProviderUi.apk       TelephonyProvider.apk
DrmProvider.apk              TtsService.apk
Email.apk                    UserDictionaryProvider.apk
FM.apk                       Vending.apk
Gallery3D.apk                VoiceDialer.apk
HTMLViewer.apk               VpnServices.apk
LatinIME.apk                 ZeamLauncher.apk
LatinImeTutorial.apk         kickback.apk
LiveWallpapers.apk           soundback.apk
LiveWallpapersPicker.apk     talkback.apk
MarketUpdater.apk

Reference:
http://wiki.cyanogenmod.com/index.php?title=Barebones

Leave a Reply