I am new in android framework development .
I try to add a service in platform/base and then I make the whole platform folder follow a post online.
Now i don't know how this change can be applied to android application. Do I need to get a new android.jar package for the application?
Thanks
update --------------------------------------------
currently I have the android source code and modified its framework by adding a testservice.java following this : Android-Adding SystemService
Then I need to write a test app to use this testservice. But I don't how to add an app to that modified android source code. I try to following this:set up the Eclipse IDE for Android platform development to add app src path to eclipse build path , I doesn't work.
before this i use eclipse and ADT to write android apps, i am wondering is there any way to write an app in the modified android source code ?
Thanks
I copied an app under [androidroot]/packages/apps/ folder and rename it and modify some code . Then it shows in application list. It works! But the problem is the directory structure is strange , very different from the one I create from the eclipse + sdk . So is there anyone know how to develop apps under a modified android framework.
Thanks !!!
-
You may want to go into detail about what you are trying to do. Your question can't be answered without more details.James Black– James Black2011年10月08日 00:33:55 +00:00Commented Oct 8, 2011 at 0:33
2 Answers 2
I see a quick and dirty solution: replace the corresponding android.jar in the install SDK location (for example $ANDROID_HOME/platforms/android-8/android.jar if you deriver from Android 2.2).
Also you may try to spoof a separate platform revision in $ANDROID_HOME/platforms. Something like android-99 to avoid clashes with the actual future platforms.
Though all of these are dirty tricks this may work for quick testing of your platform code without much pain.
Comments
It is exactly the same as the project you create using eclipse. What's more all you need is to write a makefile in the directory. Then mmm framework/res framework systemserver
bw