question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Android NDK - "$NDK/platforms/android-25" missing?

See original GitHub issue

Versions

  • Python: 3.7
  • OS: Ubuntu 19.04
  • Kivy: 1.11.1
  • Cython: 0.29.13

Description

Español:

Según la información proporcionada por el foro de android NDK No hay una nueva versión nativa del NDK(version 15+)/platforms/android-25, por lo cual se debe compilar con el NDK/platforms/android-24. Android Studio reconoce este “error” y trabaja automáticamente con NDK/platforms/android-24 mientras que p4a no… (Existe un bug en android NDK 15c en el cual no trata la carpeta faltante android-25 y se debe usar manualmente android-24)

English:

The information provided from the forum from android NDK say that there’s there were no new native APIs in NDK(version 15+)/platforms/android-25, because of that it should be compiled with NDK/platforms/android-24. Android Studio knows about this “Error” and it works automatically with NDK/platforms/android-24 while p4a still dont. (there is a bug in NDK r15+: it does not treat correctly the missing android-25 folder. and it has to be used android-24 manually)

Sources:

buildozer.spec

Command:

AppDir$ buildozer -v android debug

Spec file:

requirements = sdl2, python3, sqlite3, kivy==master, kivymd, hostpython3, pillow, libffi
# (int) Target Android API, should be as high as possible.
android.api = 29

# (int) Minimum API your APK will support.
#android.minapi = 26 # Works
#android.minapi = 24 # Works
android.minapi = 25 < --- Error

# (int) Android SDK version to use
android.sdk = 28

# (str) Android NDK version to use
#android.ndk = 20

android.ndk = 19b
#android.ndk = 20

log_level = 2

Logs

--------------------------------------------------------------------------------------------------------------------------------
[INFO]:    Recipe kivy: version "master" requested
[WARNING]: $ANDROIDNDKVER is deprecated and no longer necessary, the value you set is ignored
[INFO]:    Will compile for the following archs: armeabi-v7a
[INFO]:    Found Android API target in $ANDROIDAPI: 29
[INFO]:    Available Android APIs are (29)
[INFO]:    Requested API target 29 is available, continuing.
[INFO]:    Found NDK dir in $ANDROIDNDK: $HOME/.buildozer/android/platform/android-ndk-r19b
[INFO]:    Found NDK version 19b
[INFO]:    Getting NDK API version (i.e. minimum supported API) from user argument
[INFO]:    Found virtualenv at /usr/local/bin/virtualenv
[WARNING]: ndk_platform doesn't exist: $HOME/.buildozer/android/platform/android-ndk-r19b/platforms/android-25/arch-arm <<< This is the error
[INFO]:    Found the following toolchain versions: ['4.9']
[INFO]:    Picking the latest gcc toolchain, here 4.9
[ERROR]:   Build failed: python-for-android cannot continue due to the missing executables above
--------------------------------------------------------------------------------------------------------------------------------

By the information of the sources it might be useful to link the missing NDK api levels to the next lower one found in the NDK/platforms folder

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
bevinhexcommented, Jun 30, 2021

If anyone got problem with build tools, due to ‘platforms’ folder, unless you really need the latest version, downgrade your NDK as a workaround, it is working for me.

1reaction
podracocommented, Sep 28, 2019

It’s not too clear to me what the error is, but if you want to use android.ndk = 19b then you also need p4a.branch = develop currently

i’m actually using that…

When the minimal API is set in 25, the project won’t compile because android NDK will not find the folder “$NDK/platforms/android-25” (because it doesn’t exists.)

That means that p4a needs to use API level to 24 when android.minapi = 25

Read more comments on GitHub >

github_iconTop Results From Across the Web

NDK Downloads | Android NDK - Android Developers
Select the NDK package for your development platform. ... You can download older unsupported versions of the NDK from the Unsupported NDK ......
Read more >
Resolved - Android NDK missing - Unity Forum
I installed - Unity 2019.3.0a4 Personal with Unity Hub 2.0.0. ISSUE : "You are missing the recommended Android NDK..." in "Preferences/External ...
Read more >
NDK is missing a "platforms" directory. while trying to build
I know this is old but just ran into this and the File -> Project Structure -> SDK Location - Android NDK Location...
Read more >
ndk-build doesn't report failure for missing dependent module ...
ndk -build will not produce an error even though the above module depends on a module that was never defined. The text was...
Read more >
Setting Up Android SDK and NDK for Unreal
1. Installing Android Studio. Before setting up the required SDK and NDK components on your computer, you need to install Android Studio. Refer...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found