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

Qt 5.15.19 Fails to Build Android Application with OpenJDK 21

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • None
    • 5.15.19
    • Examples and Demos
    • None
    • Android

    Description

      Description:-

      Qt 5.15.19 fails to build an example application for Android using OpenJDK 21

      Environment:

      • Qt Version: 5.15.19
      • Qt Creator Version: 14.0.2
      • Operating System: Android 14
      • JDK Version: OpenJDK 21 (Fails), OpenJDK 17 (Works)

       

      Expected Behavior: The application should successfully build and deploy on an Android device using Qt Creator with OpenJDK 21.

      Actual Behavior:

      • Attempting to build the example application for Android using OpenJDK 21 results in a failure.
      • Downgrading to OpenJDK 17 allows the application to build and deploy successfully on Android.

      Steps to Reproduce:

      1. Install Qt 5.15.19 and configure Qt Creator for Android development.
      2. Set up OpenJDK 21 as the JDK in Qt Creator.
      3. Open any example application and configure it for Android.
      4. Attempt to build the application.
      5. Observe the build failure with an error message.
      6. Change JDK to OpenJDK 17 and rebuild.
      7. Observe that the application builds and deploys successfully.

      Workarounds Attempted:

      • Reinstalling OpenJDK 21.
      • Using different Gradle versions.
      • Ensuring correct Android SDK and NDK versions.
      • Switching to OpenJDK 17 (which resolved the issue).

      Additional Notes:

      • The issue is specifically observed with OpenJDK 21, while OpenJDK 17 works without problems.

      Attachments

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

        Activity

          People

            qtandroidteam Qt Android Team
            shzeya Shafqut Zeya
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes