Fix many Android build issues
authorLoic Blot <loic.blot@unix-experience.fr>
Sun, 10 Jun 2018 14:59:34 +0000 (16:59 +0200)
committerLoic Blot <loic.blot@unix-experience.fr>
Sun, 10 Jun 2018 15:54:44 +0000 (17:54 +0200)
It remains one issue with MT itself and rtti

build/android/Makefile
build/android/jni/Application.mk
build/android/jni/Deps.mk
build/android/jni/Irrlicht.mk
build/android/patches/irrlicht-native_activity.patch

index f32dbdc11f0d2621a50225b7fc5b36402b49781d..1d6df6e7d16889e5a0490454cc928a44371ed506 100644 (file)
@@ -86,7 +86,7 @@ OGG_LIB = $(OGG_DIR)libs/$(TARGET_ABI)/libogg.so
 VORBIS_LIB = $(OGG_DIR)libs/$(TARGET_ABI)/libogg.so
 OGG_TIMESTAMP = $(OGG_DIR)timestamp
 OGG_TIMESTAMP_INT = $(ANDR_ROOT)/deps/ogg_timestamp
-OGG_URL_GIT = https://github.com/vincentjames501/libvorbis-libogg-android
+OGG_URL_GIT = https://gitlab.com/minetest/libvorbis-libogg-android
 
 IRRLICHT_REVISION = 5145
 IRRLICHT_DIR = $(ANDR_ROOT)/deps/irrlicht/
@@ -268,11 +268,10 @@ $(OGG_LIB): $(OGG_TIMESTAMP)
        cd ${OGG_DIR};                                                             \
        export APP_PLATFORM=${APP_PLATFORM};                                       \
        export TARGET_ABI=${TARGET_ABI};                                           \
-       export TARGET_CFLAGS_ADDON="${TARGET_CFLAGS_ADDON}";                       \
-       export TARGET_CXXFLAGS_ADDON="${TARGET_CXXFLAGS_ADDON}";                   \
-       export COMPILER_VERSION=${COMPILER_VERSION};                               \
-       ${ANDROID_NDK}/ndk-build                                                   \
-               NDK_APPLICATION_MK=${ANDR_ROOT}/jni/Deps.mk || exit 1;                 \
+       ${ANDROID_NDK}/build/tools/make-standalone-toolchain.sh                    \
+               --toolchain=${TARGET_TOOLCHAIN}${COMPILER_VERSION}                     \
+               --platform=${APP_PLATFORM}                                             \
+               --install-dir=$${TOOLCHAIN};                                           \
        touch ${OGG_TIMESTAMP};                                                    \
        touch ${OGG_TIMESTAMP_INT};                                                \
        else                                                                       \
index 63442dbfc87add6cd8d20ee8d0d3da967122ce6e..f5eb96ed175edd8f4637465cd37f3cb6a5c21880 100644 (file)
@@ -1,8 +1,6 @@
 APP_PLATFORM := ${APP_PLATFORM}
 APP_ABI := ${TARGET_ABI}
 APP_STL := c++_shared
-NDK_TOOLCHAIN_VERSION := ${COMPILER_VERSION}
-APP_DEPRECATED_HEADERS := true
 APP_MODULES := minetest
 ifndef NDEBUG
 APP_OPTIM := debug
index 0d007b438d32d52e038176b9879832a0af3c20e8..ebed40adc8c3a37d7684ab712f522f7a68dbb35b 100644 (file)
@@ -4,5 +4,5 @@ APP_STL := c++_shared
 NDK_TOOLCHAIN_VERSION := ${COMPILER_VERSION}
 APP_DEPRECATED_HEADERS := true
 
-APP_CLAFGS += ${TARGET_CFLAGS_ADDON}
+APP_CFLAGS += ${TARGET_CFLAGS_ADDON}
 APP_CPPFLAGS += ${TARGET_CXXFLAGS_ADDON} -fexceptions -std=c++11
index 592e1c68f07789bd334bcee4b2749e909c387fea..cedfe3139db9f9e46c6d32f5fb4f4ad87e14e00f 100644 (file)
@@ -1,7 +1,6 @@
 APP_PLATFORM := ${APP_PLATFORM}
 APP_ABI := ${TARGET_ABI}
 APP_STL := c++_shared
-NDK_TOOLCHAIN_VERSION := ${COMPILER_VERSION}
 APP_DEPRECATED_HEADERS := true
 APP_MODULES := Irrlicht
 
index 5e9699e4f4df71ed33d685da71b06c6fc0cb54bd..83c837886fbb357e0d7bd9e2c4685960cf0ddf49 100644 (file)
@@ -1,12 +1,13 @@
---- irrlicht/source/Irrlicht/CEGLManager.cpp.orig      2017-11-15 18:19:58.467279274 +0000
-+++ irrlicht/source/Irrlicht/CEGLManager.cpp   2017-11-15 18:19:54.175279087 +0000
-@@ -8,6 +8,9 @@
+--- irrlicht/source/Irrlicht/CEGLManager.cpp.orig      2018-06-10 16:58:11.357709173 +0200
++++ irrlicht/source/Irrlicht/CEGLManager.cpp   2018-06-10 16:58:25.100709843 +0200
+@@ -9,6 +9,10 @@
  #include "irrString.h"
  #include "os.h"
 +#if defined(_IRR_COMPILE_WITH_ANDROID_DEVICE_)
 +#include <android/native_activity.h>
 +#endif
++
  namespace irr
  {
+ namespace video