A project named Python For Android has been launched to create a package of your Python app into .apk. It is a Open Source project under the maintenance of Kivy Organisation.

It currently only has one bootstrap which decompresses the packed application's files and creates an OpenGL ES 2.0 surface for drawing and it also sets audio and touch events to be accessed.

Get Started

  • Download Android SDK or NDK.
  • Start and download latest Android platform
  • Export some other environment variables: _ export ANDROIDSDK="/path/to/android/android-sdk-linux86"
    _ export ANDROIDNDK="/path/to/android/android-ndk-r7"_
    _ export ANDROIDNDKVER=r7_
    _ export ANDROIDAPI=14_

  • Clone of python-for-android:

  • Build a distribution with OpenSSL module, PIL and Kivy:

        _cd python-for-android_  

    _ ./distribute.sh -m "openssl pil kivy"_

  • Go to your fresh distribution, build the APK of your application:

     _ cd dist/default_  

    _ ./build.py --package org.test.touchtracer --name touchtracer _
    _ --version 1.0 --dir ~/code/kivy/examples/demo/touchtracer debug_

  • Install the debug apk to your device:

      _adb install bin/touchtracer-1.0-debug.apk_  

    Now you are done
    Go to official Site http://python-for-android.readthedocs.org/en/latest/index.html.