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

JNI_OnLoad not called on Qt 5.9.6

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P2: Important
    • 5.11.1
    • 5.9.6, 5.11.2
    • Extras: Android
    • None
    • Android

    Description

      I have two Qt instances installed: 5.9.6 and 5.11.1 side by side. Today I accidentally found out that JNI_OnLoad is ignored on the former.

      Steps to reproduce:

      • create 'Qt Quick Application - Empty' from the wizard
      • add this functions to main.cpp:

      JNIEXPORT jint JNI_OnLoad(JavaVM vm, void * /*reserved/)

      { qDebug() << __FUNCTION__; return JNI_VERSION_1_6; }
      • change untitled.pro to:

      QT += quick androidextras

      • execute with 5.9.6 and 5.11.1

      There is no exception or any error whatsoever in the logcat. It just works on 5.11.1 and doesn't work on 5.9.6.

      Attachments

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

        Activity

          People

            rampe Rami Potinkara
            mikro Miro Kropacek
            Veli-Pekka Heinonen Veli-Pekka Heinonen
            Votes:
            1 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes