summaryrefslogtreecommitdiffstats
path: root/mkspecs/features/java.prf
diff options
context:
space:
mode:
authorBogDan Vatra <bogdan@kde.org>2014-07-29 16:13:57 +0300
committerBogDan Vatra <bogdan@kde.org>2014-07-31 14:16:51 +0200
commitef5fb6ead50ca4423c2a1fca8b75fa571adcd00d (patch)
tree1d46a63ab048169e297b3598d92867d08432d98a /mkspecs/features/java.prf
parent291c6615a3b5209760da03d1830d31a2581bd0cc (diff)
Android: export ANDROID_SDK_BUILD_TOOLS_REVISION.
It's needed by androiddeployqt tool to run "zipalign" tool and to set it to gradle properties. Task-number:QTBUG-40481 Change-Id: I3dd665a7461a4e981867cdad75a50940e46a5ae6 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Diffstat (limited to 'mkspecs/features/java.prf')
-rw-r--r--mkspecs/features/java.prf24
1 files changed, 5 insertions, 19 deletions
diff --git a/mkspecs/features/java.prf b/mkspecs/features/java.prf
index 790724cec9..1c55b8974e 100644
--- a/mkspecs/features/java.prf
+++ b/mkspecs/features/java.prf
@@ -1,24 +1,10 @@
TEMPLATE = lib
android {
- isEmpty(SDK_ROOT): SDK_ROOT = $$(ANDROID_SDK_ROOT)
- isEmpty(SDK_ROOT): SDK_ROOT = $$DEFAULT_ANDROID_SDK_ROOT
-
API_VERSION_TO_USE = $$(ANDROID_API_VERSION)
isEmpty(API_VERSION_TO_USE): API_VERSION_TO_USE = $$API_VERSION
isEmpty(API_VERSION_TO_USE): API_VERSION_TO_USE = android-10
- isEmpty(BUILD_TOOLS_REVISION) {
- BUILD_TOOLS_REVISION = $$(ANDROID_BUILD_TOOLS_REVISION)
- isEmpty(BUILD_TOOLS_REVISION) {
- BUILD_TOOLS_REVISIONS = $$files($$SDK_ROOT/build-tools/*)
- for (REVISION, BUILD_TOOLS_REVISIONS) {
- BASENAME = $$basename(REVISION)
- greaterThan(BASENAME, $$BUILD_TOOLS_REVISION): BUILD_TOOLS_REVISION = $$BASENAME
- }
- }
- }
-
- ANDROID_JAR_FILE = $$SDK_ROOT/platforms/$$API_VERSION_TO_USE/android.jar
+ ANDROID_JAR_FILE = $$ANDROID_SDK_ROOT/platforms/$$API_VERSION_TO_USE/android.jar
!exists($$ANDROID_JAR_FILE) {
error("The Path $$ANDROID_JAR_FILE does not exist. Make sure the ANDROID_SDK_ROOT and ANDROID_API_VERSION environment variables are correctly set.")
}
@@ -69,12 +55,12 @@ android:!bundled_jar_file {
# of the base sdk folder.
# Doing it this way makes this logic more similar to the other platforms and
# also means that our dx.bat is more like Google's dx.bat
- DEX_BAT = $$SDK_ROOT/platform-tools/dx.bat
- !exists($$DEX_BAT): DEX_BAT = $$SDK_ROOT/build-tools/$$BUILD_TOOLS_REVISION/dx.bat
+ DEX_BAT = $$ANDROID_SDK_ROOT/platform-tools/dx.bat
+ !exists($$DEX_BAT): DEX_BAT = $$ANDROID_SDK_ROOT/build-tools/$$ANDROID_SDK_BUILD_TOOLS_REVISION/dx.bat
DEX_CMD = $$PWD/data/android/dx $$DEX_BAT
} else {
- DEX_CMD = $$SDK_ROOT/platform-tools/dx
- !exists($$DEX_CMD): DEX_CMD = $$SDK_ROOT/build-tools/$$BUILD_TOOLS_REVISION/dx
+ DEX_CMD = $$ANDROID_SDK_ROOT/platform-tools/dx
+ !exists($$DEX_CMD): DEX_CMD = $$ANDROID_SDK_ROOT/build-tools/$$ANDROID_SDK_BUILD_TOOLS_REVISION/dx
!exists($$DEX_CMD): error("The path $$DEX_CMD does not exist. Please set the environment variable ANDROID_BUILD_TOOLS_REVISION to the revision of the build tools installed in your Android SDK.")
}
QMAKE_LINK_SHLIB_CMD = $$DEX_CMD --dex --output $(TARGET) $$CLASS_DIR