Bluetooth projects are crashing / java.lang.ClassNotFoundException: android.graphics.drawable.RippleDrawable



  • Hello There,

    i had to reinstall my Laptop and thereby Qt Creator - since then I can´t run Blue Tooth Apps any more. I tried to search by google, but dind´t found something helpful.

    I have Android 4.4.4,
    Qt Creator 4,4.1 based on Qt 5.9.2
    jdk1.8.0_161
    android-ndk-r10e (also tried latest ndk r13 but then always had the stdlib not found issue)
    Tried both compiling with ANT and gradle
    Compiling against API level 17

    I tried the btchat example out of the box, which worked last time but doesn´t now.
    The calculator example does work.

    During deploying i get following messages:

    W/System.err(20834): java.lang.ClassNotFoundException: android.graphics.drawable.RippleDrawable
    W/System.err(20834): 	at java.lang.Class.classForName(Native Method)
    W/System.err(20834): 	at java.lang.Class.forName(Class.java:251)
    W/System.err(20834): 	at java.lang.Class.forName(Class.java:216)
    W/System.err(20834): 	at org.qtproject.qt5.android.ExtractStyle.getClass(ExtractStyle.java:395)
    W/System.err(20834): 	at org.qtproject.qt5.android.ExtractStyle.<init>(ExtractStyle.java:98)
    W/System.err(20834): 	at org.qtproject.qt5.android.QtActivityDelegate.loadApplication(QtActivityDelegate.java:592)
    W/System.err(20834): 	at java.lang.reflect.Method.invokeNative(Native Method)
    W/System.err(20834): 	at java.lang.reflect.Method.invoke(Method.java:515)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtLoader.loadApplication(QtLoader.java:237)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtLoader.startApp(QtLoader.java:647)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtActivityLoader.onCreate(QtActivityLoader.java:181)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtActivity.onCreateHook(QtActivity.java:266)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtActivity.onCreate(QtActivity.java:273)
    W/System.err(20834): 	at android.app.Activity.performCreate(Activity.java:5231)
    W/System.err(20834): 	at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087)
    W/System.err(20834): 	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2201)
    W/System.err(20834): 	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2286)
    W/System.err(20834): 	at android.app.ActivityThread.access$800(ActivityThread.java:144)
    W/System.err(20834): 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1246)
    W/System.err(20834): 	at android.os.Handler.dispatchMessage(Handler.java:102)
    W/System.err(20834): 	at android.os.Looper.loop(Looper.java:212)
    W/System.err(20834): 	at android.app.ActivityThread.main(ActivityThread.java:5137)
    W/System.err(20834): 	at java.lang.reflect.Method.invokeNative(Native Method)
    W/System.err(20834): 	at java.lang.reflect.Method.invoke(Method.java:515)
    W/System.err(20834): 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:902)
    W/System.err(20834): 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:718)
    W/System.err(20834): 	at dalvik.system.NativeStart.main(Native Method)
    W/System.err(20834): Caused by: java.lang.NoClassDefFoundError: android/graphics/drawable/RippleDrawable
    W/System.err(20834): 	... 27 more
    W/System.err(20834): Caused by: java.lang.ClassNotFoundException: Didn't find class "android.graphics.drawable.RippleDrawable" on path: DexPathList[[zip file "/data/app/org.qtproject.example.calculator-1.apk"],nativeLibraryDirectories=[/data/app-lib/org.qtproject.example.calculator-1, /vendor/lib, /system/lib]]
    W/System.err(20834): 	at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
    W/System.err(20834): 	at java.lang.ClassLoader.loadClass(ClassLoader.java:497)
    W/System.err(20834): 	at java.lang.ClassLoader.loadClass(ClassLoader.java:457)
    W/System.err(20834): 	... 27 more
    W/System.err(20834): java.lang.ClassNotFoundException: android.graphics.drawable.AnimatedStateListDrawable
    W/System.err(20834): 	at java.lang.Class.classForName(Native Method)
    W/System.err(20834): 	at java.lang.Class.forName(Class.java:251)
    W/System.err(20834): 	at java.lang.Class.forName(Class.java:216)
    W/System.err(20834): 	at org.qtproject.qt5.android.ExtractStyle.getClass(ExtractStyle.java:395)
    W/System.err(20834): 	at org.qtproject.qt5.android.ExtractStyle.<init>(ExtractStyle.java:99)
    W/System.err(20834): 	at org.qtproject.qt5.android.QtActivityDelegate.loadApplication(QtActivityDelegate.java:592)
    W/System.err(20834): 	at java.lang.reflect.Method.invokeNative(Native Method)
    W/System.err(20834): 	at java.lang.reflect.Method.invoke(Method.java:515)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtLoader.loadApplication(QtLoader.java:237)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtLoader.startApp(QtLoader.java:647)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtActivityLoader.onCreate(QtActivityLoader.java:181)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtActivity.onCreateHook(QtActivity.java:266)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtActivity.onCreate(QtActivity.java:273)
    W/System.err(20834): 	at android.app.Activity.performCreate(Activity.java:5231)
    W/System.err(20834): 	at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087)
    W/System.err(20834): 	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2201)
    W/System.err(20834): 	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2286)
    W/System.err(20834): 	at android.app.ActivityThread.access$800(ActivityThread.java:144)
    W/System.err(20834): 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1246)
    W/System.err(20834): 	at android.os.Handler.dispatchMessage(Handler.java:102)
    W/System.err(20834): 	at android.os.Looper.loop(Looper.java:212)
    W/System.err(20834): 	at android.app.ActivityThread.main(ActivityThread.java:5137)
    W/System.err(20834): 	at java.lang.reflect.Method.invokeNative(Native Method)
    W/System.err(20834): 	at java.lang.reflect.Method.invoke(Method.java:515)
    W/System.err(20834): 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:902)
    W/System.err(20834): 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:718)
    W/System.err(20834): 	at dalvik.system.NativeStart.main(Native Method)
    W/System.err(20834): Caused by: java.lang.NoClassDefFoundError: android/graphics/drawable/AnimatedStateListDrawable
    W/System.err(20834): 	... 27 more
    W/System.err(20834): Caused by: java.lang.ClassNotFoundException: Didn't find class "android.graphics.drawable.AnimatedStateListDrawable" on path: DexPathList[[zip file "/data/app/org.qtproject.example.calculator-1.apk"],nativeLibraryDirectories=[/data/app-lib/org.qtproject.example.calculator-1, /vendor/lib, /system/lib]]
    W/System.err(20834): 	at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
    W/System.err(20834): 	at java.lang.ClassLoader.loadClass(ClassLoader.java:497)
    W/System.err(20834): 	at java.lang.ClassLoader.loadClass(ClassLoader.java:457)
    W/System.err(20834): 	... 27 more
    W/System.err(20834): java.lang.ClassNotFoundException: android.graphics.drawable.VectorDrawable
    W/System.err(20834): 	at java.lang.Class.classForName(Native Method)
    W/System.err(20834): 	at java.lang.Class.forName(Class.java:251)
    W/System.err(20834): 	at java.lang.Class.forName(Class.java:216)
    W/System.err(20834): 	at org.qtproject.qt5.android.ExtractStyle.getClass(ExtractStyle.java:395)
    W/System.err(20834): 	at org.qtproject.qt5.android.ExtractStyle.<init>(ExtractStyle.java:100)
    W/System.err(20834): 	at org.qtproject.qt5.android.QtActivityDelegate.loadApplication(QtActivityDelegate.java:592)
    W/System.err(20834): 	at java.lang.reflect.Method.invokeNative(Native Method)
    W/System.err(20834): 	at java.lang.reflect.Method.invoke(Method.java:515)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtLoader.loadApplication(QtLoader.java:237)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtLoader.startApp(QtLoader.java:647)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtActivityLoader.onCreate(QtActivityLoader.java:181)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtActivity.onCreateHook(QtActivity.java:266)
    W/System.err(20834): 	at org.qtproject.qt5.android.bindings.QtActivity.onCreate(QtActivity.java:273)
    W/System.err(20834): 	at android.app.Activity.performCreate(Activity.java:5231)
    W/System.err(20834): 	at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087)
    W/System.err(20834): 	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2201)
    W/System.err(20834): 	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2286)
    W/System.err(20834): 	at android.app.ActivityThread.access$800(ActivityThread.java:144)
    W/System.err(20834): 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1246)
    W/System.err(20834): 	at android.os.Handler.dispatchMessage(Handler.java:102)
    W/System.err(20834): 	at android.os.Looper.loop(Looper.java:212)
    W/System.err(20834): 	at android.app.ActivityThread.main(ActivityThread.java:5137)
    W/System.err(20834): 	at java.lang.reflect.Method.invokeNative(Native Method)
    W/System.err(20834): 	at java.lang.reflect.Method.invoke(Method.java:515)
    W/System.err(20834): 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:902)
    W/System.err(20834): 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:718)
    W/System.err(20834): 	at dalvik.system.NativeStart.main(Native Method)
    W/System.err(20834): Caused by: java.lang.NoClassDefFoundError: android/graphics/drawable/VectorDrawable
    W/System.err(20834): 	... 27 more
    W/System.err(20834): Caused by: java.lang.ClassNotFoundException: Didn't find class "android.graphics.drawable.VectorDrawable" on path: DexPathList[[zip file "/data/app/org.qtproject.example.calculator-1.apk"],nativeLibraryDirectories=[/data/app-lib/org.qtproject.example.calculator-1, /vendor/lib, /system/lib]]
    W/System.err(20834): 	at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
    W/System.err(20834): 	at java.lang.ClassLoader.loadClass(ClassLoader.java:497)
    W/System.err(20834): 	at java.lang.ClassLoader.loadClass(ClassLoader.java:457)
    W/System.err(20834): 	... 27 more
    W/ResourceType(20834): Skipping entry 0x108057a in package table 0 because it is not complex!
    D/dalvikvm(20834): GC_CONCURRENT freed 2599K, 6% free 59290K/62792K, paused 3ms+1ms, total 22ms
    D/dalvikvm(20834): Trying to load lib /data/app-lib/org.qtproject.example.calculator-1/libcalculator.so 0x447e0df0
    D/dalvikvm(20834): Added shared lib /data/app-lib/org.qtproject.example.calculator-1/libcalculator.so 0x447e0df0
    D/dalvikvm(20834): No JNI_OnLoad found in /data/app-lib/org.qtproject.example.calculator-1/libcalculator.so 0x447e0df0, skipping init
    I/Adreno-EGL(20834): <qeglDrvAPI_eglInitialize:410>: EGL 1.4 QUALCOMM build: RGURRAM_AU_LINUX_ANDROID_LNX.LA.3.5.2.2_RB1.04.04.04.087.030+PATCH[ES]_msm8974_LNX.LA.3.5.2.2_RB1__release_ENGG ()
    I/Adreno-EGL(20834): OpenGL ES Shader Compiler Version: E031.24.00.15
    I/Adreno-EGL(20834): Build Date: 08/12/14 Tue
    I/Adreno-EGL(20834): Local Branch:
    I/Adreno-EGL(20834): Remote Branch: quic/LNX.LA.3.5.2.2_rb1
    I/Adreno-EGL(20834): Local Patches: 8b00bd16f3c1d9d35a2fa902df5e679888d2b2e3 Fixes an llvm crash with mini dEQP apk
    I/Adreno-EGL(20834):                  38bad22e162dead4e008444520a0144c78a347bd Fixes a potential dEQP crash.
    I/Adreno-EGL(20834):                  ce345e1c45c2ae2d1fb2cb125c8d2574f1af5f95 Rev
    D/OpenGLRenderer(20834): Enabling debug mode 0
    I/Timeline(20834): Timeline: Activity_idle id: android.os.BinderProxy@447a0298 time:30406791
    I/ActivityManager(  938): Process org.qtproject.example.calculator (pid 20834) has died.
    
    
    "org.qtproject.example.calculator" died.
    

    Does someone have an idea?

    best regards!


  • Moderators

    @Flaming-Moe
    RippleDrawable is available since API 21. If you are compiling against an older API you should use the corresponding support library (in your build.gradle file).



  • @Flaming-Moe I am having the same issue. Have you solved your problem?


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.