Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

"ABI is incompatible, device supports ABIs: ." with android sdk platform-tools v29.0.0



  • Hi all,
    I recently upgraded my android SDK and it brings me v29.0.0 of platform-tools with no way to get back. In this version, I suppose that ADB comportment changed a bit when listing device supported ABIs. So when trying to deploy an android app to a connected device (USB or TCPIP), QtCreator 4.9.1 reports only incompatible devices with this explanation : "ABI is incompatible, device supports ABIs: ." (No supported ABI!)

    By exploring QtCreator source code, I found that adb seems to crash after listing supported ABI of my phone. (It's not really a crash, but a non-0 exit code...)

    So I made a little ADB wrapper as a workaround and I post it here if it could help someone who encounters the same problem. You can use it by following these steps:

    1. Rename %AndroidSDK%\platform-tools\adb.exe as adb.exe.bak.exe
    2. Build a fake adb.exe using the following standard c++ code:
    #include <cstdlib>
    #include <string>
    #include <iostream>
    #include <algorithm>
    #include <cctype>
    
    int main(int argc, char *argv[])
    {
      std::string strCmd = std::string(argv[0]);
      std::string strExt = strCmd.substr(strCmd.length() - 4, 4);
      std::transform(strExt.begin(), strExt.end(), strExt.begin(),
                     [](unsigned char c) { return std::tolower(c); });
      if (strExt.compare(".exe") != 0)
        strCmd += ".exe";
    
      strCmd += ".bak.exe";
      
      if (argc > 1)
      {
        for (int i = 1; i < argc; ++i)
        {
          strCmd += " \"" + std::string(argv[i]) + "\"";
        }
      }
    
      std::system(strCmd.c_str());
    }
    
    1. Put this new adb.exe in %AndroidSDK%\platform-tools\

    I will try to propose a patch to QtCreator sources.



  • Thank you, having the same issue and your patch is working like a charm! Bravo!



  • That really saved me, thank you a lot!



  • It works! Thanks a lot!



  • From now, you can update your Android platform-tools to v29.0.1 using sdkmanager --update. ADB has been corrected by Google.


Log in to reply