summaryrefslogtreecommitdiffstats
path: root/tools/configure
diff options
context:
space:
mode:
authorEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>2016-03-09 18:27:50 +0100
committerEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>2016-03-10 11:57:39 +0000
commit437f5662d37ec2334e16b51e8d4543025e36d929 (patch)
tree9c0e2d79e95d370e6420e9fd2a9c67ee13b5b8ca /tools/configure
parentfb196e88074a8547ef93030ee385227664965106 (diff)
Allow overriding Android NDK host on Windows
The -android-ndk-host argument to configure existed in the shell script, but not in the Windows version. When using a 64-bit NDK but a 32-bit host compiler (which is what we bundle with our SDK), we would not detect the correct NDK host, making it impossible to build Qt with this combo. [ChangeLog][Android] Added -android-ndk-host configure option on Windows. Change-Id: Ie6a92b66e6875ed53f46fe41ecced70c3ec67585 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Diffstat (limited to 'tools/configure')
-rw-r--r--tools/configure/configureapp.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp
index 298e27244e..f63892b6cc 100644
--- a/tools/configure/configureapp.cpp
+++ b/tools/configure/configureapp.cpp
@@ -1370,6 +1370,14 @@ void Configure::parseCmdLine()
dictionary[ "ANDROID_PLATFORM" ] = configCmdLine.at(i);
}
+ else if (configCmdLine.at(i) == "-android-ndk-host") {
+ ++i;
+ if (i == argCount)
+ break;
+
+ dictionary[ "ANDROID_HOST" ] = configCmdLine.at(i);
+ }
+
else if (configCmdLine.at(i) == "-android-arch") {
++i;
if (i == argCount)
@@ -3464,7 +3472,9 @@ void Configure::generateQDevicePri()
deviceStream << "android_install {" << endl;
deviceStream << " DEFAULT_ANDROID_SDK_ROOT = " << formatPath(dictionary["ANDROID_SDK_ROOT"]) << endl;
deviceStream << " DEFAULT_ANDROID_NDK_ROOT = " << formatPath(dictionary["ANDROID_NDK_ROOT"]) << endl;
- if (QSysInfo::WordSize == 64)
+ if (dictionary.contains("ANDROID_HOST"))
+ deviceStream << " DEFAULT_ANDROID_NDK_HOST = " << dictionary["ANDROID_HOST"] << endl;
+ else if (QSysInfo::WordSize == 64)
deviceStream << " DEFAULT_ANDROID_NDK_HOST = windows-x86_64" << endl;
else
deviceStream << " DEFAULT_ANDROID_NDK_HOST = windows" << endl;