hello, I'm interested in editing some features of an apk. I've seen many a dev edit stock apps to work better, by removing limitations, or battery thresholds. I want to remove the wifi only option from the crunchyroll app, so that I can use it over 3g. I probably won't be successful, but it'll be a good learning experience. can anyone point me in the right direction of what program to use to start editing an apk? I'm using windows, but if need be, I can install Linux. thanks!
Sent from my GT-I9100 using XDA App
The APK Manager is good for decompiling/recompiling and all those things.
Link: http://apkmultitool.com
For editing xml files, use Notepad++
Related
I am trying to get the Library and Reader apks from the 2.1 working on cm7. I am fairly close (I hope), the next thing I have to do is sign the apks with the same key as the other apks that share the "media" userid.
If you copy over the following files you will get to where I am at.
[not sure what apks I will need just yet, so this might change]
Code:
/system/app/CryptoServer.apk
/system/app/GlobalSearch.apk
/system/app/Home.apk
/system/app/Library.apk
/system/app/Reader.apk
copy these supporting libraries/files
Code:
/system/framework/bncloudapi.jar
/system/framework/com.bn.authentication.jar
/system/framework/com.bn.cloud.jar
/system/framework/com.bn.gpb.jar
/system/framework/com.bn.provider.utils.jar
/system/lib/libbndeviceinfo.so
/system/lib/libbravodeviceinfo.so
/system/lib/libpdfhost.so
/system/etc/permissions/com.bn.app.crypto.xml
/system/etc/permissions/com.bn.app.deviceinfo.xml
Edit the following file and add the information below
Code:
/system/etc/permissions/platform.xml
This will declare the library in order for the apps to use it.
Code:
<!-- This is a list of all the libraries available for application
code to link against. -->
<library name="android.test.runner"
file="/system/framework/android.test.runner.jar" />
<library name="javax.obex"
file="/system/framework/javax.obex.jar"/>
<library name="com.bn.gpb"
file="/system/framework/com.bn.gpb.jar"/>
<library name="bncloudapi"
file="/system/framework/bncloudapi.jar"/>
<library name="com.bn.cloud"
file="/system/framework/com.bn.cloud.jar"/>
<library name="com.bn.authentication"
file="/system/framework/com.bn.authentication.jar"/>
<library name="com.bn.provider.utils"
file="/system/framework/com.bn.provider.utils.jar"/>
Once you have all this in place, restart the device. Logcat will complain about the wrong certificate for the user android.media.
My next steps are to find out which apks on cm7 use this shared id and resign them all with the same key.
Once that is done, I will launch the Library and Reader with the following commands in adb to attempt to start the activities:
Reader
Code:
am start -a android.intent.action.VIEW -n com.bn.nook.reader.activities/com.bn.nook.reader.activities.ReaderActivity
Library
Code:
am start -a android.intent.action.MAIN -n com.bn.nook.library/com.bn.nook.library.LibraryMainActivity
Very interesting concept. Possibly post in other developers sections than the NC - you may get some support.
I'm not a coder but I follow the concept.
I hope you and others are able to get this to work, because the stock reader app is my favorite.
Not sure if you've already caught this, but from looking at files so far in the APK I think there is a call being made to check for the version of android (specifically Android SDK 7 (2.1)). Is this something you got around by recompiling it?
I've made more progress. I signed the apks with ZipSigner (free in the market). I am getting some force closes trying to run the Library right now, which means I probably need to sign more of the BN apks.
FYI, if anybody else wants to give this a shot, my steps were:
1. edit the apk with 7zip and remove the META-INF dir (not sure if this is required by zipsigner) to unsign it
2. push the unsigned apk to the nook's sdcard
3. From the nook run ZipSigner and choose "media" for the key
4. sign it
5. copy the signed apk to /system/app
If you do this with the Library you should see it show up in the app drawer.
i would love to see this working
Pyrot1c said:
i would love to see this working
Click to expand...
Click to collapse
Agree'd I tried this a while back, but I really know nothing about dev stuff for android, so I didn't get far, I was really hoping someone with the know how would do this.
More Power to you. Can't wait to see this working, the library and shop apps that come with the nook color, are so much better than the Nook app off the market.
I've made a little more progress. I had to decompile the cm7 framework.jar and add some files from nook's framework.jar. I also had to merge changes into 2 files. This was all in order to get the Library app up and running. I have it loading up and I am able to see my sd card.
When I click on an epub it tries to launch the Reader but for some reason the Reader app isn't finding the libpdfhost.so shared library.
I will post instructions on what to do to the framework.jar to get the Library app up and running, but I think long-term it won't be feasible to have since the changes will need to be applied every cm7 update.
What will probably happen is I will make an app that handles epub intents and passes that off to the Reader app. The Library is adding some extra info when it starts the Reader app so I will need to copy that.
This will all be possible once I figure out why the shared library isn't being loaded properly.
Nice job man! Keep it going
Would love to see this working as well keep up the good work
Really cool.
Great progress so far. If you need a tester I'm.
I completely understand why CM can't distribute B&N software, but often it is not recognised that to many of us, the Nook Color is a family device. So it would be great if we can make these mods ourselves.
With the Market Nook app not having newspapers and magazines or NC childrens books, we still have to accommodate the entire family, in which some members of mine, still think of Gingerbread only as a type of cookie.
While I think about it...mmm ..could the library not be found because the original app's code was written to look within the file structure of Eclair instead of Gingerbread and Ext4? Or have you completely rewritten the code for the new file structure? Just thinking on my feet before I seriously studied the posted commands.
Thanks again!
Following this thread with great excitement. I would love to be able to run CM7 but still have the stock nook color app (which supports magazines, nookbooks for kids, etc.). Keep up the great work!!!!
/Kevin
OMG this would be awesome!!!
JoshMiers said:
I've made a little more progress. I had to decompile the cm7 framework.jar and add some files from nook's framework.jar. I also had to merge changes into 2 files. This was all in order to get the Library app up and running. I have it loading up and I am able to see my sd card.
When I click on an epub it tries to launch the Reader but for some reason the Reader app isn't finding the libpdfhost.so shared library.
I will post instructions on what to do to the framework.jar to get the Library app up and running, but I think long-term it won't be feasible to have since the changes will need to be applied every cm7 update.
What will probably happen is I will make an app that handles epub intents and passes that off to the Reader app. The Library is adding some extra info when it starts the Reader app so I will need to copy that.
This will all be possible once I figure out why the shared library isn't being loaded properly.
Click to expand...
Click to collapse
Have you given libpdfhost.so the correct permissions? If not chmod that mofo.
I attempted this a few weeks back myself. Your first post describes my findings exactly, including which files to copy over and adding the shared libs to platform.xml. Your followup post on modding the framework and getting the Library to stay open without FC is further than I got, however. If you want to compare notes, hit me on freenode, #nookie.
In the end, I gave up primarily because the work involved seemed to not be work it considering the Nook app from the market is quite good. The only thing it lacks is magazine subscriptions, I think. I might like a second look considering you seem to be getting closer.
-Muffin
that would be real cool if you guys could make this work.
I wish i knew how to make apps... but i'm not talented like that unfortunately.
anyone got an idea as to how to deal with the home button not working after upgrade? how about clearing of opened up apps in the notification section? how about closure of apps after being done with them as not all apps have exit button ?
i'd appreciate any comments.
thanks
Subscribed. This is the only thing keeping me from upgrading to a Froyo/GB/Honeycomb build.
Also sub'ed ... about to go with a dual-boot Stock+Froyo but would love to have the app on Froyo so I could dump stock.
This is the only thing holding me back from completely getting rid of stock. I actually use Aldiko for reading most of my books but am really looking forward to being able to read magazines from CM7.
I just wanna say keep up the good work. Your progress looks promising thus far.
Having this as an option would be great... seriously.
Work was busy last week so I didn't have much time to look into this.
I have hit a few potentially serious roadblocks. Other than needing to modify the framework.jar (with fairly simple changes) I will also need to either modify the MediaProvider.apk or write my own media provider that declares the content:// URLs that the Reader and Library apps expect.
I figured out how to launch the Reader apk from the commandline, so it will be trivial to write a front-end to do this when an epub is clicked. Also, I have gottem the Reader app to display the first page of my epub before force closing (due to unhandled content:// intents).
I was going to just stop working on this since Aldiko is suitable for my needs right now, but judging by the replies I will keep banging on it and try and write a media provider for all the content intents being sent.
I am wanting to know if there is a PC program to assist in themeing android devices? For example, it gets kind of tiring decompiling apks, editing pngs/XML files, recompiling,zipping & flashing for a trial and error test and if it isn't how you wanted it you have to go through the edit process all over again. I am requesting a PC program where you could load an apk and it visually show you an android handset where clicking different parts and selecting different options is a factor (change color/change image/change font etc.) If there is something like this that already exists please point me in the right direction and I'm not talking about using someone else's already made theme either. Thanks
Sent from my Nexus S 4G using XDA Premium App
Hey friendly xda people So I am in the beginning stages of a full on android addiction and decided I would start my first real project by attempting to re skin an existing app that is extremely well featured but lacking visually so I chose ... well I don't think I will say out of respect for the developer. But realistically I have many years experience using adobe products and am more than comfortable mucking around with pngs. So where I am at now is I have a good 80% of the assets re skinned and updated to a more kit kat like look and have verified that the dev has used no 9 pngs that I have accidentally edited, but this is where I am stuck. I have followed the walkthroughs to use apktool and signapk + zipallign to get the apk ready and have finished with the process. When I then go to load the apk on the phone I get the app to install, but then when it runs the app closes right after its splash screen. So I do understand that sight unseen it will be quite difficult to diagnose what problem I am having, but I'm learning and really would like some insight into some sort of trick/ tool or process that I could use to track down where my issue lies.
uprightbass360 said:
Hey friendly xda people So I am in the beginning stages of a full on android addiction and decided I would start my first real project by attempting to re skin an existing app that is extremely well featured but lacking visually so I chose ... well I don't think I will say out of respect for the developer. But realistically I have many years experience using adobe products and am more than comfortable mucking around with pngs. So where I am at now is I have a good 80% of the assets re skinned and updated to a more kit kat like look and have verified that the dev has used no 9 pngs that I have accidentally edited, but this is where I am stuck. I have followed the walkthroughs to use apktool and signapk + zipallign to get the apk ready and have finished with the process. When I then go to load the apk on the phone I get the app to install, but then when it runs the app closes right after its splash screen. So I do understand that sight unseen it will be quite difficult to diagnose what problem I am having, but I'm learning and really would like some insight into some sort of trick/ tool or process that I could use to track down where my issue lies.
Click to expand...
Click to collapse
From what I understood the app force closes because you edited the *.9.png, right? I suggest you to do exactly this process:
-Take a new APK of the app
-Rename to *.zip
-Open it with 7zip (DO NOT EXTRACT IT)
-Copy the new assets and res/layout pictures in the same folders of the 7zip opened APK
-Save it as a *.zip
-Rename it to *.apk
-Try to install and open it
Hope it helps
Be gentle, new poster...
I've been scouring Google Play Market, F-Droid, and the net in general for an app that can Monitor and Log all files/folders created during the installation of another apk. Preferably one that can revert these changes with it's own uninstall sequence.
I'm so tired of having to root around in a file explorer trying to identify and clean out completely useless folders and files left behind by over-reaching apps. ES File explorer pro has a feature that cleans -some- of this crud upon uninstalling an app, but it leaves much behind.
Any suggestions? Pointers? I'm not opposed to creating my own Tasker profile to achieve the results, but I'd rather have a nice neat all-in-one app for it.
[Sorry if this is in the totally wrong forum, or I made any kind of posting whoopsie. Still very new to posting in forums, feel free to berate me and point me to the right place, so that I learn.]
maybe Xinstaller,app cache cleaner,smart booster (3 of them or 2 of them can help for setting things that u want.
@mark manning
sir,
another 1..
please move it to dedicated forum.
I'm looking for the same type of app.
I was using SD maid on my rooted S2 and it was doing some kind of tracking app installations.
And after getting rid of the app, it showed corps from the specific app.
But I think it didn't show all of em.
Cause while using an Explorer like solid Explorer, I still could find some folders from apps I already deleted from my phone.
Not just folders, also library's, thumbnails and many more stuff like that.
It's not a big deal, but if you trying a lot of apps without keeping them on your phone, like me, you will came to that point, where your phone is floated with stuff from apps you aren't using anymore.
So if there is an app out there,at best without needing root, I would love this app and also would be willing to pay for it.
And if there is no app out there, what I can't imagine, we should contact an dev with that idea.
And because I'm an German, don't get mad at my bad English skills.
Sent from my SM-N915FY using XDA-Developers mobile app
Afaik, such an app does not exist (yet).
SD Maid's CorpseFinder the closest thing we have right now, but it's passive and database based.
I've looked into this idea already and some things worked, but it was not reliable or safe enough to just start deleting files based the collected information.
It also wasn't very battery friendly.
hello. i thought to be smart and download the APK through a downloader in browser on PC, but is still not able to install. it just says "App not installed".
ANYHOW... i feel this app should work just fine on the phone. problem is is that the company don't want it on other phones. so, there are some HTC and Sony apps from my past that won't install to a Coolpad phone i have.
is there any way to modify the APK so it will properly install? i don't believe the app to actually be incompatible, it is just proprietary to a different brand of phone.
the app i most want right now is > https://play.google.com/store/apps/details?id=com.sonymobile.xperiaweather
i used this to download it > https://apps.evozi.com/apk-downloader/
thanks for reading! i await any responses
@sk74261700027
If your phone's Android is rooted, you can try to edit Android's build.prop file housed in /system, will say change there brand / model settings according to your needs. Use a "BuildProp Editor" app to manage this,
jwoegerbauer said:
@sk74261700027
If your phone's Android is rooted, you can try to edit Android's build.prop file housed in /system, will say change there brand / model settings according to your needs. Use a "BuildProp Editor" app to manage this,
Click to expand...
Click to collapse
shoot. i have yet to figure out how to root this phone. it doesn't seem like there is any public root method for this phone yet. drat.
but if i could do that on the phone... shouldn't it also be possible to do this in the APK? i also don't know exactly what info that would be put there even if the phone was rooted. meh.
i figured worst case, i could use the regular Android software on PC to make changes to the APK. other then that, i think it could be possible to make changes to the APK with luckypatcher, but am not certain about that.
@sk74261700027
I never made use of LP.
You of course can try to decomplie an APK, rewrite app's source code and afterwards recompile it and then correctly sign the APK. Personally never have done so.
jwoegerbauer said:
@sk74261700027
I never made use of LP.
You of course can try to decomplie an APK, rewrite app's source code and afterwards recompile it and then correctly sign the APK. Personally never have done so.
Click to expand...
Click to collapse
oof. that sounds complicated. lol :/
i know there is Android Studio and SDK tools, but there is a lot there and i don't know exactly what is needed. i was just hoping that changing an APK for proprietary apps to install on non-proprietary devices was a normal thing, and that there would be a straight forward way to do this. sadly, i don't see any guides on this.
might just have to look around for something more generalized, like what you were talking about. i am surprised that there isn't a normal process for this type of thing. meh
well, thanks anyhow. thank you for replying here. at least that might give me an idea on where to go from here. in the meantime, imma just give this thread some more time. see if anyone knows anything more specific about this.
P.S. oh yeah! i do recall some kind of google market app that would allow you to change, or emulate, a device to download apps from the Play Store that are stated as not being compatible. will have to look for that and see if it still works. if someone knows where to find this, that would be really great.