问题
I need to find a way to convert jar file to apk file. I have reached a road block!
回答1:
Is the JAR natively made for Android? If not, you'll have to run it in an emulation layer or something like this: http://microemu.blogspot.com/2008/11/running-java-me-applications-on-android.html
Good luck?
回答2:
I've never tried this tool, but you can give it a go:
http://www.netmite.com/android/srv/1.7/getapk.php
If it doesn't work then I think you'll have to use an emulator on the device, or create an apk from source, as expressed by Blender and burpen.
回答3:
According to this thread on xda-devs, you might be able to use something like this. However, if you have the source for the jar, then you might as well compile the apk from the source. It seems to depend on what the jar was compiled as.
回答4:
ok, guess the only way around it is to run the application on an android emulator, when that is done, an apk file is automatically generated in the project directory. If the application is not built by using android libraries then the only way to get an apk file is to rewrite the code by using android libraries and run it on an emulator. Bad news for me and some of you.
来源:https://stackoverflow.com/questions/4346924/how-can-i-convert-a-jar-file-into-apk-format