Note that I am able to configure and deploy using ndk-r9d with GCC 4.8, but debugging does not work at all on a Galaxy S6. Setting a breakpoint in main(), nothing is hit. Note that I am able to debug using Android Studio for a regular Java app on the device. This is the application output:
Debugging starts
E/Zygote (18560): MountEmulatedStorage()
E/Zygote (18560): v2
I/libpersona(18560): KNOX_SDCARD checking this for 10265
I/libpersona(18560): KNOX_SDCARD not a persona
I/SELinux (18560): Function: selinux_compare_spd_ram , priority [2] , priority version is VE=SEPF_SM-G920V_5.0.2_0009
E/SELinux (18560): [DEBUG] get_category: variable seinfo: default sensitivity: NULL, cateogry: NULL
I/art (18560): Late-enabling -Xcheck:jni
D/TimaKeyStoreProvider(18560): TimaSignature is unavailable
D/ActivityThread(18560): Added TimaKeyStore provider
I/InjectionManager(18560): Inside getClassLibPath + mLibMap{0=, 1=}
D/AssetManager(18560): addAssetPath path =/data/app/org.qtproject.example.MyApp-1/base.apkmapset is 0
D/AssetManager(18560): addAssetPath path =/data/app/org.qtproject.example.MyApp-1/base.apk, mapOffset =0
D/AssetManager(18560): addAssetPath path =/data/app/org.qtproject.example.MyApp-1/base.apk,elasticAppCookieOffset ={3=0}
I/LoadedApk(18560): getClassLoader :null
I/InjectionManager(18560): Inside getClassLibPath caller
I/LoadedApk(18560): classLibPath :, mActivityThread.mCoreFeatureClassLoader :null
D/InjectionManager(18560): InjectionManager
D/InjectionManager(18560): fillFeatureStoreMap org.qtproject.example.MyApp
I/InjectionManager(18560): Constructor org.qtproject.example.MyApp, Feature store :{}
I/InjectionManager(18560): featureStore :{}
I/LoadedApk(18560): getClassLoader :dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/org.qtproject.example.MyApp-1/base.apk"],nativeLibraryDirectories=[/data/app/org.qtproject.example.MyApp-1/lib/arm, /vendor/lib, /system/lib]]]
I/LoadedApk(18560): getClassLoader :dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/org.qtproject.example.MyApp-1/base.apk"],nativeLibraryDirectories=[/data/app/org.qtproject.example.MyApp-1/lib/arm, /vendor/lib, /system/lib]]]
I/LoadedApk(18560): getClassLoader :dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/org.qtproject.example.MyApp-1/base.apk"],nativeLibraryDirectories=[/data/app/org.qtproject.example.MyApp-1/lib/arm, /vendor/lib, /system/lib]]]
I/LoadedApk(18560): getClassLoader :dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/org.qtproject.example.MyApp-1/base.apk"],nativeLibraryDirectories=[/data/app/org.qtproject.example.MyApp-1/lib/arm, /vendor/lib, /system/lib]]]
I/LoadedApk(18560): getClassLoader :dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/org.qtproject.example.MyApp-1/base.apk"],nativeLibraryDirectories=[/data/app/org.qtproject.example.MyApp-1/lib/arm, /vendor/lib, /system/lib]]]
I/LoadedApk(18560): getClassLoader :dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/org.qtproject.example.MyApp-1/base.apk"],nativeLibraryDirectories=[/data/app/org.qtproject.example.MyApp-1/lib/arm, /vendor/lib, /system/lib]]]
I/LoadedApk(18560): getClassLoader :dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/org.qtproject.example.MyApp-1/base.apk"],nativeLibraryDirectories=[/data/app/org.qtproject.example.MyApp-1/lib/arm, /vendor/lib, /system/lib]]]
I/LoadedApk(18560): getClassLoader :dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/org.qtproject.example.MyApp-1/base.apk"],nativeLibraryDirectories=[/data/app/org.qtproject.example.MyApp-1/lib/arm, /vendor/lib, /system/lib]]]
I/LoadedApk(18560): getClassLoader :dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/org.qtproject.example.MyApp-1/base.apk"],nativeLibraryDirectories=[/data/app/org.qtproject.example.MyApp-1/lib/arm, /vendor/lib, /system/lib]]]
I/LoadedApk(18560): getClassLoader :dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/org.qtproject.example.MyApp-1/base.apk"],nativeLibraryDirectories=[/data/app/org.qtproject.example.MyApp-1/lib/arm, /vendor/lib, /system/lib]]]
I/LoadedApk(18560): getClassLoader :dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/org.qtproject.example.MyApp-1/base.apk"],nativeLibraryDirectories=[/data/app/org.qtproject.example.MyApp-1/lib/arm, /vendor/lib, /system/lib]]]
D/PhoneWindow(18560): FMB installDecor mIsFloating : false
D/PhoneWindow(18560): FMB installDecor flags : 8454400
I/Qt (18560): qt start
D/ (18560): (null):0 ((null)): QML debugging is enabled. Only use this in a safe environment.
I/Qt JAVA (18560): DEBUGGER: extra parameters: Bundle[{debug_ping=true, gdbserver_socket=/data/data/org.qtproject.example.MyApp/debug-socket, qml_debug=true, gdbserver_command=/data/data/org.qtproject.example.MyApp/lib/libgdbserver.so --multi +/data/data/org.qtproject.example.MyApp/debug-socket, qmljsdebugger=port:50111,block, ping_socket=org.qtproject.example.MyApp.ping_pong_socket}]
I/Qt JAVA (18560): DEBUGGER: removing gdb socket /data/data/org.qtproject.example.MyApp/debug-socket
I/Qt JAVA (18560): DEBUGGER: starting /data/data/org.qtproject.example.MyApp/lib/libgdbserver.so --multi +/data/data/org.qtproject.example.MyApp/debug-socket
I/Qt JAVA (18560): DEBUGGER: gdbserver started
I/Qt JAVA (18560): DEBUGGER: waiting for socket at /data/data/org.qtproject.example.MyApp/debug-socket, attempt 0
I/Qt JAVA (18560): DEBUGGER: waiting for socket at /data/data/org.qtproject.example.MyApp/debug-socket, attempt 1
I/Qt JAVA (18560): DEBUGGER: socket ok
I/Qt JAVA (18560): DEBUGGER: Waiting for debug socket connect
I/Qt JAVA (18560): DEBUGGER: go to sleep
I/Qt JAVA (18560): DEBUGGER: Waiting for debug socket connect
I/Qt JAVA (18560): DEBUGGER: go to sleep
I/Qt JAVA (18560): DEBUGGER: Debug socket accepted
I/Qt JAVA (18560): DEBUGGER: Waiting for debug socket connect
I/Qt JAVA (18560): DEBUGGER: go to sleep
I/Qt JAVA (18560): DEBUGGER: Waiting for debug socket connect
I/Qt JAVA (18560): DEBUGGER: go to sleep
I/Qt JAVA (18560): DEBUGGER: Waiting for debug socket connect
I/Qt JAVA (18560): DEBUGGER: go to sleep
I/Qt JAVA (18560): DEBUGGER: Waiting for debug socket connect
I/Qt JAVA (18560): DEBUGGER: go to sleep
I/Qt JAVA (18560): DEBUGGER: Waiting for debug socket connect
I/Qt JAVA (18560): DEBUGGER: go to sleep
I/Qt JAVA (18560): DEBUGGER: Waiting for debug socket connect
I/Qt JAVA (18560): DEBUGGER: go to sleep
I/Qt JAVA (18560): DEBUGGER: Waiting for debug socket connect
I/Qt JAVA (18560): DEBUGGER: go to sleep
I/Qt JAVA (18560): DEBUGGER: Waiting for debug socket connect
I/Qt JAVA (18560): DEBUGGER: go to sleep
I/Qt JAVA (18560): DEBUGGER: Incoming socket OK
I/Qt JAVA (18560): DEBUGGER: Got pid acknowledgment
I/Qt JAVA (18560): DEBUGGER: ping not requested
I/Qt JAVA (18560): DEBUGGER: pong not requested
D/Activity(18560): registerForContextMenu with mFeatureContextMenuListener
W/Qt A11Y (18560): Could not activate platform accessibility.
D/Activity(18560): performCreate Call Injection manager
I/InjectionManager(18560): dispatchOnViewCreated > Target : org.qtproject.qt5.android.bindings.QtActivity isFragment :false
D/OpenGLRenderer(18560): Render dirty regions requested: true
D/libEGL (18560): loaded /vendor/lib/egl/libGLES_mali.so
D/PhoneWindow(18560): FMB isFloatingMenuEnabled mFloatingMenuBtn : null
D/PhoneWindow(18560): FMB isFloatingMenuEnabled return false
I/OpenGLRenderer(18560): Initialized EGL, version 1.4
I/OpenGLRenderer(18560): HWUI protection enabled for context , &this =0xe0c22088 ,&mEglDisplay = 1 , &mEglConfig = -502738276
D/OpenGLRenderer(18560): Get maximum texture size. GL_MAX_TEXTURE_SIZE is 8192
D/OpenGLRenderer(18560): Enabling debug mode 0
D/mali_winsys(18560): new_window_surface returns 0x3000, [1440x2560]-format:1
I/LoadedApk(18560): getClassLoader :dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/org.qtproject.example.MyApp-1/base.apk"],nativeLibraryDirectories=[/data/app/org.qtproject.example.MyApp-1/lib/arm, /vendor/lib, /system/lib]]]
I/InjectionManager(18560): dispatchCreateOptionsMenu :org.qtproject.qt5.android.bindings.QtActivity
I/InjectionManager(18560): dispatchPrepareOptionsMenu :org.qtproject.qt5.android.bindings.QtActivity
I/Timeline(18560): Timeline: Activity_idle id: android.os.BinderProxy@38cebf75 time:182342765
D/libMyApp.so(18560): (null):0 ((null)): QML Debugger: Waiting for connection on port 50111...
D/libMyApp.so(18560): (null):0 ((null)): FT_New_Face failed with index 0 : 90
D/mali_winsys(18560): new_window_surface returns 0x3000, [1440x2560]-format:1
D/mali_winsys(18560): new_window_surface returns 0x3000, [1440x2460]-format:1