Commit 005f5116 authored by Daniel Teske's avatar Daniel Teske
Browse files

Android: Fix abi detection for 64bit devices



Change-Id: Idde12cd5bcd54d007245d3bdd93e8ab47d7f214b
Reviewed-by: default avatarPaul Olav Tvete <paul.tvete@theqtcompany.com>
parent cd8dc3ae
......@@ -840,6 +840,24 @@ bool AndroidConfig::hasFinishedBooting(const QString &device) const
QStringList AndroidConfig::getAbis(const QString &device) const
{
QStringList result;
// First try via ro.product.cpu.abilist
QStringList arguments = AndroidDeviceInfo::adbSelector(device);
arguments << QLatin1String("shell") << QLatin1String("getprop");
arguments << QLatin1String("ro.product.cpu.abilist");
QProcess adbProc;
adbProc.start(adbToolPath().toString(), arguments);
if (!adbProc.waitForFinished(10000)) {
adbProc.kill();
return result;
}
QString output = QString::fromLocal8Bit(adbProc.readAll().trimmed());
if (!output.isEmpty()) {
QStringList result = output.split(QLatin1Char(','));
if (!result.isEmpty())
return result;
}
// Fall back to ro.product.cpu.abi, ro.product.cpu.abi2 ...
for (int i = 1; i < 6; ++i) {
QStringList arguments = AndroidDeviceInfo::adbSelector(device);
arguments << QLatin1String("shell") << QLatin1String("getprop");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment