Kivy / buildozer error when creating my apk

1

I have a problem when trying to create an apk from my .py file created with the kivy framework the error and the commands I use are the following

 wonder@wonder-M720SR:~/Kivy-Calculator$ buildozer android debug 

deploy run

# Check configuration tokens
# Ensure build layout
# Check configuration tokens
# Preparing build
# Check requirements for android
# Install platform
# Apache ANT found at /home/wonder/.buildozer/android/platform/apache-ant-1.9.4
# Android SDK found at /home/wonder/.buildozer/android/platform/android-sdk-20
# Android NDK found at /home/wonder/.buildozer/android/platform/android-ndk-r9c
# Check application requirements
# Check garden requirements
# Compile platform
# Command failed: /usr/bin/python3 -m pythonforandroid.toolchain create --dist_name=myapp --bootstrap=sdl2 --requirements=kivy --arch armeabi-v7a --copy-libs --color=always --storage-dir=/home/wonder/Kivy-Calculator/.buildozer/android/platform/build
# 
# Buildozer failed to execute the last command
# If the error is not obvious, please raise the log_level to 2
# and retry the latest command.
# In case of a bug report, please add a full log with log_level = 2

executing the command that generated the problem I receive this result:

wonder@wonder-M720SR:~/Kivy-Calculator$ /usr/bin/python3 -m pythonforandroid.toolchain create --dist_name=myapp --bootstrap=sdl2 --requirements=kivy --arch armeabi-v7a --copy-libs --color=always --storage-dir=/home/wonder/Kivy-Calculator/.buildozer/android/platform/build
[INFO]:    Will compile for the following archs: armeabi-v7a
[INFO]:    Found possible SDK dirs in buildozer dir: android-sdk-20
[INFO]:    Will attempt to use SDK at /home/wonder/.buildozer/android/platform/android-sdk-20
[WARNING]: This SDK lookup is intended for debug only, if you use python-for-android much you should probably maintain your own SDK download.
[INFO]:    Android API target was not set manually, using the default of 15
[INFO]:    Available Android APIs are (19)
[WARNING]: Requested API target 15 is not available, install it with the SDK android tool.
[WARNING]: Exiting.

thanks in advance

    
asked by wonderly gonzalez 10.10.2017 в 04:08
source

1 answer

0

In this case it is important to install the SDK that is indicated as target , this to generate the .apk, if you do not define a target the API 15 is configured by default

  

Android API target was not set manually, using the default of 15   [INFO]: Available Android APIs are (19) [WARNING]: Requested API   target 15 is not available, install it with the SDK android tool.

But the API 15 is not installed, it is necessary to install it or as another option it defines as target the 19 that is the one that you have currently installed.

Edit your file buildozer.spec and add the version of the SDK to use (it must be installed), for example if it is 19:

# (int) Android SDK version to use
#android.sdk = 21
android.sdk = 19
    
answered by 10.10.2017 / 16:33
source