Java + QT (Use QT in JAVA)

  • Good afternoon, there is a library for communicating with servers implemented on QT. There is also an application written in JAVA (Android Studio).

    Question is it possible to use the QT library in a java project?

    I created a test project, I took everything from the android project created in QT and added them to my libs folder. At startup, an error is written already at System.loadLibrary:

    A/QtCore: initJNI failed
    E/AndroidRuntime: FATAL EXCEPTION: main
        Process:, PID: 16392
        java.lang.UnsatisfiedLinkError: JNI_ERR returned from JNI_OnLoad in "/data/app/"
            at java.lang.Runtime.loadLibrary0(
            at java.lang.System.loadLibrary(


    import android.os.Bundle;
    public class MainActivity extends AppCompatActivity {
        static {
        protected void onCreate(Bundle savedInstanceState) {

  • @LeeTiK
    I think: read through Looks like people used to use Qt Jambi, but it's discontinued now.

    The last post there says:

    I believe it can be done using JNI (Java Native Interface) calls.

    Have a read through, that's 2018.

    So does get you what you are wanting?

  • not yet(
    But! I managed to connect qt under windows without any problems. One question remains, if there is any peculiarity when implementing this all in the android (Android Studio) !?
    Maybe if some example where QT is used in a java project for android?

Log in to reply