简体   繁体   中英

SL4A Android x86 installation

I am currently developing a Android Application. I couldn't install the Android Python APKs like the sl4a.apk and the PythonInterpreter.apk on my Android x86 emulator. I read that it is possible to recompile the APKs with NDK but I have not found a closer decription, yet. Has anybody experience with this and could provide a small tutorial?

Best Regards

Try the official Android emulator. If the APKs include native libraries, chances are those are compiled for ARM only. Google's emulator emulates the ARM instruction set.

To make sure, rename the APK to ZIP and look inside. The structure of the lib folder, if any, will give you an idea.

you just install an APK package available here: http://code.google.com/p/android-scripting/downloads/detail?name=beanshell_for_android_r3.apk&can=2&q=

SL4A then you will have to start, edit your script, the APK package is available here: http://code.google.com/p/android-scripting/downloads/detail?name=sl4a_r4.apk&can=2&q=

Then you just google uses the SDK to emulate your scripts on a PC you also just edit directly with a text editor on Android for example "920 text editor"

sorry for the Google translation

++ BeHuman

To install SL4A, you will need to enable the "Unknown sources" option in your device's "Application" settings, download the .apk and install it either by accessing http://code.google.com/p/android-scripting/ from your computer and click the qr-code or directly from your phone and click the qr-code and then run the downloaded .apk file.

After installing SL4A:

  • press the Home button
  • press Add button
  • go to Interpreters
  • press Home button again
  • press Add again
  • pick Python Interpreter and install it

and after that a new screen will appear with an Install button on the top, press it and it will download Python 2.6.2, at the moment, for you. Optionally there is a button so that you can download a few more Python modules.

To build your new files you have a great little tutorial here: http://jokar-johnk.blogspot.com/2011/02/how-to-make-android-app-with-sl4a.html

Just follow all of these steps and you will be able to make working .apk files written in Python for your Android phone.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM