0 votes

If I try to build godot with an andorid module I receive the title error or better the following one:

 'SConsEnvironment' object has no attribute android_add_java_dir

I set my system variables as:

ANDROID_NDK_HOME --->  C:\android-ndk-r19c
ANDROID_NDK_ROOT --->  C:\android-ndk-r19c
ANDROID_HOME  --->  C:\Users\V\AppData\Local\Android\Sdk

But Scons is like is not able to find android what I'm doing wrong?
I'm able to correctly build android without any module

asked May 27, 2019 in Engine by vito (14 points)
edited May 27, 2019 by volzhs

1 Answer

+1 vote

android build is changed recently on master branch.

if you follow this tutorial, you need to checkout 3.1 branch, not master.
https://docs.godotengine.org/en/3.1/development/cpp/creating_android_modules.html?highlight=module

if you want to use master branch, you need to follow this article.
https://godotengine.org/article/godot-3-2-will-get-new-android-plugin-system

answered May 27, 2019 by volzhs (9,466 points)

I'm not creating a module I'm just trying to install one (admob or facebook integration). So my error is in building phase......

I'm downloading the 3.1 branch

It seems working, It is building but I don't understand why with the master it doesn't work, Can you explain me better? I cannot follow the links, I don't understand them well

Android build is changed for the new android plugin system.
with master(3.2), android module can be installed via assetlib, like admob
no need to recompile the whole godot engine source.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.