Jump to content

Adding apps to a rom prior to flashing


Guest sm4tik

Recommended Posts

Guest sm4tik

I thought I'd write a small script to add/remove apps from CM7 prior to flashing it, but I haven't found a solution how to link the added apps to market to get updates. I'll be replacing ADW with LauncherPro and it would be nice to get an update withouth having to install it with adb or however one might wan't to do it. Other apps are waiting for the solution also, but I think someone out there might be doing this ADW to LP change already and have a straight forward way of doing it.

I still have stock partition table (no windows around for my gen2 device), that's basically why I want to add apps to /system. Btw if there is a way of market-updating these apps, will the update be eventually installed in data anyway?

Thanks

Link to comment
Share on other sites

Guest shadowninty

I have my own GApps.zip that removes APKs from /System (themes, wallpapers ..) and then copies GApps including Maps, Goggles, GMail etc

I still get update notifications

EDIT: if they market update they go to /Data

You can remove these updates tho

Edited by shadowninty
Link to comment
Share on other sites

Guest sm4tik
I have my own GApps.zip that removes APKs from /System (themes, wallpapers ..) and then copies GApps including Maps, Goggles, GMail etc

I still get update notifications

EDIT: if they market update they go to /Data

You can remove these updates tho

Thanks, I'll have a look at it later. I was thinking of writing a shell script, but since your .zip does the job as well, I just might hold my thought for a while..

Link to comment
Share on other sites

Guest oldfella

I remove apps from /system and add the ones I use before flashing - market updates work as usual but obviously to /data

Titanium copies them back to /system

rom is FLB

Link to comment
Share on other sites

Guest sm4tik

Another question related to the original.

I can't find a downloadable apk for some apps (Multiling keyboard for instance), so is it ok if I just copy the app from /data/app and after renaming it add it to /system/app or is there something else I need to do other than that?

Link to comment
Share on other sites

Guest shadowninty
Another question related to the original.

I can't find a downloadable apk for some apps (Multiling keyboard for instance), so is it ok if I just copy the app from /data/app and after renaming it add it to /system/app or is there something else I need to do other than that?

You need to unsign it

If you delete something from the APK (eg low DPI image folders in /res/) with astro it should unsign it

Link to comment
Share on other sites

Guest DaneelS

I can't seem to find any of my user install apps. I think they should be in data/apps/ but the data folder is empty. I'm using myphoneexplorer to try to copy them off the phone. Can anyone tell me where I'm going wrong?

What I want to do is remove a few apps from the ROM (Cyanogenmod Green V5), and add in a few of my own. I thought this would be as simple as adding and removing a few files from the apk/zip but apparently not!

Link to comment
Share on other sites

Guest Amphoras
Can I just copy the .gz files out of a titanium backup?

You can get the apk by doing that, but as mentioned above you might need to add other things as well for it to work properly.

Link to comment
Share on other sites

Guest sm4tik
I can't seem to find any of my user install apps. I think they should be in data/apps/ but the data folder is empty. I'm using myphoneexplorer to try to copy them off the phone. Can anyone tell me where I'm going wrong?

What I want to do is remove a few apps from the ROM (Cyanogenmod Green V5), and add in a few of my own. I thought this would be as simple as adding and removing a few files from the apk/zip but apparently not!

The directory is /data/app , not /data/apps. I think you need to have su rights to view/modify the content of thet directory. Just go into terminal and

$ su

# ls /data/app

and see if your apps are there. I've found apkmanager from xda to be a useful tool, including resigning your apps as system apps. It's a bit of robust tool to use and might take a try or two to get things working, but it pays off in the end.

BTW, thanks for all the replys, much appreciated!

Link to comment
Share on other sites

Guest DaneelS
The directory is /data/app , not /data/apps. I think you need to have su rights to view/modify the content of thet directory. Just go into terminal and

$ su

# ls /data/app

and see if your apps are there. I've found apkmanager from xda to be a useful tool, including resigning your apps as system apps. It's a bit of robust tool to use and might take a try or two to get things working, but it pays off in the end.

BTW, thanks for all the replys, much appreciated!

Yes, my apps are there, thanks, and I can see them from terminal emulator, but what I want to do is be able to see them from my PC and copy them over. I hoped Myphoneexplorer would let me do that but as it doesn't have root access it can't.

Edit - I'm not very bright sometimes. I just copied the files out of data/app and into sdcard/userapps/ using terminal emulator under su and it's fine. I can now copy the files off the phone as I please.

Edited by DaneelS
Link to comment
Share on other sites

Guest sm4tik
Yes, my apps are there, thanks, and I can see them from terminal emulator, but what I want to do is be able to see them from my PC and copy them over. I hoped Myphoneexplorer would let me do that but as it doesn't have root access it can't.

I use adb and would suggest you set it up too if you're going to do this more than once. In the mean time, open your term and

$ mkdir /sdcard/[dir_name]

$ su

# cp /data/app/* /sdcard/[dir_name]/

where [dir_name] is whatever you want to call a directory for a copy of your apps. This will copy all the apps to the directory you just created to your sd-card. Hope it helps!

edit: too late ;) glad you figured it out!

Edited by sm4tik
Link to comment
Share on other sites

Guest DaneelS

I'm on gen 2, an earlier version (3?), which I don't think has adb?

I think the next problem is that some apps don't just need that apk file, but some other installed files also, and I'm not sure how to either identify which apps are like that, or capture those other files for them.

Most of the time using titanium is probably the best approach, the only downside is the wasted space in the system partition.

Edited by DaneelS
Link to comment
Share on other sites

Guest sm4tik
I'm on gen 2, an earlier version (3?), which I don't think has adb?

I think the next problem is that some apps don't just need that apk file, but some other installed files also, and I'm not sure how to either identify which apps are like that, or capture those other files for them.

Most of the time using titanium is probably the best approach, the only downside is the wasted space in the system partition.

Adb isn't dependent on your phone, all you have to do is to enable debugging under application settings and then set it up on your computer. I've actually run into that other problem also where I haven't been able to find the other files assosiated with the apk. Not sure how to get those files, but I thought I'd make a backup with TB and see what's inside backup file, mabe that'll give a hint?

Link to comment
Share on other sites

Guest KonstaT
I've actually run into that other problem also where I haven't been able to find the other files assosiated with the apk. Not sure how to get those files, but I thought I'd make a backup with TB and see what's inside backup file, mabe that'll give a hint?

You can find missing files in app's .apk file. Just unzip the .apk file and copy .so files from lib/armeabi/ to your ROMs /system/lib. This has fixed force close issues when I have included terminal emulator, quickpic, etc in ROMs.

Link to comment
Share on other sites

Guest sm4tik
You can find missing files in app's .apk file. Just unzip the .apk file and copy .so files from lib/armeabi/ to your ROMs /system/lib. This has fixed force close issues when I have included terminal emulator, quickpic, etc in ROMs.

Thanks a bunch for the hint, it'll come in handy!

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.