Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-71590

Qt is using "Non-SDK" interfaces, will be blocked by Android

    XMLWordPrintable

    Details

    • Platform/s:
      Android
    • Sprint:
      2021wk30POAndroid, 2021wk32POAndroid, 2021wk34POAndroid, 2022wk02FOAndroid&Automotive, 2022wk04FOAndroid&Automotive

      Description

      In Android 9 on Qt 5.11.2 and using API 28 (tried others as well), at startup, I'm seeing output like this on simplistic Qt apps:

      Accessing hidden method Landroid/graphics/drawable/BitmapDrawable;->getTintMode()Landroid/graphics/PorterDuff$Mode; (light greylist, reflection)

      and

      java.lang.NoSuchFieldException: No field mPivotX in class Landroid/graphics/drawable/RotateDrawable$RotateState;

      When you look into this you discover that Android is going start disabling applications that use private "non-SDK" interfaces: https://developer.android.com/about/versions/pie/restrictions-non-sdk-interfaces

      You can suppress the warning popup by using an SDK target of 28, but, that doesn't change the new policy being pushed by Google to stop all applications (including all those written using Qt) from accessing non-public APIs.

        Attachments

        1. android-11-crashes.txt
          1 kB
          Anonymous
        2. android-grey-fail-list.txt
          60 kB
          Alex Blasche
        3. google-pixelbook-app-launch-warnings.txt
          25 kB
          Niels Mayer
        4. google-pixelbook-app-launch-warnings-after-style-extraction-none.txt
          7 kB
          Niels Mayer
        5. non-sdk-interfaces-in-reported-via-systemdialog.txt
          35 kB
          Anonymous
        6. qt_error.txt
          193 kB
          Tuomas Vaarala
        7. styleable_resources_attr_name_and_value.xml
          104 kB
          Anonymous
        8. styleable_resources.xml
          93 kB
          Anonymous

          Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            Activity

              People

              Assignee:
              assam Assam Boudjelthia
              Reporter:
              obsess Nicolas Sterling
              Votes:
              26 Vote for this issue
              Watchers:
              47 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes