Hello, I've already raised an issue here but I was hoping to find more information on the forum.
My project compiles fine with Linux. If I want to build/compile it for Android, it is my understanding that I need to:
- run the
SConstruct
file insidegodot-cpp/
to build it - run the
SConstruct
file outsidegodot-cpp/
to compile it
Unfortunately I have failed on both accounts so far. I am aware that the two SConstruct
files are not the same one. Inside godot-cpp/
, this is what happens when I choose platform=android
:
$ scons platform=android target=release android_arch=arm64v8
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
/home/lol/Android/Sdk/ndk/toolchains/llvm/prebuilt/linux-x86_64/bin/clang++ -o src/core/PoolArrays.o -c --target=aarch64-linux-android21 -march=armv8-a -fPIC -I. -Igodot_headers -Iinclude -Iinclude/gen -Iinclude/core src/core/PoolArrays.cpp
sh: 1: /home/lol/Android/Sdk/ndk/toolchains/llvm/prebuilt/linux-x86_64/bin/clang++: not found
scons: *** [src/core/PoolArrays.o] Error 127
scons: building terminated because of errors.
I've tried to install Clang in the SDK but I failed to find where that was an option.
Outside godot-cpp/
, this is what happens when I choose platform=android
:
$ scons platform=android target=release android_arch=arm64v8
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
g++ -o demo/bin/libhexworld.so -shared src/GDLibrary.os -Lgodot-cpp/bin -lgodot-cpp.release.64
/usr/bin/ld: cannot find -lgodot-cpp.release.64
collect2: error: ld returned 1 exit status
scons: *** [demo/bin/libhexworld.so] Error 1
scons: building terminated because of errors.
Could you please help me? My OS is Ubuntu 18.04 LTS and I don't know what to do.