aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcus Comstedt2014-06-18 21:40:13 +0200
committerMarcus Comstedt2014-06-18 21:40:13 +0200
commit0e459796346ca98684a115302f448a6317799372 (patch)
tree59fb86d1e9ea596cff27b1709f8b577f9950df0f
parente395343064936cc04f777bb12391c34bdecbd992 (diff)
downloadscummvm-rg350-0e459796346ca98684a115302f448a6317799372.tar.gz
scummvm-rg350-0e459796346ca98684a115302f448a6317799372.tar.bz2
scummvm-rg350-0e459796346ca98684a115302f448a6317799372.zip
ANDROID: Allow build with non-ancient SDK
-rw-r--r--backends/platform/android/android.mk6
-rwxr-xr-xconfigure6
2 files changed, 9 insertions, 3 deletions
diff --git a/backends/platform/android/android.mk b/backends/platform/android/android.mk
index 7c4fe01d54..1a40299dcd 100644
--- a/backends/platform/android/android.mk
+++ b/backends/platform/android/android.mk
@@ -48,10 +48,10 @@ PLUGIN_RESOURCES = \
#LDFLAGS += -Wl,--gc-sections
#CXXFLAGS += -ffunction-sections -fdata-sections -fvisibility=hidden -fvisibility-inlines-hidden
-AAPT = $(ANDROID_SDK)/platform-tools/aapt
+AAPT = $(ANDROID_SDK)/$(ANDROID_BTOOLS)/aapt
ADB = $(ANDROID_SDK)/platform-tools/adb
-DX = $(ANDROID_SDK)/platform-tools/dx
-APKBUILDER = $(ANDROID_SDK)/tools/apkbuilder
+DX = $(ANDROID_SDK)/$(ANDROID_BTOOLS)/dx
+APKBUILDER = java -Xmx128M -classpath $(ANDROID_SDK)/tools/lib/sdklib.jar com.android.sdklib.build.ApkBuilderMain
JAVAC ?= javac
JAVACFLAGS = -source 1.5 -target 1.5
diff --git a/configure b/configure
index 46edeafa4e..3f49565010 100755
--- a/configure
+++ b/configure
@@ -2157,6 +2157,12 @@ case $_host_os in
LDFLAGS="$LDFLAGS -L$ANDROID_NDK/sources/cxx-stl/gnu-libstdc++/`$CXX -dumpversion`/libs/$ABI/"
LIBS="$LIBS -lsupc++"
add_line_to_config_mk "ANDROID_SDK = $ANDROID_SDK"
+ if test -d "$ANDROID_SDK"/build-tools; then
+ _build_tools_version=`cd "$ANDROID_SDK"/build-tools && ls -1 | sort -rn | head -1`
+ add_line_to_config_mk "ANDROID_BTOOLS = build-tools/$_build_tools_version"
+ else
+ add_line_to_config_mk "ANDROID_BTOOLS = platform-tools"
+ fi
_seq_midi=no
;;
beos*)